TabularDataSupport class is the open data
class which implements the TabularData
and the Map interfaces, and which is internally based on a hash map data structure.
| Modifier and Type | Field and Description |
|---|---|
| private Map | |
| private transient String[] | indexNamesArray
The array of item names that define the index used for rows (convenience field) |
| pack-priv static final long | |
| private final TabularType |
| Access | Constructor and Description |
|---|---|
| public | TabularDataSupport(TabularType
the tabular type describing this
tabularType)TabularData instance; cannot be null.Creates an empty |
| public | TabularDataSupport(TabularType
the tabular type describing this tabularType, int TabularData instance;
cannot be null.the initial capacity of the HashMap. initialCapacity, float the load factor of the HashMap loadFactor)Creates an empty |
| Modifier and Type | Method and Description |
|---|---|
| public Object[] | Returns: the index that the specified value would have in thisTabularData instance.the composite data value whose index in this
value)TabularData instance is to be calculated;
must be of the same composite type as this instance's row type;
must not be null.Implements javax. Calculates the index that would be used in this |
| private void | |
| private List | checkValueAndIndex(CompositeData value)
Checks if the specified value can be put (ie added) in this |
| private void | checkValueType(CompositeData value)
Checks the specified value's type is valid for this |
| public void | clear()
Implements javax. Removes all rows from this |
| public Object | clone()
Overrides java. Returns a clone of this |
| public boolean | Returns: true if this TabularData indexes a row value with the specified key.the index value whose presence in this key)TabularData instance is to be tested.Implements java. Returns |
| public boolean | Returns: true if this TabularData indexes a row value with the specified key.the index value whose presence in this key)TabularData instance is to be tested.Implements javax. Returns |
| public boolean | Returns: true if this TabularData instance contains the specified row value.the row value whose presence in this value)TabularData instance is to be tested.Implements javax. Returns |
| public boolean | Returns: true if this TabularData instance contains the specified row value.the row value whose presence in this value)TabularData instance is to be tested.Implements java. Returns |
| public Set | Returns: a collection view (Set<Map.Entry<List<?>,CompositeData>>)
of the mappings contained in this map.Implements java. Returns a collection view of the index to row mappings
contained in this |
| public boolean | Returns: true if the specified object is equal to this TabularDataSupport instance.the object to be compared for equality with this obj)TabularDataSupport instance;Overrides java. Implements javax. Compares the specified obj parameter with this |
| public Object | |
| public CompositeData | Returns: the value corresponding to key.the index of the value to get in this
key)TabularData instance; must be valid with this
TabularData instance's row type definition; must not
be null.Implements javax. Returns the |
| public TabularType | getTabularType()
Implements javax. Returns the tabular type describing this |
| public int | Returns: the hash code value for thisTabularDataSupport instanceOverrides java. Implements javax. Returns the hash code value for this |
| private List | internalCalculateIndex(CompositeData value)
Returns the index for value, assuming value is valid for this |
| private CompositeData | |
| public boolean | Returns: true if this TabularDataSupport instance contains no rows.Implements javax. Returns |
| public Set | Returns: a set view (Set<List<?>>) of the keys used to index
the rows of this TabularDataSupport instance.Implements javax. Returns a set view of the keys contained in the underlying map of this
|
| public Object | Returns: the value which is putan ignored parameter. key, Object the value)CompositeData to put.Implements java. This method simply calls |
| public void | put(CompositeData value)
Implements javax. Adds value to this |
| public void | putAll(Map<?, ?>
the map whose values are to be added as new rows to
this t)TabularData instance; if t is
null or empty, this method returns without doing
anything.Implements java. Add all the values contained in the specified map t
to this |
| public void | putAll(CompositeData[]
the array of composite data values to be added as
new rows to this values)TabularData instance; if
values is null or empty, this method
returns without doing anything.Implements javax. Add all the elements in values to this
|
| private void | |
| public Object | Returns: previous value associated with specified key, ornull
if there was no mapping for key.an key)Object[] representing the key to remove.Implements java. This method simply calls |
| public CompositeData | Returns: previous value associated with specified key, ornull
if there was no mapping for key.the index of the value to get in this key)TabularData instance;
must be valid with this TabularData instance's row type definition;
must not be null.Implements javax. Removes the |
| public int | Returns: the number of rows in thisTabularDataSupport instance.Implements javax. Returns the number of rows in this |
| public String | Returns: a string representation of thisTabularDataSupport instanceOverrides java. Implements javax. Returns a string representation of this |
| public Collection | Returns: a collection view (Collection<CompositeData>) of
the values contained in this TabularDataSupport instance.Implements javax. Returns a collection view of the rows contained in this
|
| dataMap | back to summary |
|---|---|
private Map<Object, CompositeData> dataMap
| |
| indexNamesArray | back to summary |
|---|---|
| private transient String[] indexNamesArray The array of item names that define the index used for rows (convenience field) | |
| serialVersionUID | back to summary |
|---|---|
| pack-priv static final long serialVersionUID | |
| tabularType | back to summary |
|---|---|
| private final TabularType tabularType | |
| TabularDataSupport | back to summary |
|---|---|
| public TabularDataSupport(TabularType tabularType) Creates an empty
This constructor simply calls
| |
| TabularDataSupport | back to summary |
|---|---|
| public TabularDataSupport(TabularType tabularType, int initialCapacity, float loadFactor) Creates an empty
| |
| calculateIndex | back to summary |
|---|---|
| public Object[] calculateIndex(CompositeData value) Implements javax. Calculates the index that would be used in this
| |
| checkKeyType | back to summary |
|---|---|
| private void checkKeyType(Object[] key) Checks if the specified key is valid for this | |
| checkValueAndIndex | back to summary |
|---|---|
| private List Checks if the specified value can be put (ie added) in this | |
| checkValueType | back to summary |
|---|---|
| private void checkValueType(CompositeData value) Checks the specified value's type is valid for this | |
| clear | back to summary |
|---|---|
| public void clear() Implements javax. Removes all rows from this | |
| clone | back to summary |
|---|---|
| public Object clone() Overrides java. Returns a clone of this | |
| containsKey | back to summary |
|---|---|
| public boolean containsKey(Object key) Implements java. Returns
| |
| containsKey | back to summary |
|---|---|
| public boolean containsKey(Object[] key) Implements javax. Returns
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(CompositeData value) Implements javax. Returns
| |
| containsValue | back to summary |
|---|---|
| public boolean containsValue(Object value) Implements java. Returns
| |
| entrySet | back to summary |
|---|---|
| public Set Implements java. Returns a collection view of the index to row mappings
contained in this
IMPORTANT NOTICE: Do not use the | |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Implements javax. Compares the specified obj parameter with this
Returns
equals method works properly for obj parameters which are
different implementations of the TabularData interface.
| |
| get | back to summary |
|---|---|
| public Object get(Object key) Implements java. This method simply calls
| |
| get | back to summary |
|---|---|
| public CompositeData get(Object[] key) Implements javax. Returns the
| |
| getTabularType | back to summary |
|---|---|
| public TabularType getTabularType() Implements javax. Returns the tabular type describing this | |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Implements javax. Returns the hash code value for this
The hash code of a
This ensures that
However, note that another instance of a class implementing the
| |
| internalCalculateIndex | back to summary |
|---|---|
| private List Returns the index for value, assuming value is valid for this | |
| internalPut | back to summary |
|---|---|
| private CompositeData internalPut(CompositeData value) | |
| isEmpty | back to summary |
|---|---|
| public boolean isEmpty() Implements javax. Returns
| |
| keySet | back to summary |
|---|---|
| public Set Implements javax. Returns a set view of the keys contained in the underlying map of this
| |
| put | back to summary |
|---|---|
| public Object put(Object key, Object value) Implements java. This method simply calls
| |
| put | back to summary |
|---|---|
| public void put(CompositeData value) Implements javax. Doc from javax. Adds value to this | |
| putAll | back to summary |
|---|---|
| public void putAll(Map<?, ?> t) Implements java. Add all the values contained in the specified map t
to this
| |
| putAll | back to summary |
|---|---|
| public void putAll(CompositeData[] values) Implements javax. Add all the elements in values to this
| |
| readObject | back to summary |
|---|---|
| private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException Deserializes a | |
| remove | back to summary |
|---|---|
| public Object remove(Object key) Implements java. This method simply calls
| |
| remove | back to summary |
|---|---|
| public CompositeData remove(Object[] key) Implements javax. Removes the
| |
| size | back to summary |
|---|---|
| public int size() Implements javax. Returns the number of rows in this
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Implements javax. Returns a string representation of this
The string representation consists of the name of this class
(ie
| |
| values | back to summary |
|---|---|
| public Collection Implements javax. Returns a collection view of the rows contained in this
| |