Class Unique
java.lang.Object
de.uplanet.lucy.server.auxiliaries.Unique
Utility class to create unique identifiers and names.
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionbooleanTest wether the given string is a GUID.newGuid()Create a new GUID.newIdValue(String p_strKey) Deterministically create a new ID attribute value from the given key.intCreate a new GUID and return it's absolute hash code.Create a new unique variable name with the prefixl_idfollowed by up to nineteen decimal digits.newVariableName(String p_strPrefix) Create a new unique variable name with a specified prefix followed by up to nineteen decimal digits.
- 
Constructor Details- 
Uniquepublic Unique()Constructor.
 
- 
- 
Method Details- 
newGuidCreate a new GUID.- Returns:
- The new GUID's string representation.
 
- 
newUniqueIntpublic int newUniqueInt()Create a new GUID and return it's absolute hash code.- Returns:
- A unique integer.
 
- 
isGuidTest wether the given string is a GUID.- Parameters:
- p_strId- The string to test.
- Returns:
- trueif the given string is a GUID,- falseotherwise.
 
- 
newIdValueDeterministically create a new ID attribute value from the given key.- Parameters:
- p_strKey- A key.
- Returns:
- ID_+- <GUID>.
 
- 
newVariableNameCreate a new unique variable name with the prefixl_idfollowed by up to nineteen decimal digits.- Returns:
- The newly created unique variable name.
 
- 
newVariableNameCreate a new unique variable name with a specified prefix followed by up to nineteen decimal digits.- Parameters:
- p_strPrefix- The prefix to be used.
- Returns:
- The newly created unique variable name.
 
 
-