Find time zones where it’s currently a certain time
May 5, 2016, 6:18 AM
For a project I’m working I needed a function that returns the time zones where it’s currently 9am. I generalized the function to be able to find time zones where it’s currently any time. My Swift implementation was inspired by this...
Gesture Recognizers in Swift
Jul 8, 2015, 8:52 PM
I wrote about using Gesture Recognizers in Swift for thatthinginswift.com.
Ruby’s tap method in Swift
Mar 18, 2015, 9:38 AM
Ruby has a nice method called tap, which I wanted to try and port to Swift. To learn what it does, let’s take a look at Ruby’s documentation:
The Builder Pattern in Swift
Feb 2, 2015, 3:51 PM
A while ago I wrote a post about implementing the builder pattern in Objective-C. Today we’re going to do the same for Swift.
Configure your iOS app for multiple environments
Nov 20, 2014, 2:50 PM
Two weeks ago I wrote a post about cleaning up your application delegate with initializers. I eluded to a Configuration object in that post. I decided to make this two separate posts because they’re different concepts that happen to work...
Clean up the application delegate with initializers
Oct 30, 2014, 1:48 PM
The application delegate has a tendency to become unwieldy. It provides a ton of callbacks to respond to about every possible state change of your app. The method that grows quickest is usually...
Adopting a new programming language
Jul 2, 2014, 3:33 PM
Over the course of my short career I’ve had the opportunity to build production-quality software in many new languages. I like learning new languages. I think it makes me a better developer. My skill level is probably average in most of...
Hour formatting with NSDateFormatter dateFormatFromTemplate
May 27, 2014, 3:00 PM
TLDR; Using NSDateFormatter’s dateFormatFromTemplate:options:locale: for 12/24 hours? Use “j” instead of “h” or “H” for the hour format.
Builder and GCC Code Block Evaluation
May 19, 2014, 2:04 PM
My post about the builder pattern got great responses and a lot of people offered alternative solutions to the same problem. The most popular suggestion was to use GCC Code Block Evaluation without the separate builder object. Using the...
TDD - Classicists vs Mockists
Apr 9, 2014, 1:26 PM
A while ago I reread Martin Fowler’s classic mocks aren’t stubs essay. He does a great job of explaining the different schools of TDD. In summary it basically comes down to classicists, those that build the system from business models up...