Examples of FudgeRestClient


Examples of com.opengamma.util.rest.FudgeRestClient

   * the heartbeat signal should be sent as a keep-alive.
   *
   * @return a runnable sender. Each invocation of {@link Runnable#run} will send a heartbeat signal
   */
  public Runnable createHeartbeatSender() {
    final FudgeRestClient client = FudgeRestClient.create();
    final URI uri = _targetProvider.getHeartbeat();
    return new Runnable() {
      @Override
      public void run() {
        client.accessFudge(uri).post();
      }
    };
  }
View Full Code Here

Examples of com.opengamma.util.rest.FudgeRestClient

  }

  //-------------------------------------------------------------------------
  @Override
  protected URI createObject() {
    FudgeRestClient restClient = FudgeRestClient.create();
    FudgeMsg msg = restClient.accessFudge(getUri()).get(FudgeMsg.class);
    if (UriEndPointDescriptionProvider.TYPE_VALUE.equals(msg.getString(UriEndPointDescriptionProvider.TYPE_KEY)) == false) {
      throw new IllegalArgumentException("End point is not a URI target - " + msg);
    }
    URI uri = URI.create(msg.getString(UriEndPointDescriptionProvider.URI_KEY));
    uri = getUri().resolve(uri);
View Full Code Here

Examples of com.opengamma.util.rest.FudgeRestClient

  //-------------------------------------------------------------------------
  @Override
  public FudgeMsg getEndPointDescription(final FudgeContext fudgeContext) {
    ArgumentChecker.notNull(getUri(), "URI");
    FudgeRestClient restClient = FudgeRestClient.create();
    return restClient.accessFudge(getUri()).get(FudgeMsg.class);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.