コード例 #1
0
 public OMElement sendSimpleStockQuoteRequestREST(String trpUrl, String addUrl, String symbol)
     throws AxisFault {
   ServiceClient sc = getRESTEnabledServiceClient(trpUrl, addUrl);
   try {
     return buildResponse(sc.sendReceive(createStandardRequest(symbol)));
   } finally {
     sc.cleanupTransport();
   }
 }
コード例 #2
0
  public OMElement sendMultipleQuoteRequestREST(String trpUrl, String addUrl, String symbol, int n)
      throws AxisFault {

    ServiceClient serviceClient = getRESTEnabledServiceClient(trpUrl, addUrl);
    try {
      return buildResponse(serviceClient.sendReceive(createMultipleQuoteRequest(symbol, n)));
    } finally {
      serviceClient.cleanupTransport();
    }
  }
コード例 #3
0
  public OMElement send(String trpUrl, String addUrl, String action, OMElement payload)
      throws AxisFault {

    ServiceClient serviceClient = getServiceClient(trpUrl, addUrl, action);
    try {
      return buildResponse(serviceClient.sendReceive(payload));
    } finally {
      serviceClient.cleanupTransport();
    }
  }
コード例 #4
0
  public OMElement sendCustomQuoteRequest(String trpUrl, String addUrl, String symbol)
      throws AxisFault {

    ServiceClient serviceClient = getServiceClient(trpUrl, addUrl);
    try {
      return buildResponse(serviceClient.sendReceive(createCustomQuoteRequest(symbol)));
    } finally {
      serviceClient.cleanupTransport();
    }
  }
コード例 #5
0
  public OMElement sendSimpleStockQuoteRequestREST(String trpUrl, String addUrl, OMElement payload)
      throws AxisFault {

    ServiceClient serviceClient = getRESTEnabledServiceClient(trpUrl, addUrl);
    try {
      return buildResponse(serviceClient.sendReceive(payload));
    } finally {
      serviceClient.cleanupTransport();
    }
  }
コード例 #6
0
  public OMElement sendSimpleStockQuoteSoap12(String trpUrl, String addUrl, String symbol)
      throws AxisFault {

    ServiceClient serviceClient = getServiceClient(trpUrl, addUrl);
    serviceClient
        .getOptions()
        .setSoapVersionURI(org.apache.axiom.soap.SOAP12Constants.SOAP_ENVELOPE_NAMESPACE_URI);
    try {
      return buildResponse(serviceClient.sendReceive(createStandardRequest(symbol)));
    } finally {
      serviceClient.cleanupTransport();
    }
  }