public interface Collection extends IfsEventHandler
iFS uses Collections to provide an easy-to-use API to access various sets
of LIBRARYOBJECTs. LibrarySession and S_LibrarySession provide several
methods, getcollectionCollection
, to access the
Collections they maintain.
Collection implementations may cache the items they contain. For this reason, Collections are more performant than Selectors or S_Selectors.
For performance, applications iterating over the items in a Collection
should use getItems()
rather than getItems(int)
.
Modifier and Type | Method and Description |
---|---|
Object |
checkItemByUpperCaseName(String name)
Gets the specified item in this Collection by the uppercase name,
*and returns null if the item is not found.
|
Object |
getItemByUpperCaseName(String name)
Gets the specified item in this Collection by the uppercase name.
|
int |
getItemCount()
Gets the number of items in this Collection.
|
Object[] |
getItems()
Gets an array containing the items in this Collection.
|
Object |
getItems(int index)
Gets the specified item in this Collection.
|
Object |
getItems(String name)
Gets the specified item in this Collection.
|
Vector |
getItemsVector()
Gets a vector containing the items in this Collection.
|
void |
reset()
Resets this Collection.
|
handleEvent
int getItemCount() throws IfsException
IfsException
- (IFS-12211) if the operation failsObject[] getItems() throws IfsException
IfsException
- (IFS-12212) if the operation failsObject getItems(int index) throws IfsException
index
- the zero-based index of the itemIfsException
- (IFS-12213) if the operation failsObject getItems(String name) throws IfsException
name
- the name of the itemIfsException
- (IFS-12214) if the operation failsObject getItemByUpperCaseName(String name) throws IfsException
name
- the name of the itemIfsException
- (IFS-12214) if the operation failsObject checkItemByUpperCaseName(String name) throws IfsException
name
- the name of the itemIfsException
- if the operation failsVector getItemsVector() throws IfsException
The order of the items in the vector is identical to the order of the
items in the array returned by getItems()
.
IfsException
- (IFS-12215) if the operation failsvoid reset() throws IfsException
Resetting a Collection causes the items in it to be redetermined.
IfsException
- (IFS-12216) if the operation failsCopyright © 2023. All rights reserved.