Skip to content

Instantly share code, notes, and snippets.

Created April 8, 2014 13:22
What would you like to do?
Builder pattern in Objective-C
NSURL *someURL = [NSURL URLWithBuilderBlock:^(NSURLComponents *builder) {
builder.scheme = @"http"; = @"";
builder.path = @"/blog/2013/10/17/nsurlcomponents/";
// url now equals:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment