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

GTaskFactory


Enumerations

enum  { PROP_0, PROP_APP, PROP_PROGRAM, PROP_CONN_GROUP }

Functions

void gtask_factory_class_init (GTaskFactoryClass *factory)
void gtask_factory_init (GTaskFactory *factory)
 initializes a GTaskFactory

void gtask_factory_dispose (GObject *obj)
void gtask_factory_finalize (GObject *obj)
gchar * gtask_factory_next_task_id (GTaskFactory *factory)
 determines the next available task id and returns that

void gtask_factory_set_property (GObject *object, guint param_id, const GValue *value, GParamSpec *pspec)
void gtask_factory_get_property (GObject *object, guint param_id, GValue *value, GParamSpec *pspec)
GTaskFactorygtask_factory_default (void)
GType gtask_factory_get_type ()
GTaskFactorygtask_factory_new ()
 creates a new GTaskFactory

GTaskFactorygtask_factory_new_with_resources (GTaskConnectionGroup *conn_group, const gchar *program, const gchar *application)
 creates a new GTaskFactory with passed in application name

GTaskGenericTaskgtask_factory_create_task (GTaskFactory *factory, gchar *task_type)
 creates a new task of the passed in type. The new task will have it's application and task_id fields set by the factory.

const gchar * gtask_factory_get_program (GTaskFactory *factory)
 Returns the program name that is currently set in the passed in GTaskFactory.

void gtask_factory_set_program (GTaskFactory *factory, const char *program)
 Sets the program name for the passed in GTaskFactory.

const gchar * gtask_factory_get_application (GTaskFactory *factory)
 Returns the application name that is currently set in the passed in GTaskFactory.

void gtask_factory_set_application (GTaskFactory *factory, const char *application)
 Sets the application name for the passed in GTaskFactory.

GTaskConnectionGroupgtask_factory_get_connection_group (GTaskFactory *factory)
 Returns the GTaskConnectionGroup.

void gtask_factory_set_connection_group (GTaskFactory *factory, GTaskConnectionGroup *conn_group)
 Sets the GTaskConnectionGroup for the passed in GTaskFactory.


Variables

gpointer parent_class
GTaskFactorydefault_factory = NULL

Enumeration Type Documentation

anonymous enum
 

Enumeration values:
PROP_0 
PROP_APP 
PROP_PROGRAM 
PROP_CONN_GROUP 

Definition at line 9 of file gtask-factory.c.


Function Documentation

void gtask_factory_class_init GTaskFactoryClass factory  )  [static]
 

Definition at line 75 of file gtask-factory.c.

GTaskGenericTask* gtask_factory_create_task GTaskFactory factory,
gchar *  task_type
 

creates a new task of the passed in type. The new task will have it's application and task_id fields set by the factory.

Author:
Michael Henson
Parameters:
factory a GTaskFactory or NULL to use the default factory.
task_type the name or uri of the task type to be created for the moment the factory will only return packets of type GTaskGenericTask, but differing values of task type will set the category of that task for you automatically. Valid task types and their corresponding categories are: (GTaskGenericTask - "Unspecified", GTaskDownloadTask - "Downloads", GTaskPrintTask - "Print Jobs")
Returns:
the new GTaskGenericTask

Todo:
internationalize this

Todo:
this should probably return just a plain generic task

eventually this should be way more unique: ie the concat of program-pid-time-task-id

Definition at line 289 of file gtask-factory.c.

GTaskFactory * gtask_factory_default void   )  [static]
 

Definition at line 225 of file gtask-factory.c.

void gtask_factory_dispose GObject *  obj  )  [static]
 

Definition at line 141 of file gtask-factory.c.

void gtask_factory_finalize GObject *  obj  )  [static]
 

Definition at line 155 of file gtask-factory.c.

const gchar* gtask_factory_get_application GTaskFactory factory  ) 
 

Returns the application name that is currently set in the passed in GTaskFactory.

Attention:
The returned string should be considered read only.
Parameters:
factory a GTaskFactory or NULL to use the default one.
Returns:
the application name

Definition at line 396 of file gtask-factory.c.

GTaskConnectionGroup* gtask_factory_get_connection_group GTaskFactory factory  ) 
 

Returns the GTaskConnectionGroup.

Parameters:
factory a GTaskFactory or NULL for the default factory
Returns:
the GTaskConnectionGroup or NULL if none was set

Definition at line 435 of file gtask-factory.c.

const gchar* gtask_factory_get_program GTaskFactory factory  ) 
 

Returns the program name that is currently set in the passed in GTaskFactory.

Attention:
The returned string should be considered read only.
Parameters:
factory a GTaskFactory or NULL to use the default one.
Returns:
the program name

Definition at line 356 of file gtask-factory.c.

void gtask_factory_get_property GObject *  object,
guint  param_id,
GValue *  value,
GParamSpec *  pspec
[static]
 

Definition at line 190 of file gtask-factory.c.

GType gtask_factory_get_type void   ) 
 

Definition at line 49 of file gtask-factory.c.

void gtask_factory_init GTaskFactory factory  )  [static]
 

initializes a GTaskFactory

Author:
Michael Henson
Parameters:
factory the GTaskFactory to initialize
Todo:
check out glib and see which of these we may have to free ourselves

Definition at line 119 of file gtask-factory.c.

GTaskFactory* gtask_factory_new void   ) 
 

creates a new GTaskFactory

Author:
Michael Henson
Returns:
the new GTaskFactory

Definition at line 220 of file gtask-factory.c.

GTaskFactory* gtask_factory_new_with_resources GTaskConnectionGroup conn_group,
const gchar *  program,
const gchar *  application
 

creates a new GTaskFactory with passed in application name

Attention:
The passed in GTaskConnectionGroup will have its reference count incremented.
Author:
Michael Henson
Parameters:
conn a GTaskConnectionGroup -- all tasks created through the GTaskFactory will serialize to this connection group by default
program The program name, or NULL if you wish to inherit this value from glib.
application The application name, or NULL if you wish to inherit this value from glib.
Returns:
the new GTaskFactory

Definition at line 254 of file gtask-factory.c.

gchar * gtask_factory_next_task_id GTaskFactory factory  )  [static]
 

determines the next available task id and returns that

Author:
Michael Henson
Parameters:
factory a GTaskFactory
Returns:
a character string holding the new task id

Definition at line 339 of file gtask-factory.c.

void gtask_factory_set_application GTaskFactory factory,
const char *  application
 

Sets the application name for the passed in GTaskFactory.

Parameters:
factory a GTaskFactory, or NULL to use the default factory
program the new application name

Definition at line 412 of file gtask-factory.c.

void gtask_factory_set_connection_group GTaskFactory factory,
GTaskConnectionGroup conn_group
 

Sets the GTaskConnectionGroup for the passed in GTaskFactory.

Attention:
This function will increase the reference count on the passed in GTaskConnection.
Parameters:
factory a GTaskFactory or NULL for the default factory
conn_group a GTaskConnectionGroup

Definition at line 456 of file gtask-factory.c.

void gtask_factory_set_program GTaskFactory factory,
const char *  program
 

Sets the program name for the passed in GTaskFactory.

Parameters:
factory a GTaskFactory, or NULL to use the default factory
program the new program name

Definition at line 372 of file gtask-factory.c.

void gtask_factory_set_property GObject *  object,
guint  param_id,
const GValue *  value,
GParamSpec *  pspec
[static]
 

Definition at line 167 of file gtask-factory.c.


Variable Documentation

GTaskFactory* default_factory = NULL [static]
 

Definition at line 17 of file gtask-factory.c.

gpointer parent_class [static]
 

Definition at line 16 of file gtask-factory.c.


Generated on Mon Feb 2 21:26:17 2004 for libgtask by doxygen 1.3.4