Placing opening braces on a new line for methods to match Apple convention. Refs #614

Used uncrustify's "nl_fdef_brace = add" option to detect issues.
This commit is contained in:
Jawwad Ahmad
2012-06-04 00:36:19 -04:00
parent 46bf6e6295
commit eaa5484b01
139 changed files with 4172 additions and 2086 deletions

View File

@@ -30,7 +30,8 @@ extern NSString* const RKObjectMappingNestingAttributeKeyName;
/**
@private
*/
- (id)initWithSourceKeyPath:(NSString *)sourceKeyPath andDestinationKeyPath:(NSString *)destinationKeyPath {
- (id)initWithSourceKeyPath:(NSString *)sourceKeyPath andDestinationKeyPath:(NSString *)destinationKeyPath
{
NSAssert(sourceKeyPath != nil, @"Cannot define an element mapping an element name to map from");
NSAssert(destinationKeyPath != nil, @"Cannot define an element mapping without a property to apply the value to");
self = [super init];
@@ -42,28 +43,33 @@ extern NSString* const RKObjectMappingNestingAttributeKeyName;
return self;
}
- (id)copyWithZone:(NSZone *)zone {
- (id)copyWithZone:(NSZone *)zone
{
RKObjectAttributeMapping* copy = [[[self class] allocWithZone:zone] initWithSourceKeyPath:self.sourceKeyPath andDestinationKeyPath:self.destinationKeyPath];
return copy;
}
- (void)dealloc {
- (void)dealloc
{
[_sourceKeyPath release];
[_destinationKeyPath release];
[super dealloc];
}
- (NSString *)description {
- (NSString *)description
{
return [NSString stringWithFormat:@"RKObjectKeyPathMapping: %@ => %@", self.sourceKeyPath, self.destinationKeyPath];
}
+ (RKObjectAttributeMapping *)mappingFromKeyPath:(NSString *)sourceKeyPath toKeyPath:(NSString *)destinationKeyPath {
+ (RKObjectAttributeMapping *)mappingFromKeyPath:(NSString *)sourceKeyPath toKeyPath:(NSString *)destinationKeyPath
{
RKObjectAttributeMapping *mapping = [[self alloc] initWithSourceKeyPath:sourceKeyPath andDestinationKeyPath:destinationKeyPath];
return [mapping autorelease];
}
- (BOOL)isMappingForKeyOfNestedDictionary {
- (BOOL)isMappingForKeyOfNestedDictionary
{
return ([self.sourceKeyPath isEqualToString:RKObjectMappingNestingAttributeKeyName]);
}