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

## ru.biosoft.access
Interface DataCollection

All Superinterfaces:
  DataElement

All Known Subinterfaces:
  CollectionUnion

All Known Implementing Classes:
  AbstractDataCollection, Compartment, DataCollectionUnion, DataCollectionUnion2, Reaction

public interface DataCollection
extends DataElement

DataCollection is a set of homogeneous DataElements. Every `DataElement` can be unambiguously accessed from the collection by its name.
Method names in DataCollection whether it reasonable follows to convention for Java beans methods, otherwise to convention used by java.utils.Collection.

See Also:
  `DataElement`

Field Summary
`static java.lang.String` | `CHILDREN_NODE_IMAGE` Property for storing of image file names used for nodes of DataElement elements stored in `LocalRepository` collection
`static java.lang.String` | `CHILDREN_NODE_VISIBLE` Property for storing of visible state.
`static java.lang.String` | `CLASS_PROPERTY` Property for storing class of data collection.
`static java.lang.String` | `CLASSPATH_JAR_PROPERTY` Property for storing class of data collection.
`static java.lang.String` | `COMPARATOR_OBJECT`
`static java.lang.String` | `CONFIG_FILE_PROPERTY` Property for storing config file name.
`static java.lang.String` | `CONFIG_PATH_PROPERTY` Property for storing path to data collection config file.
`static java.lang.String` | `DATA_ELEMENT_CLASS_PROPERTY` Property for storing class name of data elements stored in this data collection.
`static java.lang.String` | `DEFAULT_CONFIG_FILE` Property for storing name of default data collection's config file.
`static java.lang.String` | `DEFAULT_CONFIG_SUFFIX` Property for storing default suffix of data collection's config file.
`static java.lang.String` | `DEFAULT_FILTER_CONFIG_SUFFIX` Property for storing suffix of `FilteredDataCollection` data collections
`static java.lang.String` | `DEFAULT_FORMAT_CONFIG_SUFFIX` Property for storing suffix of `FileEntryCollection` data collections
`static java.lang.String` | `DEFAULT_NODE_CONFIG_SUFFIX` Property for storing suffix of `LocalRepository` data collections
`static java.lang.String` | `DEFAULT_REPOSITORY` Property for storing name of default repository file.
`static java.lang.String` | `DESCRIPTION_PROPERTY` Property for storing data collection description.
`static java.lang.String` | `DISPLAY_NAME_PROPERTY` Property for storing display name of data collection.
`static java.lang.String` | `FILE_PATH_PROPERTY` Property for storing path to data collection file.
`static java.lang.String` | `FILE_PROPERTY` Property for storing name of data collection's file.
`static java.lang.String` | `FILTER_PROPERTY` Property for storing filter of data collection's file.
`static java.lang.String` | `ID_FORMAT` Format for automatical name (identifier) generation.
`static java.lang.String` | `IS_ROOT` Indicates whether this data collection should be registered as root by `CollectionFactory.registerRoot(ru.biosoft.access.DataCollection)`.
`static java.lang.String` | `JOB_CONTROL_PROPERTY`
`static java.lang.String` | `LATE_CHILDREN_INITIALIZATION` Property for storing of
`static java.lang.String` | `MUTABLE` Property for checking whether the data collection is mutable
`static java.lang.String` | `NAME_PROPERTY` Property for storing name of data collection.
`static java.lang.String` | `NEXT_CONFIG` Property for storing name of primary data collection config file.
`static java.lang.String` | `NODE_IMAGE` Property for storing of image file names used for nodes of `LocalRepository` collections
`static java.lang.String` | `NODE_VISIBLE` Property for storing of visible flag.
`static java.lang.String` | `PRIMARY_COLLECTION`
`static java.lang.String` | `REMOVE_CHILDREN` When removing data element from this DC, whether to remove its children
`static java.lang.String` | `TRANSFORMER_CLASS` Property for storing class of transformer for `TransformedDataCollection` collections

Method Summary
`void` | `addDataCollectionListener(DataCollectionListener l)` Add a listener to the list that's notified each time a change to the data collection occurs.
`void` | `close()` Closes data collection, releases all resources.
`boolean` | `contains(DataElement element)` Returns true if this data collection contains the specified element, false otherwise
`boolean` | `contains(java.lang.String name)` Returns true if this data collection contains the element with the specified name, false otherwise
`DataElement` | `get(java.lang.String name)` Returns the `DataElement` with the specified name.
`java.lang.String` | `getCompleteName()` Returns complete name of data collection.
`java.lang.Class` | `getDataElementType()` Returns the type of DataElements stored in the data collection.
`DataCollectionInfo` | `getInfo()` Returns additional info for this data collection.
`java.util.List` | `getNameList()` Returns an unmodifiable view of the data element name list.
`int` | `getSize()` Returns the number of elements in this data collection.
`boolean` | `isMutable()` Returns true if this data collection is mutable, false otherwise.
`boolean` | `isNotificationEnabled()`
`boolean` | `isPropagationEnabled()`
`java.util.Iterator` | `iterator()` Returns an iterator over the data elements in this collection.
`void` | `propagateElementChanged(DataCollection source, DataCollectionEvent primaryEvent)`
`void` | `propagateElementWillChange(DataCollection source, DataCollectionEvent primaryEvent)`
`DataElement` | `put(DataElement obj)` Adds the specified data element to the collection.
`void` | `release(java.lang.String dataElementName)` Release DataElement with the specified name from the DataCollection cache.
`void` | `remove(java.lang.String name)` Removes the specified data element from the collection, if present.
`void` | `removeDataCollectionListener(DataCollectionListener l)` Remove a listener from the list that's notified each time a change to the data collection occurs.
`void` | `setNotificationEnabled(boolean isEnabled)`
`void` | `setPropagationEnabled(boolean isEnabled)`

Methods inherited from interface ru.biosoft.access.DataElement
`getName, getOrigin`

Field Detail

### NAME_PROPERTY

    public static final java.lang.String NAME_PROPERTY

  Property for storing name of data collection.

  See Also:
    Constant Field Values

### DISPLAY_NAME_PROPERTY

    public static final java.lang.String DISPLAY_NAME_PROPERTY

  Property for storing display name of data collection.

  See Also:
    Constant Field Values

### CLASS_PROPERTY

    public static final java.lang.String CLASS_PROPERTY

  Property for storing class of data collection.

  See Also:
    Constant Field Values

### DATA_ELEMENT_CLASS_PROPERTY

    public static final java.lang.String DATA_ELEMENT_CLASS_PROPERTY

  Property for storing class name of data elements stored in this data collection.

  See Also:
    Constant Field Values

### DESCRIPTION_PROPERTY

    public static final java.lang.String DESCRIPTION_PROPERTY

  Property for storing data collection description. Can be in HTML format.

  See Also:
    Constant Field Values

### CLASSPATH_JAR_PROPERTY

    public static final java.lang.String CLASSPATH_JAR_PROPERTY

  Property for storing class of data collection.

  See Also:
    Constant Field Values

### CONFIG_PATH_PROPERTY

    public static final java.lang.String CONFIG_PATH_PROPERTY

  Property for storing path to data collection config file.

  See Also:
    Constant Field Values

### CONFIG_FILE_PROPERTY

    public static final java.lang.String CONFIG_FILE_PROPERTY

  Property for storing config file name.

  See Also:
    Constant Field Values

### FILE_PATH_PROPERTY

    public static final java.lang.String FILE_PATH_PROPERTY

  Property for storing path to data collection file.

  See Also:
    Constant Field Values

### FILE_PROPERTY

    public static final java.lang.String FILE_PROPERTY

  Property for storing name of data collection's file.

  See Also:
    Constant Field Values

### FILTER_PROPERTY

    public static final java.lang.String FILTER_PROPERTY

  Property for storing filter of data collection's file.

  See Also:
    Constant Field Values

### DEFAULT_CONFIG_FILE

    public static final java.lang.String DEFAULT_CONFIG_FILE

  Property for storing name of default data collection's config file.

  See Also:
    Constant Field Values

### DEFAULT_REPOSITORY

    public static final java.lang.String DEFAULT_REPOSITORY

  Property for storing name of default repository file.

  See Also:
    Constant Field Values

### DEFAULT_CONFIG_SUFFIX

    public static final java.lang.String DEFAULT_CONFIG_SUFFIX

  Property for storing default suffix of data collection's config file.

  See Also:
    Constant Field Values

### DEFAULT_NODE_CONFIG_SUFFIX

    public static final java.lang.String DEFAULT_NODE_CONFIG_SUFFIX

  Property for storing suffix of `LocalRepository` data collections

  See Also:
    Constant Field Values

### DEFAULT_FORMAT_CONFIG_SUFFIX

    public static final java.lang.String DEFAULT_FORMAT_CONFIG_SUFFIX

  Property for storing suffix of `FileEntryCollection` data collections

  See Also:
    Constant Field Values

### DEFAULT_FILTER_CONFIG_SUFFIX

    public static final java.lang.String DEFAULT_FILTER_CONFIG_SUFFIX

  Property for storing suffix of `FilteredDataCollection` data collections

  See Also:
    Constant Field Values

### NODE_IMAGE

    public static final java.lang.String NODE_IMAGE

  Property for storing of image file names used for nodes of `LocalRepository` collections

  See Also:
    Constant Field Values

### CHILDREN_NODE_IMAGE

    public static final java.lang.String CHILDREN_NODE_IMAGE

  Property for storing of image file names used for nodes of DataElement elements stored in `LocalRepository` collection

  See Also:
    Constant Field Values

### NODE_VISIBLE

    public static final java.lang.String NODE_VISIBLE

  Property for storing of visible flag. This flag is used for defining whether current node will be displayed in a Repository tree

  See Also:
    Constant Field Values

### CHILDREN_NODE_VISIBLE

    public static final java.lang.String CHILDREN_NODE_VISIBLE

  Property for storing of visible state. This flag is used for defining whether DataElement leafs of current node will be displayed in a Repository tree

  See Also:
    Constant Field Values

### LATE_CHILDREN_INITIALIZATION

    public static final java.lang.String LATE_CHILDREN_INITIALIZATION

  Property for storing of

  See Also:
    Constant Field Values

### PRIMARY_COLLECTION

    public static final java.lang.String PRIMARY_COLLECTION

See Also:
  Constant Field Values

### TRANSFORMER_CLASS

    public static final java.lang.String TRANSFORMER_CLASS

  Property for storing class of transformer for `TransformedDataCollection` collections

  See Also:
    Constant Field Values

### MUTABLE

    public static final java.lang.String MUTABLE

  Property for checking whether the data collection is mutable

  See Also:
    Constant Field Values

### JOB_CONTROL_PROPERTY

    public static final java.lang.String JOB_CONTROL_PROPERTY

See Also:
  Constant Field Values

### NEXT_CONFIG

    public static final java.lang.String NEXT_CONFIG

  Property for storing name of primary data collection config file. It is used for `TransformedDataCollection`'s to specify primary data collection

  See Also:
    Constant Field Values

### COMPARATOR_OBJECT

    public static final java.lang.String COMPARATOR_OBJECT

See Also:
  Constant Field Values

### REMOVE_CHILDREN

    public static final java.lang.String REMOVE_CHILDREN

  When removing data element from this DC, whether to remove its children

  See Also:
    Constant Field Values

### IS_ROOT

    public static final java.lang.String IS_ROOT

  Indicates whether this data collection should be registered as root by `CollectionFactory.registerRoot(ru.biosoft.access.DataCollection)`.

  See Also:
    Constant Field Values

### ID_FORMAT

    public static final java.lang.String ID_FORMAT

  Format for automatical name (identifier) generation.

  See Also:
    Constant Field Values

Method Detail

### getSize

    public int getSize()

  Returns the number of elements in this data collection.

  Returns:
    Size of this data collection.

### getDataElementType

    public java.lang.Class getDataElementType()

  Returns the type of DataElements stored in the data collection.

  Returns:
    Type of DataElements stored in the data collection.

### isMutable

    public boolean isMutable()

  Returns true if this data collection is mutable, false otherwise.

  Returns:
    true if primary data collection is mutable,
    false otherwise..

### getInfo

    public DataCollectionInfo getInfo()

  Returns additional info for this data collection. Can return `null`.

  Returns:
    Additional info for this data collection.
  See Also:
    `DataCollectionInfo`

### contains

    public boolean contains(java.lang.String name)

  Returns true if this data collection contains the element with the specified name, false otherwise

  Parameters:
    `name` - name of data element
  Returns:
    true if this data collection contains the element with specified name,
    false otherwise

### contains

    public boolean contains(DataElement element)

  Returns true if this data collection contains the specified element, false otherwise

  Parameters:
    `element` - specified data element
  Returns:
    true if this data collection contains the element wit specified name,
    false otherwise

### get

    public DataElement get(java.lang.String name)
                    throws java.lang.Exception

  Returns the `DataElement` with the specified name. Returns `null` if the data collection contains no data element for this name.

  Throws:
    `java.lang.Exception`

### iterator

    public java.util.Iterator iterator()

  Returns an iterator over the data elements in this collection. There are no guarantees concerning the order in which the elements are returned. If the data collection is modified while an iteration over it is in progress, the results of the iteration are undefined.

### getNameList

    public java.util.List getNameList()

  Returns an unmodifiable view of the data element name list. Query operations on the returned list "read through" to the internal name list, and attempts to modify the returned list, whether direct or via its iterator, result in an `UnsupportedOperationException`. The returned list is backed by the data collection, so changes to the data collection are reflected in the returned list. The name list can be sorted or unsorted depending on the DataCollection implementing class.

  Returns:
    list of names

### put

    public DataElement put(DataElement obj)
                    throws java.lang.Exception

  Adds the specified data element to the collection. If the data collection previously contained the specified element, the old value is replaced.

  Returns:
    previous version of the data element, or null if there was no one.
  Throws:
    `java.util.UnsupportedOperationException` - if the data collection is unmutable.
    `java.lang.Exception`
  See Also:
    `isMutable()`

### remove

    public void remove(java.lang.String name)
                throws java.lang.Exception

  Removes the specified data element from the collection, if present. Notifies all listeners if the data element was removed.

  Returns:
    the removed data element.
  Throws:
    `java.util.UnsupportedOperationException` - if the data collection is unmutable.
    `java.lang.Exception` - If error occured.
  See Also:
    `isMutable()`

### addDataCollectionListener

    public void addDataCollectionListener(DataCollectionListener l)

  Add a listener to the list that's notified each time a change to the data collection occurs.

  Parameters:
    `l` - the DataCollectionListener

### removeDataCollectionListener

    public void removeDataCollectionListener(DataCollectionListener l)

  Remove a listener from the list that's notified each time a change to the data collection occurs.

  Parameters:
    `l` - the DataCollectionListener

### propagateElementWillChange

    public void propagateElementWillChange(DataCollection source,
                                           DataCollectionEvent primaryEvent)

  To do:
    comment

### propagateElementChanged

    public void propagateElementChanged(DataCollection source,
                                        DataCollectionEvent primaryEvent)

  To do:
    comment

### isPropagationEnabled

    public boolean isPropagationEnabled()

### setPropagationEnabled

    public void setPropagationEnabled(boolean isEnabled)

### isNotificationEnabled

    public boolean isNotificationEnabled()

### setNotificationEnabled

    public void setNotificationEnabled(boolean isEnabled)

### getCompleteName

    public java.lang.String getCompleteName()

  Returns complete name of data collection.

  Returns:
    Full name of DataCollection in the tree hierarchy.

### close

    public void close()
               throws java.lang.Exception

  Closes data collection, releases all resources. This method invalidates DataCollection instance.

  Throws:
    `java.lang.Exception` - If error occured.

### release

    public void release(java.lang.String dataElementName)

  Release DataElement with the specified name from the DataCollection cache.

  Pendung:
    whether this operation should be called by close operation.

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

Copyright © 2001-2003 Biosof.Ru. All Rights Reserved.