From e8b3e27043f386fae4d649b4687b28f19b48c4fb Mon Sep 17 00:00:00 2001 From: Mattt Thompson Date: Tue, 9 Oct 2012 09:26:50 -0700 Subject: [PATCH] Replacing existing property ownership values of retain with strong --- AFNetworking/AFHTTPClient.m | 26 +++++++------------ AFNetworking/AFImageRequestOperation.h | 4 +-- AFNetworking/AFImageRequestOperation.m | 4 +-- .../AFNetworkActivityIndicatorManager.m | 2 +- AFNetworking/AFXMLRequestOperation.h | 4 +-- AFNetworking/AFXMLRequestOperation.m | 6 ++--- AFNetworking/UIImageView+AFNetworking.m | 2 +- 7 files changed, 20 insertions(+), 28 deletions(-) diff --git a/AFNetworking/AFHTTPClient.m b/AFNetworking/AFHTTPClient.m index 6401a56..9caeaf4 100755 --- a/AFNetworking/AFHTTPClient.m +++ b/AFNetworking/AFHTTPClient.m @@ -90,13 +90,12 @@ static NSString * AFPercentEscapedQueryStringPairMemberFromStringWithEncoding(NS #pragma mark - @interface AFQueryStringPair : NSObject -@property (readwrite, nonatomic, retain) id field; -@property (readwrite, nonatomic, retain) id value; +@property (readwrite, nonatomic, strong) id field; +@property (readwrite, nonatomic, strong) id value; - (id)initWithField:(id)field value:(id)value; - (NSString *)URLEncodedStringValueWithEncoding:(NSStringEncoding)stringEncoding; - @end @implementation AFQueryStringPair @@ -185,12 +184,10 @@ static NSString * AFPropertyListStringFromParameters(NSDictionary *parameters) { } @interface AFStreamingMultipartFormData : NSObject - - (id)initWithURLRequest:(NSMutableURLRequest *)request stringEncoding:(NSStringEncoding)encoding; - (NSMutableURLRequest *)requestByFinalizingMultipartFormData; - @end #pragma mark - @@ -733,10 +730,9 @@ NSUInteger const kAFUploadStream3GSuggestedPacketSize = 1024 * 16; NSTimeInterval const kAFUploadStream3GSuggestedDelay = 0.2; @interface AFHTTPBodyPart : NSObject - @property (nonatomic, assign) NSStringEncoding stringEncoding; -@property (nonatomic, retain) NSDictionary *headers; -@property (nonatomic, retain) NSInputStream *inputStream; +@property (nonatomic, strong) NSDictionary *headers; +@property (nonatomic, strong) NSInputStream *inputStream; @property (nonatomic, assign) unsigned long long bodyContentLength; @property (nonatomic, assign) BOOL hasInitialBoundary; @@ -746,11 +742,9 @@ NSTimeInterval const kAFUploadStream3GSuggestedDelay = 0.2; @property (readonly) unsigned long long contentLength; - (NSInteger)read:(uint8_t *)buffer maxLength:(NSUInteger)length; - @end @interface AFMultipartBodyStream : NSInputStream - @property (nonatomic, assign) NSUInteger numberOfBytesInPacket; @property (nonatomic, assign) NSTimeInterval delay; @property (readonly) unsigned long long contentLength; @@ -759,14 +753,13 @@ NSTimeInterval const kAFUploadStream3GSuggestedDelay = 0.2; - (id)initWithStringEncoding:(NSStringEncoding)encoding; - (void)setInitialAndFinalBoundaries; - (void)appendHTTPBodyPart:(AFHTTPBodyPart *)bodyPart; - @end #pragma mark - @interface AFStreamingMultipartFormData () @property (readwrite, nonatomic, copy) NSMutableURLRequest *request; -@property (readwrite, nonatomic, retain) AFMultipartBodyStream *bodyStream; +@property (readwrite, nonatomic, strong) AFMultipartBodyStream *bodyStream; @property (readwrite, nonatomic, assign) NSStringEncoding stringEncoding; @end @@ -897,12 +890,12 @@ NSTimeInterval const kAFUploadStream3GSuggestedDelay = 0.2; @interface AFMultipartBodyStream () @property (nonatomic, assign) NSStreamStatus streamStatus; -@property (nonatomic, retain) NSError *streamError; +@property (nonatomic, strong) NSError *streamError; @property (nonatomic, assign) NSStringEncoding stringEncoding; -@property (nonatomic, retain) NSMutableArray *HTTPBodyParts; -@property (nonatomic, retain) NSEnumerator *HTTPBodyPartEnumerator; -@property (nonatomic, retain) AFHTTPBodyPart *currentHTTPBodyPart; +@property (nonatomic, strong) NSMutableArray *HTTPBodyParts; +@property (nonatomic, strong) NSEnumerator *HTTPBodyPartEnumerator; +@property (nonatomic, strong) AFHTTPBodyPart *currentHTTPBodyPart; @end @implementation AFMultipartBodyStream @@ -1056,7 +1049,6 @@ typedef enum { } - (BOOL)transitionToNextPhase; - @end @implementation AFHTTPBodyPart diff --git a/AFNetworking/AFImageRequestOperation.h b/AFNetworking/AFImageRequestOperation.h index 6c29fe6..d028a84 100644 --- a/AFNetworking/AFImageRequestOperation.h +++ b/AFNetworking/AFImageRequestOperation.h @@ -55,9 +55,9 @@ An image constructed from the response data. If an error occurs during the request, `nil` will be returned, and the `error` property will be set to the error. */ #if __IPHONE_OS_VERSION_MIN_REQUIRED -@property (readonly, nonatomic) UIImage *responseImage; +@property (readonly, nonatomic, strong) UIImage *responseImage; #elif __MAC_OS_X_VERSION_MIN_REQUIRED -@property (readonly, nonatomic, retain) NSImage *responseImage; +@property (readonly, nonatomic, strong) NSImage *responseImage; #endif #if __IPHONE_OS_VERSION_MIN_REQUIRED diff --git a/AFNetworking/AFImageRequestOperation.m b/AFNetworking/AFImageRequestOperation.m index cac1307..f4f724a 100644 --- a/AFNetworking/AFImageRequestOperation.m +++ b/AFNetworking/AFImageRequestOperation.m @@ -33,9 +33,9 @@ static dispatch_queue_t image_request_operation_processing_queue() { @interface AFImageRequestOperation () #if __IPHONE_OS_VERSION_MIN_REQUIRED -@property (readwrite, nonatomic) UIImage *responseImage; +@property (readwrite, nonatomic, strong) UIImage *responseImage; #elif __MAC_OS_X_VERSION_MIN_REQUIRED -@property (readwrite, nonatomic, retain) NSImage *responseImage; +@property (readwrite, nonatomic, strong) NSImage *responseImage; #endif @end diff --git a/AFNetworking/AFNetworkActivityIndicatorManager.m b/AFNetworking/AFNetworkActivityIndicatorManager.m index 32553fc..a67cfec 100644 --- a/AFNetworking/AFNetworkActivityIndicatorManager.m +++ b/AFNetworking/AFNetworkActivityIndicatorManager.m @@ -29,7 +29,7 @@ static NSTimeInterval const kAFNetworkActivityIndicatorInvisibilityDelay = 0.17; @interface AFNetworkActivityIndicatorManager () @property (readwrite, assign) NSInteger activityCount; -@property (readwrite, nonatomic, retain) NSTimer *activityIndicatorVisibilityTimer; +@property (readwrite, nonatomic, strong) NSTimer *activityIndicatorVisibilityTimer; @property (readonly, getter = isNetworkActivityIndicatorVisible) BOOL networkActivityIndicatorVisible; - (void)updateNetworkActivityIndicatorVisibility; diff --git a/AFNetworking/AFXMLRequestOperation.h b/AFNetworking/AFXMLRequestOperation.h index 197e1c2..f8d5e04 100644 --- a/AFNetworking/AFXMLRequestOperation.h +++ b/AFNetworking/AFXMLRequestOperation.h @@ -48,13 +48,13 @@ /** An `NSXMLParser` object constructed from the response data. */ -@property (readonly, nonatomic) NSXMLParser *responseXMLParser; +@property (readonly, nonatomic, strong) NSXMLParser *responseXMLParser; #ifdef __MAC_OS_X_VERSION_MIN_REQUIRED /** An `NSXMLDocument` object constructed from the response data. If an error occurs while parsing, `nil` will be returned, and the `error` property will be set to the error. */ -@property (readonly, nonatomic, retain) NSXMLDocument *responseXMLDocument; +@property (readonly, nonatomic, strong) NSXMLDocument *responseXMLDocument; #endif /** diff --git a/AFNetworking/AFXMLRequestOperation.m b/AFNetworking/AFXMLRequestOperation.m index 2efaba6..d8de09a 100644 --- a/AFNetworking/AFXMLRequestOperation.m +++ b/AFNetworking/AFXMLRequestOperation.m @@ -34,11 +34,11 @@ static dispatch_queue_t xml_request_operation_processing_queue() { } @interface AFXMLRequestOperation () -@property (readwrite, nonatomic) NSXMLParser *responseXMLParser; +@property (readwrite, nonatomic, strong) NSXMLParser *responseXMLParser; #ifdef __MAC_OS_X_VERSION_MIN_REQUIRED -@property (readwrite, nonatomic, retain) NSXMLDocument *responseXMLDocument; +@property (readwrite, nonatomic, strong) NSXMLDocument *responseXMLDocument; #endif -@property (readwrite, nonatomic) NSError *XMLError; +@property (readwrite, nonatomic, strong) NSError *XMLError; @end @implementation AFXMLRequestOperation diff --git a/AFNetworking/UIImageView+AFNetworking.m b/AFNetworking/UIImageView+AFNetworking.m index 8933290..30f60a9 100644 --- a/AFNetworking/UIImageView+AFNetworking.m +++ b/AFNetworking/UIImageView+AFNetworking.m @@ -37,7 +37,7 @@ static char kAFImageRequestOperationObjectKey; @interface UIImageView (_AFNetworking) -@property (readwrite, nonatomic, retain, setter = af_setImageRequestOperation:) AFImageRequestOperation *af_imageRequestOperation; +@property (readwrite, nonatomic, strong, setter = af_setImageRequestOperation:) AFImageRequestOperation *af_imageRequestOperation; @end @implementation UIImageView (_AFNetworking)