FileDocCategorySizeDatePackage
TestCircularRefs.javaAPI DocApache Axis 1.41312Sat Apr 22 18:57:28 BST 2006test.encoding

TestCircularRefs

public class TestCircularRefs extends test.GenericLocalTest

Fields Summary
Constructors Summary
public TestCircularRefs()

        super("foo");
    
public TestCircularRefs(String s)

        super(s);
    
Methods Summary
public java.util.VectorgetCircle()
Service method. Return a Vector containing an object graph with a loop.

return
a Vector with circular references

        Vector vector1 = new Vector();
        vector1.addElement("AString");
        Vector vector2 = new Vector();
        vector2.addElement(vector1);
        vector1.addElement(vector2);
        return vector2;
    
public voidtestCircularVectors()

        try {
            Call call = getCall();
            Object result = call.invoke("getCircle", null);
        } catch (AxisFault af){
            return;
        }
        fail("Expected a fault");
        // This just tests that we don't get exceptions during deserialization
        // for now.  We're still getting nulls for some reason, and once that's
        // fixed we should uncomment this next line
        
        // assertTrue("Result wasn't an array", result.getClass().isArray());