class Snowflake

Defined in:

snowflake.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(instance : Int64, ep : Int64) #

[View source]
def self.new(instance : Int64, ep : Time) #

[View source]

Instance Method Detail

def generate(time : Time, sequence : Int64 | Int32) #

[View source]
def generate(time : Int64, sequence : Int64 | Int32) #

[View source]
def next #

[View source]
def sequence : Int32 #

[View source]
def sequence=(sequence : Int32) #

[View source]
def set_epoch(ep : Time) #

[View source]
def set_epoch(ep : Int64) #

[View source]
def snowflake_to_instance(snowflake : Int64) #

[View source]
def snowflake_to_sequence(snowflake : Int) #

[View source]
def snowflake_to_timestamp(snowflake : Int64) #

[View source]