public class ServerIdentity extends Object
| Modifier and Type | Class and Description |
|---|---|
static interface |
ServerIdentity.StreamHandler
The default handler interface for handling streaming responses.
|
class |
ServerIdentity.StreamingConn |
class |
ServerIdentity.SyncSendMessage |
| Constructor and Description |
|---|
ServerIdentity(NetworkProto.ServerIdentity sid) |
ServerIdentity(com.moandjiezana.toml.Toml siToml) |
ServerIdentity(URI serverWsAddress,
String publicKey) |
| Modifier and Type | Method and Description |
|---|---|
URI |
getAddress() |
StatusProto.Response |
GetStatus() |
ServerIdentity.StreamingConn |
MakeStreamingConnection(String path,
byte[] data,
ServerIdentity.StreamHandler h)
Make a streaming connection.
|
byte[] |
SendMessage(String path,
byte[] data)
Synchronously send a message.
|
NetworkProto.ServerIdentity |
toProto() |
public Point Public
public ServerIdentity(com.moandjiezana.toml.Toml siToml)
throws URISyntaxException
URISyntaxExceptionpublic ServerIdentity(NetworkProto.ServerIdentity sid) throws URISyntaxException
URISyntaxExceptionpublic URI getAddress()
public StatusProto.Response GetStatus() throws CothorityCommunicationException
CothorityCommunicationExceptionpublic NetworkProto.ServerIdentity toProto()
public byte[] SendMessage(String path, byte[] data) throws CothorityCommunicationException
path - The API endpoint.data - The request message.CothorityCommunicationExceptionpublic ServerIdentity.StreamingConn MakeStreamingConnection(String path, byte[] data, ServerIdentity.StreamHandler h) throws CothorityCommunicationException
path - The API endpoint.data - The request message.h - The handler for handling every response.CothorityCommunicationExceptionCopyright © 2018. All rights reserved.