Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
MCollectible
Inherited By:
TGUIPresenterState
Purpose:
Provides persistent storage for states associated with a presenter on a model. It supports the creation of a document presenter, as well as subordinate document presenters.
Instantiation:
Abstract class; do not instantiate.
Deriving Classes:
Presenter states that provide state for specific types of model presenters derive from TModelPresenterState. Derived classes must override the pure virtual function CreateDocumentPresenter.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
- TModelPresenterState (const TModelReference& )
- TModelPresenterState (const TModelPresenterState&)
- TModelPresenterState ()
Interface Category:
API.
Purpose:
- Creates a new presenter state attached to the given model.
- Copy constructor.
- Default constructor.
Calling Context:
- Call this function directly.
- Call this function directly.
- Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
~ TModelPresenterState ()
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.
static TModelPresenterState * LookupForWriting (const TPresenterStateReference &)
Interface Category:
API.
Purpose:
Looks up a presenter state from a reference for read/write access. The component containing the presenter state must be locked for read/write access.
Calling Context:
Called to access a presenter state safely in a concurrent environment.
Parameters:
Return Value:
Returns a pointer to an instance of TModelPresenterState.
Exceptions:
Throws TCompoundDocumentException::kPresenterStateDoesNotExist if the presenter state is not found.
Throws TCompoundDocumentException::kComponentNotLocked if the component containing the presenter state is not locked.
Concurrency:
Not multithread safe.
Other Considerations:
None.
static const TModelPresenterState * LookupForReading (const TPresenterStateReference &)
Interface Category:
API.
Purpose:
Looks up a presenter state from a reference for read access. The component containing the presenter state must be locked for read access.
Calling Context:
Called to access a presenter state safely in a concurrent environment.
Parameters:
Return Value:
Returns a const pointer to an instance of TModelPresenterState.
Exceptions:
Throws TCompoundDocumentException::kPresenterStateDoesNotExist if the presenter state is not found.
Throws TCompoundDocumentException::kComponentNotLocked if the component containing the presenter state is not locked.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TPresenterStateReference GetReference () const
Interface Category:
API.
Purpose:
Returns a reference to this model presenter state.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns a reference to this model presenter state.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TModelPresenterState::CreateDocumentPresenter
virtual TDocumentPresenter * CreateDocumentPresenter (const TPlaceReference &) const
Interface Category:
API.
Purpose:
Creates the document presenter for the model attached to this presenter state. The document presenter must be a document-level stand-alone presenter. A typical TModelPresenterState retrieves a document presenter state from the session store or creates one, and delegates that presenter state to create the presenter.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
This function is a pure virtual function and must be overridden by classes deriving from TModelPresenterState.
Preconditions:
Assertion (TPresenterSessionStore * != NIL).
Member Function: TModelPresenterState::CreateBackupPresenterState
virtual TModelPresenterState * CreateBackupPresenterState () const
Interface Category:
API.
Purpose:
Creates a backup presenter for the attached model. A backup presenter is asked to be created each time a presenter state is streamed across. The backup presenter state must be guaranteed to be resurrectable at the destination side. It is used to display a dummy presentation if the either the presenter state or the model's shared libraries are missing. Because the backup presenter state must be resurrectable, use one of the standard backup presenter states provided by Taligent.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns a pointer to a TModelPresenterState.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
void AttachToModel (const TModelReference &)
Interface Category:
API.
Purpose:
Attaches this presenter state to a model to present.
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.
void DetachFromModel ()
Interface Category:
API.
Purpose:
Detaches from a model previously attached to.
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.
TModelReference GetModelReference () const
Interface Category:
API.
Purpose:
Gets a reference to the model to which this presenter state is attached.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns a reference to the attached model.
Exceptions:
Throws kNoModelAttach if there is not a model attached to this presenter state.
Concurrency:
Not multithread safe.
Other Considerations:
Preconditions:
Assertion (fModelReference.IsDefined() ==true).
virtual void NotifyOfChange (const TNotification &)
Interface Category:
API.
Purpose:
Notifies clients that a change has occurred in this presenter state.
Calling Context:
Called by derived classes and client selections.
Parameters:
- const TNotification & -The notification to be propagated to clients.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual void NotifyButNoChange (const TNotification &) const
Interface Category:
API.
Purpose:
Notifies clients of the status in this presenter state. Do not use this member function to notify of changes to the presenter state because it does not update the time stamp. It can be used to notify of the availability of some remotely accessed data.
Calling Context:
Called by derived classes.
Parameters:
- const TNotification & -The notification to be propagated to clients.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual void DeleteStore();
Interface Category:
API.
Purpose:
Deletes the TDocumentComponentStore associated with the component that contains this presenter state. The component stores for all children of the component are also deleted.
Calling Context:
Called when the deletion of a component is committed and the storage will never be used again.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TModelPresenterState & operator =(const TModelPresenterState &)
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 &) 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.
virtual TStream & operator <<= (TStream &)
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 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.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.