Package org.serviceconnector.api.cln

Examples of org.serviceconnector.api.cln.SCFileService


    FileOutputStream dstStream = null;
    SCClient client = null;
    try {
      // try to connect client
      client = connectClientToService(service);
      SCFileService scFileService = client.newFileService(service.getName());
      dstStream = new FileOutputStream(dstFile);
      scFileService.downloadFile(remoteFile, dstStream);
      writer.writeStartElement("message");
      writer.writeCharacters(dstFile.getName() + "  " + status);
      writer.writeEndElement();
    } catch (Exception e) {
      status = "failed";
View Full Code Here


    /** {@inheritDoc} */
    @Override
    public Integer call() {
      try {
        SCFileService scFileService = client.newFileService(this.serviceName);
        scFileService.uploadFile(360, this.remotePath, this.is);
        // reads buffer intern until the end of output stream
        client.detach();
        return 0;
      } catch (Exception e) {
        LOGGER.error(e.toString());
View Full Code Here

      sc.setMaxConnections(20);
      sc.setKeepAliveIntervalSeconds(30);
      sc.attach();

      LOGGER.info("FileUploader attached to: " + hostToConnect + ":" + portToConnect + " " + conType + " - " + serviceName);
      SCFileService service = sc.newFileService(serviceName);

      switch (function) {
      case LIST:
        list(service);
        break;
View Full Code Here

TOP

Related Classes of org.serviceconnector.api.cln.SCFileService

Copyright © 2018 www.massapicom. 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.