public class SecondSnowflakeIdStateParser extends SnowflakeIdStateParser
| 限定符和类型 | 字段和说明 |
|---|---|
static java.time.format.DateTimeFormatter |
DATE_TIME_FORMATTER |
DELIMITER, epoch, machineBit, machineLeft, machineMask, sequenceBit, sequenceMask, timestampBit, timestampLeft, timestampMask| 构造器和说明 |
|---|
SecondSnowflakeIdStateParser(long epoch,
int timestampBit,
int machineBit,
int sequenceBit) |
| 限定符和类型 | 方法和说明 |
|---|---|
protected java.time.format.DateTimeFormatter |
getDateTimeFormatter() |
protected long |
getDiffTime(java.time.LocalDateTime timestamp) |
protected java.time.LocalDateTime |
getTimestamp(long diffTime) |
static SecondSnowflakeIdStateParser |
of(SnowflakeId snowflakeId) |
parse, parsepublic static final java.time.format.DateTimeFormatter DATE_TIME_FORMATTER
public SecondSnowflakeIdStateParser(long epoch,
int timestampBit,
int machineBit,
int sequenceBit)
protected java.time.format.DateTimeFormatter getDateTimeFormatter()
protected java.time.LocalDateTime getTimestamp(long diffTime)
getTimestamp 在类中 SnowflakeIdStateParserprotected long getDiffTime(java.time.LocalDateTime timestamp)
getDiffTime 在类中 SnowflakeIdStateParserpublic static SecondSnowflakeIdStateParser of(SnowflakeId snowflakeId)