C# Class IronIO.IronWorker

Iron Worker API interface
Mostra file Open project: odeits/IronTools Class Usage Examples

Public Methods

Method Description
Cancel ( string id ) : bool

Cancels a task

CancelSchedule ( string id ) : void

Cancels a schedule

Code ( string id ) : CodeInfo

Gets information on a code object

CodeRevisions ( string id, int page, int per_page = 30 ) : IList

Gets a paged list of the revisions of a code object

Codes ( int page, int per_page = 30 ) : IList

Gets a paged list of code objects

DeleteCode ( string id ) : void

Deletes a code object

IronWorker ( string projectId = null, string token = null ) : System

Initializes a new instance of the IronWorker class.

Log ( string id ) : string

Get a log

Queue ( IEnumerable tasks ) : IList

Enqueue an IEnumerable of Task

Queue ( string code_name, string payload, int priority, int timeout = 3600, int delay ) : IList

Enqueue a single task

Schedule ( string id ) : ScheduleTask

Gets a Schedule

ScheduleWorker ( ) : IList

Schedules tasks

Schedules ( int page, int per_page = 30 ) : IList

Gets a paged list of Schedules

Task ( string id ) : Task

Get a Task

Tasks ( int page, int per_page = 30, StatusEnum statusFilter = StatusEnum.All, System.DateTime from_time = null, System.DateTime to_time = null ) : IList

Gets a paged list of Tasks

Method Details

Cancel() public method

Cancels a task
public Cancel ( string id ) : bool
id string Task identifier
return bool

CancelSchedule() public method

Cancels a schedule
public CancelSchedule ( string id ) : void
id string Schedule identifier
return void

Code() public method

Gets information on a code object
public Code ( string id ) : CodeInfo
id string Code identifier
return IronIO.Data.CodeInfo

CodeRevisions() public method

Gets a paged list of the revisions of a code object
public CodeRevisions ( string id, int page, int per_page = 30 ) : IList
id string Code identifier
page int Zero based page index
per_page int Number of results per page
return IList

Codes() public method

Gets a paged list of code objects
public Codes ( int page, int per_page = 30 ) : IList
page int Zero based page index
per_page int Number of results per page
return IList

DeleteCode() public method

Deletes a code object
public DeleteCode ( string id ) : void
id string Code identifier
return void

IronWorker() public method

Initializes a new instance of the IronWorker class.
public IronWorker ( string projectId = null, string token = null ) : System
projectId string Project identifier available from the HUD
token string Token available from the HUD
return System

Log() public method

Get a log
public Log ( string id ) : string
id string Log identifier
return string

Queue() public method

Enqueue an IEnumerable of Task
public Queue ( IEnumerable tasks ) : IList
tasks IEnumerable Tasks to be enqueued
return IList

Queue() public method

Enqueue a single task
public Queue ( string code_name, string payload, int priority, int timeout = 3600, int delay ) : IList
code_name string Code name of the task
payload string JSON payload to be sent to the task
priority int Task priority
timeout int Task timeout
delay int Delay in seconds before executing the task
return IList

Schedule() public method

Gets a Schedule
public Schedule ( string id ) : ScheduleTask
id string Schedule identifier
return IronIO.Data.ScheduleTask

ScheduleWorker() public method

Schedules tasks
public ScheduleWorker ( ) : IList
return IList

Schedules() public method

Gets a paged list of Schedules
public Schedules ( int page, int per_page = 30 ) : IList
page int Zero based page index
per_page int Number of results per page
return IList

Task() public method

Get a Task
public Task ( string id ) : Task
id string Task identifier
return IronIO.Data.Task

Tasks() public method

Gets a paged list of Tasks
public Tasks ( int page, int per_page = 30, StatusEnum statusFilter = StatusEnum.All, System.DateTime from_time = null, System.DateTime to_time = null ) : IList
page int Zero based page index
per_page int Number of results per page
statusFilter StatusEnum Only lists tasks that match this status filter
from_time System.DateTime Lower bound of the time of the task
to_time System.DateTime Upper bound of the time of the task
return IList