Skip to main content

Module ids

Module ids 

Source
Expand description

Item and folder IDs.

Eagle builds an ID from the creation time in milliseconds, written in base 36, followed by 5 random base-36 characters, all upper case. Eagle’s own random part can come out shorter than 5 characters; falcon always pads it, because Eagle only loads .info folders whose name is 13 or 36 long.

Functions§

id_at
An ID for ms (milliseconds since the epoch) using rng for the suffix.
is_valid
Whether Eagle would load an .info folder with this ID.
new_id
A new ID for the current time.
timestamp
The creation time encoded in an ID’s prefix, in milliseconds.