public interface Oid
Modifier and Type | Field and Description |
---|---|
static int |
_CC_0 |
static int |
_CC_a |
static int |
_CC_A |
static int[] |
_CC_EXTRA |
static int |
_CC_RANGE |
static int |
_CHAR_PER_INT |
static int |
_INT_LEN |
static Pattern |
_oidPattern |
static Random |
_random |
static int |
OID_LENGTH |
Modifier and Type | Method and Description |
---|---|
static int |
_escOid(int v) |
static int[] |
getRandomInts(int length)
The function used to generate a list of random integers to construct OID.
|
static boolean |
isValidOid(String value) |
static String |
mergeOid(String oid1,
String oid2)
Creates a new OID based two OIDs.
|
static String |
nextOid()
Returns the next unique object ID.
|
static final int OID_LENGTH
static final int[] _CC_EXTRA
static final int _CC_RANGE
static final int _CC_0
static final int _CC_A
static final int _CC_a
static final int _INT_LEN
static final int _CHAR_PER_INT
static final Pattern _oidPattern
static final Random _random
static String nextOid()
static String mergeOid(String oid1, String oid2)
> To shorten the result OID, we retrieve the substring of [oid1] and [oid2] and concatenate them together. Of course, there might be conflict but the chance is so low that we can ignore (like OID generator),
static boolean isValidOid(String value)
static int[] getRandomInts(int length)
The default implementation uses [Random] to generate the random number. When running at the browser, it is better to replace with `Crypto.getRandomValues`.
static int _escOid(int v)
Copyright © 2020. All rights reserved.