Include file: cbentity.h
An instance of this class is a combination (or list) of geometric entities. Access to elements of the list is through an index which is either an integer (default starting index = 0) or a string name. This class "contains" its constituent geometric entities --- it is an aggregate list class.
Chris Anderson © UCLA 6/27/97
CAMcombinedEntity()
CAMcombinedEntity( const CAMcombinedEntity&A)
void initialize()
void initialize(const CAMcombinedEntity& E)
ostream& operator <<(ostream& out_stream, const CAMcombinedEntity& A)
istream& operator >>(istream& in_stream, CAMcombinedEntity& A)
CAMcombinedEntity& operator = ( const CAMcombinedEntity& A)
char* getEntityType()
void addEntity(const CAMgeometricEntity& E)
void addEntity(char* entityName, const CAMgeometricEntity& E)
void addEntity(CAMgeometricEntity* E)
void addEntity(char* entityName, CAMgeometricEntity* E)
long getEntityCount()
CAMgeometricEntity& operator[](CAMcharPtrHandle entityName)
CAMgeometricEntity& operator[](long entityIndex)
char* getIndexName(long index)
void setIndexName(long index, char* newName)
int operator ==(const CAMcombinedEntity &A)
int operator !=(const CAMcombinedEntity &A)
This routine creates an un-initialized instance of CAMcombinedEntity
CAMcombinedEntity( const CAMcombinedEntity& A)
Creates a replicate list from A (each of the entities of A are replicated in the new list).
Initializes an existing instance to a null instance (essentially an invocation of the null constructor for and existing object).
void initialize(const CAMcombinedEntity& E)
Initializes an existing instance with the entity E (essentially an invocation of the copy constructor for and existing object).
ostream& operator <<(ostream& out_stream, const CAMcombinedEntity& A)
Outputs the combined entity list to the output stream out_stream. Essentially, this routine calls the output routine for each class instance contained in the list. This operation is the inverse of the >> operator. The output format is text based.
istream& operator >>(istream& in_stream, CAMcombinedEntity& A)
Inputs a combined entity list from the input stream in_stream. This operation is the inverse of the << operator. The input format is text based.
CAMcombinedEntity& operator = ( const CAMcombinedEntity& A)
A replicate of A (the right hand side) is created and assigned to the left hand side argument.
Returns class name of this class as a null terminated string .
void addEntity(const CAMgeometricEntity& E)
This routine adds an entity to the CAMcombinedEntity. The entity is given a default name constructed from the type of the geometric entity and it's order of addition to the CAMcombinedEntity. The input entity can be an instance of any class derived from CAMgeometricEntity.
void addEntity(char* entityName, const CAMgeometricEntity& E)
This routine adds an entity with name entityName to a CAMcombinedEntity. The input entity can be an instance of any class derived from CAMgeometricEntity.
void addEntity(CAMgeometricEntity* E)
A version of the addEntity member function that accepts pointers to instances of classes derived from CAMgeometricEntity.
void addEntity(char* entityName, CAMgeometricEntity* E)
A version of the addEntity member function that accepts pointers to instances of classes derived from CAMgeometricEntity.
This routine returns the number of entities in the combinedEntity instance.
CAMgeometricEntity& operator[](CAMcharPtrHandle entityName)
This routine returns (by reference) the entity with name entityName.
CAMgeometricEntity& operator[](long entityIndex)
This routine returns (by reference) the ith entity. The default base for the index is 0.
char* getIndexName(long index)
This routine returns the index name associated with the ith entity.
void setIndexName(long index, char* newName)
This routine sets the index name associated with the ith entity.
int operator ==(const CAMcombinedEntity &A)
Returns a value of 1 if all of the contained entities are equivalent. This routine uses the derived class instances of the == operator, returns 0 otherwise.
int operator !=(const CAMcombinedEntity &A)
Returns a value of 1 unless all of the the entities are equivalent, in which case returns 0. This routine uses the derived class instances of the != operator.