class TLParser::Type

Defined in:

tl_parser/tl/type.cr

Constructors

Class Method Summary

Instance Method Summary

Constructor Detail

def self.new(namespace : Array(String), name : String, bare : Bool = false, generic_ref : Bool = false, generic_arg : Nil | TLParser::Type = nil) #

[View source]

Class Method Detail

def self.parse(str : String) #

[View source]

Instance Method Detail

def ==(other) #
Description copied from class Reference

Returns false (other can only be a Value here).


[View source]
def bare : Bool #

Whether this type is bare or boxed.


[View source]
def bare=(bare : Bool) #

Whether this type is bare or boxed.


[View source]
def find_generic_refs #

[View source]
def generic_arg : Type | Nil #

The generic argument's type, if #generic_ref is true.


[View source]
def generic_arg=(generic_arg : Type | Nil) #

The generic argument's type, if #generic_ref is true.


[View source]
def generic_ref : Bool #

Whether the type name refers to a generic definition.


[View source]
def generic_ref=(generic_ref : Bool) #

Whether the type name refers to a generic definition.


[View source]
def name : String #

The name of the type.


[View source]
def name=(name : String) #

The name of the type.


[View source]
def namespace : Array(String) #

The namespace components of the type.


[View source]
def namespace=(namespace : Array(String)) #

The namespace components of the type.


[View source]
def namespace_str(joiner = ".", proc : String -> String = ->(str : String) do str end) #

[View source]
def to_s(io) #

[View source]