Inherits from NSObject
Declared in OGWJob.h

Overview

A job performs a sequence of OGWTask objects. Jobs are run and managed by the OGWJobAspect.

Tasks that complete instantly will execute sequentially within the same frame, until either the job is finished or the job advanced to a task that does not finish instantly.

Tasks

Job Aspect

Delegate

State

Creating Jobs

Internal Use Only

Properties

currentTask

The currently running OGWTask. Returns nil if the job isn’t running.

@property (readonly) OGWTask *currentTask

Return Value

The currently running OGWTask. Returns nil if the job isn’t running.

Declared In

OGWJob.h

delegate

The Job’s delegate. Must be an OGWAspect.

@property (weak) OGWAspect<OGWJobDelegate> *delegate

Return Value

The Job’s delegate. Must be an OGWAspect.

Declared In

OGWJob.h

jobAspect

Reference to the OGWJobAspect running this job. Is nil if the job isn’t running.

@property (weak) OGWJobAspect *jobAspect

Return Value

Reference to the OGWJobAspect running this job. Is nil if the job isn’t running.

Declared In

OGWJob.h

running

YES if the job is running, NO otherwise (not started or already finished).

@property (readonly) BOOL running

Return Value

YES if the job is running, NO otherwise (not started or already finished).

Declared In

OGWJob.h

Class Methods

jobWithTasks:

Creates a new job with one or more tasks.

+ (id)jobWithTasks:(NSArray *)tasks

Parameters

tasks

An array of OGWTask objects.

Return Value

A new job.

Declared In

OGWJob.h

Instance Methods

cancel

- (void)cancel

proceedWithStep:

- (void)proceedWithStep:(GWStep)currentStep

startWithStep:

- (void)startWithStep:(GWStep)step