module Dynany(T)
Direct including types
Defined in:
dynany.crInstance Method Summary
-
#[](path : Enumerable) : T::Any
Returns the value corresponding to the path.
-
#[]=(key : Int, value : T::Any)
Sets the value of key to the given value.
-
#[]=(path : Enumerable, value : T::Any) : T::Any
Sets the value of key to the given value.
-
#[]?(path : Enumerable) : T::Any | Nil
Returns the value corresponding to the path.
-
#delete(index : Int) : T::Any | Nil
Deletes the element at the given index.
-
#delete(key : String) : T::Any | Nil
Deletes the key-value pair.
-
#delete(path : Enumerable) : T::Any
Removes the element corresponding to the path.
Instance Method Detail
def [](path : Enumerable) : T::Any
#
Returns the value corresponding to the path. If not found, raise.
def []?(path : Enumerable) : T::Any | Nil
#
Returns the value corresponding to the path. If not found, returns nil.