Sending soap Object[] from a client to a server

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • horatiuhapca
    New Member
    • Sep 2007
    • 3

    Sending soap Object[] from a client to a server

    Hello,

    I have a client in a java class and i have to send an Object to a server....somet hing like this ClassName
    {String one,
    String two,
    Integer tree}.
    I read something about serialization/deserialization but I don't have access to the server to implement there a class that could deserialize the data (the Object[]) that i send from the client.
    I also try to send a null Object[] and it works, but I couldn't send the compact Object ClassName[] that I want. I obtain a NullPointerExce ption from the xfire.fault that i use for my SOAP WebService.

    There is another solution to solve this? Can anyone help me plz?

    Thanks in advance.
    Best regards,
    Horatiu
  • r035198x
    MVP
    • Sep 2006
    • 13225

    #2
    Originally posted by horatiuhapca
    Hello,

    I have a client in a java class and i have to send an Object to a server....somet hing like this ClassName
    {String one,
    String two,
    Integer tree}.
    I read something about serialization/deserialization but I don't have access to the server to implement there a class that could deserialize the data (the Object[]) that i send from the client.
    I also try to send a null Object[] and it works, but I couldn't send the compact Object ClassName[] that I want. I obtain a NullPointerExce ption from the xfire.fault that i use for my SOAP WebService.

    There is another solution to solve this? Can anyone help me plz?

    Thanks in advance.
    Best regards,
    Horatiu
    So your class is serialized?

    Comment

    • horatiuhapca
      New Member
      • Sep 2007
      • 3

      #3
      Originally posted by r035198x
      So your class is serialized?
      No, because I could not use this because I don't have acces to the server to deserealize there the information that I send from the client.
      Thanks, Horatiu

      Comment

      • Nepomuk
        Recognized Expert Specialist
        • Aug 2007
        • 3111

        #4
        Originally posted by horatiuhapca
        No, because I could not use this because I don't have acces to the server to deserealize there the information that I send from the client.
        Thanks, Horatiu
        How did you send it then? I know that some methods (maybe all) can only send Objects when they are serialized.

        Greetings,
        Nepomuk

        Comment

        • horatiuhapca
          New Member
          • Sep 2007
          • 3

          #5
          Originally posted by nepomuk
          How did you send it then? I know that some methods (maybe all) can only send Objects when they are serialized.

          Greetings,
          Nepomuk
          Well...this is the question....how can i send it?
          Can this be done without using serialization or only with serialization?

          Now i try something like this
          SOAPPublishDTOV alue[] params = new SOAPPublishDTOV alue[]{soapPublishDTO Value};

          String result = MPMClassInvocat ionTemplate.inv okeMPM(Configur ation.getValueO f("endpointMPM" ), methodName, params);

          but is not working.

          It works only if i tried to send a null object...like this:

          SOAPPublishDTOV alue[] params = new SOAPPublishDTOV alue[]{null};

          Thanks in advance,
          Horatiu

          Comment

          Working...