Tangence::Meta::Type - structure representing one Tangence value type
Tangence::Meta::Type
Tangence
This data structure object represents information about a type, such as a method or event argument, a method return value, or a property element type.
Due to their simple contents and immutable nature, these objects may be implemented as singletons.
$type = Tangence::Meta::Type->new( $primitive )
Returns an instance to represent the given primitive type signature.
$type = Tangence::Meta::Type->new( $aggregate => $member_type )
Returns an instance to represent the given aggregation of the given type instance.
$type = Tangence::Meta::Type->new_from_sig( $sig )
Parses the given full Tangence type signature and returns an instance to represent it.
$agg = $type->aggregate
Returns "prim" for primitive types, or the aggregation name for list and dict aggregate types.
"prim"
$member_type = $type->member_type
Returns the member type for aggregation types. Throws an exception for primitive types.
$sig = $type->sig
Returns the Tangence type signature for the type.
Paul Evans <leonerd@leonerd.org.uk>
To install Tangence, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Tangence
CPAN shell
perl -MCPAN -e shell install Tangence
For more information on module installation, please visit the detailed CPAN module installation guide.