Skip to content

Instantly share code, notes, and snippets.

@jacksonh
Created January 15, 2015 18:45
Show Gist options
  • Save jacksonh/35b60775ee7e9bf4dac8 to your computer and use it in GitHub Desktop.
Save jacksonh/35b60775ee7e9bf4dac8 to your computer and use it in GitHub Desktop.
// Public
@interface Image()
@property (assign, nonatomic, readonly) CGSize size;
@end
// Private
@interface Image()
@property (assign, nonatomic, readwrite) CGSize size;
@property (assign, nonatomic, readonly) CGFloat width;
@property (assign, nonatomic, readonly) CGFloat height;
@end
@implementation Image ()
- (void)mantleDidFinishParsing
{
_size = CGSizeMake (self.width, self.height);
}
@end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment