pygccxml package¶
Python CastXML or GCC-XML front end.
This package provides functionality to extract and inspect declarations from C/C++ header files. This is accomplished by invoking an external tool like CastXML or GCC-XML, which parses a header file and dumps the declarations as a XML file. This XML file is then read by pygccxml and the contents are made available as appropriate Python objects.
To parse a set of C/C++ header files you use the parse
function in the :mod:parser sub package which returns a tree that contains all
declarations found in the header files. The root of the tree represents the
main namespace :: and the children nodes represent the namespace contents
such as other namespaces, classes, functions, etc. Each node in the tree is an
object of a type derived from the declaration_t
class. An inner node
is always either a namespace declarations.namespace_t
or a class
declarations.class_t
, which are both derived from
declarations.scopedef_t
class. Everything else (free functions,
member functions, enumerations, variables, etc.) are always a leaf. You will
find all those declaration classes in the :mod:declarations sub-package.
Subpackages¶
- pygccxml.declarations package
access_type_matcher
and_matcher
calldef_matcher
custom_matcher
declaration_matcher
namespace_matcher
not_matcher
operator_matcher
or_matcher
regex_matcher
variable_matcher
virtuality_type_matcher
- Submodules
- pygccxml.declarations.algorithm module
- pygccxml.declarations.algorithms_cache module
- pygccxml.declarations.byte_info module
- pygccxml.declarations.call_invocation module
- pygccxml.declarations.calldef module
- pygccxml.declarations.calldef_members module
- pygccxml.declarations.calldef_types module
- pygccxml.declarations.class_declaration module
- pygccxml.declarations.comment module
- pygccxml.declarations.container_traits module
- pygccxml.declarations.cpptypes module
FUNDAMENTAL_TYPES
array_t
bool_t
calldef_type_t
char_t
complex_double_t
complex_float_t
complex_long_double_t
compound_t
const_t
declarated_t
double_t
dummy_type_t
elaborated_t
ellipsis_t
float_t
free_function_type_t
fundamental_t
int128_t
int_t
java_fundamental_t
jboolean_t
jbyte_t
jchar_t
jdouble_t
jfloat_t
jint_t
jlong_t
jshort_t
long_double_t
long_int_t
long_long_int_t
long_long_unsigned_int_t
long_unsigned_int_t
member_function_type_t
member_variable_type_t
pointer_t
reference_t
restrict_t
short_int_t
short_unsigned_int_t
signed_char_t
type_qualifiers_t
type_t
uint128_t
unknown_t
unsigned_char_t
unsigned_int_t
void_t
volatile_t
wchar_t
- pygccxml.declarations.decl_factory module
- pygccxml.declarations.decl_printer module
- pygccxml.declarations.decl_visitor module
- pygccxml.declarations.declaration module
- pygccxml.declarations.declaration_utils module
- pygccxml.declarations.declarations_matchers module
- pygccxml.declarations.dependencies module
- pygccxml.declarations.elaborated_info module
- pygccxml.declarations.enumeration module
- pygccxml.declarations.free_calldef module
- pygccxml.declarations.function_traits module
- pygccxml.declarations.has_operator_matcher module
- pygccxml.declarations.location module
- pygccxml.declarations.matchers module
- pygccxml.declarations.mdecl_wrapper module
- pygccxml.declarations.namespace module
- pygccxml.declarations.pattern_parser module
- pygccxml.declarations.pointer_traits module
- pygccxml.declarations.runtime_errors module
- pygccxml.declarations.scopedef module
- pygccxml.declarations.templates module
- pygccxml.declarations.traits_impl_details module
- pygccxml.declarations.type_traits module
array_item_type()
array_size()
base_type()
decompose_class()
decompose_type()
does_match_definition()
is_arithmetic()
is_array()
is_bool()
is_calldef_pointer()
is_const()
is_elaborated()
is_floating_point()
is_fundamental()
is_integral()
is_pointer()
is_reference()
is_same()
is_std_ostream()
is_std_string()
is_std_wostream()
is_std_wstring()
is_void()
is_void_pointer()
is_volatile()
remove_alias()
remove_const()
remove_cv()
remove_declarated()
remove_elaborated()
remove_pointer()
remove_reference()
remove_volatile()
- pygccxml.declarations.type_traits_classes module
class_declaration_traits
class_traits
declaration_xxx_traits
enum_declaration()
enum_traits
find_copy_constructor()
find_noncopyable_vars()
find_trivial_constructor()
has_any_non_copyconstructor()
has_copy_constructor()
has_destructor()
has_public_assign()
has_public_constructor()
has_public_destructor()
has_trivial_constructor()
has_vtable()
is_base_and_derived()
is_binary_operator()
is_class()
is_class_declaration()
is_convertible()
is_copy_constructor()
is_enum()
is_noncopyable()
is_struct()
is_trivial_constructor()
is_unary_operator()
is_union()
- pygccxml.declarations.type_visitor module
- pygccxml.declarations.typedef module
- pygccxml.declarations.variable module
- pygccxml.declarations.xml_generators module
- pygccxml.parser package
parse()
parse_string()
parse_xml_file()
- Submodules
- pygccxml.parser.config module
- pygccxml.parser.declarations_cache module
- pygccxml.parser.declarations_joiner module
- pygccxml.parser.directory_cache module
- pygccxml.parser.etree_scanner module
- pygccxml.parser.linker module
- pygccxml.parser.patcher module
- pygccxml.parser.project_reader module
- pygccxml.parser.scanner module
- pygccxml.parser.source_reader module
- pygccxml.utils package