Daniel Zheng

iOS UI Testing

I was initially attracted to Wealthfront by its great business model and engineering driven culture. But after visiting the office, I was convinced that I belonged to Wealthfront because of the strong emphasis on test driven development (TDD), continuous integration, and rapid deployment. Furthermore, a solid foundation had already been laid for the iOS initiatives […]

September 16, 2014

Hugh

Mimicking Abstract Classes with Objective-C

Objective-C doesn’t have the abstract class construct. The common approach to mimic it is to use NSObject’s doesNotRecognizeSelector: @interface ShapeBase : NSObject {} – (void)draw { [self doesNotRecognizeSelector:_cmd]; } @end @interface Circle : ShapeBase {} // missing draw method @end This forces subclasses to override, otherwise you get a runtime exception. There’s also another approach […]

July 03, 2010

Hugh

iPhone Authentication with Facebook Connect

Here at kaChing, we have multiple platforms to access your Virtual Portfolio. Two of those are the iPhone and Facebook. When we released our iPhone app, we wanted Facebook users to easily login using their Facebook credentials. Facebook provides an iPhone library that handles sessions/authentication. To show a login dialog: FBSession *session = [FBSession sessionForApplication:myApiKey […]

November 02, 2009