class Bindgen::TypeDatabase::TypeConfig
- Bindgen::TypeDatabase::TypeConfig
 - Reference
 - Object
 
Overview
Configuration of types, used in Configuration#types (The types: map
in YAML).  See TypeDatabase::Configuration.
Included Modules
- YAML::Serializable
 
Defined in:
bindgen/type_database.crConstructors
- .new(ctx : YAML::ParseContext, node : YAML::Nodes::Node)
 - .new(crystal_type : String | Nil = nil, cpp_type : String | Nil = nil, binding_type : String | Nil = nil, from_cpp : Bindgen::Template::Base = Template::None.new, to_cpp : Bindgen::Template::Base = Template::None.new, converter : Nil | String = nil, from_crystal : Bindgen::Template::Base = Template::None.new, to_crystal : Bindgen::Template::Base = Template::None.new, kind : Bindgen::Parser::Type::Kind = Parser::Type::Kind::Class, ignore : Bool = false, pass_by : Bindgen::TypeDatabase::PassBy = PassBy::Original, wrapper_pass_by : PassBy | Nil = nil, sub_class : Bool = true, copy_structure : Bool = false, generate_wrapper : Bool = true, generate_binding : Bool = true, generate_superclass : Bool = true, builtin : Bool = false, ignore_methods : Array(String) = [] of String, superclass_ignore_methods : Regex = Util::FAIL_RX, instance_variables : Hash(Regex, Bindgen::TypeDatabase::InstanceVariableConfig) = InstanceVariableConfig::Collection.new, graph_node : Bindgen::Graph::Node | Nil = nil)
 
Instance Method Summary
- 
        #anonymous? : Bool
        
          
Is this type anonymous?
 - 
        #binding_type : String | Nil
        
          
The type used in Crystal, but only in the
libbinding. - 
        #binding_type=(binding_type : String | Nil)
        
          
The type used in Crystal, but only in the
libbinding. - 
        #builtin=(builtin : Bool)
        
          
Treat this type as built-in type in C++ and Crystal.
 - 
        #builtin? : Bool
        
          
Treat this type as built-in type in C++ and Crystal.
 - 
        #converter : String | Nil
        
          
Converter for this type in Crystal.
 - 
        #converter=(converter : String | Nil)
        
          
Converter for this type in Crystal.
 - 
        #copy_structure=(copy_structure : Bool)
        
          
If the structure (as in, its non-static fields) shall be tried to replicated in Crystal.
 - 
        #copy_structure? : Bool
        
          
If the structure (as in, its non-static fields) shall be tried to replicated in Crystal.
 - 
        #cpp_type : String | Nil
        
          
The C++ type to pass it around.
 - 
        #cpp_type=(cpp_type : String | Nil)
        
          
The C++ type to pass it around.
 - 
        #crystal_pass_by : PassBy
        
          
Pass-by configuration in wrapper code.
 - 
        #crystal_type : String | Nil
        
          
The crystal name of this type.
 - 
        #crystal_type=(crystal_type : String | Nil)
        
          
The crystal name of this type.
 - #from_cpp : Template::Base
 - #from_cpp=(from_cpp : Template::Base)
 - #from_crystal : Template::Base
 - #from_crystal=(from_crystal : Template::Base)
 - 
        #generate_binding=(generate_binding : Bool)
        
          
If to generate bindings in C++ and Crystal.
 - 
        #generate_binding? : Bool
        
          
If to generate bindings in C++ and Crystal.
 - 
        #generate_superclass=(generate_superclass : Bool)
        
          
If to generate a superclass wrapper in Crystal.
 - 
        #generate_superclass? : Bool
        
          
If to generate a superclass wrapper in Crystal.
 - 
        #generate_wrapper=(generate_wrapper : Bool)
        
          
If to generate a wrapper in Crystal.
 - 
        #generate_wrapper? : Bool
        
          
If to generate a wrapper in Crystal.
 - #graph_node : Graph::Node | Nil
 - #graph_node=(graph_node : Graph::Node | Nil)
 - 
        #ignore=(ignore : Bool)
        
          
Ignore any and all methods using this type anywhere.
 - 
        #ignore? : Bool
        
          
Ignore any and all methods using this type anywhere.
 - 
        #ignore_methods : Array(String)
        
          
Which methods to filter out.
 - 
        #ignore_methods=(ignore_methods : Array(String))
        
          
Which methods to filter out.
 - #instance_variables : Hash(Regex, Bindgen::TypeDatabase::InstanceVariableConfig)
 - #instance_variables=(instance_variables : Hash(Regex, Bindgen::TypeDatabase::InstanceVariableConfig))
 - 
        #kind : Bindgen::Parser::Type::Kind
        
          
Semantics of the type (Kind overwrite)
 - 
        #kind=(kind : Bindgen::Parser::Type::Kind)
        
          
Semantics of the type (Kind overwrite)
 - 
        #lib_type : String | Nil
        
          
Type name to use in the Crystal
libblock. - 
        #merge(other : self) : self
        
          
Merges the other rules with these rules.
 - 
        #pass_by : Bindgen::TypeDatabase::PassBy
        
          
How to pass this type to C++?
 - 
        #pass_by=(pass_by : Bindgen::TypeDatabase::PassBy)
        
          
How to pass this type to C++?
 - 
        #sub_class=(sub_class : Bool)
        
          
If sub-classing of this type is allowed, if it's wrapped and has virtual methods.
 - 
        #sub_class? : Bool
        
          
If sub-classing of this type is allowed, if it's wrapped and has virtual methods.
 - #superclass_ignore_methods : Regex
 - #superclass_ignore_methods=(superclass_ignore_methods : Regex)
 - #to_cpp : Template::Base
 - #to_cpp=(to_cpp : Template::Base)
 - #to_crystal : Template::Base
 - #to_crystal=(to_crystal : Template::Base)
 - 
        #wrapper_pass_by : Bindgen::TypeDatabase::PassBy | Nil
        
          
How to pass this type from Crystal? Defaults to
#pass_by. - 
        #wrapper_pass_by=(wrapper_pass_by : Bindgen::TypeDatabase::PassBy | Nil)
        
          
How to pass this type from Crystal? Defaults to
#pass_by. - 
        #wrapper_type : String | Nil
        
          
Type name to use in the Crystal wrapper.
 
Constructor Detail
Instance Method Detail
The type used in Crystal, but only in the lib binding.
Converter for this type in Crystal.  Takes precedence over the
#to_crystal and #from_crystal fields.
Converter for this type in Crystal.  Takes precedence over the
#to_crystal and #from_crystal fields.
If the structure (as in, its non-static fields) shall be tried to
replicated in Crystal.  Implies instance_variables: false.
This doesn't support inheritance!
If the structure (as in, its non-static fields) shall be tried to
replicated in Crystal.  Implies instance_variables: false.
This doesn't support inheritance!
Pass-by configuration in wrapper code.  Prefers the #wrapper_pass_by
value, and falls back to #pass_by.
If to generate a superclass wrapper in Crystal.
Type name to use in the Crystal lib block.  Namespace operators (::)
are automatically converted into underscores for types defined in
lib Binding.
Merges the other rules with these rules. If a rule is set in both rule-sets, the value from other wins.
If sub-classing of this type is allowed, if it's wrapped and has virtual methods.
If sub-classing of this type is allowed, if it's wrapped and has virtual methods.
How to pass this type from Crystal?  Defaults to #pass_by.
How to pass this type from Crystal?  Defaults to #pass_by.