Code Monkey home page Code Monkey logo

ios-twitter-network-layer's People

Contributors

juliaferraioli avatar nsprogrammer avatar vinayganesh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

ios-twitter-network-layer's Issues

Remove iOS 7 support

There is a great deal of cleanup that can naturally occur by dropping iOS 7 support from the project. There aren't even any projects utilizing iOS 7, so it is a no-brainer :)

Thanks!

You did a great job and thank you for sharing!
๐Ÿ‘

Improvements in code style.

Well, I am a bit confused about your code style.
Well, it sometimes old, sometimes mis-conceptual, sometimes doesn't fit objective-c style.

For example:

// TNLSafeOperation
// NULL and nil are equivalent here, doesn't matter, of course.
// but in objective-c self.completionHandler = nil; is more appropriate
//  [super setCompletionBlock:nil];
- (void)tnl_clearCompletionBlock
{
    [super setCompletionBlock:NULL];
}

Moreover, you don't use auto type inference that cause a lot of boring reading.
Do not tell me that you build your apps with "not brand new xcode and bleeding-edge sdk".
So, bring new features of clang and llvm to your "codebase at the end of universe".

        NSProcessInfo *processInfo = [NSProcessInfo processInfo];

will turn into

        __auto_type processInfo = [NSProcessInfo processInfo];

Again, look at TNLSafeOperation static function in .m file.

For what reason you put static function here? Is it a C API? I do not see any invocation anywhere but in this file.

Oh, similar mistake to a lot of frameworks.

NSString * const TNLBackgroundRequestOperationDidCompleteNotification = @"TNLBackgroundRequestOperationDidCompleteNotification";
NSString * const TNLBackgroundRequestURLRequestKey = @"URLRequest";
NSString * const TNLBackgroundRequestResponseKey = @"response";
NSString * const TNLBackgroundRequestURLSessionConfigurationIdentifierKey = @"identifier";
NSString * const TNLBackgroundRequestURLSessionTaskIdentifierKey = @"taskIdentifier";
NSString * const TNLBackgroundRequestURLSessionSharedContainerIdentifierKey = @"sharedContainerIdentifier";

I don't want to see these keys, well, never.
I want to see a group of them like, for example, TNLBackgroundRequest__Keys.

@interface TNLBackgroundRequest__Keys : NSObject
+ (NSString *)OperationDidCompleteNotification;
+ (NSString *)URLRequestKey;
+ (NSString *)ResponseKey;
+ (NSString *)URLSessionConfigurationIdentifierKey;
+ (NSString *)URLSessionTaskIdentifierKey;
+ (NSString *)URLSessionSharedContainerIdentifierKey;
@end

Yes, I add additional interface that mimic string enums ( not really ) in "modern" swift.

Not really sure why you use static everywhere.

static dispatch_queue_t _URLSessionTaskOperationPropertyQueue(void);
static dispatch_queue_t _URLSessionTaskOperationPropertyQueue()
{
    static dispatch_queue_t sQueue;
    static dispatch_once_t onceToken;
    dispatch_once(&onceToken, ^{
        sQueue = dispatch_queue_create("TNLRequestOperation.URLSessionTaskOperation.atomic.queue", DISPATCH_QUEUE_CONCURRENT);
    });
    return sQueue;
}

Perfect place for them is @interface with class methods.

Sometimes you use explicit obj == nil and obj != nil.
But when your demons come out, you prefer if (obj) and if (!obj).

No code style at all?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.