Class DefaultShortCodeServiceImpl
java.lang.Object
icu.easyj.core.util.shortcode.impls.DefaultShortCodeServiceImpl
- All Implemented Interfaces:
IShortCodeService
- Direct Known Subclasses:
MinLengthShortCodeServiceImpl
@LoadLevel(name="default",
order=200)
public class DefaultShortCodeServiceImpl
extends Object
implements IShortCodeService
long型ID 与 短字符串 互相转换服务 默认实现
- Author:
- wangliang181230
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
charTable
protected final char[] charTable字符集 -
firstChar
-
-
Constructor Details
-
DefaultShortCodeServiceImpl
public DefaultShortCodeServiceImpl() -
DefaultShortCodeServiceImpl
public DefaultShortCodeServiceImpl(char[] charTable)
-
-
Method Details
-
toCode
Description copied from interface:IShortCodeServicelong型ID 转换为 短字符串- Specified by:
toCodein interfaceIShortCodeService- Parameters:
id- ID(必须大于等于0)- Returns:
- 短字符串
-
toId
Description copied from interface:IShortCodeService短字符串 转换为 long长整形ID- Specified by:
toIdin interfaceIShortCodeService- Parameters:
shortCode- 短字符串- Returns:
- 原ID
-