<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Two Toasters</title>
	<atom:link href="http://twotoasters.com/index.php/feed/" rel="self" type="application/rss+xml" />
	<link>http://twotoasters.com</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Thu, 06 May 2010 17:28:42 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Introducing RestKit</title>
		<link>http://twotoasters.com/index.php/2010/04/06/introducing-restkit/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=introducing-restkit</link>
		<comments>http://twotoasters.com/index.php/2010/04/06/introducing-restkit/#comments</comments>
		<pubDate>Tue, 06 Apr 2010 15:27:58 +0000</pubDate>
		<dc:creator>Blake Watters</dc:creator>
				<category><![CDATA[Development]]></category>
		<category><![CDATA[two toasters]]></category>

		<guid isPermaLink="false">http://twotoasters.com/index.php/2010/04/06/introducing-restkit-2/</guid>
		<description><![CDATA[After reading Luke Redpath&#8217;s recent article about Core Resource and his own RestfulCoreData library, I knew we had been waiting far too long to introduce our restful modeling library to the world. So on that note I would like to introduce the Two Toasters&#8217; solution for syncing Cocoa objects with the cloud: RestKit. Design &#38; [...]]]></description>
			<content:encoded><![CDATA[<p>After reading <a href="http://lukeredpath.co.uk/blog/synching-web-services-with-core-data.html">Luke Redpath&#8217;s recent article</a> about <a href="http://coreresource.org/">Core Resource</a> and his own <a href="http://github.com/lukeredpath/RestfulCoreData">RestfulCoreData library</a>, I knew we had been waiting far too long to introduce our restful modeling library to the world. So on that note I would like to introduce the Two Toasters&#8217; solution for syncing Cocoa objects with the cloud: RestKit.</p>
<h3>Design &amp; Feature Set</h3>
<p>RestKit is a mature library providing a layer between your app&#8217;s domain objects and a restful backend in the cloud. It enables you to live in a world of Cocoa objects and then serialize them to and from your backend system with minimum fuss. RestKit aims to stay out of your way and make interacting with the web as simple and painless as possible. RestKit can currently be considered production quality and is in use on <a href="http://www.gateguruapp.com/">GateGuru</a> as well as a number of other Two Toasters apps thriving in the App Store.</p>
<p>It is quickly approaching 1.0, but still has some rough edges and currently lacks sample code to help others get started (rest assured we&#8217;ll have sample code ready by next week!). Let&#8217;s take a quick tour of the feature-set:</p>
<ul>
<li> Simple, clean API designed to be succinct and Cocoa like</li>
<li>Works on OS X and iPhone OS</li>
<li>Minimal external dependencies, currently the only external dependency is on json-framework</li>
<li> Provides robust wrappers for the request/response cycle with MIME type and status code introspection methods (i.e. isOK, isHTML, isJSON, etc.)</li>
<li> Provides support for synchronous as well as asynchronous requests out of the box</li>
<li>Supports file uploads and other requests that cannot be URL encoded</li>
<li> Provides a key-value coding based system for model mapping from JSON payloads to Cocoa object properties</li>
<li> Allows for model mapping to Core Data backed persistent models or transient vanilla NSObjects</li>
<li> Can hydrate Core Data relationships as well as properties</li>
<li>Model mapping operations are threaded to prevent the main UI thread from becoming bogged down while network operations are handled</li>
<li> Stays focused on providing excellent transport layer support without bringing UI baggage along for the ride</li>
<li> Allows for easy integration with Three20 by using the RKRequestTTModel and RKRequestFilterableTTModel (the filterable flavor enables support for searching, filtering the loaded models via one or more NSPredicate&#8217;s, and sorting the models via an NSSortDescriptor)</li>
<li> Quick switching between development/staging/production hosts by using a baseURL and resourcePath&#8217;s instead of full URL strings</li>
<li> Just enough support for Rails conventions to make integration easy, while avoiding becoming a Rails-centric library</li>
<li> Support for a global &#8216;offline&#8217; mode that enables the use of Core Data as an object cache queried via resourcePath&#8217;s. Will not generate requests in offline mode.</li>
</ul>
<h3>Let&#8217;s check out some code&#8230;</h3>
<p>Below are some simple snippets to give you a taste of what it feels like to work with RestKit.</p>
<h4>Request/Response cycle</h4>
<p>Let&#8217;s initialize a RestKit client, fire a GET request, and then ask the RKResponse object to tell us a bit about the results of the request. Note that there are corresponding methods for POST/PUT/DELETE and associated flavors that allow passing in parameters for the request.</p>
<pre>#import &lt;RestKit/RestKit.h&gt;

RKClient* client = [RKClient clientWithBaseURL:@"http://myrestkitapp.heroku.com"];
[client isNetworkAvailable];
[client get:@"/airports" delegate:self callback:@selector(airportsDidLoadResponse:)];

- (void)airportsDidLoadResponse:(RKResponse*)response {
 NSString* responseBody = [response bodyAsString];
 if ([response isHTML]) {
 // show HTML page
 } else if ([response isJSON]) {
 // parse JSON
 } else if ([response isRedirect]) {
 // follow the redirect
 }
}
</pre>
<h4>Initialize RestKit model manager</h4>
<p>Let&#8217;s initialize the a Core Data backing store for RestKit, set the mapping format to JSON (currently the only format supported, though MessagePack is planned), and register some mappings from model classes to payload elements.</p>
<pre>RKModelManager* manager = [RKModelManager managerWithBaseURL:@"http://myrestkitapp.heroku.com"];
manager.format = RKMappingFormatJSON;
manager.objectStore = [[RKManagedObjectStore alloc] initWithStoreFilename:@"RestKitApp.sqlite"];

// Establish model mapping relationships from JSON payload elements to Cocoa classes
[manager registerModel:[GGAirport class] forElementNamed:@"airport"];
[manager registerModel:[GGZone class] forElementNamed:@"zone"];</pre>
<h4>Model Mapping</h4>
<p>Here we can see what a mappable object implementation looks like. The elementToPropertyMappings method defines a dictionary specifying how to map elements in the payload to properties of the model. The elements are extracted via <strong>valueForKeyPath</strong>, so you can traverse through the response using key-value coding instead of relying on direct 1 to 1 mappings from your payload to your models.</p>
<pre>@implementation GGAirport

@dynamic city;
@dynamic code;
@dynamic name;
@dynamic state;
@dynamic country;
@dynamic airportId;

+ (NSString*)primaryKey {
 return @"airportId";
}

+ (NSDictionary*)elementToPropertyMappings {
 return [NSDictionary dictionaryWithObjectsAndKeys:
 @"city", @"city",
 @"code", @"code",
 @"name", @"name",
 @"state", @"state",
 @"country", @"country",
 @"airportId", @"id",
 nil];
}

// Sub-models included in the payload and specified here will be model-mapped
// and then assigned as the target for any Core Data associations
+ (NSDictionary*)elementToRelationshipMappings {
 return [NSDictionary dictionaryWithKeysAndObjects:
 @"zone", @"zone",
 nil];
}

@end
</pre>
<p>Here we see an example of how to work with the manager to load mappable models from the remote system. Unlike the client implementation which is callback based for flexibility, the model loader uses a simple protocol that abstracts successful and failed model loads into two methods.</p>
<pre>@implementation GGAirportConsumerExample

- (void)loadAirports {
 [[RKModelManager manager] loadModels:@"/airports" delegate:self];
}

- (void)modelLoaderRequest:(RKRequest*)request didLoadModels:(NSArray*)models response:(RKResponse*)response model:(id&lt;RKModelMappable&gt;)model {
 for (GGAirport* airport in models) {
 NSLog(@"I loaded an airport named %@", airport.name);
 }
}

- (void)modelLoaderRequest:(RKRequest*)request didFailWithError:(NSError*)error response:(RKResponse*)response model:(id&lt;RKModelMappable&gt;)model {
 NSLog(@"**** Model Loader Request failed with error : %@", [error localizedDescription]);
}

@end</pre>
<h3>Where do we go from here?</h3>
<p>I hope I&#8217;ve given you enough of a taste of RestKit to get excited and dive in. We&#8217;ve set up a Google Group as well as the normal channels of communication:</p>
<ul>
<li>Write back in the comments</li>
<li>Fork us on GitHub: <a href="http://github.com/twotoasters/RestKit">http://github.com/twotoasters/RestKit</a></li>
<li>Join the mailing list: <a href="http://groups.google.com/group/restkit">http://groups.google.com/group/restkit</a></li>
<li>Hit us up on Twitter: <a href="http://www.twitter.com/twotoasters">http://www.twitter.com/twotoasters</a></li>
</ul>
<p>Additional documentation, API polish, and sample code are in the works and on the way. Please let us know what you think and how you are using RestKit.</p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2010/04/06/introducing-restkit/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>RunnersUnite</title>
		<link>http://twotoasters.com/index.php/2010/04/02/runnersunite/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=runnersunite</link>
		<comments>http://twotoasters.com/index.php/2010/04/02/runnersunite/#comments</comments>
		<pubDate>Fri, 02 Apr 2010 13:03:30 +0000</pubDate>
		<dc:creator>Rachit Shukla</dc:creator>
				<category><![CDATA[Featured Projects]]></category>
		<category><![CDATA[Facebook]]></category>
		<category><![CDATA[Foursquare]]></category>
		<category><![CDATA[Running]]></category>
		<category><![CDATA[Twitter]]></category>

		<guid isPermaLink="false">http://twotoasters.com/index.php/2010/04/02/runnersunite/</guid>
		<description><![CDATA[Make running social Running is more fun with friends! Use the FREE RunnersUnite! application from Dick’s Sporting Goods to let your friends know about your runs and invite others to run with you. RunnersUnite! also lets you find popular running spots in your area, and see where people are running near you right now. As [...]]]></description>
			<content:encoded><![CDATA[<h4>Make running social</h4>
<p>Running is more fun with friends! Use the FREE RunnersUnite! application from Dick’s Sporting Goods to let your friends know about your runs and invite others to run with you. RunnersUnite! also lets you find popular running spots in your area, and see where people are running near you right now. As an added bonus, users that install the RunnersUnite! application will be able to receive special promotions from Dick’s Sporting Goods on popular running gear. So get out there and run – but don’t run alone!</p>
<p>Sign in with your Facebook, Twitter, or Foursquare account to get started!</p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2010/04/02/runnersunite/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Freshly Toasted Site</title>
		<link>http://twotoasters.com/index.php/2010/03/19/freshly-toasted-site/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=freshly-toasted-site</link>
		<comments>http://twotoasters.com/index.php/2010/03/19/freshly-toasted-site/#comments</comments>
		<pubDate>Fri, 19 Mar 2010 00:54:49 +0000</pubDate>
		<dc:creator>adit</dc:creator>
				<category><![CDATA[Site Related]]></category>
		<category><![CDATA[two toasters]]></category>

		<guid isPermaLink="false">http://twotoasters.com/?p=809</guid>
		<description><![CDATA[We&#8217;re in the process of getting our site upgraded to a newer theme. Look out for some new projects showing up under our work and please do let us know if you run into any issues.]]></description>
			<content:encoded><![CDATA[<p>We&#8217;re in the process of getting our site upgraded to a newer theme. Look out for some new projects showing up under our work and please do let us know if you run into any issues.</p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2010/03/19/freshly-toasted-site/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WWM</title>
		<link>http://twotoasters.com/index.php/2010/03/16/wwm/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=wwm</link>
		<comments>http://twotoasters.com/index.php/2010/03/16/wwm/#comments</comments>
		<pubDate>Tue, 16 Mar 2010 17:12:54 +0000</pubDate>
		<dc:creator>adit</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[Match]]></category>
		<category><![CDATA[Rugby]]></category>
		<category><![CDATA[Soccer]]></category>

		<guid isPermaLink="false">http://aditshukla.com/tt/2010/03/16/wwm/</guid>
		<description><![CDATA[Never miss the match 365 Incorporated, a leader in sports properties, wanted to allow soccer and rugby fans in the United States to find local venues that are showing broadcasts of their favorite rugby and soccer games. Two Toasters partnered with 365 Inc. to implement their idea through a suite of iPhone applications. We designed [...]]]></description>
			<content:encoded><![CDATA[<h4>Never miss the match</h4>
<p>365 Incorporated, a leader in sports properties, wanted to allow soccer and rugby fans in the United States to find local venues that are showing broadcasts of their favorite rugby and soccer games. Two Toasters partnered with 365 Inc. to implement their idea through a suite of iPhone applications.</p>
<p>We designed and built both iPhone applications and implemented their supporting web servers. The Where to Watch the Match applications showcase Two Toasters technical ability and diverse skill set to implement for a wide range of clients.</p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2010/03/16/wwm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>FakeConv</title>
		<link>http://twotoasters.com/index.php/2010/03/15/fakeconv/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=fakeconv</link>
		<comments>http://twotoasters.com/index.php/2010/03/15/fakeconv/#comments</comments>
		<pubDate>Mon, 15 Mar 2010 17:29:14 +0000</pubDate>
		<dc:creator>adit</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[Humor]]></category>
		<category><![CDATA[In-App Purchases]]></category>
		<category><![CDATA[iPhone]]></category>

		<guid isPermaLink="false">http://aditshukla.com/tt/2010/03/15/fakeconv/</guid>
		<description><![CDATA[Instant Multiple Personalities Fake Conversation (http://www.fakeconversation.com/) is a fun app we created in partnership with Dr. Strange App that allows users to receive fake phone conversations that give them prepared scripts so they can pretend to be any number of humorous characters. The 2.0 update to Fake Conversation that features a marketplace of new conversations [...]]]></description>
			<content:encoded><![CDATA[<h4>Instant Multiple Personalities</h4>
<p>Fake Conversation (<a href="http://www.fakeconversation.com/">http://www.fakeconversation.com/</a>)  is a fun app we created in partnership with Dr. Strange App that allows  users to receive fake phone conversations that give them prepared  scripts so they can pretend to be any number of humorous characters.</p>
<p>The  2.0 update to Fake Conversation that features a marketplace of new  conversations that can be purchased using in app purchases.Fake  Conversation shows how a fun idea can be turned into a solid revenue  stream with good mobile strategy centered around monetization</p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2010/03/15/fakeconv/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cash Register</title>
		<link>http://twotoasters.com/index.php/2010/02/06/cashregister/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=cashregister</link>
		<comments>http://twotoasters.com/index.php/2010/02/06/cashregister/#comments</comments>
		<pubDate>Sat, 06 Feb 2010 20:05:11 +0000</pubDate>
		<dc:creator>adit</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[Cash Register]]></category>
		<category><![CDATA[Inventory]]></category>
		<category><![CDATA[iPhone]]></category>

		<guid isPermaLink="false">http://aditshukla.com/tt/2010/02/06/cashregister/</guid>
		<description><![CDATA[Manage inventory beautifully Regenus, LLC. partnered with Two Toasters to develop one of the highly ranked ideas on MyAppIdea: Cash Register. Cash Register is a simple tool that replaces the need for a physical cash register or point of sale system for events like a garage sale. Cash Register will also optionally perform basic inventory [...]]]></description>
			<content:encoded><![CDATA[<h4>Manage inventory beautifully</h4>
<p>Regenus, LLC. partnered with Two Toasters to develop one of the highly ranked ideas on MyAppIdea: Cash Register. Cash Register is a simple tool that replaces the need for a physical cash register or point of sale system for events like a garage sale. Cash Register will also optionally perform basic inventory management.</p>
<p>Cash Register features a lightweight custom interface that showcases Two Toasters design abilities. Additionally Cash Register is another case where Two Toasters took an idea, refined it, and implemented a commercially successful mobile application.</p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2010/02/06/cashregister/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GateGuru</title>
		<link>http://twotoasters.com/index.php/2010/02/02/gate-guru/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=gate-guru</link>
		<comments>http://twotoasters.com/index.php/2010/02/02/gate-guru/#comments</comments>
		<pubDate>Tue, 02 Feb 2010 03:24:42 +0000</pubDate>
		<dc:creator>adit</dc:creator>
				<category><![CDATA[Projects]]></category>
		<category><![CDATA[Airport]]></category>
		<category><![CDATA[Amenities]]></category>
		<category><![CDATA[Community]]></category>

		<guid isPermaLink="false">http://aditshukla.com/tt/?p=45</guid>
		<description><![CDATA[Empowering the Traveler The airport is a stressful environment as it is with long security lines and the constant wave of travelers. Now imagine, trying to find a place to eat or buy a last minute gift for a loved one in this maze. Mobility Apps, a leading innovator in the space saw an opportunity [...]]]></description>
			<content:encoded><![CDATA[<h4>Empowering the Traveler</h4>
<p>The airport is a stressful environment as it is with long security  lines and the constant wave of travelers. Now imagine, trying to find a  place to eat or buy a last minute gift for a loved one in this maze.  Mobility Apps, a leading innovator in the space saw an opportunity to  improve the airport experience by creating a mobile guide for airport  amenities. We were thrilled to partner with them to take their idea to  market, implementing an iPhone application and web backend, to manage  the entire ecosystem.</p>
<p>From the get go, the traveler&#8217;s  experience was central in shaping the design of the application and  ensuring that they were able to access information easily. We achieved  this by offering a simple interface where the traveler could select the  airport, terminal and filter categories to find relevant amenities. The  second focus was creating an engaging app to foster an active community  of travelers that would fill in details like photos, reviews, flag  out-of-date and new amenities to create a self propelling ecosystem. We  worked together with Mobility Apps to take the social travel experience  further with facebook and twitter integration including contextual posts  to share travel with friends and a social leader board to reward  content creation.</p>
<p>We are excited to be a part of the  GateGuru story and helping travelers change the way they view the  airport experience.</p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2010/02/02/gate-guru/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>HQ Resizable iPhone PSD</title>
		<link>http://twotoasters.com/index.php/2009/06/02/resizable-iphone-psd/?utm_source=rss&amp;utm_medium=rss&amp;utm_campaign=resizable-iphone-psd</link>
		<comments>http://twotoasters.com/index.php/2009/06/02/resizable-iphone-psd/#comments</comments>
		<pubDate>Tue, 02 Jun 2009 14:54:15 +0000</pubDate>
		<dc:creator>adit</dc:creator>
				<category><![CDATA[Design]]></category>
		<category><![CDATA[Resources]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[Vector]]></category>

		<guid isPermaLink="false">http://twotoasters.com/?p=359</guid>
		<description><![CDATA[Often times while designing iPhone related pieces, I've found myself needing a high resolution image of the iPhone. Unfortunately a quick Google search reveals that there aren't any high quality images of the iPhone floating around on the internet.

As a result, I decided to recreate the iPhone in a completely resizable format for Photoshop. Admittedly it would've been smarter to do this in Illustrator, but since most of the time these designs are mocked up in Photoshop it works out well.]]></description>
			<content:encoded><![CDATA[<p>Often times while designing iPhone related pieces, I&#8217;ve found myself needing a high resolution image of the iPhone. Unfortunately a quick Google search reveals that there aren&#8217;t any high quality images of the iPhone floating around on the internet.</p>
<p>As a result, I decided to recreate the iPhone in a completely resizable format for Photoshop. Admittedly it would&#8217;ve been smarter to do this in Illustrator, but since most of the time these designs are mocked up in Photoshop it works out well.</p>
<p>Ultimately, the outcome of this little experiment is a combination of quite a few shapes and layer styling that looks extremely realistic.</p>
<h4>Some Notes on the File:</h4>
<ul>
<li>The zip archive contains a psd format of the iPhone.</li>
<li>The psd can be<strong> infinitely resized without a loss in quality</strong> as long as you check the &#8220;scale styles&#8221; property under image resize.</li>
<li>All of the layers are completely editable&#8211;however it is not recommended that you touch any of the shapes within the speaker group or the bezel group.</li>
<li>The files are published under creative commons and can be used both commercially and personally as long as this post is attributed in some way.</li>
</ul>
<h3>Download</h3>
<p><a href="http://twotoasters.com/wp-content/uploads/2009/06/iphone.png" target="_blank">541x1000px PNG (44kb)</a></p>
<p><strong><a href="http://twotoasters.com/wp-content/uploads/2009/06/iphone.zip">Zip Archive with PSD (142kb)</a></strong></p>
]]></content:encoded>
			<wfw:commentRss>http://twotoasters.com/index.php/2009/06/02/resizable-iphone-psd/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
