类 AutoIncrementZerofillUtils


  • public class AutoIncrementZerofillUtils
    extends Object
    自动递增填充零
    版本:
    创建时间:2018年12月10日
    作者:
    ylyue
    • 构造器详细资料

      • AutoIncrementZerofillUtils

        public AutoIncrementZerofillUtils()
    • 方法详细资料

      • getInitValue

        public static String getInitValue​(int length)
        获得初始化值,自动填充零
        参数:
        length - 初始化长度
        返回:
        如:0001
      • autoIncrement

        public static String autoIncrement​(String str)
        字符串尾部值自动递增
        参数:
        str - 尾部值是 Integer 类型
        返回:
        自动递增后的值
        抛出:
        ParamException - 如:("999", "str999")
      • autoDecr

        public static String autoDecr​(String str)
        字符串尾部值自动递减
        参数:
        str - 尾部值是 Integer 类型
        返回:
        自动递减后的值