wt.index
Class IndexerSet

java.lang.Object
  extended bywt.index.IndexerSet
All Implemented Interfaces:
Externalizable, Serializable

public class IndexerSet
extends Object
implements Externalizable

IndexerSet is a comma separated list that holds the names of indexers.

Supported API: false

Extendable: false

See Also:
Serialized Form

Field Summary
private static String CLASSNAME
           
static long EXTERNALIZATION_VERSION_UID
           
private  String indexers
           
private  Vector indexerSet
           
private static int INIITIAL_COLLECTION_SIZE
          Initial allocation size of vector to contain collection names (i.e.
private static int INIITIAL_STRBUFFER_SIZE
          Initial allocation size of string buffer used to build up the indexers field.
protected static long OLD_FORMAT_VERSION_UID
           
private static String RESOURCE
           
(package private) static long serialVersionUID
           
private static boolean VERBOSE_POLICY
           
private static long VERSION_PRE_31_UID
           
private static long VERSION_PRE_60_UID
           
 
Constructor Summary
IndexerSet()
          No-arg constuctor.
IndexerSet(String set_str)
          Constructor that takes as input the string representation of the set.
 
Method Summary
 boolean addIndexer(String indexer)
          Adds indexer to the list.
 boolean contains(String indexer)
          Determines if indexer is in the list.
 Enumeration elements()
          Returns the indexers of the list as an enumeration of type String.
protected  String getIndexers()
          Gets the value of the attribute: indexers; Set of indexers.
 boolean isEmpty()
          Returns true if there is no colection; false otherwise.
 IndexerSet merge(IndexerSet set)
          Performs the union of the current set of indexers with the given one.
 void readExternal(ObjectInput input)
          Reads the non-transient fields of this class from an external source.
private  boolean readOldVersion(ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source, which is not the current version.
protected  boolean readVersion(IndexerSet thisObject, ObjectInput input, long readSerialVersionUID, boolean passThrough, boolean superDone)
          Reads the non-transient fields of this class from an external source.
private  void rebuildState()
           
private  void rebuildStateFrom(IndexerSet decoded_indexer_set)
           
private  void rebuildStateFrom(Vector decoded_vector)
           
 boolean removeIndexer(String indexer)
          Removes indexer from the list.
protected  void setIndexers(String a_Indexers)
          Sets the value of the attribute: indexers; Set of indexers.
private  void synchronizeState()
          Makes sure that the indexers and indexerSet fields are consistent.
 String toString()
          Returns a string representation of the indexer set.
 void writeExternal(ObjectOutput output)
          Writes the non-transient fields of this class to an external source.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

RESOURCE

private static final String RESOURCE
See Also:
Constant Field Values

CLASSNAME

private static final String CLASSNAME

indexers

private String indexers

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

EXTERNALIZATION_VERSION_UID

public static final long EXTERNALIZATION_VERSION_UID
See Also:
Constant Field Values

OLD_FORMAT_VERSION_UID

protected static final long OLD_FORMAT_VERSION_UID
See Also:
Constant Field Values

VERSION_PRE_60_UID

private static final long VERSION_PRE_60_UID
See Also:
Constant Field Values

VERSION_PRE_31_UID

private static final long VERSION_PRE_31_UID
See Also:
Constant Field Values

VERBOSE_POLICY

private static boolean VERBOSE_POLICY

indexerSet

private Vector indexerSet

INIITIAL_STRBUFFER_SIZE

private static final int INIITIAL_STRBUFFER_SIZE
Initial allocation size of string buffer used to build up the indexers field.

See Also:
Constant Field Values

INIITIAL_COLLECTION_SIZE

private static final int INIITIAL_COLLECTION_SIZE
Initial allocation size of vector to contain collection names (i.e. indexerSet field).

See Also:
Constant Field Values
Constructor Detail

IndexerSet

public IndexerSet()
No-arg constuctor.

Supported API: false


IndexerSet

public IndexerSet(String set_str)
Constructor that takes as input the string representation of the set.

Supported API: false

Parameters:
set_str -
Method Detail

writeExternal

public void writeExternal(ObjectOutput output)
                   throws IOException
Writes the non-transient fields of this class to an external source.

Supported API: false

Specified by:
writeExternal in interface Externalizable
Parameters:
output -
Throws:
IOException

readExternal

public void readExternal(ObjectInput input)
                  throws IOException,
                         ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Specified by:
readExternal in interface Externalizable
Parameters:
input -
Throws:
IOException
ClassNotFoundException

readVersion

protected boolean readVersion(IndexerSet thisObject,
                              ObjectInput input,
                              long readSerialVersionUID,
                              boolean passThrough,
                              boolean superDone)
                       throws IOException,
                              ClassNotFoundException
Reads the non-transient fields of this class from an external source.

Supported API: false

Parameters:
thisObject -
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

readOldVersion

private boolean readOldVersion(ObjectInput input,
                               long readSerialVersionUID,
                               boolean passThrough,
                               boolean superDone)
                        throws IOException,
                               ClassNotFoundException
Reads the non-transient fields of this class from an external source, which is not the current version.

Parameters:
input -
readSerialVersionUID -
passThrough -
superDone -
Returns:
boolean
Throws:
IOException
ClassNotFoundException

getIndexers

protected String getIndexers()
Gets the value of the attribute: indexers; Set of indexers.

Supported API: false

Returns:
String

setIndexers

protected void setIndexers(String a_Indexers)
Sets the value of the attribute: indexers; Set of indexers.

Supported API: false

Parameters:
a_Indexers -

addIndexer

public boolean addIndexer(String indexer)
Adds indexer to the list.

Supported API: false

Parameters:
indexer -
Returns:
boolean

removeIndexer

public boolean removeIndexer(String indexer)
Removes indexer from the list.

Supported API: false

Parameters:
indexer -
Returns:
boolean

contains

public boolean contains(String indexer)
Determines if indexer is in the list. Returns 'true' if this is the case, 'false' otherwise.

Supported API: false

Parameters:
indexer -
Returns:
boolean

isEmpty

public boolean isEmpty()
Returns true if there is no colection; false otherwise.

Supported API: false

Returns:
boolean

elements

public Enumeration elements()
Returns the indexers of the list as an enumeration of type String.

Supported API: false

Returns:
Enumeration

merge

public IndexerSet merge(IndexerSet set)
Performs the union of the current set of indexers with the given one.

Supported API: false

Parameters:
set -
Returns:
IndexerSet

toString

public String toString()
Returns a string representation of the indexer set.

Supported API: false

Returns:
String

synchronizeState

private void synchronizeState()
Makes sure that the indexers and indexerSet fields are consistent. This method should be called before using the indexers and indexerSet fields in any of the methods except the constructors, externalization methods, and setIndexers.


rebuildState

private void rebuildState()

rebuildStateFrom

private void rebuildStateFrom(Vector decoded_vector)

rebuildStateFrom

private void rebuildStateFrom(IndexerSet decoded_indexer_set)