No luck... I did try what pointed out, but the problem does not seem to be in the server's wsdl. I mean... if I remove the test method and build the app, the wsdl lacks the type definition for the EO stuff... in detail:

<schema targetNamespace="http://eocontrol.webobjects.com"; xmlns="http://www.w3.org/2001/XMLSchema";>
    <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
    <complexType name="EOGenericRecord">
        <complexContent>
            <extension base="tns1:EOEnterpriseObject">
                <sequence/>
            </extension>
        </complexContent>
    </complexType>
</schema>

If I compile with the 'test' method this fragment finds it's way inside the wsdl. This is also the only place where actually the EOEnterpriseObject is referred as I had only used concrete classes like EOGenericRecord.

I would say that the server has correctly recognized the EO classes and has added some stuff to the wsdl. If that stuff is wrong I can't tell :-(

Would anybody have even the shortest snippet of code in which they pass an EO object between webservices it would help a lot. At lest I could check what I did wrong.

Bye,
Riccardo


On 17 ott 2005, at 21:34, LD wrote:

Hi there,

On 18/10/2005, at 12:17 AM, Riccardo De Menna wrote:


I was wondering if someone could help me shed some light on a problem that has locked me for a while. Let me first say I'm no expert on the subject and I'm a bit lost as I can't find any viable documentation to help me out.

I'm working on a client/server webservice app that needs to pass back and forth various EOEnterpriseObjects. For what I've understood, WO should be able to serialize and deserialize them out of the box. But I keep getting an error that I don't seem to understand. Everything else (Strings, Arrays etc) works fine... but as soon as I simply define a method that returns a EOEnterpriseObject descendant I get:

javax.xml.rpc.ServiceException: Error processing WSDL document: java.io.IOException: Type EOEnterpriseObject is referenced but not defined. Reason: Error processing WSDL document: java.io.IOException: Type EOEnterpriseObject is referenced but not defined.

    at org.apache.axis.client.Service.initService(Service.java:278)
    at org.apache.axis.client.Service.<init>(Service.java:193)
at org.apache.axis.client.ServiceFactory.createService (ServiceFactory.java:232) at com.webobjects.webservices.client.WOWebService.axisService (WOWebService.java:185) at com.webobjects.webservices.client.WOWebService.createCallForOperation (WOWebService.java:235) at com.webobjects.webservices.client.WOWebServiceClient.invoke (WOWebServiceClient.java:482)
    at CalculatorClient.invoke(CalculatorClient.java:51)
    at Main.calculate(Main.java:46)

As an example, my server app has a method like the following in the WS registered class (forgive my lack of imagination :) :

public EOGenericRecord test() {
    return new EOGenericRecord();
}


Random thoughts/guesses...
1) try the full package/class path: i.e.,
public com.webobjects.eocontrol.EOGenericRecord test() {...}

2) Would you have any better luck using the other constructor, where you provide the class description. Is that what it means by being undefined perhaps... return new EOGenericRecord (EOClassDescription.classDescriptionForEntityName("Author"));

3) Make sure the entity type is understood by the client app.

with regards,
--

LD



Attachment: smime.p7s
Description: S/MIME cryptographic signature

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to