Package com.clover.sdk.v3.report
Class BaseSale
- java.lang.Object
-
- com.clover.sdk.GenericParcelable
-
- com.clover.sdk.v3.report.BaseSale
-
- All Implemented Interfaces:
Parcelable
,JSONifiable
,Validator
public class BaseSale extends GenericParcelable implements Validator, JSONifiable
This is an auto-generated Clover data object.Fields
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
BaseSale.Constraints
-
Nested classes/interfaces inherited from interface com.clover.sdk.JSONifiable
JSONifiable.Creator<T>
-
Nested classes/interfaces inherited from interface android.os.Parcelable
Parcelable.ClassLoaderCreator<T extends Object>, Parcelable.Creator<T extends Object>
-
-
Field Summary
Fields Modifier and Type Field Description static Parcelable.Creator<BaseSale>
CREATOR
static JSONifiable.Creator<BaseSale>
JSON_CREATOR
-
Fields inherited from interface android.os.Parcelable
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE
-
-
Constructor Summary
Constructors Modifier Constructor Description BaseSale()
Constructs a new empty instance.protected
BaseSale(boolean noInit)
Constructs a new empty instance.BaseSale(BaseSale src)
Constructs a new instance that is a deep copy of the source instance.BaseSale(String json)
Constructs a new instance from the given JSON String.BaseSale(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.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clearName()
Clears the 'name' field, the 'has' method for this field will now return falsevoid
clearNumberSold()
Clears the 'numberSold' field, the 'has' method for this field will now return falsevoid
clearNumNonRevenueSold()
Clears the 'numNonRevenueSold' field, the 'has' method for this field will now return falsevoid
clearPriceSold()
Clears the 'priceSold' field, the 'has' method for this field will now return falsevoid
clearRevenueSold()
Clears the 'revenueSold' field, the 'has' method for this field will now return falseboolean
containsChanges()
Returns true if this instance has any changes.BaseSale
copyChanges()
Create a copy of this instance that contains only fields that were set after the constructor was called.protected GenericClient
getGenericClient()
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.String
getName()
Double
getNumberSold()
Double
getNumNonRevenueSold()
Double
getPriceSold()
Long
getRevenueSold()
boolean
hasName()
Checks whether the 'name' field has been set, however the value could be nullboolean
hasNumberSold()
Checks whether the 'numberSold' field has been set, however the value could be nullboolean
hasNumNonRevenueSold()
Checks whether the 'numNonRevenueSold' field has been set, however the value could be nullboolean
hasPriceSold()
Checks whether the 'priceSold' field has been set, however the value could be nullboolean
hasRevenueSold()
Checks whether the 'revenueSold' field has been set, however the value could be nullboolean
isNotNullName()
Checks whether the 'name' field is set and is not nullboolean
isNotNullNumberSold()
Checks whether the 'numberSold' field is set and is not nullboolean
isNotNullNumNonRevenueSold()
Checks whether the 'numNonRevenueSold' field is set and is not nullboolean
isNotNullPriceSold()
Checks whether the 'priceSold' field is set and is not nullboolean
isNotNullRevenueSold()
Checks whether the 'revenueSold' field is set and is not nullvoid
mergeChanges(BaseSale 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.BaseSale
setName(String name)
Sets the field 'name'.BaseSale
setNumberSold(Double numberSold)
Sets the field 'numberSold'.BaseSale
setNumNonRevenueSold(Double numNonRevenueSold)
Sets the field 'numNonRevenueSold'.BaseSale
setPriceSold(Double priceSold)
Sets the field 'priceSold'.BaseSale
setRevenueSold(Long revenueSold)
Sets the field 'revenueSold'.void
validate()
-
Methods inherited from class com.clover.sdk.GenericParcelable
describeContents, getBundle, toString, writeToParcel
-
-
-
-
Field Detail
-
CREATOR
public static final Parcelable.Creator<BaseSale> CREATOR
-
JSON_CREATOR
public static final JSONifiable.Creator<BaseSale> JSON_CREATOR
-
-
Constructor Detail
-
BaseSale
public BaseSale()
Constructs a new empty instance.
-
BaseSale
protected BaseSale(boolean noInit)
Constructs a new empty instance.
-
BaseSale
public BaseSale(String json) throws IllegalArgumentException
Constructs a new instance from the given JSON String.- Throws:
IllegalArgumentException
-
BaseSale
public BaseSale(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.
-
BaseSale
public BaseSale(BaseSale src)
Constructs a new instance that is a deep copy of the source instance. It does not copy the bundle or changelog.
-
-
Method Detail
-
getName
public String getName()
-
getNumberSold
public Double getNumberSold()
-
getRevenueSold
public Long getRevenueSold()
-
getNumNonRevenueSold
public Double getNumNonRevenueSold()
-
getPriceSold
public Double getPriceSold()
-
getGenericClient
protected GenericClient getGenericClient()
- Specified by:
getGenericClient
in classGenericParcelable
-
getJSONObject
public 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.- Specified by:
getJSONObject
in interfaceJSONifiable
-
isNotNullName
public boolean isNotNullName()
Checks whether the 'name' field is set and is not null
-
isNotNullNumberSold
public boolean isNotNullNumberSold()
Checks whether the 'numberSold' field is set and is not null
-
isNotNullRevenueSold
public boolean isNotNullRevenueSold()
Checks whether the 'revenueSold' field is set and is not null
-
isNotNullNumNonRevenueSold
public boolean isNotNullNumNonRevenueSold()
Checks whether the 'numNonRevenueSold' field is set and is not null
-
isNotNullPriceSold
public boolean isNotNullPriceSold()
Checks whether the 'priceSold' field is set and is not null
-
hasName
public boolean hasName()
Checks whether the 'name' field has been set, however the value could be null
-
hasNumberSold
public boolean hasNumberSold()
Checks whether the 'numberSold' field has been set, however the value could be null
-
hasRevenueSold
public boolean hasRevenueSold()
Checks whether the 'revenueSold' field has been set, however the value could be null
-
hasNumNonRevenueSold
public boolean hasNumNonRevenueSold()
Checks whether the 'numNonRevenueSold' field has been set, however the value could be null
-
hasPriceSold
public boolean hasPriceSold()
Checks whether the 'priceSold' field has been set, however the value could be null
-
setNumNonRevenueSold
public BaseSale setNumNonRevenueSold(Double numNonRevenueSold)
Sets the field 'numNonRevenueSold'.
-
clearName
public void clearName()
Clears the 'name' field, the 'has' method for this field will now return false
-
clearNumberSold
public void clearNumberSold()
Clears the 'numberSold' field, the 'has' method for this field will now return false
-
clearRevenueSold
public void clearRevenueSold()
Clears the 'revenueSold' field, the 'has' method for this field will now return false
-
clearNumNonRevenueSold
public void clearNumNonRevenueSold()
Clears the 'numNonRevenueSold' field, the 'has' method for this field will now return false
-
clearPriceSold
public void clearPriceSold()
Clears the 'priceSold' field, the 'has' method for this field will now return false
-
containsChanges
public boolean containsChanges()
Returns true if this instance has any changes.
-
resetChangeLog
public void resetChangeLog()
Reset the log of changes made to this instance, calling copyChanges() after this would return an empty instance.
-
copyChanges
public BaseSale copyChanges()
Create a copy of this instance that contains only fields that were set after the constructor was called.
-
mergeChanges
public void mergeChanges(BaseSale src)
Copy all the changed fields from the given source to this instance.
-
-