public class SummaryGroup extends GenericParcelable implements Validator, JSONifiable
Modifier and Type | Class and Description |
---|---|
static interface |
SummaryGroup.Constraints |
JSONifiable.Creator<T>
Parcelable.ClassLoaderCreator<T>, Parcelable.Creator<T>
Modifier and Type | Field and Description |
---|---|
static Parcelable.Creator<SummaryGroup> |
CREATOR |
static JSONifiable.Creator<SummaryGroup> |
JSON_CREATOR |
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE
Modifier | Constructor and Description |
---|---|
|
SummaryGroup()
Constructs a new empty instance.
|
protected |
SummaryGroup(boolean noInit)
Constructs a new empty instance.
|
|
SummaryGroup(JSONObject jsonObject)
Construct a new instance backed by the given JSONObject, the parameter is not copied so changes to it will be
reflected in this instance and vice-versa.
|
|
SummaryGroup(String json)
Constructs a new instance from the given JSON String.
|
|
SummaryGroup(SummaryGroup src)
Constructs a new instance that is a deep copy of the source instance.
|
Modifier and Type | Method and Description |
---|---|
void |
clearCreditsSummary()
Clears the 'creditsSummary' field, the 'has' method for this field will now return false
|
void |
clearDiscountsSummary()
Clears the 'discountsSummary' field, the 'has' method for this field will now return false
|
void |
clearId()
Clears the 'id' field, the 'has' method for this field will now return false
|
void |
clearPaymentsSummary()
Clears the 'paymentsSummary' field, the 'has' method for this field will now return false
|
void |
clearRefundsSummary()
Clears the 'refundsSummary' field, the 'has' method for this field will now return false
|
void |
clearSummaryObject()
Clears the 'summaryObject' field, the 'has' method for this field will now return false
|
boolean |
containsChanges()
Returns true if this instance has any changes.
|
SummaryGroup |
copyChanges()
Create a copy of this instance that contains only fields that were set after the constructor was called.
|
Summary |
getCreditsSummary() |
Summary |
getDiscountsSummary() |
protected GenericClient |
getGenericClient() |
String |
getId() |
JSONObject |
getJSONObject()
Returns the internal JSONObject backing this instance, the return value is not a copy so changes to it will be
reflected in this instance and vice-versa.
|
Summary |
getPaymentsSummary() |
Summary |
getRefundsSummary() |
Reference |
getSummaryObject() |
boolean |
hasCreditsSummary()
Checks whether the 'creditsSummary' field has been set, however the value could be null
|
boolean |
hasDiscountsSummary()
Checks whether the 'discountsSummary' field has been set, however the value could be null
|
boolean |
hasId()
Checks whether the 'id' field has been set, however the value could be null
|
boolean |
hasPaymentsSummary()
Checks whether the 'paymentsSummary' field has been set, however the value could be null
|
boolean |
hasRefundsSummary()
Checks whether the 'refundsSummary' field has been set, however the value could be null
|
boolean |
hasSummaryObject()
Checks whether the 'summaryObject' field has been set, however the value could be null
|
boolean |
isNotNullCreditsSummary()
Checks whether the 'creditsSummary' field is set and is not null
|
boolean |
isNotNullDiscountsSummary()
Checks whether the 'discountsSummary' field is set and is not null
|
boolean |
isNotNullId()
Checks whether the 'id' field is set and is not null
|
boolean |
isNotNullPaymentsSummary()
Checks whether the 'paymentsSummary' field is set and is not null
|
boolean |
isNotNullRefundsSummary()
Checks whether the 'refundsSummary' field is set and is not null
|
boolean |
isNotNullSummaryObject()
Checks whether the 'summaryObject' field is set and is not null
|
void |
mergeChanges(SummaryGroup src)
Copy all the changed fields from the given source to this instance.
|
void |
resetChangeLog()
Reset the log of changes made to this instance, calling copyChanges() after this would return an empty instance.
|
SummaryGroup |
setCreditsSummary(Summary creditsSummary)
Sets the field 'creditsSummary'.
|
SummaryGroup |
setDiscountsSummary(Summary discountsSummary)
Sets the field 'discountsSummary'.
|
SummaryGroup |
setId(String id)
Sets the field 'id'.
|
SummaryGroup |
setPaymentsSummary(Summary paymentsSummary)
Sets the field 'paymentsSummary'.
|
SummaryGroup |
setRefundsSummary(Summary refundsSummary)
Sets the field 'refundsSummary'.
|
SummaryGroup |
setSummaryObject(Reference summaryObject)
Sets the field 'summaryObject'.
|
void |
validate() |
describeContents, getBundle, toString, writeToParcel
public static final Parcelable.Creator<SummaryGroup> CREATOR
public static final JSONifiable.Creator<SummaryGroup> JSON_CREATOR
public SummaryGroup()
protected SummaryGroup(boolean noInit)
public SummaryGroup(String json) throws IllegalArgumentException
IllegalArgumentException
public SummaryGroup(JSONObject jsonObject)
public SummaryGroup(SummaryGroup src)
public String getId()
public Reference getSummaryObject()
public Summary getPaymentsSummary()
public Summary getRefundsSummary()
public Summary getCreditsSummary()
public Summary getDiscountsSummary()
protected GenericClient getGenericClient()
getGenericClient
in class GenericParcelable
public JSONObject getJSONObject()
getJSONObject
in interface JSONifiable
public boolean isNotNullId()
public boolean isNotNullSummaryObject()
public boolean isNotNullPaymentsSummary()
public boolean isNotNullRefundsSummary()
public boolean isNotNullCreditsSummary()
public boolean isNotNullDiscountsSummary()
public boolean hasId()
public boolean hasSummaryObject()
public boolean hasPaymentsSummary()
public boolean hasRefundsSummary()
public boolean hasCreditsSummary()
public boolean hasDiscountsSummary()
public SummaryGroup setId(String id)
public SummaryGroup setSummaryObject(Reference summaryObject)
public SummaryGroup setPaymentsSummary(Summary paymentsSummary)
public SummaryGroup setRefundsSummary(Summary refundsSummary)
public SummaryGroup setCreditsSummary(Summary creditsSummary)
public SummaryGroup setDiscountsSummary(Summary discountsSummary)
public void clearId()
public void clearSummaryObject()
public void clearPaymentsSummary()
public void clearRefundsSummary()
public void clearCreditsSummary()
public void clearDiscountsSummary()
public boolean containsChanges()
public void resetChangeLog()
public SummaryGroup copyChanges()
public void mergeChanges(SummaryGroup src)