FileDocCategorySizeDatePackage
DynamicProxyTestCase.javaAPI DocApache Axis 1.456121Sat Apr 22 18:57:28 BST 2006test.wsdl.types

DynamicProxyTestCase

public class DynamicProxyTestCase extends TestCase
TypeTestServiceTestCase.java This file was auto-generated from WSDL by the Apache Axis Wsdl2java emitter.

Fields Summary
Constructors Summary
public DynamicProxyTestCase(String name)

        super(name);
    
Methods Summary
private voidallPrimitivesIn(test.wsdl.types.comprehensive_service.TypeTest binding)

        assertTrue("binding is null", binding != null);
        try {

            binding.allPrimitivesIn(
                    new String(),
                    new BigInteger("0"),
                    0,
                    0,
                    (short)0,
                    new BigDecimal(0),
                    0,
                    0,
                    true,
                    (byte)0,
                    new QName("http://double-double", "toil-and-trouble"),
                    Calendar.getInstance(),
                    new byte[0],
                    new byte[0],
                    new String(),
                    new Boolean(false),
                    new Float(0),
                    new Double(0),
                    new BigDecimal(0),
                    new Integer(0),
                    new Short((short)0),
                    new byte[0],
                    new Time("12:01:30.150Z"),
                    new UnsignedLong(0),
                    new UnsignedInt(0),
                    new UnsignedShort(0),
                    new UnsignedByte(0),
                    new NonNegativeInteger("0"),
                    new PositiveInteger("1"),
                    new NonPositiveInteger("0"),
                    new NegativeInteger("-1"),
                    new URI("urn:this-is-a-test"),
                    new Year(1995),
                    new Month(7),
                    new Day(13),
                    new YearMonth(2002, 8),
                    new MonthDay(8, 26)
                    );
        }
        catch (RemoteException re) {
            re.printStackTrace();
            throw new AssertionFailedError("Remote Exception caught: " + re);
        }
        catch (Exception e) {
            // possibly thrown from Unsigned constructors
            // wont happen since we know the value are good!
        }
        
    
private voidallPrimitivesInout(test.wsdl.types.comprehensive_service.TypeTest binding)

        assertTrue("binding is null", binding != null);
        try {

            binding.allPrimitivesInout(
                    new StringHolder(new String()),
                    new BigIntegerHolder(new BigInteger("0")),
                    new IntHolder(0),
                    new LongHolder(0),
                    new ShortHolder((short)0),
                    new BigDecimalHolder(new BigDecimal(0)),
                    new FloatHolder(0),
                    new DoubleHolder(0),
                    new BooleanHolder(true),
                    new ByteHolder((byte)0),
                    new QNameHolder(new QName("http://double-double",
                            "toil-and-trouble")),
                    new CalendarHolder(Calendar.getInstance()),
                    new ByteArrayHolder(new byte[0]),
                    new ByteArrayHolder(new byte[0]),
                    new StringHolder(new String()),
                    new BooleanWrapperHolder(new Boolean(false)),
                    new FloatWrapperHolder(new Float(0)),
                    new DoubleWrapperHolder(new Double(0)),
                    new BigDecimalHolder(new BigDecimal(0)),
                    new IntegerWrapperHolder(new Integer(0)),
                    new ShortWrapperHolder(new Short((short)0)),
                    new ByteArrayHolder(new byte[0]),
                    new TimeHolder(new Time("12:01:30.150Z")),
                    new UnsignedLongHolder(new UnsignedLong(0)),
                    new UnsignedIntHolder(new UnsignedInt(0)),
                    new UnsignedShortHolder(new UnsignedShort(0)),
                    new UnsignedByteHolder(new UnsignedByte(0)),
                    new NonNegativeIntegerHolder(new NonNegativeInteger("0")),
                    new PositiveIntegerHolder(new PositiveInteger("1")),
                    new NonPositiveIntegerHolder(new NonPositiveInteger("0")),
                    new NegativeIntegerHolder(new NegativeInteger("-1")),
                    new URIHolder(new URI("urn:this-is-a-test")),
                    new YearHolder(new Year(1995)),
                    new MonthHolder(new Month(7)),
                    new DayHolder(new Day(13)),
                    new YearMonthHolder(new YearMonth(2002, 8)),
                    new MonthDayHolder(new MonthDay(8, 26))
                    
            );
        }
        catch (RemoteException re) {
            re.printStackTrace();
            throw new AssertionFailedError("Remote Exception caught: " + re);
        }
        catch (Exception e) {
            // possibly thrown from Unsigned constructors
            // wont happen since we know the value are good!
        }
    
private voidallPrimitivesOut(test.wsdl.types.comprehensive_service.TypeTest binding)

        assertTrue("binding is null", binding != null);
        try {
            binding.allPrimitivesOut(
                    new StringHolder(), 
                    new BigIntegerHolder(), 
                    new IntHolder(), 
                    new LongHolder(), 
                    new ShortHolder(), 
                    new BigDecimalHolder(), 
                    new FloatHolder(), 
                    new DoubleHolder(), 
                    new BooleanHolder(), 
                    new ByteHolder(), 
                    new QNameHolder(), 
                    new CalendarHolder(), 
                    new ByteArrayHolder(), 
                    new ByteArrayHolder(), 
                    new StringHolder(), 
                    new BooleanWrapperHolder(), 
                    new FloatWrapperHolder(), 
                    new DoubleWrapperHolder(), 
                    new BigDecimalHolder(), 
                    new IntegerWrapperHolder(), 
                    new ShortWrapperHolder(), 
                    new ByteArrayHolder(),
                    new TimeHolder(),
                    new UnsignedLongHolder(),
                    new UnsignedIntHolder(),
                    new UnsignedShortHolder(),
                    new UnsignedByteHolder(),
                    new NonNegativeIntegerHolder(),
                    new PositiveIntegerHolder(),
                    new NonPositiveIntegerHolder(),
                    new NegativeIntegerHolder(),
                    new URIHolder(),
                    new YearHolder(),
                    new MonthHolder(),
                    new DayHolder(),
                    new YearMonthHolder(),
                    new MonthDayHolder()
                    
            );
        }
        catch (RemoteException re) {
            throw new AssertionFailedError("Remote Exception caught: " + re);
        }
    
private test.wsdl.types.comprehensive_service.TypeTestgetProxy()

        try {
            Service service = ServiceFactory.newInstance().createService(null);
            Stub binding = (Stub) service.getPort(TypeTest.class);
            binding._setProperty(Stub.ENDPOINT_ADDRESS_PROPERTY,
                    "http://localhost:8080/axis/services/TypeTest");
            throw new AssertionFailedError("Should not get a binding");
        }
        catch (ServiceException jre) {
            return null;
        }
    
private test.wsdl.types.comprehensive_service.TypeTestgetProxyWithWSDL()

        try {
            Service service = ServiceFactory.newInstance().createService(
                new URL("file", "", "test/wsdl/types/ComprehensiveTypes.wsdl"),
                new QName("urn:comprehensive-service.types.wsdl.test",
                        "TypeTestService"));
            return (TypeTest) service.getPort(
                new QName("", "TypeTest"), TypeTest.class);
        }
        catch (MalformedURLException mue) {
            throw new AssertionFailedError(
                    "MalformedURLException caught: " + mue);
        }
        catch (ServiceException jre) {
            throw new AssertionFailedError("ServiceException caught: " + jre);
        }
    
public voidtest1TypeTestAllPrimitivesIn()

        TypeTest binding = getProxyWithWSDL();
        allPrimitivesIn(binding);
        binding = getProxy();
        assertTrue(binding == null);
    
public voidtest2TypeTestAllPrimitivesInout()

/*
        TypeTest binding = getProxyWithWSDL();
        allPrimitivesInout(binding);
        binding = getProxy();
        allPrimitivesInout(binding);
*/
    
public voidtest3TypeTestAllPrimitivesOut()

/*
        TypeTest binding = getProxyWithWSDL();
        allPrimitivesOut(binding);
        binding = getProxy();
        allPrimitivesOut(binding);
*/