public class ZipcodeProperties extends GenericParcelable implements Validator, JSONifiable
Modifier and Type | Class and Description |
---|---|
static interface |
ZipcodeProperties.Constraints |
JSONifiable.Creator<T>
Parcelable.ClassLoaderCreator<T>, Parcelable.Creator<T>
Modifier and Type | Field and Description |
---|---|
static Parcelable.Creator<ZipcodeProperties> |
CREATOR |
static JSONifiable.Creator<ZipcodeProperties> |
JSON_CREATOR |
CONTENTS_FILE_DESCRIPTOR, PARCELABLE_WRITE_RETURN_VALUE
Modifier | Constructor and Description |
---|---|
|
ZipcodeProperties()
Constructs a new empty instance.
|
protected |
ZipcodeProperties(boolean noInit)
Constructs a new empty instance.
|
|
ZipcodeProperties(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.
|
|
ZipcodeProperties(String json)
Constructs a new instance from the given JSON String.
|
|
ZipcodeProperties(ZipcodeProperties src)
Constructs a new instance that is a deep copy of the source instance.
|
Modifier and Type | Method and Description |
---|---|
void |
clearDeletedTime()
Clears the 'deletedTime' 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 |
clearModifiedTime()
Clears the 'modifiedTime' field, the 'has' method for this field will now return false
|
void |
clearSurchargeProhibited()
Clears the 'surchargeProhibited' field, the 'has' method for this field will now return false
|
void |
clearZip()
Clears the 'zip' field, the 'has' method for this field will now return false
|
boolean |
containsChanges()
Returns true if this instance has any changes.
|
ZipcodeProperties |
copyChanges()
Create a copy of this instance that contains only fields that were set after the constructor was called.
|
Long |
getDeletedTime()
Deleted time
|
protected GenericClient |
getGenericClient() |
String |
getId()
Unique identifier
|
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.
|
Long |
getModifiedTime()
Last modified time
|
Boolean |
getSurchargeProhibited()
If the zip code has surcharge prohibited.
|
String |
getZip()
The zipcode
|
boolean |
hasDeletedTime()
Checks whether the 'deletedTime' 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 |
hasModifiedTime()
Checks whether the 'modifiedTime' field has been set, however the value could be null
|
boolean |
hasSurchargeProhibited()
Checks whether the 'surchargeProhibited' field has been set, however the value could be null
|
boolean |
hasZip()
Checks whether the 'zip' field has been set, however the value could be null
|
boolean |
isNotNullDeletedTime()
Checks whether the 'deletedTime' field is set and is not null
|
boolean |
isNotNullId()
Checks whether the 'id' field is set and is not null
|
boolean |
isNotNullModifiedTime()
Checks whether the 'modifiedTime' field is set and is not null
|
boolean |
isNotNullSurchargeProhibited()
Checks whether the 'surchargeProhibited' field is set and is not null
|
boolean |
isNotNullZip()
Checks whether the 'zip' field is set and is not null
|
void |
mergeChanges(ZipcodeProperties 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.
|
ZipcodeProperties |
setDeletedTime(Long deletedTime)
Sets the field 'deletedTime'.
|
ZipcodeProperties |
setId(String id)
Sets the field 'id'.
|
ZipcodeProperties |
setModifiedTime(Long modifiedTime)
Sets the field 'modifiedTime'.
|
ZipcodeProperties |
setSurchargeProhibited(Boolean surchargeProhibited)
Sets the field 'surchargeProhibited'.
|
ZipcodeProperties |
setZip(String zip)
Sets the field 'zip'.
|
void |
validate() |
describeContents, getBundle, toString, writeToParcel
public static final Parcelable.Creator<ZipcodeProperties> CREATOR
public static final JSONifiable.Creator<ZipcodeProperties> JSON_CREATOR
public ZipcodeProperties()
protected ZipcodeProperties(boolean noInit)
public ZipcodeProperties(String json) throws IllegalArgumentException
IllegalArgumentException
public ZipcodeProperties(JSONObject jsonObject)
public ZipcodeProperties(ZipcodeProperties src)
public String getId()
public String getZip()
public Boolean getSurchargeProhibited()
public Long getModifiedTime()
public Long getDeletedTime()
protected GenericClient getGenericClient()
getGenericClient
in class GenericParcelable
public JSONObject getJSONObject()
getJSONObject
in interface JSONifiable
public boolean isNotNullId()
public boolean isNotNullZip()
public boolean isNotNullSurchargeProhibited()
public boolean isNotNullModifiedTime()
public boolean isNotNullDeletedTime()
public boolean hasId()
public boolean hasZip()
public boolean hasSurchargeProhibited()
public boolean hasModifiedTime()
public boolean hasDeletedTime()
public ZipcodeProperties setId(String id)
public ZipcodeProperties setZip(String zip)
public ZipcodeProperties setSurchargeProhibited(Boolean surchargeProhibited)
public ZipcodeProperties setModifiedTime(Long modifiedTime)
public ZipcodeProperties setDeletedTime(Long deletedTime)
public void clearId()
public void clearZip()
public void clearSurchargeProhibited()
public void clearModifiedTime()
public void clearDeletedTime()
public boolean containsChanges()
public void resetChangeLog()
public ZipcodeProperties copyChanges()
public void mergeChanges(ZipcodeProperties src)