class Panini::Language
- Panini::Language
- Reference
- Object
Defined in:
language.crConstant Summary
-
EPSILON =
Lang.from(Alphabet::EPSILON)
-
PHI =
Lang.new
Constructors
- .new(operation : Regularity, *constituents : Language, ignore_epsilon = false)
- .new(*, membership = NO_MEMBERSHIP, criterion : String -> Bool = REJECT_ALL, alphabet : Panini::Alphabet = Alphabet::NIL, min_size : Int32 = 0, max_size : Int32 = INFINITY, name : String = Helper.random_name)
- .new(*, alphabets : Tuple, **named_args)
Class Method Summary
Instance Method Summary
- #**(n, ignore_epsilon = false)
-
#+(other : self, ignore_epsilon = false)
concatenation
-
#|(other : self)
union
-
#~
closure
- #alphabet : Panini::Alphabet
-
#criterion : String -> Bool
TODO replace with REJECT_ALL?
-
#includes?(string : String)
only membership is inclusion type, rest all are in reality exclusion types if membership test passes, language contains the string if other tests fail, language does not contain the string if all other tests pass, only then language contains the string
- #includes_epsilon?
- #max_size : Int32
- #membership : Set(String)
- #min_size : Int32
- #name : String
- #nfa_datum
- #regular?
- #to_dfa
- #to_nfa
- #words(size)
Constructor Detail
def self.new(*, membership = NO_MEMBERSHIP, criterion : String -> Bool = REJECT_ALL, alphabet : Panini::Alphabet = Alphabet::NIL, min_size : Int32 = 0, max_size : Int32 = INFINITY, name : String = Helper.random_name)
#
Class Method Detail
Instance Method Detail
def includes?(string : String)
#
only membership is inclusion type, rest all are in reality exclusion types if membership test passes, language contains the string if other tests fail, language does not contain the string if all other tests pass, only then language contains the string