1# Copyright 2014-2017 Insight Software Consortium. 2# Copyright 2004-2009 Roman Yakovenko. 3# Distributed under the Boost Software License, Version 1.0. 4# See http://www.boost.org/LICENSE_1_0.txt 5 6""" 7defines default declarations factory class 8""" 9 10from .calldef_members import member_function_t 11from .calldef_members import constructor_t 12from .calldef_members import destructor_t 13from .calldef_members import member_operator_t 14from .calldef_members import casting_operator_t 15from .free_calldef import free_function_t 16from .free_calldef import free_operator_t 17from .enumeration import enumeration_t 18from .namespace import namespace_t 19from .class_declaration import class_t 20from .class_declaration import class_declaration_t 21from .typedef import typedef_t 22from .variable import variable_t 23 24 25class decl_factory_t(object): 26 27 """ 28 declarations factory class 29 """ 30 31 def __init__(self): 32 """creates declarations factory""" 33 object.__init__(self) 34 35 def create_member_function(self, *arguments, **keywords): 36 """creates instance of class that describes member function 37 declaration""" 38 return member_function_t(*arguments, **keywords) 39 40 def create_constructor(self, *arguments, **keywords): 41 """creates instance of class that describes constructor declaration""" 42 return constructor_t(*arguments, **keywords) 43 44 def create_destructor(self, *arguments, **keywords): 45 """creates instance of class that describes destructor declaration""" 46 return destructor_t(*arguments, **keywords) 47 48 def create_member_operator(self, *arguments, **keywords): 49 """creates instance of class that describes member operator 50 declaration""" 51 return member_operator_t(*arguments, **keywords) 52 53 def create_casting_operator(self, *arguments, **keywords): 54 """creates instance of class that describes casting operator 55 declaration""" 56 return casting_operator_t(*arguments, **keywords) 57 58 def create_free_function(self, *arguments, **keywords): 59 """creates instance of class that describes free function 60 declaration""" 61 return free_function_t(*arguments, **keywords) 62 63 def create_free_operator(self, *arguments, **keywords): 64 """creates instance of class that describes free operator 65 declaration""" 66 return free_operator_t(*arguments, **keywords) 67 68 def create_class_declaration(self, *arguments, **keywords): 69 """creates instance of class that describes class declaration""" 70 return class_declaration_t(*arguments, **keywords) 71 72 def create_class(self, *arguments, **keywords): 73 """creates instance of class that describes class definition 74 declaration""" 75 return class_t(*arguments, **keywords) 76 77 def create_enumeration(self, *arguments, **keywords): 78 """creates instance of class that describes enumeration declaration""" 79 return enumeration_t(*arguments, **keywords) 80 81 def create_namespace(self, *arguments, **keywords): 82 """creates instance of class that describes namespace declaration""" 83 return namespace_t(*arguments, **keywords) 84 85 def create_typedef(self, *arguments, **keywords): 86 """creates instance of class that describes typedef declaration""" 87 return typedef_t(*arguments, **keywords) 88 89 def create_variable(self, *arguments, **keywords): 90 """creates instance of class that describes variable declaration""" 91 return variable_t(*arguments, **keywords) 92