Web Services WebLogic 7.0 Sample Code

Simple console application demonstrating how to run a WebLogic 7.0 Web service.

Sample Code:

package com.attachmate.test;

//These classes were generated by WebLogic
import Test.TestService;
import Test.TestService_Impl;
import Test.TestServicePort;
import Test.TaskInput.ScreenInputs;
import Test.TaskOutput.ScreenOutputs;

 * A simple console application that demonstrates how to run a WebLogic 7.0 web
 * service with the client jar that is automatically generated when you deploy
 * the service.
public class WL70WSClient
     * Application entry point.
     * @param args Command line arguments.  Not used.
    public static void main (String[] args)
            //Get an instance of the service
            TestService service = new TestService_Impl("http://localhost:7001/Test/TestServiceuri?WSDL");
            TestServicePort servicePort = service.getTestServicePort();

            //Set the task inputs
            ScreenInputs inputs = new ScreenInputs();

            //Execute the task
            ScreenOutputs outputs = servicePort.task(inputs);

            //Display the output
        catch (Exception xx)
Related Topics
Bullet Using Tasks in Your Applications, Overview
Bullet Building Web Services Using BEA WebLogic 7.0