Package net.sodacan.core.util
Class Base62
java.lang.Object
net.sodacan.core.util.Base62
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
encode
(StringBuffer sb, long value) A String buffer containing the provided long value encoded as a base62 stringstatic String
encodeNextId
(String baseId, long nextId) Convert a number to base62 and append it to the supplied string.
-
Constructor Details
-
Base62
public Base62()
-
-
Method Details
-
encode
A String buffer containing the provided long value encoded as a base62 string- Parameters:
sb
-value
-
-
encodeNextId
Convert a number to base62 and append it to the supplied string.- Parameters:
baseId
- A String containing "our" idnextId
- A long containing the next id to append- Returns:
- An Id string with the neextId appended
-