pyplusplus.decl_wrappers.calldef_wrapper.calldef_t

Package pyplusplus :: Package decl_wrappers :: Module calldef_wrapper :: Class calldef_t |

# type calldef_t

source code

                     object --+
                              |
    decl_wrapper.decl_wrapper_t --+
                                  |
                                 calldef_t

Known Subclasses:
  - casting_operator_t
  - , constructor_t
  - , destructor_t
  - , free_function_t
  - , free_operator_t
  - , member_function_t
  - , member_operator_t

base class, for code generator configration, for function declaration classes.

Instance Methods
__init__(self, *arguments, **keywords) | source code
get_call_policies(self) | source code
set_call_policies(self, call_policies) | source code
has_wrapper(self) returns True, if function - wrapper is needed | source code
get_overridable(self) Check if the method can be overridden. | source code
set_overridable(self, overridable) | source code
mark_as_non_overridable(self, reason) mark this function as non-overridable | source code
add_transformation(self, *transformer_creators, **keywd) add new function transformation. | source code
Inherited from `decl_wrapper.decl_wrapper_t`: `disable_messages`, `disable_warnings`, `exclude`, `get_already_exposed`, `get_exportable`, `include`, `readme`, `rename`, `set_already_exposed`, `set_exportable`, `why_not_exportable`

Class Variables
| BOOST_PYTHON_MAX_ARITY = `10` Boost.Python configuration macro value.
Inherited from `decl_wrapper.decl_wrapper_t`: `SPECIAL_TYPEDEF_PICK_ANY`

Properties
| call_policies reference to call policies class.Default value is calculated at runtime, based on return value.
| use_keywords boolean, if True, allows to call function from Python using keyword arguments.Default value is True.
| create_with_signature boolean, if True Py++ will generate next code: def( ..., function type( function ref )Thus, the generated code is safe, when a user creates function overloading.Default value is computed, based on information from the declarations tree
| use_default_arguments boolean, if True Py++ will generate code that will set default argumentsDefault value is True.
| overridable Check if the method can be overridden.
| non_overridable_reason returns the reason the function could not be overriden
| transformations return list of function transformations that should be applied on the function
Inherited from `decl_wrapper.decl_wrapper_t`: `alias`, `already_exposed`, `disabled_messages`, `documentation`, `exportable`, `ignore`, `include_files`, `logger`

Method Details

### __init__(self, *arguments, **keywords) (Constructor) | source code
Overrides: decl_wrapper.decl_wrapper_t.__init__

### has_wrapper(self) | source code
returns True, if function - wrapper is needed The functionality by this function is uncomplete. So please don't use it in your code.

### mark_as_non_overridable(self, reason) | source code
mark this function as non-overridable Not all fucntions could be overrided from Python, for example virtual function that returns non const reference to a member variable. Py++ allows you to mark these functions and provide and explanation to the user.

### add_transformation(self, *transformer_creators, **keywd) | source code
add new function transformation. transformer_creators - list of transformer creators, which should be applied on the function keywd - keyword arguments for function_transformation_t class initialization

Class Variable Details

  ### BOOST_PYTHON_MAX_ARITY Boost.Python configuration macro value. A function has more than BOOST_PYTHON_MAX_ARITY arguments, will not compile. You should adjust BOOST_PYTHON_MAX_ARITY macro. For more information see: http://mail.python.org/pipermail/c++-sig/2002-June/001554.html Value:
      10

Property Details

### call_policies reference to call policies class.Default value is calculated at runtime, based on return value. Get Method: get_call_policies(self) Set Method: set_call_policies(self, call_policies)

### use_keywords boolean, if True, allows to call function from Python using keyword arguments.Default value is True. Get Method: _get_use_keywords(self) Set Method: _set_use_keywords(self, use_keywords)

### create_with_signature boolean, if True Py++ will generate next code: def( ..., function type( function ref )Thus, the generated code is safe, when a user creates function overloading.Default value is computed, based on information from the declarations tree Get Method: _get_create_with_signature(self) Set Method: _set_create_with_signature(self, create_with_signature)

### use_default_arguments boolean, if True Py++ will generate code that will set default argumentsDefault value is True. Get Method: _get_use_default_arguments(self) Set Method: _set_use_default_arguments(self, use_default_arguments)

### overridable Check if the method can be overridden. Get Method: get_overridable(self) - Check if the method can be overridden. Set Method: set_overridable(self, overridable)

### non_overridable_reason returns the reason the function could not be overriden

### transformations return list of function transformations that should be applied on the function