|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.opensubsystems.core.data.DataObject
org.opensubsystems.core.data.BasicDataObject
org.opensubsystems.inventory.data.ItemUnitView
public class ItemUnitView
This data object represents union of information between unit and item. Since this is a combination of these two objects and cannot be modified on its own, we will use unit data type to represent this object rather then define new data type. In this case it is critical to reuse the constants from the original objects especially for the id attribute since the combination of the data type (unit) and id (which then has to be unit id) is being used for acccess rights checking. This class is immutable since it is a view and it should be never modified.
| Field Summary | |
|---|---|
static int[] |
ALL_FILTER_COLUMNS
Static variable for array of all filter columns codes. |
static int[] |
ALL_ITEM_UNIT_VIEW_COLUMNS
Static variable for array of all columns codes. |
static int |
COL_ITEM_UNIT_VIEW_AVAILABLE_COUNT
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_AVAILABLE_COUNT2
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_AVERAGE_COST
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_COST
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_CREATION_DATE
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_CREATION_DATE2
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_DESCRIPTION
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_DISPLAY_ORDER
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_DOMAIN_ID
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_EXPENSE_TYPE
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_FOUND_HOLDER
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_ID
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_INVENTORY_ID
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_ITEM_ID
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_LAST_RECOUNT_TIMESTAMP
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_MINIMAL_AVAILABLE_COUNT
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_MODIFICATION_DATE
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_MODIFICATION_DATE2
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_NAME
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_NAME_STEM
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_ONHOLD_COUNT
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_PERMANENTLY_ASSIGNED
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_POPULARITY_RANK
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_PRICE
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_REUSABLE
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_SHIPPED_COUNT
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_SHIPPED_COUNT2
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_SIZE
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_UNIQUELY_TRACKED
Code for attribute. |
static int |
COL_ITEM_UNIT_VIEW_UNIT_OF_MEASURE
Code for attribute. |
static int[] |
DEFAULT_LIST_COLUMNS
Default columns to retrieve when asked for list of objects. |
static int[] |
DEFAULT_LIST_SORT_COLUMNS
Default columns to sort by when asked for list of objects. |
static java.lang.String[] |
DEFAULT_LIST_SORT_ORDER
Default order in which the columns will be sorted. |
protected Item |
m_item
Item object. |
protected Unit |
m_unit
Unit object. |
static int |
UNIT_BY_CATEGORY
Code for units by category. |
static java.lang.Integer |
UNIT_BY_CATEGORY_OBJ
Code for units by category. |
| Fields inherited from class org.opensubsystems.core.data.BasicDataObject |
|---|
m_creationTimestamp, m_iDomainId |
| Fields inherited from class org.opensubsystems.core.data.DataObject |
|---|
NEW_ID, NEW_ID_OBJ, NEW_ID_STR |
| Constructor Summary | |
|---|---|
ItemUnitView()
Empty constructor |
|
ItemUnitView(int iUnitId,
int iDomainId,
int iInventoryId,
int iItemId,
int iShippedCount,
int iAvailableCount,
double dCost,
boolean bFoundHolder,
java.sql.Timestamp creationDate,
java.sql.Timestamp modificationDate,
java.lang.String strName,
java.lang.String strDescription,
int iUnitOfMeasure,
boolean bReusable,
int iExpenseType,
int iAvailableCount2,
int iOnHoldCount,
int iPopularityRank,
int iShippedCount2,
boolean bUniquelyTracked,
int iMinimalAvailableCount,
boolean bPermanentlyAssigned,
double dAverageCost,
double dPrice,
int iDisplayOrder,
java.lang.String strNameStem,
java.lang.String strSize,
java.sql.Timestamp lastRecountDate,
java.sql.Timestamp creationDate2,
java.sql.Timestamp modificationDate2)
Full constructor. |
|
ItemUnitView(Item item,
Unit unit)
Constructor |
|
ItemUnitView(ItemUnitView originalItem,
Unit update)
Kind of copy constructor. |
|
| Method Summary | |
|---|---|
boolean |
equals(java.lang.Object oObject)
|
java.sql.Timestamp |
getCreationTimestamp()
|
int |
getDomainId()
|
int |
getId()
|
java.lang.Integer |
getIdAsObject()
|
Item |
getItem()
Return item object |
Unit |
getUnit()
Return unit object |
int |
hashCode()
|
boolean |
isSame(java.lang.Object oObject)
|
void |
setCreationTimestamp(java.sql.Timestamp creationTimestamp)
Creation timestamp is timestamp when the data object was created. |
void |
setId(int iNewId)
|
| Methods inherited from class org.opensubsystems.core.data.BasicDataObject |
|---|
restore |
| Methods inherited from class org.opensubsystems.core.data.DataObject |
|---|
isFromPersistenceStore, setFromPersistenceStore |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int COL_ITEM_UNIT_VIEW_ID
public static final int COL_ITEM_UNIT_VIEW_DOMAIN_ID
public static final int COL_ITEM_UNIT_VIEW_INVENTORY_ID
public static final int COL_ITEM_UNIT_VIEW_ITEM_ID
public static final int COL_ITEM_UNIT_VIEW_SHIPPED_COUNT
public static final int COL_ITEM_UNIT_VIEW_AVAILABLE_COUNT
public static final int COL_ITEM_UNIT_VIEW_COST
public static final int COL_ITEM_UNIT_VIEW_FOUND_HOLDER
public static final int COL_ITEM_UNIT_VIEW_CREATION_DATE
public static final int COL_ITEM_UNIT_VIEW_MODIFICATION_DATE
public static final int COL_ITEM_UNIT_VIEW_NAME
public static final int COL_ITEM_UNIT_VIEW_DESCRIPTION
public static final int COL_ITEM_UNIT_VIEW_UNIT_OF_MEASURE
public static final int COL_ITEM_UNIT_VIEW_REUSABLE
public static final int COL_ITEM_UNIT_VIEW_EXPENSE_TYPE
public static final int COL_ITEM_UNIT_VIEW_AVAILABLE_COUNT2
public static final int COL_ITEM_UNIT_VIEW_ONHOLD_COUNT
public static final int COL_ITEM_UNIT_VIEW_POPULARITY_RANK
public static final int COL_ITEM_UNIT_VIEW_SHIPPED_COUNT2
public static final int COL_ITEM_UNIT_VIEW_UNIQUELY_TRACKED
public static final int COL_ITEM_UNIT_VIEW_MINIMAL_AVAILABLE_COUNT
public static final int COL_ITEM_UNIT_VIEW_PERMANENTLY_ASSIGNED
public static final int COL_ITEM_UNIT_VIEW_AVERAGE_COST
public static final int COL_ITEM_UNIT_VIEW_PRICE
public static final int COL_ITEM_UNIT_VIEW_DISPLAY_ORDER
public static final int COL_ITEM_UNIT_VIEW_NAME_STEM
public static final int COL_ITEM_UNIT_VIEW_SIZE
public static final int COL_ITEM_UNIT_VIEW_LAST_RECOUNT_TIMESTAMP
public static final int COL_ITEM_UNIT_VIEW_CREATION_DATE2
public static final int COL_ITEM_UNIT_VIEW_MODIFICATION_DATE2
public static final int UNIT_BY_CATEGORY
public static final java.lang.Integer UNIT_BY_CATEGORY_OBJ
public static final int[] ALL_ITEM_UNIT_VIEW_COLUMNS
public static final int[] DEFAULT_LIST_COLUMNS
public static final int[] DEFAULT_LIST_SORT_COLUMNS
public static final int[] ALL_FILTER_COLUMNS
public static final java.lang.String[] DEFAULT_LIST_SORT_ORDER
protected Item m_item
protected Unit m_unit
| Constructor Detail |
|---|
public ItemUnitView()
public ItemUnitView(Item item,
Unit unit)
item - - item objectunit - - unit object
public ItemUnitView(ItemUnitView originalItem,
Unit update)
originalItem - - original itemupdate - - update to use
public ItemUnitView(int iUnitId,
int iDomainId,
int iInventoryId,
int iItemId,
int iShippedCount,
int iAvailableCount,
double dCost,
boolean bFoundHolder,
java.sql.Timestamp creationDate,
java.sql.Timestamp modificationDate,
java.lang.String strName,
java.lang.String strDescription,
int iUnitOfMeasure,
boolean bReusable,
int iExpenseType,
int iAvailableCount2,
int iOnHoldCount,
int iPopularityRank,
int iShippedCount2,
boolean bUniquelyTracked,
int iMinimalAvailableCount,
boolean bPermanentlyAssigned,
double dAverageCost,
double dPrice,
int iDisplayOrder,
java.lang.String strNameStem,
java.lang.String strSize,
java.sql.Timestamp lastRecountDate,
java.sql.Timestamp creationDate2,
java.sql.Timestamp modificationDate2)
iUnitId - - see unit objectiDomainId - - see unit objectiInventoryId - - see unit objectiItemId - - see unit objectiShippedCount - - see unit objectiAvailableCount - - see unit objectdCost - - see unit objectbFoundHolder - - see unit objectcreationDate - - see unit objectmodificationDate - - see unit objectstrName - - see item objectstrDescription - - see item objectiUnitOfMeasure - - see item objectbReusable - - see item objectiExpenseType - - see item objectiAvailableCount2 - - see item objectiOnHoldCount - - see item objectiPopularityRank - - see item objectiShippedCount2 - - see item objectbUniquelyTracked - - see item objectiMinimalAvailableCount - - see item objectbPermanentlyAssigned - - see item objectdAverageCost - - see item objectdPrice - - see item objectiDisplayOrder - - see item objectstrNameStem - - see item objectstrSize - - see item objectlastRecountDate - - see item objectcreationDate2 - - see item objectmodificationDate2 - - see item object| Method Detail |
|---|
public int getDomainId()
getDomainId in class org.opensubsystems.core.data.BasicDataObjectpublic int getId()
getId in class org.opensubsystems.core.data.BasicDataObjectpublic java.lang.Integer getIdAsObject()
getIdAsObject in class org.opensubsystems.core.data.BasicDataObjectpublic void setId(int iNewId)
setId in class org.opensubsystems.core.data.BasicDataObjectpublic java.sql.Timestamp getCreationTimestamp()
getCreationTimestamp in class org.opensubsystems.core.data.BasicDataObjectpublic void setCreationTimestamp(java.sql.Timestamp creationTimestamp)
setCreationTimestamp in class org.opensubsystems.core.data.BasicDataObjectcreationTimestamp - - new creation timestamppublic Unit getUnit()
public Item getItem()
public boolean equals(java.lang.Object oObject)
equals in class org.opensubsystems.core.data.BasicDataObjectpublic int hashCode()
hashCode in class org.opensubsystems.core.data.BasicDataObjectpublic boolean isSame(java.lang.Object oObject)
isSame in class org.opensubsystems.core.data.DataObject
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||