com.evernote.edam.type
Class Accounting

java.lang.Object
  extended by com.evernote.edam.type.Accounting
All Implemented Interfaces:
com.evernote.thrift.TBase<Accounting>, java.io.Serializable, java.lang.Cloneable, java.lang.Comparable<Accounting>

public class Accounting
extends java.lang.Object
implements com.evernote.thrift.TBase<Accounting>, java.io.Serializable, java.lang.Cloneable

This represents the bookkeeping information for the user's subscription.

uploadLimit
The number of bytes that can be uploaded to the account in the current month. For new notes that are created, this is the length of the note content (in Unicode characters) plus the size of each resource (in bytes). For edited notes, this is the the difference between the old length and the new length (if this is greater than 0) plus the size of each new resource.
uploadLimitEnd
The date and time when the current upload limit expires. At this time, the monthly upload count reverts to 0 and a new limit is imposed. This date and time is exclusive, so this is effectively the start of the new month.
uploadLimitNextMonth
When uploadLimitEnd is reached, the service will change uploadLimit to uploadLimitNextMonth. If a premium account is canceled, this mechanism will reset the quota appropriately.
premiumServiceStatus
Indicates the phases of a premium account during the billing process.
premiumOrderNumber
The order number used by the commerce system to process recurring payments
premiumServiceStart
The start date when this premium promotion began (this number will get overwritten if a premium service is canceled and then re-activated).
premiumCommerceService
The commerce system used (paypal, Google checkout, etc)
premiumServiceSKU
The code associated with the purchase eg. monthly or annual purchase. Clients should interpret this value and localize it.
lastSuccessfulCharge
Date the last time the user was charged. Null if never charged.
lastFailedCharge
Date the last time a charge was attempted and failed.
lastFailedChargeReason
Reason provided for the charge failure
nextPaymentDue
The end of the billing cycle. This could be in the past if there are failed charges.
premiumLockUntil
An internal variable to manage locking operations on the commerce variables.
updated
The date any modification where made to this record.
premiumSubscriptionNumber
The number number identifying the recurring subscription used to make the recurring charges.
lastRequestedCharge
Date charge last attempted
currency
ISO 4217 currency code
unitPrice
charge in the smallest unit of the currency (e.g. cents for USD)
businessId
DEPRECATED:See BusinessUserInfo.
businessName
DEPRECATED:See BusinessUserInfo.
businessRole
DEPRECATED:See BusinessUserInfo.
unitDiscount
discount per seat in negative amount and smallest unit of the currency (e.g. cents for USD)
nextChargeDate
The next time the user will be charged, may or may not be the same as nextPaymentDue

See Also:
Serialized Form

Constructor Summary
Accounting()
           
Accounting(Accounting other)
          Performs a deep copy on other.
 
Method Summary
 void clear()
          Return to the state of having just been initialized, as though you had just called the default constructor.
 int compareTo(Accounting other)
           
 Accounting deepCopy()
          Creates a deep copy of the object.
 boolean equals(Accounting that)
           
 boolean equals(java.lang.Object that)
           
 int getBusinessId()
           
 java.lang.String getBusinessName()
           
 BusinessUserRole getBusinessRole()
           
 java.lang.String getCurrency()
           
 long getLastFailedCharge()
           
 java.lang.String getLastFailedChargeReason()
           
 long getLastRequestedCharge()
           
 long getLastSuccessfulCharge()
           
 long getNextChargeDate()
           
 long getNextPaymentDue()
           
 java.lang.String getPremiumCommerceService()
           
 long getPremiumLockUntil()
           
 java.lang.String getPremiumOrderNumber()
           
 java.lang.String getPremiumServiceSKU()
           
 long getPremiumServiceStart()
           
 PremiumOrderStatus getPremiumServiceStatus()
           
 java.lang.String getPremiumSubscriptionNumber()
           
 int getUnitDiscount()
           
 int getUnitPrice()
           
 long getUpdated()
           
 long getUploadLimit()
           
 long getUploadLimitEnd()
           
 long getUploadLimitNextMonth()
           
 int hashCode()
           
 boolean isSetBusinessId()
          Returns true if field businessId is set (has been asigned a value) and false otherwise
 boolean isSetBusinessName()
          Returns true if field businessName is set (has been asigned a value) and false otherwise
 boolean isSetBusinessRole()
          Returns true if field businessRole is set (has been asigned a value) and false otherwise
 boolean isSetCurrency()
          Returns true if field currency is set (has been asigned a value) and false otherwise
 boolean isSetLastFailedCharge()
          Returns true if field lastFailedCharge is set (has been asigned a value) and false otherwise
 boolean isSetLastFailedChargeReason()
          Returns true if field lastFailedChargeReason is set (has been asigned a value) and false otherwise
 boolean isSetLastRequestedCharge()
          Returns true if field lastRequestedCharge is set (has been asigned a value) and false otherwise
 boolean isSetLastSuccessfulCharge()
          Returns true if field lastSuccessfulCharge is set (has been asigned a value) and false otherwise
 boolean isSetNextChargeDate()
          Returns true if field nextChargeDate is set (has been asigned a value) and false otherwise
 boolean isSetNextPaymentDue()
          Returns true if field nextPaymentDue is set (has been asigned a value) and false otherwise
 boolean isSetPremiumCommerceService()
          Returns true if field premiumCommerceService is set (has been asigned a value) and false otherwise
 boolean isSetPremiumLockUntil()
          Returns true if field premiumLockUntil is set (has been asigned a value) and false otherwise
 boolean isSetPremiumOrderNumber()
          Returns true if field premiumOrderNumber is set (has been asigned a value) and false otherwise
 boolean isSetPremiumServiceSKU()
          Returns true if field premiumServiceSKU is set (has been asigned a value) and false otherwise
 boolean isSetPremiumServiceStart()
          Returns true if field premiumServiceStart is set (has been asigned a value) and false otherwise
 boolean isSetPremiumServiceStatus()
          Returns true if field premiumServiceStatus is set (has been asigned a value) and false otherwise
 boolean isSetPremiumSubscriptionNumber()
          Returns true if field premiumSubscriptionNumber is set (has been asigned a value) and false otherwise
 boolean isSetUnitDiscount()
          Returns true if field unitDiscount is set (has been asigned a value) and false otherwise
 boolean isSetUnitPrice()
          Returns true if field unitPrice is set (has been asigned a value) and false otherwise
 boolean isSetUpdated()
          Returns true if field updated is set (has been asigned a value) and false otherwise
 boolean isSetUploadLimit()
          Returns true if field uploadLimit is set (has been asigned a value) and false otherwise
 boolean isSetUploadLimitEnd()
          Returns true if field uploadLimitEnd is set (has been asigned a value) and false otherwise
 boolean isSetUploadLimitNextMonth()
          Returns true if field uploadLimitNextMonth is set (has been asigned a value) and false otherwise
 void read(com.evernote.thrift.protocol.TProtocol iprot)
          Reads an instance of the object from the given protocol.
 void setBusinessId(int businessId)
           
 void setBusinessIdIsSet(boolean value)
           
 void setBusinessName(java.lang.String businessName)
           
 void setBusinessNameIsSet(boolean value)
           
 void setBusinessRole(BusinessUserRole businessRole)
           
 void setBusinessRoleIsSet(boolean value)
           
 void setCurrency(java.lang.String currency)
           
 void setCurrencyIsSet(boolean value)
           
 void setLastFailedCharge(long lastFailedCharge)
           
 void setLastFailedChargeIsSet(boolean value)
           
 void setLastFailedChargeReason(java.lang.String lastFailedChargeReason)
           
 void setLastFailedChargeReasonIsSet(boolean value)
           
 void setLastRequestedCharge(long lastRequestedCharge)
           
 void setLastRequestedChargeIsSet(boolean value)
           
 void setLastSuccessfulCharge(long lastSuccessfulCharge)
           
 void setLastSuccessfulChargeIsSet(boolean value)
           
 void setNextChargeDate(long nextChargeDate)
           
 void setNextChargeDateIsSet(boolean value)
           
 void setNextPaymentDue(long nextPaymentDue)
           
 void setNextPaymentDueIsSet(boolean value)
           
 void setPremiumCommerceService(java.lang.String premiumCommerceService)
           
 void setPremiumCommerceServiceIsSet(boolean value)
           
 void setPremiumLockUntil(long premiumLockUntil)
           
 void setPremiumLockUntilIsSet(boolean value)
           
 void setPremiumOrderNumber(java.lang.String premiumOrderNumber)
           
 void setPremiumOrderNumberIsSet(boolean value)
           
 void setPremiumServiceSKU(java.lang.String premiumServiceSKU)
           
 void setPremiumServiceSKUIsSet(boolean value)
           
 void setPremiumServiceStart(long premiumServiceStart)
           
 void setPremiumServiceStartIsSet(boolean value)
           
 void setPremiumServiceStatus(PremiumOrderStatus premiumServiceStatus)
           
 void setPremiumServiceStatusIsSet(boolean value)
           
 void setPremiumSubscriptionNumber(java.lang.String premiumSubscriptionNumber)
           
 void setPremiumSubscriptionNumberIsSet(boolean value)
           
 void setUnitDiscount(int unitDiscount)
           
 void setUnitDiscountIsSet(boolean value)
           
 void setUnitPrice(int unitPrice)
           
 void setUnitPriceIsSet(boolean value)
           
 void setUpdated(long updated)
           
 void setUpdatedIsSet(boolean value)
           
 void setUploadLimit(long uploadLimit)
           
 void setUploadLimitEnd(long uploadLimitEnd)
           
 void setUploadLimitEndIsSet(boolean value)
           
 void setUploadLimitIsSet(boolean value)
           
 void setUploadLimitNextMonth(long uploadLimitNextMonth)
           
 void setUploadLimitNextMonthIsSet(boolean value)
           
 java.lang.String toString()
           
 void unsetBusinessId()
           
 void unsetBusinessName()
           
 void unsetBusinessRole()
           
 void unsetCurrency()
           
 void unsetLastFailedCharge()
           
 void unsetLastFailedChargeReason()
           
 void unsetLastRequestedCharge()
           
 void unsetLastSuccessfulCharge()
           
 void unsetNextChargeDate()
           
 void unsetNextPaymentDue()
           
 void unsetPremiumCommerceService()
           
 void unsetPremiumLockUntil()
           
 void unsetPremiumOrderNumber()
           
 void unsetPremiumServiceSKU()
           
 void unsetPremiumServiceStart()
           
 void unsetPremiumServiceStatus()
           
 void unsetPremiumSubscriptionNumber()
           
 void unsetUnitDiscount()
           
 void unsetUnitPrice()
           
 void unsetUpdated()
           
 void unsetUploadLimit()
           
 void unsetUploadLimitEnd()
           
 void unsetUploadLimitNextMonth()
           
 void validate()
           
 void write(com.evernote.thrift.protocol.TProtocol oprot)
          Writes the object to the given protocol.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Accounting

public Accounting()

Accounting

public Accounting(Accounting other)
Performs a deep copy on other.

Method Detail

deepCopy

public Accounting deepCopy()
Description copied from interface: com.evernote.thrift.TBase
Creates a deep copy of the object.

Specified by:
deepCopy in interface com.evernote.thrift.TBase<Accounting>

clear

public void clear()
Description copied from interface: com.evernote.thrift.TBase
Return to the state of having just been initialized, as though you had just called the default constructor.

Specified by:
clear in interface com.evernote.thrift.TBase<Accounting>

getUploadLimit

public long getUploadLimit()

setUploadLimit

public void setUploadLimit(long uploadLimit)

unsetUploadLimit

public void unsetUploadLimit()

isSetUploadLimit

public boolean isSetUploadLimit()
Returns true if field uploadLimit is set (has been asigned a value) and false otherwise


setUploadLimitIsSet

public void setUploadLimitIsSet(boolean value)

getUploadLimitEnd

public long getUploadLimitEnd()

setUploadLimitEnd

public void setUploadLimitEnd(long uploadLimitEnd)

unsetUploadLimitEnd

public void unsetUploadLimitEnd()

isSetUploadLimitEnd

public boolean isSetUploadLimitEnd()
Returns true if field uploadLimitEnd is set (has been asigned a value) and false otherwise


setUploadLimitEndIsSet

public void setUploadLimitEndIsSet(boolean value)

getUploadLimitNextMonth

public long getUploadLimitNextMonth()

setUploadLimitNextMonth

public void setUploadLimitNextMonth(long uploadLimitNextMonth)

unsetUploadLimitNextMonth

public void unsetUploadLimitNextMonth()

isSetUploadLimitNextMonth

public boolean isSetUploadLimitNextMonth()
Returns true if field uploadLimitNextMonth is set (has been asigned a value) and false otherwise


setUploadLimitNextMonthIsSet

public void setUploadLimitNextMonthIsSet(boolean value)

getPremiumServiceStatus

public PremiumOrderStatus getPremiumServiceStatus()
See Also:
PremiumOrderStatus

setPremiumServiceStatus

public void setPremiumServiceStatus(PremiumOrderStatus premiumServiceStatus)
See Also:
PremiumOrderStatus

unsetPremiumServiceStatus

public void unsetPremiumServiceStatus()

isSetPremiumServiceStatus

public boolean isSetPremiumServiceStatus()
Returns true if field premiumServiceStatus is set (has been asigned a value) and false otherwise


setPremiumServiceStatusIsSet

public void setPremiumServiceStatusIsSet(boolean value)

getPremiumOrderNumber

public java.lang.String getPremiumOrderNumber()

setPremiumOrderNumber

public void setPremiumOrderNumber(java.lang.String premiumOrderNumber)

unsetPremiumOrderNumber

public void unsetPremiumOrderNumber()

isSetPremiumOrderNumber

public boolean isSetPremiumOrderNumber()
Returns true if field premiumOrderNumber is set (has been asigned a value) and false otherwise


setPremiumOrderNumberIsSet

public void setPremiumOrderNumberIsSet(boolean value)

getPremiumCommerceService

public java.lang.String getPremiumCommerceService()

setPremiumCommerceService

public void setPremiumCommerceService(java.lang.String premiumCommerceService)

unsetPremiumCommerceService

public void unsetPremiumCommerceService()

isSetPremiumCommerceService

public boolean isSetPremiumCommerceService()
Returns true if field premiumCommerceService is set (has been asigned a value) and false otherwise


setPremiumCommerceServiceIsSet

public void setPremiumCommerceServiceIsSet(boolean value)

getPremiumServiceStart

public long getPremiumServiceStart()

setPremiumServiceStart

public void setPremiumServiceStart(long premiumServiceStart)

unsetPremiumServiceStart

public void unsetPremiumServiceStart()

isSetPremiumServiceStart

public boolean isSetPremiumServiceStart()
Returns true if field premiumServiceStart is set (has been asigned a value) and false otherwise


setPremiumServiceStartIsSet

public void setPremiumServiceStartIsSet(boolean value)

getPremiumServiceSKU

public java.lang.String getPremiumServiceSKU()

setPremiumServiceSKU

public void setPremiumServiceSKU(java.lang.String premiumServiceSKU)

unsetPremiumServiceSKU

public void unsetPremiumServiceSKU()

isSetPremiumServiceSKU

public boolean isSetPremiumServiceSKU()
Returns true if field premiumServiceSKU is set (has been asigned a value) and false otherwise


setPremiumServiceSKUIsSet

public void setPremiumServiceSKUIsSet(boolean value)

getLastSuccessfulCharge

public long getLastSuccessfulCharge()

setLastSuccessfulCharge

public void setLastSuccessfulCharge(long lastSuccessfulCharge)

unsetLastSuccessfulCharge

public void unsetLastSuccessfulCharge()

isSetLastSuccessfulCharge

public boolean isSetLastSuccessfulCharge()
Returns true if field lastSuccessfulCharge is set (has been asigned a value) and false otherwise


setLastSuccessfulChargeIsSet

public void setLastSuccessfulChargeIsSet(boolean value)

getLastFailedCharge

public long getLastFailedCharge()

setLastFailedCharge

public void setLastFailedCharge(long lastFailedCharge)

unsetLastFailedCharge

public void unsetLastFailedCharge()

isSetLastFailedCharge

public boolean isSetLastFailedCharge()
Returns true if field lastFailedCharge is set (has been asigned a value) and false otherwise


setLastFailedChargeIsSet

public void setLastFailedChargeIsSet(boolean value)

getLastFailedChargeReason

public java.lang.String getLastFailedChargeReason()

setLastFailedChargeReason

public void setLastFailedChargeReason(java.lang.String lastFailedChargeReason)

unsetLastFailedChargeReason

public void unsetLastFailedChargeReason()

isSetLastFailedChargeReason

public boolean isSetLastFailedChargeReason()
Returns true if field lastFailedChargeReason is set (has been asigned a value) and false otherwise


setLastFailedChargeReasonIsSet

public void setLastFailedChargeReasonIsSet(boolean value)

getNextPaymentDue

public long getNextPaymentDue()

setNextPaymentDue

public void setNextPaymentDue(long nextPaymentDue)

unsetNextPaymentDue

public void unsetNextPaymentDue()

isSetNextPaymentDue

public boolean isSetNextPaymentDue()
Returns true if field nextPaymentDue is set (has been asigned a value) and false otherwise


setNextPaymentDueIsSet

public void setNextPaymentDueIsSet(boolean value)

getPremiumLockUntil

public long getPremiumLockUntil()

setPremiumLockUntil

public void setPremiumLockUntil(long premiumLockUntil)

unsetPremiumLockUntil

public void unsetPremiumLockUntil()

isSetPremiumLockUntil

public boolean isSetPremiumLockUntil()
Returns true if field premiumLockUntil is set (has been asigned a value) and false otherwise


setPremiumLockUntilIsSet

public void setPremiumLockUntilIsSet(boolean value)

getUpdated

public long getUpdated()

setUpdated

public void setUpdated(long updated)

unsetUpdated

public void unsetUpdated()

isSetUpdated

public boolean isSetUpdated()
Returns true if field updated is set (has been asigned a value) and false otherwise


setUpdatedIsSet

public void setUpdatedIsSet(boolean value)

getPremiumSubscriptionNumber

public java.lang.String getPremiumSubscriptionNumber()

setPremiumSubscriptionNumber

public void setPremiumSubscriptionNumber(java.lang.String premiumSubscriptionNumber)

unsetPremiumSubscriptionNumber

public void unsetPremiumSubscriptionNumber()

isSetPremiumSubscriptionNumber

public boolean isSetPremiumSubscriptionNumber()
Returns true if field premiumSubscriptionNumber is set (has been asigned a value) and false otherwise


setPremiumSubscriptionNumberIsSet

public void setPremiumSubscriptionNumberIsSet(boolean value)

getLastRequestedCharge

public long getLastRequestedCharge()

setLastRequestedCharge

public void setLastRequestedCharge(long lastRequestedCharge)

unsetLastRequestedCharge

public void unsetLastRequestedCharge()

isSetLastRequestedCharge

public boolean isSetLastRequestedCharge()
Returns true if field lastRequestedCharge is set (has been asigned a value) and false otherwise


setLastRequestedChargeIsSet

public void setLastRequestedChargeIsSet(boolean value)

getCurrency

public java.lang.String getCurrency()

setCurrency

public void setCurrency(java.lang.String currency)

unsetCurrency

public void unsetCurrency()

isSetCurrency

public boolean isSetCurrency()
Returns true if field currency is set (has been asigned a value) and false otherwise


setCurrencyIsSet

public void setCurrencyIsSet(boolean value)

getUnitPrice

public int getUnitPrice()

setUnitPrice

public void setUnitPrice(int unitPrice)

unsetUnitPrice

public void unsetUnitPrice()

isSetUnitPrice

public boolean isSetUnitPrice()
Returns true if field unitPrice is set (has been asigned a value) and false otherwise


setUnitPriceIsSet

public void setUnitPriceIsSet(boolean value)

getBusinessId

public int getBusinessId()

setBusinessId

public void setBusinessId(int businessId)

unsetBusinessId

public void unsetBusinessId()

isSetBusinessId

public boolean isSetBusinessId()
Returns true if field businessId is set (has been asigned a value) and false otherwise


setBusinessIdIsSet

public void setBusinessIdIsSet(boolean value)

getBusinessName

public java.lang.String getBusinessName()

setBusinessName

public void setBusinessName(java.lang.String businessName)

unsetBusinessName

public void unsetBusinessName()

isSetBusinessName

public boolean isSetBusinessName()
Returns true if field businessName is set (has been asigned a value) and false otherwise


setBusinessNameIsSet

public void setBusinessNameIsSet(boolean value)

getBusinessRole

public BusinessUserRole getBusinessRole()
See Also:
BusinessUserRole

setBusinessRole

public void setBusinessRole(BusinessUserRole businessRole)
See Also:
BusinessUserRole

unsetBusinessRole

public void unsetBusinessRole()

isSetBusinessRole

public boolean isSetBusinessRole()
Returns true if field businessRole is set (has been asigned a value) and false otherwise


setBusinessRoleIsSet

public void setBusinessRoleIsSet(boolean value)

getUnitDiscount

public int getUnitDiscount()

setUnitDiscount

public void setUnitDiscount(int unitDiscount)

unsetUnitDiscount

public void unsetUnitDiscount()

isSetUnitDiscount

public boolean isSetUnitDiscount()
Returns true if field unitDiscount is set (has been asigned a value) and false otherwise


setUnitDiscountIsSet

public void setUnitDiscountIsSet(boolean value)

getNextChargeDate

public long getNextChargeDate()

setNextChargeDate

public void setNextChargeDate(long nextChargeDate)

unsetNextChargeDate

public void unsetNextChargeDate()

isSetNextChargeDate

public boolean isSetNextChargeDate()
Returns true if field nextChargeDate is set (has been asigned a value) and false otherwise


setNextChargeDateIsSet

public void setNextChargeDateIsSet(boolean value)

equals

public boolean equals(java.lang.Object that)
Overrides:
equals in class java.lang.Object

equals

public boolean equals(Accounting that)

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

compareTo

public int compareTo(Accounting other)
Specified by:
compareTo in interface java.lang.Comparable<Accounting>

read

public void read(com.evernote.thrift.protocol.TProtocol iprot)
          throws com.evernote.thrift.TException
Description copied from interface: com.evernote.thrift.TBase
Reads an instance of the object from the given protocol.

Specified by:
read in interface com.evernote.thrift.TBase<Accounting>
Parameters:
iprot - Input protocol
Throws:
com.evernote.thrift.TException

write

public void write(com.evernote.thrift.protocol.TProtocol oprot)
           throws com.evernote.thrift.TException
Description copied from interface: com.evernote.thrift.TBase
Writes the object to the given protocol.

Specified by:
write in interface com.evernote.thrift.TBase<Accounting>
Parameters:
oprot - Output protocol
Throws:
com.evernote.thrift.TException

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

validate

public void validate()
              throws com.evernote.thrift.TException
Throws:
com.evernote.thrift.TException