8 Replies Latest reply on Jan 2, 2014 3:33 PM by 1053383

    [AutoVue Web Service]Where is VueBeanWS_Service class..?


      I'm testing AutoVue Server 20.2.1 .


      AutoVue WS sample code is like below.


      There is no 'com.oracle.autovue.services.VueBeanWS_Service' class in AutoVueWS.jar.


      I can not compile sample code.


      Anybody know about this...?



      import com.oracle.autovue.services.AuthorizationProxy;
      import com.oracle.autovue.services.PrintPageType;
      import com.oracle.autovue.services.VueBeanWS;
      import com.oracle.autovue.services.VueBeanWS_Service;
      import com.oracle.autovue.services.WsPrintOptions;
      import com.oracle.autovue.services.WsPrintHeaders;
      import com.oracle.autovue.services.WsPrintWatermark;

      public class SampleClient {
          public static void main(String[] args) throws Exception {

            VueBeanWS_Service vueBeanWS_Service = new VueBeanWS_Service();
            VueBeanWS proxy = vueBeanWS_Service.getVueBeanWSPort();
            // Permission check for the local files should be added here if upload protocol is enabled
            // to ensure that the client has permission to read the file before print it out
         // AuthorizationProxy is needed if the resourse has resricted access (e.g. document is being retrieved by VueLink)
         AuthorizationProxy authProx = new AuthorizationProxy();

            // One example is access using username and password

            WsPrintOptions options = new WsPrintOptions();
         // The list of available printers can be obtained from getPrinterNameList() web method.
               options.setPrinter("Some Printer Name");
         // refer to WsPrintOptions for all valid Page Types
            // if document is a 3d file, it is recommended to use "options.setSendPageAsImage(true)"

            WsPrintWatermark watermark = new WsPrintWatermark();
            // refer to WsPrintWatermark for all available attributes.

            WsPrintHeaders headers = new WsPrintHeaders();
            //refer to WsPrintHeaders for all available attibutes.

            // specify URI
            String URI = args[0];

            System.out.println(URI + " will be printed!");
            boolean busy = true;
            int attempt = 0;
            while (busy) {
              String msg = proxy.print(URI, options, headers, watermark, authProx, false, null);
              busy = false;
              System.out.println("file: "  + msg);
             } catch (Exception ex){
              System.out.println("Exception : " + ex.getMessage());

              if (ex.getMessage().contains("ERROR_00")){ //retry after 1 minute
               System.out.println(" Retrying.  -Attempt # "+ (++attempt));
              } else {
               busy = false;
               System.out.println("Other exceptions: " + ex.getMessage());
            } // end of while(busy)

           }catch(Exception topEx){
            System.out.println("Outer Exception : " + topEx.getMessage());