bravo/object
This module provides the Object
type and functions that use it. Object
s are essential to accessing any ETS table.
Types
Functions
pub fn element(object: Object(a), index: Int) -> Option(Dynamic)
Gets the nth element of an Object
(currently 1-indexed but this may change). Fails if the index is out of range.
pub fn extract(object: Object(a)) -> Dynamic
Creates a Dynamic
from the data stored inside an Object
. This should always be a tuple.
pub fn new(tuple: a) -> Object(a)
Creates a new Object
from a tuple. Passing in a non-tuple may result in unexpected behavior.