| Puma Reference Manual | Puma: Puma::CStructure Class Reference |
#include <Puma/CStructure.h>

Public Types | |
| typedef list< CObjectInfo * > | ObjectInfoList |
| List type for semantic objects. | |
| typedef map< DString, ObjectInfoList > | ObjectsByName |
| Map type for entity name to semantic object mapping. | |
| typedef set< CObjectInfo * > | ObjectInfoSet |
| Set type for semantic objects. | |
Public Member Functions | |
| ~CStructure () | |
| Destructor. | |
| ObjectsByName & | ObjectInfoMap () |
| Get the entity name to semantic object map. | |
| const ObjectInfoSet & | ObjectInfos () const |
| Get the entity name to semantic object map. | |
| unsigned | Objects () const |
| Get the number of contained semantic objects. | |
| unsigned | Objects (const DString &name) const |
| Get the number of contained semantic objects for entities with the given name. | |
| unsigned | Types () const |
| Get the number of contained semantic objects for type declarations. | |
| unsigned | Types (const DString &name) const |
| Get the number of contained semantic objects for declarations of types with the given name. | |
| unsigned | Attributes () const |
| Get the number of contained semantic objects for object declarations. | |
| unsigned | Attributes (const DString &name) const |
| Get the number of contained semantic objects for declarations of objects with the given name. | |
| unsigned | TemplateParams () const |
| Get the number of contained semantic objects for template parameter declarations. | |
| unsigned | TemplateParams (const DString &name) const |
| Get the number of contained semantic objects for declarations of template parameters with the given name. | |
| unsigned | Functions () const |
| Get the number of contained semantic objects for function declarations. | |
| unsigned | Functions (const DString &name) const |
| Get the number of contained semantic objects for declarations of functions with the given name. | |
| unsigned | Usings () const |
| Get the number of contained semantic objects for used members. | |
| unsigned | Usings (const DString &name) const |
| Get the number of contained semantic objects for used members with the given name. | |
| unsigned | Namespaces () const |
| Get the number of contained semantic objects for namespace declarations. | |
| unsigned | Namespaces (const DString &name) const |
| Get the number of contained semantic objects for declarations of namespaces with the given name. | |
| unsigned | Friends () const |
| Get the number of contained semantic objects for friend declarations. | |
| unsigned | Friends (const DString &name) const |
| Get the number of contained semantic objects for declarations of friends with the given name. | |
| CObjectInfo * | Object (unsigned n) const |
| Get the n-th contained semantic object. | |
| CObjectInfo * | Object (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for entities with the given name. | |
| CObjectInfo * | Type (unsigned n) const |
| Get the n-th contained semantic object for a type. | |
| CObjectInfo * | Type (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for types with the given name. | |
| CUsingInfo * | Using (unsigned n) const |
| Get the n-th contained semantic object for a using-directive. | |
| CUsingInfo * | Using (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for used members with the given name. | |
| CNamespaceInfo * | Namespace (unsigned n) const |
| Get the n-th contained semantic object for a namespace. | |
| CNamespaceInfo * | Namespace (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for namespaces with the given name. | |
| CRecord * | Friend (unsigned n) const |
| Get the n-th contained semantic object for a friend. | |
| CRecord * | Friend (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for friends with the given name. | |
| CAttributeInfo * | Attribute (unsigned n) const |
| Get the n-th contained semantic object for an object. | |
| CAttributeInfo * | Attribute (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for objects with the given name. | |
| CTemplateParamInfo * | TemplateParam (unsigned n) const |
| Get the n-th contained semantic object for a template parameter. | |
| CTemplateParamInfo * | TemplateParam (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for template parameters with the given name. | |
| CFunctionInfo * | Function (unsigned n) const |
| Get the n-th contained semantic object for a function. | |
| CFunctionInfo * | Function (const DString &name, unsigned n=0) const |
| Get the n-th contained semantic object for functions with the given name. | |
| CFunctionInfo * | Function (const DString &name, CTypeInfo *type) const |
| Get the contained semantic object for functions with the given name and type. | |
| bool | isMemberAlias (const CObjectInfo *info) const |
| Check if an alias exists for the given entity in this scope. | |
| CMemberAliasInfo * | MemberAlias (const CObjectInfo *info) const |
| Get the member alias information for the aliased entity. | |
| void | setShared (CStructure *share) |
| Set a common data object for the linked semantic objects. | |
| void | addObject (CObjectInfo *info) |
| Add a semantic object. | |
| void | addAttribute (CAttributeInfo *info) |
| Add a semantic object for an object. | |
| void | addTemplateParam (CTemplateParamInfo *info) |
| Add a semantic object for a template parameter. | |
| void | addFunction (CFunctionInfo *info) |
| Add a semantic object for a function. | |
| void | addType (CObjectInfo *info) |
| Add a semantic object for a type. | |
| void | addUsing (CUsingInfo *info) |
| Add a semantic object for a using-directive. | |
| void | addNamespace (CNamespaceInfo *info) |
| Add a semantic object for a namespace. | |
| void | addFriend (CRecord *info) |
| Add a semantic object for a friend. | |
| void | removeObject (const CObjectInfo *info) |
| Remove the semantic object. | |
| void | removeAttribute (const CAttributeInfo *info) |
| Remove the semantic object for an object. | |
| void | removeTemplateParam (const CTemplateParamInfo *info) |
| Remove the semantic object for a template parameter. | |
| void | removeFunction (const CFunctionInfo *info) |
| Remove the semantic object for a function. | |
| void | removeType (const CObjectInfo *info) |
| Remove the semantic object for a type. | |
| void | removeUsing (const CUsingInfo *info) |
| Remove the semantic object for a using-directive. | |
| void | removeNamespace (const CNamespaceInfo *info) |
| Remove the semantic object for a namespace. | |
| void | removeFriend (const CRecord *info) |
| Remove the semantic object for a friend. | |
| void | removeMemberAlias (const CMemberAliasInfo *info) |
| Remove the semantic object for a member alias. | |
| void | removeRegisterEntry () |
| Unregister this semantic object at all contained semantic objects. | |
| void | addObjectName (CObjectInfo *info) |
| Add a semantic object to the name map. | |
| void | removeObjectName (const DString &name, CObjectInfo *info) |
| Remove the given semantic object for the entity with the given name from the name map. | |
| CAttributeInfo * | newAttribute () |
| Create a new semantic object for an object declaration. | |
| CEnumInfo * | newEnum () |
| Create a new semantic object for an enumeration. | |
| CUsingInfo * | newUsing () |
| Create a new semantic object for a using-directive. | |
| CTypedefInfo * | newTypedef () |
| Create a new semantic object for a typedef. | |
| CMemberAliasInfo * | newMemberAlias (CObjectInfo *member) |
| Create a new semantic object for a member alias. | |
| void | deleteAttribute (const CAttributeInfo *info) |
| Remove and destroy the given semantic object for an object. | |
| void | deleteEnum (const CEnumInfo *info) |
| Remove and destroy the given semantic object for an enumeration. | |
| void | deleteUsing (const CUsingInfo *info) |
| Remove and destroy the given semantic object for a using-directive. | |
| void | deleteTypedef (const CTypedefInfo *info) |
| Remove and destroy the given semantic object for a typedef. | |
| void | deleteMemberAlias (const CMemberAliasInfo *info) |
| Remove and destroy the given semantic object for a member alias. | |
Protected Member Functions | |
| CStructure (ObjectId id) | |
| Constructor. | |
| typedef list<CObjectInfo*> Puma::CStructure::ObjectInfoList |
List type for semantic objects.
| typedef map<DString,ObjectInfoList> Puma::CStructure::ObjectsByName |
Map type for entity name to semantic object mapping.
| typedef set<CObjectInfo*> Puma::CStructure::ObjectInfoSet |
Set type for semantic objects.
| Puma::CStructure::CStructure | ( | CObjectInfo::ObjectId | id | ) | [inline, protected] |
Constructor.
| id | The object type. |
| Puma::CStructure::~CStructure | ( | ) |
Destructor.
| ObjectsByName& Puma::CStructure::ObjectInfoMap | ( | ) | [inline] |
Get the entity name to semantic object map.
| const ObjectInfoSet& Puma::CStructure::ObjectInfos | ( | ) | const [inline] |
Get the entity name to semantic object map.
| unsigned Puma::CStructure::Objects | ( | ) | const [inline] |
Get the number of contained semantic objects.
| unsigned Puma::CStructure::Objects | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for entities with the given name.
| name | The name of the entity. |
| unsigned Puma::CStructure::Types | ( | ) | const [inline] |
Get the number of contained semantic objects for type declarations.
| unsigned Puma::CStructure::Types | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for declarations of types with the given name.
| name | The name of the type. |
| unsigned Puma::CStructure::Attributes | ( | ) | const [inline] |
Get the number of contained semantic objects for object declarations.
| unsigned Puma::CStructure::Attributes | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for declarations of objects with the given name.
| name | The name of the object. |
| unsigned Puma::CStructure::TemplateParams | ( | ) | const [inline] |
Get the number of contained semantic objects for template parameter declarations.
| unsigned Puma::CStructure::TemplateParams | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for declarations of template parameters with the given name.
| name | The name of the template parameter. |
| unsigned Puma::CStructure::Functions | ( | ) | const [inline] |
Get the number of contained semantic objects for function declarations.
| unsigned Puma::CStructure::Functions | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for declarations of functions with the given name.
| name | The name of the function. |
| unsigned Puma::CStructure::Usings | ( | ) | const [inline] |
Get the number of contained semantic objects for used members.
| unsigned Puma::CStructure::Usings | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for used members with the given name.
| name | The name of the member. |
| unsigned Puma::CStructure::Namespaces | ( | ) | const [inline] |
Get the number of contained semantic objects for namespace declarations.
| unsigned Puma::CStructure::Namespaces | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for declarations of namespaces with the given name.
| name | The name of the namespace. |
| unsigned Puma::CStructure::Friends | ( | ) | const [inline] |
Get the number of contained semantic objects for friend declarations.
| unsigned Puma::CStructure::Friends | ( | const DString & | name | ) | const |
Get the number of contained semantic objects for declarations of friends with the given name.
| name | The name of the friend. |
| CObjectInfo * Puma::CStructure::Object | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object.
| n | The index of the semantic object. |
| CObjectInfo* Puma::CStructure::Object | ( | const DString & | name, | |
| unsigned | n = 0 | |||
| ) | const |
Get the n-th contained semantic object for entities with the given name.
| name | The name of the entity. | |
| n | Optional index of the semantic object (defaults to 0). |
| CObjectInfo * Puma::CStructure::Type | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object for a type.
| n | The index of the semantic object. |
| CObjectInfo* Puma::CStructure::Type | ( | const DString & | name, | |
| unsigned | n = 0 | |||
| ) | const |
Get the n-th contained semantic object for types with the given name.
| name | The name of the type. | |
| n | Optional index of the semantic object (defaults to 0). |
| CUsingInfo * Puma::CStructure::Using | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object for a using-directive.
| n | The index of the semantic object. |
| CUsingInfo* Puma::CStructure::Using | ( | const DString & | name, | |
| unsigned | n = 0 | |||
| ) | const |
Get the n-th contained semantic object for used members with the given name.
| name | The name of the member. | |
| n | Optional index of the semantic object (defaults to 0). |
| CNamespaceInfo * Puma::CStructure::Namespace | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object for a namespace.
| n | The index of the semantic object. |
| CNamespaceInfo* Puma::CStructure::Namespace | ( | const DString & | name, | |
| unsigned | n = 0 | |||
| ) | const |
Get the n-th contained semantic object for namespaces with the given name.
| name | The name of the namespace. | |
| n | Optional index of the semantic object (defaults to 0). |
| CRecord * Puma::CStructure::Friend | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object for a friend.
| n | The index of the semantic object. |
Get the n-th contained semantic object for friends with the given name.
| name | The name of the friend. | |
| n | Optional index of the semantic object (defaults to 0). |
| CAttributeInfo * Puma::CStructure::Attribute | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object for an object.
| n | The index of the semantic object. |
| CAttributeInfo* Puma::CStructure::Attribute | ( | const DString & | name, | |
| unsigned | n = 0 | |||
| ) | const |
Get the n-th contained semantic object for objects with the given name.
| name | The name of the object. | |
| n | Optional index of the semantic object (defaults to 0). |
| CTemplateParamInfo * Puma::CStructure::TemplateParam | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object for a template parameter.
| n | The index of the semantic object. |
| CTemplateParamInfo* Puma::CStructure::TemplateParam | ( | const DString & | name, | |
| unsigned | n = 0 | |||
| ) | const |
Get the n-th contained semantic object for template parameters with the given name.
| name | The name of the template parameter. | |
| n | Optional index of the semantic object (defaults to 0). |
| CFunctionInfo * Puma::CStructure::Function | ( | unsigned | n | ) | const [inline] |
Get the n-th contained semantic object for a function.
| n | The index of the semantic object. |
| CFunctionInfo* Puma::CStructure::Function | ( | const DString & | name, | |
| unsigned | n = 0 | |||
| ) | const |
Get the n-th contained semantic object for functions with the given name.
| name | The name of the function. | |
| n | Optional index of the semantic object (defaults to 0). |
| CFunctionInfo* Puma::CStructure::Function | ( | const DString & | name, | |
| CTypeInfo * | type | |||
| ) | const |
Get the contained semantic object for functions with the given name and type.
| name | The name of the function. | |
| type | The type of the function. |
| bool Puma::CStructure::isMemberAlias | ( | const CObjectInfo * | info | ) | const [inline] |
Check if an alias exists for the given entity in this scope.
| info | The semantic object of the entity. |
| CMemberAliasInfo* Puma::CStructure::MemberAlias | ( | const CObjectInfo * | info | ) | const |
Get the member alias information for the aliased entity.
| info | The semantic object of the entity. |
| void Puma::CStructure::setShared | ( | CStructure * | share | ) |
Set a common data object for the linked semantic objects.
| share | The common data object. |
| void Puma::CStructure::addObject | ( | CObjectInfo * | info | ) |
Add a semantic object.
| info | The semantic object. |
| void Puma::CStructure::addAttribute | ( | CAttributeInfo * | info | ) |
Add a semantic object for an object.
| info | The semantic object. |
| void Puma::CStructure::addTemplateParam | ( | CTemplateParamInfo * | info | ) |
Add a semantic object for a template parameter.
| info | The semantic object. |
| void Puma::CStructure::addFunction | ( | CFunctionInfo * | info | ) |
Add a semantic object for a function.
| info | The semantic object. |
| void Puma::CStructure::addType | ( | CObjectInfo * | info | ) |
Add a semantic object for a type.
| info | The semantic object. |
| void Puma::CStructure::addUsing | ( | CUsingInfo * | info | ) |
Add a semantic object for a using-directive.
| info | The semantic object. |
| void Puma::CStructure::addNamespace | ( | CNamespaceInfo * | info | ) |
Add a semantic object for a namespace.
| info | The semantic object. |
| void Puma::CStructure::addFriend | ( | CRecord * | info | ) |
Add a semantic object for a friend.
| info | The semantic object. |
| void Puma::CStructure::removeObject | ( | const CObjectInfo * | info | ) |
Remove the semantic object.
| info | The semantic object. |
| void Puma::CStructure::removeAttribute | ( | const CAttributeInfo * | info | ) |
Remove the semantic object for an object.
| info | The semantic object. |
| void Puma::CStructure::removeTemplateParam | ( | const CTemplateParamInfo * | info | ) |
Remove the semantic object for a template parameter.
| info | The semantic object. |
| void Puma::CStructure::removeFunction | ( | const CFunctionInfo * | info | ) |
Remove the semantic object for a function.
| info | The semantic object. |
| void Puma::CStructure::removeType | ( | const CObjectInfo * | info | ) |
Remove the semantic object for a type.
| info | The semantic object. |
| void Puma::CStructure::removeUsing | ( | const CUsingInfo * | info | ) |
Remove the semantic object for a using-directive.
| info | The semantic object. |
| void Puma::CStructure::removeNamespace | ( | const CNamespaceInfo * | info | ) |
Remove the semantic object for a namespace.
| info | The semantic object. |
| void Puma::CStructure::removeFriend | ( | const CRecord * | info | ) |
Remove the semantic object for a friend.
| info | The semantic object. |
| void Puma::CStructure::removeMemberAlias | ( | const CMemberAliasInfo * | info | ) |
Remove the semantic object for a member alias.
| info | The semantic object. |
| void Puma::CStructure::removeRegisterEntry | ( | ) |
Unregister this semantic object at all contained semantic objects.
| void Puma::CStructure::addObjectName | ( | CObjectInfo * | info | ) |
Add a semantic object to the name map.
| info | The semantic object. |
| void Puma::CStructure::removeObjectName | ( | const DString & | name, | |
| CObjectInfo * | info | |||
| ) |
Remove the given semantic object for the entity with the given name from the name map.
| name | The name of the entity. | |
| info | The semantic object. |
| CAttributeInfo* Puma::CStructure::newAttribute | ( | ) |
Create a new semantic object for an object declaration.
| CEnumInfo* Puma::CStructure::newEnum | ( | ) |
Create a new semantic object for an enumeration.
| CUsingInfo* Puma::CStructure::newUsing | ( | ) |
Create a new semantic object for a using-directive.
| CTypedefInfo* Puma::CStructure::newTypedef | ( | ) |
Create a new semantic object for a typedef.
| CMemberAliasInfo* Puma::CStructure::newMemberAlias | ( | CObjectInfo * | member | ) |
Create a new semantic object for a member alias.
| member | The aliased member. |
| void Puma::CStructure::deleteAttribute | ( | const CAttributeInfo * | info | ) |
Remove and destroy the given semantic object for an object.
| info | The semantic object. |
| void Puma::CStructure::deleteEnum | ( | const CEnumInfo * | info | ) |
Remove and destroy the given semantic object for an enumeration.
| info | The semantic object. |
| void Puma::CStructure::deleteUsing | ( | const CUsingInfo * | info | ) |
Remove and destroy the given semantic object for a using-directive.
| info | The semantic object. |
| void Puma::CStructure::deleteTypedef | ( | const CTypedefInfo * | info | ) |
Remove and destroy the given semantic object for a typedef.
| info | The semantic object. |
| void Puma::CStructure::deleteMemberAlias | ( | const CMemberAliasInfo * | info | ) |
Remove and destroy the given semantic object for a member alias.
| info | The semantic object. |