Example #1
0
  @Override
  public void run() {
    try {
      while (!isInterrupted()) {
        String m = i.readLine();
        if (m == null) break;
        clients.add(m);
        writer(m);
      }
    } catch (IOException ignored) {

    }

    client.send.interrupt();
    clients.remove(client);
  }
  public Client getClient() {

    ApiKey apiKey = ApiKeys.builder().setFileLocation(path).build();
    com.stormpath.sdk.client.Client client = Clients.builder().setApiKey(apiKey).build();
    System.out.println(client.getCurrentTenant().getName());

    return client;
  }