Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.ifs.common
Class UncachedPreparedSelectorCollection

    java.lang.Object
      oracle.ifs.common.UncachedPreparedSelectorCollection

All Implemented Interfaces:
  Collection, IfsEventHandler

    public class UncachedPreparedSelectorCollection

extends java.lang.Object
implements Collection

An UncachedPreparedSelectorCollection is a Collection whose items are LIBRARYOBJECTs specified by a PreparedSelector or S_PreparedSelector and not cached by the collection.

By not caching its items, an UncachedPreparedSelectorCollection maintains a small memory footprint. However, each use of the collection causes a database roundtrip, making UncachedPreparedSelectorCollection less performant than CachedSelectorCollection.

A PreparedSelector is used so that the same preparedStatement can be used internally. The `getItemCount` method is not supported by this type of Collection.

The order of items returned by `getItems()` and `getItemsVector()` is determined by the sort specification of the PreparedSelector or S_PreparedSelector. The method `getItems(int)` is implemented in terms of `getItems()`. For best performance in iterating over the items of the collection, call `getItems()` once instead of `getItems(int)` repeatedly.

Use `getItems(String)` to look up an item by name (or equivalent, as specified by the nameExpresion during construction). This lookup is case-insentive. If more than one item has the same case-insensitive name, `getItems(String)` returns an arbitrary item with that name.

The performance of `getItems(String)` can be improved by enabling a mini-cache of the "n" items most-recently returned by this method. The size of this mini-cache is specified by a constructor argument.

(Published)

Field Summary
`protected java.lang.Class` | `m_Class` The class of the objects in this Collection.
`protected java.lang.String` | `m_GetItemsSearchCondition` The search condition to use to get all items in the collection.
`protected int` | `m_ItemCount` The number of items in this collection, or -1 if unknown.
`protected int` | `m_MaximumRecentItems` The maximum length of m_RecentItems.
`protected oracle.ifs.common.UncachedPreparedSelectorCollection.ItemLink` | `m_RecentItems` A linked list of the "n" items most recently returned by getItems(String), with the most recent at the head and the least recent at the tail of the list.
`protected PreparedSelector` | `m_Selector` The PreparedSelector used to obtain the items in this Collection (if this is a collection of LibraryObjects).
`protected S_PreparedSelector` | `m_SSelector` The S_PreparedSelector used to obtain the items in this Collection (if this is a collection of S_LibraryObjects).

Constructor Summary
`UncachedPreparedSelectorCollection(PreparedSelector sel, java.lang.String className, java.lang.String getItemsClause, int maxRecentItems)` Constructs a collection of LibraryObjects.
`UncachedPreparedSelectorCollection(S_PreparedSelector sel, java.lang.String className, java.lang.String getItemsClause, int maxRecentItems)` Constructs a collection of S_LibraryObjects.

Method Summary
`java.lang.Object` | `checkItemByUpperCaseName(java.lang.String upperCaseName)` Gets the specified item in this Collection by uppercase name, and returns null if not found.
`java.lang.Object` | `getItemByUpperCaseName(java.lang.String upperCaseName)` Gets the specified item in this Collection by uppercase name.
`int` | `getItemCount()` Gets the number of items in this Collection.
`java.lang.Object[]` | `getItems()` Gets an array containing the items in this Collection.
`java.lang.Object` | `getItems(int index)` Gets the specified item in this Collection.
`java.lang.Object` | `getItems(java.lang.String name)` Gets the specified item in this Collection.
`java.util.Vector` | `getItemsVector()` Gets a vector containing the items in this Collection.
`void` | `handleEvent(IfsEvent event)` Handles the specified event.
`void` | `reset()` Resets this Collection.
`protected void` | `resolve()` Ensures the items in this Collection are resolved.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### m_Class

    protected java.lang.Class m_Class

  Description copied from class: `UncachedPreparedSelectorCollection`
  The class of the objects in this Collection.

  The value returned by getItems() can be cast to an array of this type.

  (Unpublished)

### m_SSelector

    protected S_PreparedSelector m_SSelector

  Description copied from class: `UncachedPreparedSelectorCollection`
  The S_PreparedSelector used to obtain the items in this Collection (if this is a collection of S_LibraryObjects).

  (Unpublished)

### m_Selector

    protected PreparedSelector m_Selector

  Description copied from class: `UncachedPreparedSelectorCollection`
  The PreparedSelector used to obtain the items in this Collection (if this is a collection of LibraryObjects).

  (Unpublished)

### m_GetItemsSearchCondition

    protected java.lang.String m_GetItemsSearchCondition

  Description copied from class: `UncachedPreparedSelectorCollection`
  The search condition to use to get all items in the collection.

  can be null, indicating no clause is needed.

  (Unpublished)

### m_ItemCount

    protected int m_ItemCount

  Description copied from class: `UncachedPreparedSelectorCollection`
  The number of items in this collection, or -1 if unknown.

  (Unpublished)

### m_RecentItems

    protected oracle.ifs.common.UncachedPreparedSelectorCollection.ItemLink m_RecentItems

  Description copied from class: `UncachedPreparedSelectorCollection`
  A linked list of the "n" items most recently returned by getItems(String), with the most recent at the head and the least recent at the tail of the list.

  (Unpublished)

### m_MaximumRecentItems

    protected int m_MaximumRecentItems

  Description copied from class: `UncachedPreparedSelectorCollection`
  The maximum length of m_RecentItems.

  (Unpublished)

Constructor Detail

### UncachedPreparedSelectorCollection

    public UncachedPreparedSelectorCollection(S_PreparedSelector sel,
                                              java.lang.String className,
                                              java.lang.String getItemsClause,
                                              int maxRecentItems)
                                       throws IfsException

  Constructs a collection of S_LibraryObjects.

  Parameters:
    `sel` - the S_PreparedSelector used to obtain the items in the Collection
    `className` - the full classname of the objects in this Collection; must be S_LibraryObject or a subclass of S_LibraryObject; if null, S_LibraryObject is used
    `getItemsClause` - the search condition to use when selection all items
    `maxRecentItems` - the maximum number of items recently returned by `getItems(String)` to cache; typical values are 1 to 50, or 0 to disable caching
  Throws:
    `IfsException` - 12210: if the operation fails
  (Unpublished)

### UncachedPreparedSelectorCollection

    public UncachedPreparedSelectorCollection(PreparedSelector sel,
                                              java.lang.String className,
                                              java.lang.String getItemsClause,
                                              int maxRecentItems)
                                       throws IfsException

  Constructs a collection of LibraryObjects.

  Parameters:
    `sel` - the PreparedSelector used to obtain the items in the Collection
    `className` - the full classname of the objects in this Collection; must be LibraryObject or a subclass of LibraryObject; if null, LibraryObject is used
    `getItemsClause` - the search condition to use when selection all items
    `maxRecentItems` - the maximum number of items recently returned by `getItems(String)` to cache; typical values are 1 to 50, or 0 to disable caching
  Throws:
    `IfsException` - 12210: if the operation fails
  (Unpublished)

Method Detail

### getItemCount

    public int getItemCount()
                     throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Gets the number of items in this Collection.

  This collection type does not support this operation.

  Specified by:
    `getItemCount` in interface `Collection`
  Returns:
    the number of items in this Collection
  Throws:
    `IfsException` - 19008: in all cases
  (Published)

### getItems

    public java.lang.Object[] getItems()
                                throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Gets an array containing the items in this Collection.

  Specified by:
    `getItems` in interface `Collection`
  Returns:
    the items in this Collection
  Throws:
    `IfsException` - 12212: if the operation fails
  (Published)

### getItems

    public java.lang.Object getItems(int index)
                              throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Gets the specified item in this Collection.

  This collection type does not support this operation.

  Specified by:
    `getItems` in interface `Collection`
  Parameters:
    `index` - the zero-based index of the item
  Returns:
    the item
  Throws:
    `IfsException` - 19008: in all cases
  (Published)

### getItems

    public java.lang.Object getItems(java.lang.String name)
                              throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Gets the specified item in this Collection.

  Specified by:
    `getItems` in interface `Collection`
  Parameters:
    `name` - the name of the item
  Returns:
    the item
  Throws:
    `IfsException` - (IFS-12214) if the operation fails
  (Published)

### getItemByUpperCaseName

    public java.lang.Object getItemByUpperCaseName(java.lang.String upperCaseName)
                                            throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Gets the specified item in this Collection by uppercase name.

  Specified by:
    `getItemByUpperCaseName` in interface `Collection`
  Parameters:
    `upperCaseName` - the name of the item
  Returns:
    the item
  Throws:
    `IfsException` - 12214: if the operation fails
  (Unpublished)

### checkItemByUpperCaseName

    public java.lang.Object checkItemByUpperCaseName(java.lang.String upperCaseName)
                                              throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Gets the specified item in this Collection by uppercase name, and returns null if not found.

  Specified by:
    `checkItemByUpperCaseName` in interface `Collection`
  Parameters:
    `upperCaseName` - the name of the item
  Returns:
    the item, or null if not found
  Throws:
    `IfsException` - 12214: if the operation fails
  (Unpublished)

### getItemsVector

    public java.util.Vector getItemsVector()
                                    throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Gets a vector containing the items in this Collection.

  The order of the items in the vector is identical to the order of the items in the array returned by `getItems()`.

  Specified by:
    `getItemsVector` in interface `Collection`
  Returns:
    a vector containing the items in this Collection
  Throws:
    `IfsException` - 12215: if the operation fails
  (Published)

### reset

    public void reset()
               throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Resets this Collection.

  Resetting a Collection causes the items in it to be redetermined.

  Specified by:
    `reset` in interface `Collection`
  Throws:
    `IfsException` - 12216: if the operation fails
  (Unpublished)

### resolve

    protected final void resolve()
                          throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Ensures the items in this Collection are resolved.

  Throws:
    `IfsException` - 12201: if the operation fails
  (Unpublished)

### handleEvent

    public void handleEvent(IfsEvent event)
                     throws IfsException

  Description copied from class: `UncachedPreparedSelectorCollection`
  Handles the specified event. This results in the Collection being reset.

  Specified by:
    `handleEvent` in interface `IfsEventHandler`
  Parameters:
    `event` - the event
  Throws:
    `IfsException` - if the operation fails
  (Published)

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD