Main Page | Data Structures | File List | Data Fields | Globals | Related Pages

KProgress.h File Reference

Task progress structure. More...

#include "ktypes.h"

Typedefs

typedef _KProgress KProgress
 Task.

Enumerations

enum  EProgress {
  IKX_PROGRESS_WAIT_BEGIN = 0, IKX_PROGRESS_PAUSE = 1, IKX_PROGRESS_RUNNING = 2, IKX_PROGRESS_CANCEL = -1,
  IKX_PROGRESS_ERROR = -2, IKX_PROGRESS_SUCCESS = 3
}
 Execution states of a task. More...

Functions

KTL_API KProgressKProgress_new ()
 Allocates a KProgress structure.
KTL_API void KProgress_init (KProgress *pProg)
 Initializes a KProgress structure.
KTL_API void KProgress_delete (KProgress **ppProg)
 Deletes a KProgress structure.
KTL_API void KProgress_setDProg (KProgress *prg, KDouble progress)
 Sets the progression with a double value between 0 and 1.
KTL_API void KProgress_setIProg (KProgress *prg, KInt64 progress)
 Sets the progression with a integer value.
KTL_API void KProgress_setITotal (KProgress *prg, KInt64 total)
 Sets the maximum integer value of the progression.
KTL_API void KProgress_setMsg (KProgress *prg, KString msg)
 Sets a message.
KTL_API void KProgress_setState (KProgress *prg, EProgress state)
 Defines the execution state of a task.
KTL_API KDouble KProgress_getProg (KProgress *prg)
 Returns the progression in a double value between 0 and 1.
KTL_API KString KProgress_getMsg (KProgress *prg)
 Returns the last message.
KTL_API EProgress KProgress_getState (KProgress *prg)
 Gets the execution state of a task.


Detailed Description

Task progress structure.

Version:
KToolLib-1.0
Author:
Fabien Gallot
Date:
22/01/2008
Note:
Copyright © 2008-2010 iKlax Media SAS (www.iklaxmedia.com). All rights reserved.

Enumeration Type Documentation

enum EProgress
 

Execution states of a task.

Enumeration values:
IKX_PROGRESS_WAIT_BEGIN  The task's waiting to begin.
IKX_PROGRESS_PAUSE  The task is in pause.
IKX_PROGRESS_RUNNING  The task's running.
IKX_PROGRESS_CANCEL  The task has been cancelled.
IKX_PROGRESS_ERROR  The task returned an error.
IKX_PROGRESS_SUCCESS  The task successed.


Function Documentation

KTL_API void KProgress_delete KProgress **  ppProg  ) 
 

Deletes a KProgress structure.

Parameters:
ppProg a reference to a KProgress structure pointer

KTL_API KString KProgress_getMsg KProgress prg  ) 
 

Returns the last message.

Parameters:
prg the pointer to the KProgress structure
Returns:
the last message

KTL_API KDouble KProgress_getProg KProgress prg  ) 
 

Returns the progression in a double value between 0 and 1.

Parameters:
prg the pointer to the KProgress structure
Returns:
the progression in a double value between 0 and 1

KTL_API EProgress KProgress_getState KProgress prg  ) 
 

Gets the execution state of a task.

Parameters:
prg the pointer to the KProgress structure
Returns:
the execution state of the task

KTL_API void KProgress_init KProgress pProg  ) 
 

Initializes a KProgress structure.

Parameters:
pProg the pointer to the structure to be initialized

KTL_API KProgress* KProgress_new  ) 
 

Allocates a KProgress structure.

Returns:
the pointer to the allocated structure if successful otherwise knull

KTL_API void KProgress_setDProg KProgress prg,
KDouble  progress
 

Sets the progression with a double value between 0 and 1.

Parameters:
prg the pointer to the KProgress structure
progress the progression as a double value between 0 and 1

KTL_API void KProgress_setIProg KProgress prg,
KInt64  progress
 

Sets the progression with a integer value.

Parameters:
prg the pointer to the KProgress structure
progress the progression as an integer value

KTL_API void KProgress_setITotal KProgress prg,
KInt64  total
 

Sets the maximum integer value of the progression.

Parameters:
prg the pointer to the KProgress structure
total the maximum integer value

KTL_API void KProgress_setMsg KProgress prg,
KString  msg
 

Sets a message.

Parameters:
prg the pointer to the KProgress structure
msg a message

KTL_API void KProgress_setState KProgress prg,
EProgress  state
 

Defines the execution state of a task.

Parameters:
prg the pointer to the KProgress structure
state the execution state


Generated on Tue Mar 9 10:49:30 2010 for iKlax Tools Library (KToolLib) by doxygen 1.3.8