|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.novell.util.StringCache
A class to cache strings and equate them with unique integers to allow fast comparisons for equality, etc.
Constructor Summary | |
StringCache()
Construct a StringCache with default Map implementation and default string cache initial size |
|
StringCache(int cacheSize)
Construct a StringCache with default Map implementation and passed string cache initial size |
|
StringCache(Map mapImpl,
int cacheSize)
Construct a StringCache with passed Map implementation and passed default string cache initial size |
Method Summary | |
int |
getNumber(String str)
Get the unique number given a string |
String |
getString(int number)
Get the string that corresponds to a number |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public StringCache()
public StringCache(int cacheSize)
cacheSize
- The initial cache size for the String cachepublic StringCache(Map mapImpl, int cacheSize)
mapImpl
- An Object that implements the Map interface, used
to map Strings to integers.cacheSize
- The initial cache size for the String cacheMethod Detail |
public int getNumber(String str)
str
- The string for which to get the number
public String getString(int number)
number
- The number for which to get the uri string
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |