|
Rice Pastry API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IdFactory
Method Summary | |
---|---|
Id |
buildId(byte[] material)
Builds a protocol-specific Id given the source data. |
Id |
buildId(int[] material)
Builds a protocol-specific Id given the source data. |
Id |
buildId(java.lang.String string)
Builds a protocol-specific Id by using the hash of the given string as source data. |
Id.Distance |
buildIdDistance(byte[] material)
Builds a protocol-specific Id.Distance given the source data. |
Id |
buildIdFromToString(char[] chars,
int offset,
int length)
Builds an Id by converting the given toString() output back to an Id. |
Id |
buildIdFromToString(java.lang.String string)
Builds an Id by converting the given toString() output back to an Id. |
IdRange |
buildIdRange(Id cw,
Id ccw)
Creates an IdRange given the CW and CCW ids. |
IdRange |
buildIdRangeFromPrefix(java.lang.String string)
Builds an IdRange based on a prefix. |
IdSet |
buildIdSet()
Creates an empty IdSet. |
IdSet |
buildIdSet(java.util.SortedMap map)
Creates an empty IdSet. |
NodeHandleSet |
buildNodeHandleSet()
Creates an empty NodeHandleSet. |
Id |
buildRandomId(java.util.Random rng)
Builds a random protocol-specific Id. |
Id |
buildRandomId(RandomSource rng)
|
int |
getIdToStringLength()
Returns the length a Id.toString should be. |
Method Detail |
---|
Id buildId(byte[] material)
material
- The material to use
Id buildId(int[] material)
material
- The material to use
Id buildId(java.lang.String string)
string
- The string to use as source data
Id buildRandomId(java.util.Random rng)
rng
- A random number generator
Id buildRandomId(RandomSource rng)
Id buildIdFromToString(java.lang.String string)
string
- The toString() representation of an Id
Id buildIdFromToString(char[] chars, int offset, int length)
chars
- The character arrayoffset
- The offset to start reading atlength
- The length to read
IdRange buildIdRangeFromPrefix(java.lang.String string)
string
- The toString() representation of an Id
int getIdToStringLength()
Id.Distance buildIdDistance(byte[] material)
material
- The material to use
IdRange buildIdRange(Id cw, Id ccw)
cw
- The clockwise Idccw
- The counterclockwise Id
IdSet buildIdSet()
IdSet buildIdSet(java.util.SortedMap map)
NodeHandleSet buildNodeHandleSet()
|
Rice Pastry API | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |