ObjectiveCInlines 0.1.0

ObjectiveCInlines 0.1.0

TestsTested
LangLanguage Obj-CObjective C
License MIT
ReleasedLast Release Dec 2014

Maintained by Unclaimed.



  • By
  • Austin David Brown

Objective C Inlines

Fun, fast inline functions for Objective C.

Installation

  1. Manually add the 'ObjectiveCInlines' folder into your Xcode project.
  2. Install via CocoaPods
pod "ObjectiveCInlines", "~> 0.1.0"

Usage

NSArray

  #import <ObjectiveCInlines/NSArrayInlines.h>

  NSArrayEach(arr, ^(id obj) {
  });

  NSArrayMap(arr, ^id*(id obj) {
    return obj;
  });

  NSArrayReduce(arr, memo, ^id(id memo, id obj) {
    return memo;
  });

  NSArrayFind(numsArr, ^bool(id obj) {
    return true;
  });

NSDictionary

  #import <ObjectiveCInlines/NSDictionaryInlines.h>

  NSDictionaryEach(dict, ^(NSString *key, id obj) {
  });

  NSDictionaryMap(dict, ^id(NSString *key, id obj) {
    return obj;
  });

NSJSON

  #import <ObjectiveCInlines/NSJSONInlines.h>

  NSJSONObjectWithData(stringDictData, NSJSONReadingAllowFragments, nil);
  NSJSONDataWithObject(stringDict, NSJSONWritingPrettyPrinted, nil);

  NSJSONStringWithObject(dict, NSJSONWritingPrettyPrinted, nil);
  NSJSONObjectWithString(@"{}", NSJSONReadingAllowFragments, nil);

GCDAsync

  #import <ObjectiveCInlines/GCDInlines.h>

  GCDAsync(^{
    // background
  });

  GCDAsyncMain(^{
    // main thread
  });

Contributing

See CONTRIBUTING

License

See LICENSE

Team