This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Only log names that start with "j". | |
| // Objective-C version... | |
| [[RACAble(self.username) | |
| filter:^(NSString *newName) { | |
| return [newName hasPrefix:@"j"]; | |
| }] | |
| subscribeNext:^(NSString *newName) { | |
| NSLog(@"%@", newName); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #import <Foundation/Foundation.h> | |
| #import <ReactiveCocoa/ReactiveCocoa.h> | |
| interface Reactive | |
| property (retain) | |
| String name | |
| String address | |
| registerProperties |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| parseQueue = OperationQueue.new | |
| NotificationCenter.defaultCenter.addObserver: self, | |
| selector: |addEarthquakes:|, | |
| name: kAddEarthquakesNotif, | |
| object: nil | |
| ... | |
| self.parseQueue.addOperation: parseOperation | |
| parseOperation.release // once added to the NSOperationQueue it's retained, we don't need it anymore |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| protocol OrderedCollection <FastEnumeration> | |
| at: UInteger index, return instancetype | |
| put: instancetype object | |
| end | |
| protocol MapCollection <FastEnumeration> | |
| at: id key, return instancetype |
NewerOlder