84 "CPrefetchManager::AddAction: action is null");
113 case eFailed:
return "eFailed";
135 : m_Manager(&manager),
138 for (
size_t i = 0;
i < active_size; ++
i ) {
148 it->GetNCPointer()->RequestToCancel();
Base class for all object manager exceptions.
#define ITERATE(Type, Var, Cont)
ITERATE macro to sequence through container elements.
TErrCode GetErrCode(void) const
Get error code.
#define NCBI_THROW(exception_class, err_code, message)
Generic macro to throw an exception, given the exception class, error code and message string.
virtual const char * GetErrCodeString(void) const
Get error code interpreted as text.
virtual ~IPrefetchListener(void)
void CancelAllTasks(void)
virtual const char * GetErrCodeString(void) const override
Get error code interpreted as text.
CIRef< IPrefetchActionSource > m_Source
CPrefetchSequence(CPrefetchManager &manager, IPrefetchActionSource *source, size_t active_size=10)
void EnqueNextAction(void)
CRef< CPrefetchRequest > GetNextToken(void)
Returns next action waiting for its result if necessary.
virtual ~IPrefetchActionSource(void)
CRef< CPrefetchManager > m_Manager
CRef< CPrefetchRequest > AddAction(TPriority priority, IPrefetchAction *action, IPrefetchListener *listener)
CRef< CPrefetchManager_Impl > m_Impl
virtual const char * GetErrCodeString(void) const override
Get error code interpreted as text.
list< CRef< CPrefetchRequest > > m_ActiveTokens
CRef< CPrefetchRequest > AddAction(TPriority priority, IPrefetchAction *action, IPrefetchListener *listener=0)
void Reset(void)
Reset reference object.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define END_SCOPE(ns)
End the previously defined scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define BEGIN_SCOPE(ns)
Define a new scope.
void Abort(const CTimeSpan *timeout=NULL)
Abort all functions of the pool – cancel all queued tasks, send cancellation notifications to all cur...
void CancelTasks(TExclusiveFlags tasks_group)
Cancel the selected groups of tasks in the pool.
@ fCancelQueuedTasks
Cancel all tasks waiting in the queue and not yet executing.
@ fCancelExecutingTasks
Cancel all currently executing tasks.
int TRunMode
Bitwise OR'd flags for thread creation passed to Run().
const CharType(& source)[N]
Static variables safety - create on demand, destroy on application termination.
Multi-threading – classes, functions, and features.