class Dawg::Node
- Dawg::Node
- Dawg::AbstractNode
- Reference
- Object
Defined in:
dawg/node/node.crConstructors
Instance Method Summary
-
#==(other)
Returns
false
(other can only be aValue
here). - #[](letter : Char)
- #each_edge(&)
- #edge_count : Int32
- #edge_count=(edge_count : Int32)
- #edges : Hash(Char, Dawg::Node)
- #edges=(edges : Hash(Char, ::Dawg::Node))
-
#hash
Generates an
UInt64
hash value for this object. - #id : Int32
- #id=(id : Int32)
- #index : Int32
- #index=(index : Int32)
-
#to_s
Returns a nicely readable and concise string representation of this object, typically intended for users.
Instance methods inherited from class Dawg::AbstractNode
[](letter : Char)
[],
each_edge(&)
each_edge,
final : Bool
final,
final=(final : Bool)
final=
Constructor Detail
Instance Method Detail
Returns false
(other can only be a Value
here).
Generates an UInt64
hash value for this object.
This method must have the property that a == b
implies a.hash == b.hash
.
The hash value is used along with #==
by the Hash
class to determine if two objects
reference the same hash key.
Subclasses must not override this method. Instead, they must define hash(hasher)
,
though usually the macro def_hash
can be used to generate this method.
Returns a nicely readable and concise string representation of this object, typically intended for users.
This method should usually not be overridden. It delegates to
#to_s(IO)
which can be overridden for custom implementations.
Also see #inspect
.