jigcell.compare.objective
Class ChainedDataGeneratorList

java.lang.Object
  extended by jigcell.compare.data.DataGeneratorList
      extended by jigcell.compare.objective.ChainedDataGeneratorList
All Implemented Interfaces:
java.lang.Cloneable, IDataGeneratorCollection, IDataGeneratorList

public final class ChainedDataGeneratorList
extends DataGeneratorList

Compactly stores additions to an existing data generator list. This class is unsynchronized and must be protected from concurrent access. Chaining only applies to lookups on generator names and keys. Attempts to copy, iterate, or examine this list other than by name or key will not reveal the chained generators. This can lead to unusual behavior such as lookups successfully completing despite the list being empty.

This code is licensed under the DARPA BioCOMP Open Source License. See LICENSE for more details.

Author:
Nicholas Allen

Nested Class Summary
 
Nested classes/interfaces inherited from class jigcell.compare.data.DataGeneratorList
DataGeneratorList.DataGeneratorListDelegate
 
Nested classes/interfaces inherited from interface jigcell.compare.data.IDataGeneratorCollection
IDataGeneratorCollection.Key
 
Field Summary
private  IDataGeneratorList parent
          Another data generator list
 
Fields inherited from class jigcell.compare.data.DataGeneratorList
idToGenerator, indexed, list, nameToGenerator
 
Constructor Summary
ChainedDataGeneratorList(IDataGeneratorList parent)
          Chains to an existing data generator list.
 
Method Summary
 IDataGenerator get(IDataGeneratorCollection.Key key)
          A generator in the list. The id is the primary search key. This operation will be significantly accelerated if an index exists.
 IDataGenerator get(java.lang.String name)
          A generator in the list by name. This operation will be significantly accelerated if an index exists.
 
Methods inherited from class jigcell.compare.data.DataGeneratorList
add, add, addAll, addAll, asList, clear, clone, createIndex, createList, flushIndex, get, indexOf, isEmpty, iterator, iterator, remove, set, size, sort, toArray, toString
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

parent

private final IDataGeneratorList parent
Another data generator list

Constructor Detail

ChainedDataGeneratorList

public ChainedDataGeneratorList(IDataGeneratorList parent)
Chains to an existing data generator list. Generators can be added to this list without affecting the existing list.

Parameters:
parent - Data generator list
Method Detail

get

public IDataGenerator get(IDataGeneratorCollection.Key key)
A generator in the list. The id is the primary search key. This operation will be significantly accelerated if an index exists.

Specified by:
get in interface IDataGeneratorList
Overrides:
get in class DataGeneratorList
Parameters:
key - Key

get

public IDataGenerator get(java.lang.String name)
A generator in the list by name. This operation will be significantly accelerated if an index exists.

Specified by:
get in interface IDataGeneratorList
Overrides:
get in class DataGeneratorList
Parameters:
name - Name