Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
The library tries to be as similar as possible to the java/android version of the SymbIoTeSecurity The class SecurityHandler has the same methods with the same names of parameters
The library allows easy access to SymbIoTe API from iOS apps.
swift version >= 3.2
ios deployment target >= 10.0
SymbIoTeSecurity4iOS is available through CocoaPods. To install it, simply add the following line to Podfile in your workspace:
pod install command
Other option is to clone/download this repository.
Note: CocoaPod Manager will automatically install SymbioteIosUtils library.
How to use
Knowing SymbIoTe API anyone can build a software (in any programming language) to join the ecosystem.
However, it is not always easy to remember all the url paths, http headers format and security procedures.
To simplify iOS apps development this library was created.
The library takes care of building http headers, acquiring request tokens, parsing JSONs from API, etc. so your app can be coded cleanly. To demonstrate the usage - this repository contains an Example app, that show how to call library method.
Getting observations results - getting messured values from a device
Actuators - sending commands to devices
The structure and syntax of Swift is completely different than java syntax, nevertheless we put a lot of effort to keep the usage coherent over all platforms. Therefore all the public functions in
SecurityHandler have the same name (and names of the parameters are the same) and behavior is as similar as possible as in java/android version of the security library.
Therefore one can check SymbIoTeSecurity java library documentation for deeper understanding of security protocols used in the SymbIoTe project Also, please forgive us if you are a hardcore swift developer and hate java-like code structures and conventions - this is for the integrity sake :-)
The workspace is made of the pod library itself and
The library has typical folders structure for a CocoaPod lib (all classes in the
The Example project contains a simple app that is using the library and unit tests.
This is the main class to refer when accessing SymbIoTe API.
public functions overview
Another usage examples
The fully working application can be found SymbioteApp which is an app that combines L1 and L3/L4 resources