Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

CPPType Class Reference

#include <cppType.h>

Inheritance diagram for CPPType:

CPPDeclaration CPPArrayType CPPClassTemplateParameter CPPConstType CPPExtensionType CPPFunctionType CPPPointerType CPPReferenceType CPPSimpleType CPPTBDType CPPTypeProxy List of all members.

Public Types

typedef vector< CPPTypedef * > Typedefs

Public Member Functions

 CPPType (const CPPFile &file)
virtual CPPType * resolve_type (CPPScope *current_scope, CPPScope *global_scope)
virtual bool is_tbd () const
bool has_typedef_name () const
string get_typedef_name (CPPScope *scope=NULL) const
virtual string get_simple_name () const
virtual string get_local_name (CPPScope *scope=NULL) const
virtual string get_fully_scoped_name () const
virtual string get_preferred_name () const
virtual bool is_incomplete () const
virtual bool is_equivalent (const CPPType &other) const
void output_instance (ostream &out, const string &name, CPPScope *scope) const
virtual void output_instance (ostream &out, int indent_level, CPPScope *scope, bool complete, const string &prename, const string &name) const
virtual CPPType * as_type ()

Static Public Member Functions

CPPType * new_type (CPPType *type)
void record_preferred_name_for (const CPPType *type, const string &name)
string get_preferred_name_for (const CPPType *type)

Public Attributes

Typedefs _typedefs
CPPTypeDeclaration_declaration

Protected Types

typedef set< CPPType *, CPPTypeCompareTypes
typedef map< string, string > PreferredNames

Static Protected Attributes

Types _types
PreferredNames _preferred_names

Member Typedef Documentation

typedef map<string, string> CPPType::PreferredNames [protected]
 

Definition at line 88 of file cppType.h.

typedef vector<CPPTypedef *> CPPType::Typedefs
 

Definition at line 46 of file cppType.h.

typedef set<CPPType *, CPPTypeCompare> CPPType::Types [protected]
 

Definition at line 85 of file cppType.h.


Constructor & Destructor Documentation

CPPType::CPPType const CPPFile file  ) 
 

Definition at line 37 of file cppType.cxx.

References _declaration, and NULL.


Member Function Documentation

CPPType * CPPType::as_type  )  [virtual]
 

Reimplemented from CPPDeclaration.

Reimplemented in CPPTypeProxy.

Definition at line 221 of file cppType.cxx.

string CPPType::get_fully_scoped_name  )  const [virtual]
 

Reimplemented in CPPExtensionType, CPPTBDType, and CPPTypeProxy.

Definition at line 132 of file cppType.cxx.

References get_local_name().

Referenced by CPPTypeProxy::get_fully_scoped_name().

string CPPType::get_local_name CPPScope scope = NULL  )  const [virtual]
 

Reimplemented in CPPExtensionType, CPPTBDType, and CPPTypeProxy.

Definition at line 119 of file cppType.cxx.

References CPPDeclaration::output(), and ostringstream::str().

Referenced by FunctionRemap::call_function(), FunctionWriterPtrFromPython::FunctionWriterPtrFromPython(), FunctionWriterPtrToPython::FunctionWriterPtrToPython(), InterfaceMakerPythonObj::get_builder_name(), FunctionRemap::get_call_str(), get_fully_scoped_name(), TypeManager::get_function_signature(), CPPTypeProxy::get_local_name(), get_preferred_name(), CPPSimpleType::get_preferred_name(), ParameterRemapConcreteToPointer::get_return_expr(), get_simple_name(), TypeManager::is_basic_string_char(), TypeManager::is_reference_count(), InterfaceMaker::manage_return_value(), InterfaceMaker::output_ref(), ParameterRemapEnumToInt::pass_parameter(), InterfaceMaker::remap_parameter(), InterfaceMakerPythonObj::write_class_wrapper(), FunctionWriterPtrFromPython::write_code(), and InterfaceMakerC::write_function_header().

string CPPType::get_preferred_name  )  const [virtual]
 

Reimplemented in CPPSimpleType, and CPPTypeProxy.

Definition at line 147 of file cppType.cxx.

References get_local_name(), and get_preferred_name_for().

Referenced by CPPTypeProxy::get_preferred_name().

string CPPType::get_preferred_name_for const CPPType *  type  )  [static]
 

Definition at line 283 of file cppType.cxx.

References _preferred_names, and type.

Referenced by get_preferred_name().

string CPPType::get_simple_name  )  const [virtual]
 

Reimplemented in CPPExtensionType, CPPTBDType, and CPPTypeProxy.

Definition at line 107 of file cppType.cxx.

References get_local_name().

Referenced by CPPTypeProxy::get_simple_name(), and InterfaceMakerPythonObj::write_class_wrapper().

string CPPType::get_typedef_name CPPScope scope = NULL  )  const
 

Reimplemented in CPPTypeProxy.

Definition at line 90 of file cppType.cxx.

References _typedefs.

Referenced by CPPTypeProxy::get_typedef_name().

bool CPPType::has_typedef_name  )  const
 

Reimplemented in CPPTypeProxy.

Definition at line 78 of file cppType.cxx.

References _typedefs.

Referenced by CPPTypeProxy::has_typedef_name().

bool CPPType::is_equivalent const CPPType &  other  )  const [virtual]
 

Reimplemented in CPPArrayType, CPPConstType, CPPExtensionType, CPPPointerType, and CPPReferenceType.

Definition at line 177 of file cppType.cxx.

References CPPDeclaration::get_subtype(), and CPPDeclaration::is_equal().

Referenced by CPPReferenceType::is_equivalent(), CPPPointerType::is_equivalent(), CPPExtensionType::is_equivalent(), CPPConstType::is_equivalent(), CPPArrayType::is_equivalent(), and CPPFunctionType::is_equivalent_function().

bool CPPType::is_incomplete  )  const [virtual]
 

Reimplemented in CPPEnumType, CPPExtensionType, CPPStructType, and CPPTypeProxy.

Definition at line 163 of file cppType.cxx.

Referenced by CPPScope::define_extension_type(), and CPPTypeProxy::is_incomplete().

bool CPPType::is_tbd  )  const [virtual]
 

Reimplemented in CPPArrayType, CPPConstType, CPPExtensionType, CPPFunctionType, CPPPointerType, CPPReferenceType, CPPSimpleType, CPPTBDType, and CPPTypeProxy.

Definition at line 65 of file cppType.cxx.

Referenced by CPPTypeProxy::is_tbd(), CPPReferenceType::is_tbd(), CPPPointerType::is_tbd(), CPPFunctionType::is_tbd(), CPPConstType::is_tbd(), CPPArrayType::is_tbd(), and CPPParameterList::resolve_type().

CPPType * CPPType::new_type CPPType *  type  )  [static]
 

Definition at line 237 of file cppType.cxx.

References _types, assert, and type.

Referenced by CPPEnumType::add_element(), CPPInstance::check_for_constructor(), CPPExpression::determine_type(), CPPIdentifier::find_symbol(), CPPIdentifier::find_type(), InterrogateBuilder::get_cast_function(), TypeManager::get_int_type(), TypeManager::get_void_type(), CPPStructType::instantiate(), CPPInstance::make_typecast_function(), CPPPreprocessor::nested_parse_template_instantiation(), ParameterRemapEnumToInt::ParameterRemapEnumToInt(), CPPInstanceIdentifier::r_unroll_type(), CPPReferenceType::resolve_type(), CPPPointerType::resolve_type(), CPPFunctionType::resolve_type(), CPPConstType::resolve_type(), CPPArrayType::resolve_type(), FunctionRemap::setup_properties(), CPPTBDType::substitute_decl(), CPPStructType::substitute_decl(), CPPReferenceType::substitute_decl(), CPPPointerType::substitute_decl(), CPPFunctionType::substitute_decl(), CPPExtensionType::substitute_decl(), CPPEnumType::substitute_decl(), CPPConstType::substitute_decl(), CPPArrayType::substitute_decl(), TypeManager::wrap_const_pointer(), TypeManager::wrap_const_reference(), and TypeManager::wrap_pointer().

void CPPType::output_instance ostream out,
int  indent_level,
CPPScope scope,
bool  complete,
const string &  prename,
const string &  name
const [virtual]
 

Reimplemented in CPPArrayType, CPPConstType, CPPFunctionType, CPPPointerType, CPPReferenceType, and CPPTypeProxy.

Definition at line 207 of file cppType.cxx.

References CPPDeclaration::output().

void CPPType::output_instance ostream out,
const string &  name,
CPPScope scope
const
 

Definition at line 194 of file cppType.cxx.

Referenced by FunctionRemap::call_function(), CPPInstance::output(), CPPTypeProxy::output_instance(), CPPReferenceType::output_instance(), CPPPointerType::output_instance(), CPPFunctionType::output_instance(), CPPConstType::output_instance(), CPPArrayType::output_instance(), FunctionWriterPtrToPython::write_code(), FunctionWriterPtrFromPython::write_code(), FunctionWriterPtrToPython::write_prototype(), and FunctionWriterPtrFromPython::write_prototype().

void CPPType::record_preferred_name_for const CPPType *  type,
const string &  name
[static]
 

Definition at line 266 of file cppType.cxx.

References _preferred_names, and type.

Referenced by CPPTypedef::CPPTypedef().

CPPType * CPPType::resolve_type CPPScope current_scope,
CPPScope global_scope
[virtual]
 

Reimplemented in CPPArrayType, CPPConstType, CPPFunctionType, CPPPointerType, CPPReferenceType, CPPTBDType, and CPPTypeProxy.

Definition at line 52 of file cppType.cxx.

Referenced by InterrogateBuilder::build(), CPPTemplateParameterList::build_subst_decl(), InterrogateBuilder::define_method(), InterrogateBuilder::get_function(), ParameterRemapPTToPointer::ParameterRemapPTToPointer(), TypeManager::resolve_type(), CPPReferenceType::resolve_type(), CPPPointerType::resolve_type(), CPPParameterList::resolve_type(), CPPFunctionType::resolve_type(), CPPConstType::resolve_type(), CPPArrayType::resolve_type(), InterrogateBuilder::scan_function(), FunctionRemap::setup_properties(), and InterrogateBuilder::update_method_comment().


Member Data Documentation

CPPTypeDeclaration* CPPType::_declaration
 

Definition at line 82 of file cppType.h.

Referenced by CPPType(), and CPPTypeDeclaration::CPPTypeDeclaration().

CPPType::PreferredNames CPPType::_preferred_names [static, protected]
 

Definition at line 24 of file cppType.cxx.

Referenced by get_preferred_name_for(), and record_preferred_name_for().

Typedefs CPPType::_typedefs
 

Definition at line 47 of file cppType.h.

Referenced by CPPTypedef::CPPTypedef(), get_typedef_name(), has_typedef_name(), CPPStructType::output(), CPPExtensionType::output(), and CPPEnumType::output().

CPPType::Types CPPType::_types [static, protected]
 

Definition at line 23 of file cppType.cxx.

Referenced by new_type().


The documentation for this class was generated from the following files:
Generated on Fri Apr 18 01:34:54 2003 for DTool by doxygen1.3