|
Developer Documentation |
|
Centre for Vision, Speech & Signal Processing |
Parent Classes:
Variables:
- StringC name;
-
- BooleanT Terminal;
-
Methods:
- VLExprType(StringC nName,IntT nargs)
-
Construct named expression with 'nargs' arguments.
- VLExprType(StringC nName,BooleanT Term = False)
-
Construct
- VLExprType(StringC nName,VLExprLabelLstC & ALst,BooleanT Term = False)
-
Construct in context from ExprLabel list.
- BooleanT operator==(const VLExprType & Oth) const
-
Compair two expression types.x
- BooleanT operator!=(const VLExprType & Oth) const
-
Compair two expression types.
- VLExprLabelLstC LabLst(void)
-
Get a ordered list of argument labels.
- BooleanT AddTerm(const VLExprLabel & EL)
-
Add argument to expression type.
Do NOT use after instances of this expression type have been
generated.
- BooleanT AddTerm(const VLExprLabelC & EL)
-
Add argument to expression type.
Do NOT use after instances of this expression type have been
generated.
- BooleanT DelTerm(const VLExprLabel & EL)
-
Delete argument from expression type.
Do NOT use after instances of this expression type have been
generated.
- VLExprLabelC & ArgType(IndexT i)
-
Get label of arg i of expression.
- const VLExprLabelC & ArgType(IndexT i) const
-
Get label of arg i of expression.
- IndexT NotFound()
-
Returned by GetIndex if label not found.
- IndexT GetIndex(const VLExprLabel & EL) const
-
Get index of argument labeled EL in expression.
Returns 'NotFound' if is not present in the expression.
- IndexT GetIndex(const VLExprLabelC & EL) const
-
Get index of argument labeled EL in expression.
Returns 'NotFound' if is not present in the expression.
- IndexT GetIndex(StringC EL) const
-
Get index of arg label in expression.
Returns 'NotFound' if is not present in the expression.
- int Size(void) const
-
Get the number of terms in the expression.
- BooleanT IsTerminal(void) const
-
Is the expression type terminal, used in matching, see LCIndexT .
- StringC GetName(StringC Buff = StringC()) const
-
Get label name.
- const StringC & BaseName() const
-
Get basname.
- StringC GetArgText() const
-
Get string containing args for type.
- UIntT Hash() const
-
Get hash value.
- void AddReference()
-
Another reference to the object has been created.
- void RemoveReference()
-
One reference to the object was deleted.
Locking scheme
--------------
The object is possible to lock (to make constant). The scheme
assumes that the object is created, it can be locked, after that
it can only be destroyed. The locked object cannot be unlocked.
This locking scheme is very useful
during debugging, using assert() function,
when it is necassary to check that object
is treated as constant and the constancy is not violated by
any casting or passing through the copy constructor of shared
objects.
- void SetConst(void) const
-
This locks the object.
Often objects you wish to lock are already const.
- void SetConst(void)
-
This locks the object.
- BooleanT IsConst(void) const
-
Returns TRUE if the object is locked, ie. it is assumed to be constant.
- BooleanT IsNotConst(void) const
-
Returns TRUE if the object is unlocked.
ie. there is no special
information if the object is constant or not.
Counter state information
-------------------------
- BooleanT ToBeDeleted() const
-
Returns TRUE if there is only one reference to the object and the whole object or its reference counting part can be deleted.
- BooleanT ToBeDeletedRemoveIgnoreNoRemove()
-
Decrement refrence by 1 return true if this leaves no refrences to the object.
- BooleanT ToBeDeletedRemove()
-
Decrement refrence by 1 return true if this leaves no refrences to the object. This also checks the NoRemove flag.
- BooleanT BodyMightBeDeleted() const
-
Returns TRUE if the reference counted part of the object can be deleted, ie. flag NOREMOVE is false .
- BooleanT IsCountZero() const
-
Are there any refrences left ?
- BooleanT BRCPtrCanDeleteObject() const
-
Used by BRRCPtrC to establish if an object has ZERO refrences and can be deleted.
- IntT Count() const
-
Returns the current state of the counter, ie. how many references to this object exist.
- const BodyRefCounterC & operator=(const BodyRefCounterC & b)
-
It has not meaning to assign object 'b' to this object because it would destroy a history of the object which is counted. So this is a dummy function.
- BooleanT IsValidObject() const
-
Test if object is valid.
When amma check is disabled this always returns true.
- BooleanT UserBitTest(IntT x) const
-
Test user flag.
- void UserBitSet(IntT x,BooleanT setit = TRUE)
-
Test user flag.
- void UserBitZero(IntT x)
-
Set bit to zero.
- void ReportBRCError(char * Msg)
-
Report error, used in BRCPtrC.
- UIntT Hash() const
-
Hash on address of object.
- void SetUndeletable()
-
Make object undeletable.
Usefull to prevent recursive deleting in graph structures.
Only hackers need this function.
- void ReportInvalidObject(char * Msg = 0) const
-
Tell user about validation failure.
- VLExprLabelC & Arg(IndexT i)
-
Access arg i.
- const VLExprLabelC & Arg(IndexT i) const
-
Constant access to arg i.
- VLExprLabelC & SafeArg(IndexT i)
-
Safe access to arg i.
- const VLExprLabelC & SafeArg(IndexT i) const
-
Safe, constant access to arg i.
- VLExprLabelC & operator[](IndexT i)
-
Access args through array operator.
- const VLExprLabelC & operator[](IndexT i) const
-
Constant access to args through array operator.
- IndexT GetArity() const
-
Get number of args. OBSOLETE
- IndexT Arity() const
-
Get nymber of args.
- void Resize(IndexT NewArity)
-
Change size. Copy prevous data.
- IndexT Remove(IndexT i)
-
Remove item, and bring things back 1. Returns size.
- IndexT Append(const VLExprLabelC & Item)
-
Append an item. Returns size.
- LabelT Label() const
-
Returns the label of this reference counter.
The member function
is useful mainly to recognize objects during debugging.
The value of the label is uniquely defined pointer.
|
Programmer:Charles Galambos, Documentation by CxxDoc: Tue Mar 20 10:49:27 2001
|