|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectdata.Mapping<T,U>
public class Mapping<T,U>
Mapping of spotIDs to corresponding indices of RNA sets
Constructor Summary | |
---|---|
Mapping()
Constructor to initialize the Mapping |
Method Summary | |
---|---|
void |
addMap(T spotId,
U attribute)
add the values to the internal map as well as to the map containing the inverted values (attribute --> spotID) |
void |
changeMap(T spotId,
U attribute)
Change the attribute of a specific spotID |
boolean |
containsAttribute(U attribute)
Returns true if the given attribute exists in the Mapping |
boolean |
containsSpot(T spotId)
Returns true if the given key exists in the Mapping |
U |
getAttribute(T spotId)
Retrieves the attribute for one given key |
java.util.ArrayList<T> |
getSpotId(U attribute)
Retrieves the list of keys for one given attribute |
java.util.Iterator<T> |
iterate()
Provides an iterator to iterate over the keys of the Mapping |
java.util.Iterator<T> |
iterateSpots(U attr)
Provides an iterator to iterate over the keys corresponding to a certain attribute |
int |
mapSize()
Returns the size of the Mapping (=number of entries) |
void |
removeAllSpots(java.util.ArrayList<T> spots)
Removes all keys given in a list |
void |
removeAttribute(U attribute)
Removes all entries corresponding to a specific attribute from the Mapping |
void |
removeSpot(T spotId)
Removes a given key from the Mapping |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Mapping()
Method Detail |
---|
public void addMap(T spotId, U attribute)
spotId
- attribute
- public void removeSpot(T spotId)
spotId
- Key that will be removedpublic void removeAllSpots(java.util.ArrayList<T> spots)
spots
- List of keys that will be removedpublic void removeAttribute(U attribute)
attribute
- Attribute for which all corresponding entries will be removedpublic void changeMap(T spotId, U attribute)
spotId
- attribute
- public boolean containsSpot(T spotId)
spotId
-
public boolean containsAttribute(U attribute)
attribute
-
public java.util.Iterator<T> iterate()
public java.util.Iterator<T> iterateSpots(U attr)
public java.util.ArrayList<T> getSpotId(U attribute)
attribute
- The attribute for which the list of keys will be given
public U getAttribute(T spotId)
spotId
- The key for which the attribute will be given
public int mapSize()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |