Class Base62

java.lang.Object
net.sodacan.core.util.Base62

public class Base62 extends Object
  • Constructor Details

    • Base62

      public Base62()
  • Method Details

    • encode

      public static void encode(StringBuffer sb, long value)
      A String buffer containing the provided long value encoded as a base62 string
      Parameters:
      sb -
      value -
    • encodeNextId

      public static String encodeNextId(String baseId, long nextId)
      Convert a number to base62 and append it to the supplied string.
      Parameters:
      baseId - A String containing "our" id
      nextId - A long containing the next id to append
      Returns:
      An Id string with the neextId appended