class Ven::Suite::MGenericFunction
Overview
An abstract callable entity that supervises a list of
MFunction
s.
Defined in:
ven/suite/model.crConstructors
Instance Method Summary
- #[](*args, **options)
- #[](*args, **options, &)
-
#add(variant : MFunction) : self
Adds variant to the list of variants this generic supervises.
-
#add!(variant : MFunction) : self
Adds variant to the list of variants this generic supervises.
- #field(name)
- #leading?(type)
-
#length
Returns the length (#) of this model.
- #name : String
- #size(*args, **options)
- #size(*args, **options, &)
- #to_s(io)
- #variant?(args) : MFunction | Nil
Instance methods inherited from class Ven::Suite::MFunction
callable?
callable?,
leading?(type : Model)
leading?,
pg(params : Array(String), given : Models)
pg,
specificity : Int32
specificity,
variant?(args : Models)
variant?
Instance methods inherited from class Ven::Suite::MClass
[]=(referent : Model, value : Model) : Model | Nil
[]=,
[]?(index : Int)[]?(index : Range) []?, callable? : Bool callable?, eqv?(other : Model) : Bool eqv?, false? : Bool false?, field(name : String) : Model | Nil field, indexable? indexable?, length : Int32 length, match(other : Model) match, nth(index : Num)
nth(range : MRange)
nth(other) nth, of?(other : MType) : Bool
of?(other : MAny)
of?(other) of?, set_referent(referent : Model, value : Model) : Model set_referent, to_bool(inverse = false) : MBool to_bool, to_num : Num to_num, to_str : Str to_str, to_vec : Vec to_vec, true? : Bool true?, weight : MWeight weight
Constructor Detail
Instance Method Detail
Adds variant to the list of variants this generic supervises. Checks if an identical variant already exists there and overwrites it with the variant if it does,
Adds variant to the list of variants this generic supervises. Does not check if an identical variant already exists, nor does it overwrite one.