Condividi tramite


CAsyncMonikerFile Class

Provides functionality for the use of asynchronous monikers in ActiveX controls (formerly OLE controls).

class CAsyncMonikerFile : public CMonikerFile

Members

Public Constructors

Name

Description

CAsyncMonikerFile::CAsyncMonikerFile

Constructs a CAsyncMonikerFile object.

Public Methods

Name

Description

CAsyncMonikerFile::Close

Closes and releases all resources.

CAsyncMonikerFile::GetBinding

Retrieves a pointer to the asynchronous transfer binding.

CAsyncMonikerFile::GetFormatEtc

Retrieves the format of the data in the stream.

CAsyncMonikerFile::Open

Opens a file asynchronously.

Protected Methods

Name

Description

CAsyncMonikerFile::CreateBindStatusCallback

Creates a COM object that implements IBindStatusCallback.

CAsyncMonikerFile::GetBindInfo

Called by the OLE system library to request information on the type of bind to be created.

CAsyncMonikerFile::GetPriority

Called by the OLE system library to get the priority of the binding.

CAsyncMonikerFile::OnDataAvailable

Called to provide data as it becomes available to the client during asynchronous bind operations.

CAsyncMonikerFile::OnLowResource

Called when resources are low.

CAsyncMonikerFile::OnProgress

Called to indicate progress on the data downloading process.

CAsyncMonikerFile::OnStartBinding

Called when binding is starting up.

CAsyncMonikerFile::OnStopBinding

Called when asynchronous transfer is stopped.

Remarks

Derived from CMonikerFile, which in turn is derived from COleStreamFile, CAsyncMonikerFile uses the IMoniker interface to access any data stream asynchronously, including loading files asynchronously from a URL. The files can be datapath properties of ActiveX controls.

Asynchronous monikers are used primarily in Internet-enabled applications and ActiveX controls to provide a responsive user-interface during file transfers. A prime example of this is the use of CDataPathProperty to provide asynchronous properties for ActiveX controls. The CDataPathProperty object will repeatedly get a callback to indicate availability of new data during a lengthy property exchange process.

For more information about how to use asynchronous monikers and ActiveX controls in Internet applications, see the following articles:

Inheritance Hierarchy

CObject

CFile

COleStreamFile

CMonikerFile

CAsyncMonikerFile

Requirements

Header: afxole.h

See Also

Reference

CMonikerFile Class

Hierarchy Chart

CMonikerFile Class

CDataPathProperty Class

Asynchronous Versus Synchronous Monikers