in reply to Re: Unlimited chaining (is there a way to detect this?)
in thread Unlimited chaining (is there a way to detect this?)

I really dislike the SOAP::Lite style of chained methods constructors

my $soap_client = SOAP::Lite->proxy($proxy) ->uri($uri) ->on_fault(sub {...}); .... my $soap_value = SOAP::Data ->name($name) ->value($value) ->type($type);

and don't understand why is it pursued overall in the documentation at the expense of ordinary new:

my $soap_value = SOAP::Data->new( 'name' => $name, 'value' => $value, 'type' => $type);

But I think the SOAP::Lite style is different from the one discussed here.

AFAIK SOAP::Lite methods are overloaded as being:

but only the setter variant can be chained as it modifies the current object and returns it. So there are no new objects created by chained methods.