Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
MCollectible
Inherited By:
None.
Purpose:
Selections are used to specify the data that is to be the target of a document component command. The document component selection is a monomorphic class that splits the data into two pieces: a selection on the presenter state and a selection on the model.
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
Do not derive from this class.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
Other Considerations:
Invariants:
Assertion (GetPresenterStateSelection() != NIL).
Assertion (GetModelSelection() != NIL ).
- TDocumentComponentSelection (const TModelSelection &, const TPresenterStateSelection &)
- TDocumentComponentSelection (TModelSelection * adoptM, TPresenterStateSelection * adoptP)
- TDocumentComponentSelection (TDocumentComponent&)
- TDocumentComponentSelection (const TDocumentComponentSelection &)
- TDocumentComponentSelection()
Interface Category:
API.
Purpose:
- Creates a component selection containing the presenter state selection, and the model selection.
- Creates a component selection adopting the presenter state selection, and the model selection.
- Creates a component selection with a whole model selection and whole presenter state selection for the component.
- Copy constructor. Deep-copies the component selection. In both cases, the component selection owns the presenter state and model selections.
- Default constructor. This is only for internal use by Resurrect. This function is protected.
Calling Context:
- Call this function directly.
- Call this function directly.
- Call this function directly.
- Called to copy an object. You can also call this function directly.
- Only for internal use by Resurrect.
Parameters:
Return Value:
None.
Exceptions:
- Throws no exceptions, passes all exceptions through.
- Throws kNILSelection if either the presenter state selection or the model selection is NIL.
- Throws no exceptions, passes all exceptions through.
- Throws no exceptions, passes all exceptions through.
- Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual ~ TDocumentComponentSelection ()
Interface Category:
API.
Purpose:
Destructor. Called to destroy an object. Deletes the presenter state selection and the model selection.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
bool IsDefined () const
Interface Category:
API.
Purpose:
Indicates whether this selection specifies a valid range of data.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns true if the selection is defined.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
- TPresenterStateSelection * GetPresenterStateSelection ()
- const TPresenterStateSelection * GetPresenterStateSelection () const
Interface Category:
API.
Purpose:
- The component selection is comprised of a presenter state and a model selection. This accessor returns the presenter state subselection.
- The component selection is comprised of a presenter state and a model selection. This accessor returns the presenter state subselection.
Calling Context:
Call this function directly.
Parameters:
Return Value:
- Returns a pointer to the presenter state selection.
- Returns a const pointer to the presenter state selection.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
void AdoptPresenterStateSelection (TPresenterStateSelection *)
Interface Category:
API.
Purpose:
Adopts the specified presenter state selection into the component selection. The old presenter state selection is deleted. There is no corresponding OrphanPresenterSelection because it is not possible to have a component selection with out a presenter state subselection.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
- TModelSelection * GetModelSelection ()
- const TModelSelection * GetModelSelection () const
Interface Category:
API.
Purpose:
- The component selection is comprised of a presenter state and model selection. This accessor returns the model subselection.
- The component selection is comprised of a presenter state and model selection. This accessor returns the model subselection.
Calling Context:
Call this function directly.
Parameters:
Return Value:
- Returns a pointer to a subselection on the model's data.
- Returns a const pointer to a subselection on the model's data.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
void AdoptModelSelection (TModelSelection *)
Interface Category:
API.
Purpose:
Adopts the specified model selection into the component selection. The old model selection is deleted. There is no corresponding OrphanModelSelection because it is not possible to have a component selection with out a model subselection.
Calling Context:
Call this function directly.
Parameters:
- TModelSelection * -The new model selection to replace the old model selection.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
void DeselectAll ()
Interface Category:
API.
Purpose:
Resets the selection so that it no longer specifies any model or presenter state data. This delegates to TPresenterStateSelection:: DeselectAll and TModelSelection::DeselectAll.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
Preconditions:
Assertion (IsDefined() ==true ).
Postconditions:
Assertion ( IsEmpty() ==true ).
Invariants:
Assertion ( IsDefined() ==true ).
void SelectWholeComponent ()
Interface Category:
API.
Purpose:
Selects all the information contained in the model and presenter states. It does this by delegating to TModelSelection::SelectWholeModel and TPresenterStateSelection::SelectWholePresenterState.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
Postconditions:
Assertion (IsDefined() ==true ).
virtual void SetUndefined ()
Interface Category:
API.
Purpose:
Marks this selection as being undefined. It does not specify any model insertion point or model data.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
Postconditions:
Assertion (IsDefined() ==false ).
void SelectDefault ()
Interface Category:
API.
Purpose:
Makes a default selection on this model and presenter state. This member function delegates to TModelSelection::SelectDefault and TPresenterStateSelection::SelectDefault.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
Postconditions:
Assertion (IsDefined() ==true ).
TDocumentComponentSelection & operator =(const TDocumentComponentSelection &)
Interface Category:
API.
Purpose:
Assignment operator.
Calling Context:
Called when an object is assigned to another compatible object.
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 TStream & operator >>=(TStream & towhere) const
Interface Category:
API.
Purpose:
Stream-out operator.
Calling Context:
Called to stream out data. You can also call this function directly.
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.
virtual TStream & operator <<= (TStream & fromwhere)
Interface Category:
API.
Purpose:
Stream-in operator.
Calling Context:
Called to stream in data. You can also call this function directly.
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 a TInvalidVersionError if the version of the object on the stream is unknown to the version of the shared library installed.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual long Hash () const
Interface Category:
API.
Purpose:
Standard hashing for the collection classes.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns the hash value.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
void SetModelSelection (const TModelSelection &)
Interface Category:
Adopts a copy of the specified model selection into the component selection. The old model selection is deleted.
Calling Context:
Call this function directly.
Parameters:
- TModelSelection * -The new model selection to replace the old model selection.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
API.
Other Considerations:
None.
void SetPresenterStateSelection (const TPresenterStateSelection &)
Interface Category:
API.
Purpose:
Adopts a copy of the specified presenter state selection into the component selection. The old presenter state selection is deleted.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
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.