TestsTested | ✓ |
LangLanguage | Obj-CObjective C |
License | Apache 2 |
ReleasedLast Release | Sep 2016 |
Maintained by Matt Magoffin, wmjesstaylor.
This project provides core modules to help kick start iOS applications. It works in tandem with the BlueRocketFuelAppp starter project. Each module is available as a Cocoapod subspec and can be imported into projects like
pod 'BlueRocketFuelCore/Core'
By default all modules will be imported if your Podfile
contains just
pod 'BlueRocketFuelCore'
The Core module provides basic support for the following areas:
The UI module provides UI components and support for the following areas:
Core
module localization frameworkThe WebApiClient-RestKit module provides provides mapping support for the core domain objects. The BRRestKitDataMapping class is a good starting point for applications to extend: it registers object mappers for the BRAppUser domain object for the standardized login
and register
route names.
The WebApiClient-Services module provides a WebApiClient implementation of the BRUserService
API, to handle login and registration tasks.
The WebRequest module provides a HTTP client framework based on NSURLConnection
that can be configured via the Core
module configuration framework along with some simple conventions.
Web service configuration and support is managed via three areas:
This JSON file is where you define all the endpoints that your web service provides. You will need to specify the path and method (GET, POST, PUT, etc.) for each end point here.
The URL, port and protocol of your web service are configured via BREnvironment.
For each endpoint in your web service you will want to implement a class. Name the class using a naming convention of {EndPoint}WebServiceRequest
, where {EndPoint}
is the name of the endpoint you defined in the config.json file with the first letter capitalized.
Your custom web service endpoint class should then subclass one of the following built-in BRFC classes, depending on which one best fits the endpoint:
For public, non-restricted endpoints that do not require an authenticated user token to access.
For endpoints that require an authenticated user token (passed in the "USER-AUTHORIZATION" HTTP header) to access.
For endpoints that not only require an authenticated user token to access, but also require the user's record ID appended to the path of the end point. Subclasses of this would typically be for endpoints that provide user-specific details, such as a user profile endpoint.