Class: MScrapNegotiator

Declaration: ScrapNegotiator.h

Taxonomy Categories:

Member Functions:


Interface Category:

API.

Inherits From:

MScrapAcceptor

Inherited By:

None.

Purpose:

MScrapNegotiator derives from MScrapAcceptor and is a mixin class that defines the protocols necessary for negotiating with the clipboard over the data type to be transferred.

Instantiation:

Abstract base class; do not allocate.

Deriving Classes:

Derived classes must override the pure virtual functions AcceptData, and ChoosePreferredType.

Concurrency:

Not multithread safe.

Resource Use:

No special requirements.

Member Function: MScrapNegotiator::~MScrapNegotiator

virtual ~ MScrapNegotiator ()

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.

Member Function: MScrapNegotiator::ChoosePreferredType

virtual bool ChoosePreferredType (const TSequenceOf < TTypeDescription > & types, TTypeDescription & chosenType) const

Interface Category:

API.

Purpose:

Selects from the specified sequence, the data type preferred by this acceptor.

Calling Context:

You can call this function directly.

Parameters:

Return Value:

Returns true if this function returned a preferred data type.

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 MScrapNegotiator.

Member Function: MScrapNegotiator::AcceptData

virtual bool AcceptData (const TTypeDescription & theType, const TScrapItem & theData)

Interface Category:

API.

Purpose:

Accepts the specified data of the specified type.

Calling Context:

You can call this function directly.

Parameters:

Return Value:

Returns true if this acceptor accepts the provided data.

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 MScrapNegotiator.

Member Function: MScrapNegotiator::MScrapNegotiator

MScrapNegotiator ()

Interface Category:

API.

Purpose:

Default constructor.

Calling Context:

Called by the stream-in operators.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

MScrapNegotiator is an abstract base class--all the constructors are protected. Do not instantiate this class.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.