API  0.9.6
 All Classes Files Functions Variables Macros Modules Pages
CPOperationQueue Class Reference

Represents an operation queue that can run CPOperations. More...

#import <CPOperationQueue.h>

+ Inheritance diagram for CPOperationQueue:

Instance Methods

(void) - addOperation:
 
(void) - addOperations:waitUntilFinished:
 
(void) - addOperationWithFunction:
 
(void) - cancelAllOperations
 
(id) - init
 
(BOOL) - isSuspended
 
(int) - maxConcurrentOperationCount
 
(CPString- name
 
(int) - operationCount
 
(CPArray- operations
 
(void) - setName:
 
(void) - setSuspended:
 
(void) - waitUntilAllOperationsAreFinished
 
- Instance Methods inherited from CPObject
(void) - addObserver:forKeyPath:options:context:
 
(void) - applyChange:toKeyPath:
 
(id) - autorelease
 
(id) - awakeAfterUsingCoder:
 
(void) - awakeFromCib
 
(void) - bind:toObject:withKeyPath:options:
 
(Class) - classForCoder
 
(Class) - classForKeyedArchiver
 
(CPString- className
 
(id) - copy
 
(void) - dealloc
 
(CPString- description
 
(CPDictionary- dictionaryWithValuesForKeys:
 
(void) - didChange:valuesAtIndexes:forKey:
 
(void) - didChangeValueForKey:
 
(void) - didChangeValueForKey:withSetMutation:usingObjects:
 
(void) - doesNotRecognizeSelector:
 
(CPArray- exposedBindings
 
(id) - forwardingTargetForSelector:
 
(void) - forwardInvocation:
 
(unsigned) - hash
 
(BOOL) - implementsSelector:
 
(CPDictionary- infoForBinding:
 
(BOOL) - isEqual:
 
(BOOL) - isKindOfClass:
 
(BOOL) - isMemberOfClass:
 
(BOOL) - isProxy
 
(IMP) - methodForSelector:
 
(CPMethodSignature) - methodSignatureForSelector:
 
(id) - mutableArrayValueForKey:
 
(id) - mutableArrayValueForKeyPath:
 
(id) - mutableCopy
 
(id) - mutableSetValueForKey:
 
(id) - mutableSetValueForKeyPath:
 
(id) - performSelector:
 
(id) - performSelector:withObject:
 
(id) - performSelector:withObject:withObject:
 
(id) - performSelector:withObjects:
 
(void) - release
 
(void) - removeObserver:forKeyPath:
 
(id) - replacementObjectForArchiver:
 
(id) - replacementObjectForCoder:
 
(id) - replacementObjectForKeyedArchiver:
 
(BOOL) - respondsToSelector:
 
(id) - retain
 
(id) - self
 
(void) - setValue:forKey:
 
(void) - setValue:forKeyPath:
 
(void) - setValue:forUndefinedKey:
 
(void) - setValuesForKeysWithDictionary:
 
(CPString- UID
 
(void) - unbind:
 
(Class) - valueClassForBinding:
 
(id) - valueForKey:
 
(id) - valueForKeyPath:
 
(id) - valueForUndefinedKey:
 
(void) - willChange:valuesAtIndexes:forKey:
 
(void) - willChangeValueForKey:
 
(void) - willChangeValueForKey:withSetMutation:usingObjects:
 

Class Methods

(CPOperationQueue+ currentQueue
 
(CPOperationQueue+ mainQueue
 
- Class Methods inherited from CPObject
(BOOL) + accessInstanceVariablesDirectly
 
(id) + alloc
 
(id) + allocWithCoder:
 
(BOOL) + automaticallyNotifiesObserversForKey:
 
(Class) + class
 
(void) + exposeBinding:
 
(void) + initialize
 
(IMP) + instanceMethodForSelector:
 
(BOOL) + instancesRespondToSelector:
 
(BOOL) + isSubclassOfClass:
 
(CPSet+ keyPathsForValuesAffectingValueForKey:
 
(void) + load
 
(id) + new
 
(void) + setVersion:
 
(Class) + superclass
 
(int) + version
 

Additional Inherited Members

- Instance Variables inherited from CPObject
Class isa
 

Detailed Description

Represents an operation queue that can run CPOperations.

Definition at line 2 of file CPOperationQueue.h.

Method Documentation

- (void) addOperation: (CPOperation anOperation
implementation

Adds the specified operation object to the receiver.

Parameters
anOperationthe operation that should be scheduled for execution

Definition at line 101 of file CPOperationQueue.j.

- (void) addOperations: (CPArray ops
waitUntilFinished: (BOOL)  wait 
implementation

Adds the specified array of operations to the queue.

Parameters
opsThe array of CPOperation objects that you want to add to the receiver.
waitIf YES, the method only returns once all of the specified operations finish executing. If NO, the operations are added to the queue and control returns immediately to the caller.

Definition at line 116 of file CPOperationQueue.j.

- (void) addOperationWithFunction: (JSObject)  aFunction
implementation

Wraps the given js function in a CPOperation and adds it to the queue

Parameters
aFunctionthe JS function to add

Definition at line 135 of file CPOperationQueue.j.

- (void) cancelAllOperations
implementation

Cancels all queued and executing operations.

Definition at line 158 of file CPOperationQueue.j.

+ (CPOperationQueue) currentQueue
implementation

Convenience method for one system wide singleton queue. Returns the same queue as mainQueue.

Definition at line 292 of file CPOperationQueue.j.

- (id) init
implementation

Initializes the receiver

Returns
the initialized receiver

Reimplemented from CPObject.

Definition at line 38 of file CPOperationQueue.j.

- (BOOL) isSuspended
implementation

Returns a Boolean value indicating whether the receiver is scheduling queued operations for execution.

Definition at line 209 of file CPOperationQueue.j.

+ (CPOperationQueue) mainQueue
implementation

Convenience method for one system wide singleton queue. Returns the same queue as currentQueue.

Definition at line 278 of file CPOperationQueue.j.

- (int) maxConcurrentOperationCount
implementation

Returns the maximum number of concurrent operations that the receiver can execute. Always returns 1 because JS doesn't have threads

Definition at line 191 of file CPOperationQueue.j.

- (CPString) name
implementation

Synthesized accessor method.

Provided by category CPOperationQueue(CPSynthesizedAccessors).

Definition at line 304 of file CPOperationQueue.j.

- (int) operationCount
implementation

Definition at line 145 of file CPOperationQueue.j.

- (CPArray) operations
implementation

Definition at line 140 of file CPOperationQueue.j.

- (void) setName: (CPString aValue
implementation

Synthesized accessor method.

Provided by category CPOperationQueue(CPSynthesizedAccessors).

Definition at line 312 of file CPOperationQueue.j.

- (void) setSuspended: (BOOL)  suspend
implementation

Modifies the execution of pending operations

Parameters
suspendif YES, queue execution is suspended. If NO, it is resumed

Definition at line 200 of file CPOperationQueue.j.

- (void) waitUntilAllOperationsAreFinished
implementation

Blocks until all of the receiver’s queued and executing operations finish executing.

Definition at line 175 of file CPOperationQueue.j.


The documentation for this class was generated from the following files: