次の方法で共有


ISpTask (Windows Embedded CE 6.0)

1/6/2010

This interface is a C++ pure virtual interface, and not a COM interface. It is used by objects that want to perform atomic operations that are optimized for a multiprocessor computer. The ISpTaskManager can be used to create task objects that support the ISpNotifySink interface. When the Notify is called on these objects, a thread will be allocated from a thread pool, and the ISpTask::Execute method will be called on that thread. The client code then performs whatever operation it wishes on that thread and returns from the Execute method when done. Applications should avoid blocking on I/O operations because they are consuming a thread from the shared thread pool.

When to Implement

ISpTask is most useful with multiprocessor computers. ISpTask allocates tasks efficiently based on the current availability of microprocessor time. Implement ISpTask on objects that perform tasks that can be broken into smaller tasks.

Methods

The following table lists the methods for the ISpTask interface in Vtable Order.

Methods Description

Execute

Calls on a worker thread to allow the client to perform necessary task operations.

Requirements

Header sapiddk.h, sapiddk.idl
Library sapilib.lib
Windows Embedded CE Windows CE .NET 4.1 and later

See Also

Reference

SAPI Interfaces