InDesign SDK  20.5
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
CusDtLnkLinkResourceStateUpdaterIdleTask Class Reference
Inheritance diagram for CusDtLnkLinkResourceStateUpdaterIdleTask:
CIdleTaskIIdleTaskIPMUnknown

Public Member Functions

 CusDtLnkLinkResourceStateUpdaterIdleTask (IPMUnknown *boss)
 
virtual uint32 RunTask (uint32 flags, IdleTimer *timeCheck)
 
virtual const char * TaskName ()
 
- Public Member Functions inherited from CIdleTask
 CIdleTask (IPMUnknown *boss)
 
virtual void InstallTask (uint32 millisecsBeforeFirstRun)
 
virtual void UninstallTask ()
 

Additional Inherited Members

- Public Types inherited from IIdleTask
enum  { kDefaultIID = IID_IIDLETASK }
 
enum  { kEndOfTime = ~(uint32)0, kOnFlagChange = ~(uint32)1, kNextEventCycle = ~(uint32)2 }
 
enum  { kMaxTaskNameLength = 1023 }
 

Detailed Description

This idle task is to process the pending job for providing status update for a link resource. The jobs are maintained by the ICusDtLnkStateUpdateProcessor, this idle task simply calls ICusDtLnkStateUpdateProcessor::UpdateStateForTopJob to process the job on the queue.

See Also
CusDtLnkLinkResourceStateUpdater
ICusDtLnkStateUpdateProcessor
CusDtLnkStateUpdateProcessor

Member Function Documentation

uint32 CusDtLnkLinkResourceStateUpdaterIdleTask::RunTask (uint32 appFlags,
IdleTimertimeCheck 
)
virtual

Will perform its task and then relinquish control until it is called again. See CIdleTaskThread.h if this API is inconvenient for the task at hand.

Parameters
appFlags- Informs this method of the current state of the app see IIdleTaskMgr::ApplicationStateFlags
timeCheck- A callback method that should be called periodically during long tasks to see whether RunTask has run out of time and needs to return.
Returns
- The number of milliseconds to sleep before running again.

o Returning kEndOfTime means that this task will be removed from the IdleTaskMgr–without calling its UninstallTask method. Hence, you should do whatever other chores you do in UninstallTask before returning this value.

o If this task's UninstallTask method is called before RunTask returns, then the return value for RunTask will be ignored.

o Returning kOnFlagChange suspends this task until appFlags changes. At which point it will be called again ASAP. RunTask can continue to return kOnFlagChange as long as it doesn't like the current appFlags.

See Also
IdleTaskMgr
CIdleTaskThread
IIdleTaskMgr::ApplicationStateFlags

Implements IIdleTask.

const char * CusDtLnkLinkResourceStateUpdaterIdleTask::TaskName ()
virtual

Get the task name

Reimplemented from CIdleTask.