Loading ...
Sorry, an error occurred while loading the content.

982Re: [soaplite] Test code of my inheritance problem

Expand Messages
  • Duncan Cameron
    Nov 3, 2001
      Ivan

      I'm not sure that I understand what the example is meant to be doing, as both of classes A and B are on each server, so no autodispatching will occur.

      To return to your original problem, what you seem to want to do is implement remote inheritance through autodispatching
      i.e. class D has no event() or d_event() methods but wants to inherit them from class G which is on a different server.

      I don't see how Perl's way of inheritance is going to allow your model to work. Remember, that inheritance is dynamic, if class D doesn't have a event() method then Perl will look at all the parents of the class to try to find one. This means that the parent class, G, needs to be on the same server as D, not on a separate server.

      When Perl doesn't find an event() method then it will invoke the AUTOLOAD method in class D which is provided by SOAP::Lite. Autodispatching will then kick-in to send a request to the other server for the event() method for class D, not for class G. But now class D is on the wrong server.

      In fact even referring to a superclass's method doesn't work. If in class D you try something like
      $self->SUPER::event()

      then AUTOLOAD is passed the string 'D::SUPER::event' and then creates a request for method event in class D::SUPER.

      Can you explain your model a bit more clearly? If you've got something working then I'd be interested in seeing what you have done.

      Paul: what's your view on this?

      Regards,
      Duncan Cameron

      On 2001-11-02 Ivan R. Judson <judson@...> wrote:
      >Here's a small example that I think illustrates my problem. Any ideas?
      >
      >--Ivan
      >
      > test.zip
      >To unsubscribe from this group, send an email to:
      >soaplite-unsubscribe@yahoogroups.com
      >
      >
      >
      >Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
    • Show all 3 messages in this topic