#include <gconcepttype.h>

Inheritance diagram for GConceptType:
[legend]

Public Member Functions

 GConceptType (GSession *session, tConceptCat cat, size_t id, const R::RString &name, const R::RString &desc, size_t s)
 
virtual R::RCString GetClassName (void) const
 
int Compare (const GConceptType &type) const
 
int Compare (const GConceptType *type) const
 
int Compare (const R::RString &name) const
 
tConceptCat GetCategory (void) const
 
R::RString GetDescription (void) const
 
GConceptGetNeutral (void) const
 
R::RCursor< GConceptGetObjs (const GConcept *obj) const
 
bool IsIn (const GConcept *obj, const R::RString &name) const
 
GConceptGetObj (const GConcept *obj, const R::RString &name, bool null) const
 
size_t GetNbObjs (const GConcept *obj) const
 
virtual ~GConceptType (void)
 
- Public Member Functions inherited from GObject
 GObject (GSession *session, size_t id, const R::RString &name, tObjType type)
 
 GObject (const GObject &obj)
 
void VerifyStatements (tStatementElement what, size_t size)
 
int Compare (const GObject &obj) const
 
int Compare (size_t id) const
 
int Search (const GObject &obj) const
 
int Search (const R::RString &name) const
 
GSessionGetSession (void) const
 
size_t GetId (void) const
 
void SetId (size_t id)
 
tObjType GetObjType (void) const
 
R::RCursor< GStatementGetObjs (const GStatement *obj, tStatementElement what)
 
virtual void HandlerNotFound (const R::RNotification &notification)
 
virtual ~GObject (void)
 
- Public Member Functions inherited from RObject
 RObject (const RString &name=RString::Null)
 
int Compare (const RObject &obj) const
 
RString GetName (void) const
 
void PostNotification (const hNotification handle)
 
void PostNotification (const RCString &name)
 
void PostNotification (const hNotification handle, T data)
 
void PostNotification (const RCString &name, T data)
 
void InsertObserver (tNotificationHandler handler, const hNotification handle, RObject *object)
 
void InsertObserver (tNotificationHandler handler, const RCString &name, RObject *object)
 
void InsertObserver (tNotificationHandler handler, const hNotification handle)
 
void InsertObserver (tNotificationHandler handler, const RCString &name)
 
void InsertObserver (tNotificationHandler handler, RObject *object)
 
void InsertObserver (tNotificationHandler handler)
 
void DeleteObserver (void)
 
void DeleteObserver (const hNotification handle, RObject *object)
 
void DeleteObserver (const RCString &name, RObject *object)
 
hNotification GetNotificationHandle (const RCString &name) const
 
RCString GetNotificationName (const hNotification handle) const
 
virtual ~RObject (void)
 

Private Member Functions

void InsertObj (GConcept *concept)
 
void DeleteObj (GConcept *concept)
 

Private Attributes

tConceptCat Category
 
GConceptNeutral
 
R::RContainer< GConcept, false,
false > 
Concepts
 
R::RString Description
 

Additional Inherited Members

- Static Public Member Functions inherited from GObject
static bool HasDesc (void)
 
static bool HasTree (void)
 
- Protected Attributes inherited from GObject
GSessionSession
 
size_t Id
 
tObjType ObjType
 
R::RContainer< GStatement,
false, true > * 
Subjects
 
R::RContainer< GStatement,
false, false > * 
Predicates
 
R::RContainer< GStatement,
false, false > * 
Values
 
- Protected Attributes inherited from RObject
RString Name
 

Detailed Description

The GConceptType provides a representation for a given type of concepts. It also manage a dictionary of concepts, each concept having its own identifier. The name of a concept is unique for a given type, while the identifiers are unique for all concepts.

Parameters
authorPascal Francq
shortConcept Type.

Constructor & Destructor Documentation

GConceptType ( GSession session,
tConceptCat  cat,
size_t  id,
const R::RString name,
const R::RString desc,
size_t  s 
)

Construct a concept type.

Parameters
sessionSession.
catCategory.
idIdentifier of the type.
nameName of the type.
descShort description.
sSize of the second hash table.
virtual ~GConceptType ( void  )
virtual

Destruct.

Member Function Documentation

virtual R::RCString GetClassName ( void  ) const
virtual
Returns
the class name.

Reimplemented from GObject.

int Compare ( const GConceptType type) const

Compare two concepts types.

Parameters
typeConcept type used.
See also
R::RContainer.
int Compare ( const GConceptType type) const

Compare two concepts types.

Parameters
typeConcept type used.
See also
R::RContainer.
int Compare ( const R::RString name) const

Compare a concept type with a name.

Parameters
nameName used.
See also
R::RContainer.
tConceptCat GetCategory ( void  ) const
Returns
the category.
R::RString GetDescription ( void  ) const
Returns
the description.
GConcept* GetNeutral ( void  ) const
Returns
the neutral concept.
R::RCursor<GConcept> GetObjs ( const GConcept obj) const
Returns
a cursor over the concepts.
Parameters
objPseudo-parameter.
bool IsIn ( const GConcept obj,
const R::RString name 
) const

Look if a given concept is in the dictionary.

Parameters
objPseudo-parameter.
nameName of the concept to look for.
Returns
true if the concept is in the dictionary.
GConcept* GetObj ( const GConcept obj,
const R::RString name,
bool  null 
) const

Get a given concept from the dictionary.

Parameters
objPseudo-parameter.
nameName of the concept to look for.
nullIf set to true, if the concept does not exist, return 0, else an exception is generated.
Returns
Pointer to the concept.
void InsertObj ( GConcept concept)
private

Insert a concept in the dictionary.

Parameters
conceptConcept.
void DeleteObj ( GConcept concept)
private

Delete a concept from the dictionary.

Parameters
conceptConcept.
size_t GetNbObjs ( const GConcept obj) const

Get the total number of concepts.

Parameters
objPseudo-parameter.

Member Data Documentation

tConceptCat Category
private

Category.

GConcept* Neutral
private

The neutral concept;

R::RContainer<GConcept,false,false> Concepts
private

Concepts.

R::RString Description
private

Short description of the type.