Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
None.
Inherited By:
None.
Purpose:
TTypeDescription is a concrete class that is used as part of a type negotiation: for example, cut, copy, and paste.
Typically, a data source produces a list of TTypeDescriptions, describing the types it can produce. A data receiver will choose the most appropriate type from the list and request the data in that type. Most TModel derived classes provide a static GetTypeDescription function that returns the type description describing that model's class.
A TTypeDescription uses the class TType to identify the described objects type. A TTypeDescriptionExtension may also be included to provide additional information about the type or an instance of the type. If a TTypeDescriptionExtension exists, it is used for comparison.
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
This class must not be derived. This system treats TTypeDescription monomorphically. To extend a TTypeDescription, see TTypeDescriptionExtension.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
- TTypeDescription (const TType &)
- TTypeDescription (const TType &, TTypeDescriptionExtension *)
- TTypeDescription ()
- TTypeDescription (const TTypeDescription &)
Interface Category:
API.
Purpose:
- Creates a new TTypeDescription and initializes it to the specified type.
- Creates a new TTypeDescription object and initializes it to the specified type, and adopts the TTypeDescriptionExtension.
- Default constructor.
- Copy constructor.
Calling Context:
- You can call this function directly.
- You can call this function directly.
- Called by the stream-in operators.
- Called to copy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TTypeDescription & operator =(const TTypeDescription &)
Interface Category:
API.
Purpose:
Assignment operator.
Calling Context:
Call this function by using the operator in an assignment statement.
Parameters:
Return Value:
Returns a const reference to the left-hand side object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual ~ TTypeDescription ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TType GetType () const
Interface Category:
API.
Purpose:
Returns the current type for this type description object. The current type can be empty.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
Returns a TType that is the current type for this type description object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
void SetType (const TType &)
Interface Category:
API.
Purpose:
Sets the type for this type description object to the specified TToken.
Calling Context:
You can call this function directly.
Parameters:
- const TType & -The new type name for this type description object.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TTypeDescription::AdoptExtension
void AdoptExtension (TTypeDescriptionExtension *)
Interface Category:
API.
Purpose:
Adopt a type description extension into this type description. The extension allows additional, type specific data to be specified for the type.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
const TTypeDescriptionExtension * GetExtension () const
Interface Category:
API.
Purpose:
Gets thetype description extension associated with this type description. The extension may be NIL type.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
TTypeDescriptionExtension * -The current extension for this type description.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TStream & operator >>=(TStream & towhere) const
Interface Category:
API.
Purpose:
Stream-out operator.
Calling Context:
Called to stream out data.
Parameters:
- TStream & towhere -The stream to which the object streams itself out.
Return Value:
Returns a reference to the stream the object streams itself out to.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TStream & operator <<= (TStream & towhere)
Interface Category:
API.
Purpose:
Stream-in operator.
Calling Context:
Called to stream in data.
Parameters:
- TStream & fromwhere -The stream from which the object streams itself in.
Return Value:
Returns a reference to the stream the object streams itself in from.
Exceptions:
Throws TInvalidVersionError if the streamed version is not know.
Concurrency:
Not multithread safe.
Other Considerations:
None.
HashResult Hash () const
Interface Category:
API.
Purpose:
Returns the hash value for this type description object which uniquely identifies this object within its type.
Calling Context:
You can call this function directly.
Parameters:
Return Value:
Returns the hash value for this type description object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.