class LightWalletGrpcService : LightWalletService
Implementation of LightwalletService using gRPC for requests to lightwalletd.
<init> |
Construct an instance that corresponds to the given host and port. LightWalletGrpcService(appContext: Context, host: String, port: Int = DEFAULT_LIGHTWALLETD_PORT, usePlaintext: Boolean = appContext.resources.getBoolean(R.bool.lightwalletd_allow_very_insecure_connections)) |
getBlockRange |
Return the given range of blocks. fun getBlockRange(heightRange: IntRange): List<<ERROR CLASS>> |
getLatestBlockHeight |
Return the latest block height known to the service. fun getLatestBlockHeight(): Int |
shutdown |
Cleanup any connections when the service is shutting down and not going to be used again. fun shutdown(): Unit |
submitTransaction |
Submit a raw transaction. fun submitTransaction(spendTransaction: ByteArray): <ERROR CLASS> |
createDefaultChannel |
Convenience function for creating the default channel to be used for all connections. It is important that this channel can handle transitioning from WiFi to Cellular connections and is properly setup to support TLS, when required. fun createDefaultChannel(appContext: Context, host: String, port: Int, usePlaintext: Boolean): ManagedChannel |