The library was created to provide convienent interface for iOS applications to communicate with Iroha blockchain including sending transactions/query, streaming transaction statuses and block commits.
For new iroha users we recommend to checkout iOS example project. It tries to establish connection with Iroha peer which should be also run locally on your computer to create new account and send some asset quantity to it. To run the project, please, go through steps below:
-
Follow instructions from Iroha documentation to setup and run iroha peer in Docker container.
-
Clone current repository.
-
cd Example directory and run
pod install
. -
Open IrohaCommunication.xcworkspace in XCode
-
Build and Run IrohaExample target.
-
Consider logs to see if the scenario completed successfully.
Feel free to experiment with example project and don't hesistate to ask any questions.
Integration tests is a good place to check existing scenarious or to introduce new ones. To run integration tests, please, go through steps below:
- Follow instructions from Iroha documentation to setup and run iroha peer in Docker container. However make sure you run iroha using following command (consider additional --overwrite_ledger flag):
docker run --name iroha -d -p 50051:50051 -v $(pwd)/iroha/example:/opt/iroha_data -v blockstore:/tmp/block_store --network=iroha-network -e KEY='node0 --overwrite_ledger' hyperledger/iroha:latest
- Launch proxy for docker daemon to make it available through http. For example, one can use socat utility:
brew install socat
socat TCP-LISTEN:49721,fork UNIX-CONNECT:/var/run/docker.sock
-
Clone current repository.
-
cd Example directory and run
pod install
. -
Open IrohaCommunication.xcworkspace in XCode
-
Run tests under IntegrationTests target.
- Join Hyperledger RocketChat #iroha channel
- Use mailing list [email protected]
Iroha iOS library is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'IrohaCommunication'
Ruslan Rezin, [email protected]
Andrei Marin, [email protected]
Copyright 2018 Soramitsu Co., Ltd.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http:https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.