abstract class Docopt::LeafPattern
- Docopt::LeafPattern
- Docopt::Pattern
- Reference
- Object
Direct Known Subclasses
Defined in:
docopt.crConstructors
Instance Method Summary
- #flat(*types)
- #match(left : Array(Pattern), collected : Nil | Array(Pattern) = nil) : Tuple(Bool, Array(Pattern), Array(Pattern))
- #name : String?
- #single_match(left)
-
#to_s
Returns a nicely readable and concise string representation of this object, typically intended for users.
- #value : Array(String) | Bool | Int32 | String | Nil
- #value=(value : Array(String) | Bool | Int32 | String | Nil)
Instance methods inherited from class Docopt::Pattern
==(other : Pattern) : Bool
==,
children : Array(Docopt::Pattern)?
children,
either : Either
either,
fix : Pattern
fix,
fix_identities(uniq = nil) : Pattern
fix_identities,
fix_repeating_arguments : Pattern
fix_repeating_arguments,
flat(*types)
flat,
hash
hash,
inspect(io)
inspect,
match(left : Array(Pattern), collected : Nil | Array(Pattern) = nil) : Tuple(Bool, Array(Pattern), Array(Pattern))
match
Constructor methods inherited from class Docopt::Pattern
new
new
Constructor Detail
def self.new(name : Nil | String, value : Array(String) | Bool | Int32 | String | Nil = nil)
#
Instance Method Detail
def match(left : Array(Pattern), collected : Nil | Array(Pattern) = nil) : Tuple(Bool, Array(Pattern), Array(Pattern))
#
def to_s
#
Description copied from class Object
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
.