PFJob Class |
Namespace: Packflow.Core.Jobs
public abstract class PFJob : IPFLoggable
The PFJob type exposes the following members.
Name | Description | |
---|---|---|
PFJob |
You may instanciate a PFJob Implementation by using this constructor.
Call Run() or RunAsync() on it to execute.
|
Name | Description | |
---|---|---|
Description |
Override this property to return a friendly description of the PFJob.
| |
ExecutionGuid |
Gets the execution unique identifier.
| |
ExecutionId |
Gets the execution Id.
| |
FullName |
Gets the type full name.
| |
IsBusy |
Gets a value indicating whether this instance is currently executing.
| |
IsCanceled |
Gets a value indicating whether this execution should be canceled.
Code in the Execute method should take this property into account for async cancelation.
| |
Key |
Gets an unique key for this instance
| |
Logger |
Gets the loggerfor this instance. Anything logged here can be retrieved as part of a job execution info.
| |
LogIdentification |
Gets the log identification.
| |
Progression |
Gets the progression info object.
| |
Settings |
Gets the collection of settings for this PFJob.
Typical usage doen't require manipulating this collection.
Use the decorated properties on the PFJob instance instead.
| |
Site |
Gets the PFSite this PFJob belongs to.
|
Name | Description | |
---|---|---|
CancelAsync |
Call this method to cancel PFJob execution.
| |
Execute |
Main job execution method.
Will be called by the execution engine after a call to Run() or RunAsync().
Implementation should take the 'IsCanceled' property into account, and report progression via calls to 'OnProgressionChanged'.
| |
GetChoicesForSetting |
Gets the possible choices for given setting (or parameter).
| |
GetRunUsers |
Override this property to return a list of users authorized to run this PFJob.
Don't forget to include users from base method.
| |
InitJob |
Initializes the job.
Override this method to set default values to parameters, and to subscribe on job events.
| |
OnProgressionChanged |
Call this method in 'Execute' to report a progression changed.
Makes the 'Progression' property available.
| |
OnProgressionChanged(Int32, String) |
Call this method in 'Execute' to report a progression changed.
Makes the 'Progression' property available.
| |
Run |
Call this method to run PFJob synchronously.
| |
RunAsync |
Call this method to run PFJob asynchronously
| |
ToString | Returns a string that represents the current object. (Inherited from Object.) | |
Validate |
Validates this job parameters.
Override this method to provide custom validation for your parameters.
Throw PFJobValidationException if necessary.
|
Name | Description | |
---|---|---|
ExecuteCompleted |
Occurs when the execution has completed.
| |
ExecuteProgressChanged |
Occurs when OnProgressionChanged is called from execution code.
|
Name | Description | |
---|---|---|
AsT |
Casts an object to another type. Returns default(T) if the object is null.
(Defined by Utils_Other.) | |
EqualsAll |
Checks that this object is equal to every object in parameters.
(Defined by Utils_Other.) | |
EqualsAny |
Checks that this object is equal to at least one of the parameters.
(Defined by Utils_Other.) | |
GetString |
Converts an object to String using ToString() method, else returns String.Empty.
(Defined by Utils_Other.) | |
IsGenericList | Overloaded.
Checks if this object is a System.Collections.Generic.List.
(Defined by Utils_Linq.) | |
IsGenericList(Type) | Overloaded.
Checks if this object is a System.Collections.Generic.List using type as T.
(Defined by Utils_Linq.) | |
Serialize | Overloaded.
Serializes an object into an XML document.
(Defined by Utils_Xml.) | |
Serialize(String) | Overloaded.
Serializes an object into an XML document.
(Defined by Utils_Xml.) | |
SerializeJson | Overloaded.
Serializes an object using a DataContractJsonSerializer.
(Defined by Utils_String.) | |
SerializeJson(ListType) | Overloaded.
Serializes an object using a DataContractJsonSerializer.
(Defined by Utils_String.) | |
SerializeJson(DataContractJsonSerializerSettings) | Overloaded.
Serializes an object using a DataContractJsonSerializer.
(Defined by Utils_String.) |