T - public class CartItem<T> extends ModelObject implements Identifiable<T>, IHierarchialReference<T>
Cart. By default identified by getName(). Override equals(Object) and hashCode()
to select another field(s) as primary.getKey(),
Serialized FormROOT| Constructor and Description |
|---|
CartItem() |
CartItem(CartItem item) |
CartItem(String json) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object item) |
String |
getCode() |
String |
getComments() |
String |
getHierarchy()
A String like: "rootId-nodeId-subnodeId-thisId"; gives the entire picture of
the hierarchy to this point.
|
T |
getId() |
String |
getKey()
Since there is no clear indication of which field(s) can be used as a Key
Provide an abstraction.
|
String |
getName()
Unique Name to refer to the record
Id is an Auto generated number used by the system,
but is difficult for the outside world to get a handle on it.
|
T |
getParentId() |
int |
hashCode() |
void |
setCode(String code) |
void |
setComments(String comments) |
void |
setHierarchy(String hierarchy)
A String like: "rootId-nodeId-subnodeId-thisId"; gives the entire picture of
the hierarchy to this point.
|
void |
setId(T id) |
void |
setKey(String key) |
void |
setName(String name)
Unique Name to refer to the record
Id is an Auto generated number used by the system,
but is difficult for the outside world to get a handle on it.
|
void |
setParentId(T parentId) |
public CartItem()
public CartItem(String json)
public CartItem(CartItem item)
public T getId()
getId in interface IHierarchialReference<T>getId in interface Identifiable<T>public void setId(T id)
setId in interface IHierarchialReference<T>setId in interface Identifiable<T>public String getName()
IHierarchialReferencegetName in interface IHierarchialReference<T>public void setName(String name)
IHierarchialReferencesetName in interface IHierarchialReference<T>public String getCode()
public void setCode(String code)
public String getComments()
public void setComments(String comments)
public T getParentId()
getParentId in interface IHierarchialReference<T>public void setParentId(T parentId)
setParentId in interface IHierarchialReference<T>public String getHierarchy()
IHierarchialReferencegetHierarchy in interface IHierarchialReference<T>public void setHierarchy(String hierarchy)
IHierarchialReferencesetHierarchy in interface IHierarchialReference<T>public String getKey()
Product. It is important
the two keys match to identify the item corresponds to a particular product or service.setKey(String)nameCopyright © 2018. All rights reserved.