org.space4j.indexing
Class Key

java.lang.Object
  extended by org.space4j.indexing.Key
All Implemented Interfaces:
java.io.Serializable

public class Key
extends java.lang.Object
implements java.io.Serializable

A key to be used by the Maps of the IndexManager.

See Also:
Serialized Form

Constructor Summary
Key()
          Creates a new Key.
Key(int i)
          Creates a new Key (int)
Key(int i, java.lang.String s)
          Creates a new Compound Key (int + String)
Key(java.lang.Object... objs)
           
Key(java.lang.Object obj)
           
Key(java.lang.String... args)
           
Key(java.lang.String s)
          Creates a new Key (String)
 
Method Summary
 void add(java.lang.Object value)
          Add a new value for this key.
 boolean equals(java.lang.Object obj)
           
 java.lang.Object get(int i)
           
 int hashCode()
           
 int size()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Key

public Key()
Creates a new Key.


Key

public Key(java.lang.String... args)

Key

public Key(int i,
           java.lang.String s)
Creates a new Compound Key (int + String)

Parameters:
i - An integer
s - An String

Key

public Key(int i)
Creates a new Key (int)

Parameters:
i - An integer

Key

public Key(java.lang.String s)
Creates a new Key (String)

Parameters:
s - An String

Key

public Key(java.lang.Object obj)

Key

public Key(java.lang.Object... objs)
Method Detail

add

public void add(java.lang.Object value)
Add a new value for this key. Compound keys have more than one value.

Parameters:
value - The value to be added.

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

size

public int size()

get

public java.lang.Object get(int i)


Copyright © 2005 Space4J Team. All Rights Reserved.