Class: TCopyToClipboard

Declaration: ClipboardCommands.h

Taxonomy Categories:

Member Functions:


Interface Category:

API.

Inherits From:

TDocumentFunctor

Inherited By:

None.

Purpose:

The TCopyToClipboard class is the functor used to copy the selected data to the clipboard. It does this by creating a clipboard component and adding it to the document's list of published components. This is purely a convenience functor. Please note that this is not a command that is directed against the source document, but a functor. This is because the source document is not modified at all. Only the clipboard is.

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.

Member Function: TCopyToClipboard::TCopyToClipboard

  1. TCopyToClipboard ()
  2. TCopyToClipboard (const TCopyToClipboard &)

Interface Category:

API.

Purpose:

  1. Default constructor.
  2. Copy constructor.

Calling Context:

  1. Called by the stream-in operators.
  2. Called to copy an object.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TCopyToClipboard::~TCopyToClipboard

virtual ~ TCopyToClipboard ()

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: TCopyToClipboard::operator()

void operator () ( const TCompoundDocumentSurrogate &, const TDocumentComponentSelection & theSource) const

Interface Category:

API.

Purpose:

This operator sets the selection and document to be copied to the clipboard.

Calling Context:

You can call this directly.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TCopyToClipboard::HandleDo

void HandleDo (TDocument &)

Interface Category:

API.

Purpose:

Copies the selection from the document into the clipboard. The selection and document are set up with the operator().

Calling Context:

Called from Do.

Parameters:

Return Value:

None.

Exceptions:

Throws TCompoundDocumentException::kNILSelection if the current selection is NIL.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TCopyToClipboard::HandleStreamOutArguments

virtual void HandleStreamOutArguments (TStream &) const

Interface Category:

API.

Purpose:

Streams out the current selection to the specified stream.

Calling Context:

Called from StreamOutArguments.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TCopyToClipboard::HandleStreamInArguments

virtual void HandleStreamInArguments (TStream &)

Interface Category:

API.

Purpose:

Streams in the current selection from the specified stream.

Calling Context:

Called from StreamInArguments.

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.