mirror of
https://github.com/zhigang1992/RestKit.git
synced 2026-04-22 20:18:53 +08:00
Placing opening braces on a new line for methods to match Apple convention. Refs #614
Used uncrustify's "nl_fdef_brace = add" option to detect issues.
This commit is contained in:
@@ -10,7 +10,8 @@
|
||||
|
||||
@implementation RKMappingOperationQueue
|
||||
|
||||
- (id)init {
|
||||
- (id)init
|
||||
{
|
||||
self = [super init];
|
||||
if (self) {
|
||||
_operations = [NSMutableArray new];
|
||||
@@ -19,29 +20,35 @@
|
||||
return self;
|
||||
}
|
||||
|
||||
- (void)dealloc {
|
||||
- (void)dealloc
|
||||
{
|
||||
[_operations release];
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
- (void)addOperation:(NSOperation *)op {
|
||||
- (void)addOperation:(NSOperation *)op
|
||||
{
|
||||
[_operations addObject:op];
|
||||
}
|
||||
|
||||
- (void)addOperationWithBlock:(void (^)(void))block {
|
||||
- (void)addOperationWithBlock:(void (^)(void))block
|
||||
{
|
||||
NSBlockOperation *blockOperation = [NSBlockOperation blockOperationWithBlock:block];
|
||||
[_operations addObject:blockOperation];
|
||||
}
|
||||
|
||||
- (NSArray *)operations {
|
||||
- (NSArray *)operations
|
||||
{
|
||||
return [NSArray arrayWithArray:_operations];
|
||||
}
|
||||
|
||||
- (NSUInteger)operationCount {
|
||||
- (NSUInteger)operationCount
|
||||
{
|
||||
return [_operations count];
|
||||
}
|
||||
|
||||
- (void)waitUntilAllOperationsAreFinished {
|
||||
- (void)waitUntilAllOperationsAreFinished
|
||||
{
|
||||
for (NSOperation *operation in _operations) {
|
||||
[operation start];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user