Net::Amazon::Response(3pm) - phpMan

Command: man perldoc info search(apropos)  


Net::Amazon::Response(3pm)     User Contributed Perl Documentation     Net::Amazon::Response(3pm)



NAME
       Net::Amazon::Response - Baseclass for responses from Amazon's web service

SYNOPSIS
           $resp = $ua->request($request);

           if($resp->is_success()) {
               print $resp->as_string();
           }

           if($resp->is_error()) {
               print $resp->message();
           }

           if($resp->is_success()) {
               for my $property ($resp->properties) {
                   print $property->as_string(), "\n";
               }
           }

DESCRIPTION
       "Net::Amazon::Response" is the baseclass for responses coming back from the useragent's
       "request" method. Responses are typically not of type "Net::Amazon::Response" but one of
       its subclasses "Net::Amazon::Response::*". However, for basic error handling and dumping
       content, "Net::Amazon::Response"'s methods are typically used, because we typically don't
       know what type of object we're actually dealing with.

       METHODS


       is_success()
           Returns true if the request was successful. This doesn't mean any objects have been
           found, it just indicates a successful roundtrip.

       is_error()
           Returns true if an error occurred. Use "message()" to determine what kind of error.

       properties()
           Returns the list of "Net::Amazon::Property" objects which were found by the query.

       as_string()
           Dumps the content of the response.

       message()
           Returns the error message as a string in case an error occurred. In case several
           errors occurred, they're stringed together. Look up "messages()" if you need them sep-
           arated.

       messages()
           Returns all error messages for a response as a reference to an array of string mes-
           sages.

SEE ALSO
AUTHOR
       Mike Schilli, <m AT perlmeister.com>

COPYRIGHT AND LICENSE
       Copyright 2003 by Mike Schilli <m AT perlmeister.com>

       This library is free software; you can redistribute it and/or modify it under the same
       terms as Perl itself.



perl v5.8.8                                 2007-11-11                 Net::Amazon::Response(3pm)

Generated by $Id: phpMan.php,v 4.49 2006/02/26 13:18:18 chedong Exp $ Author: Che Dong
On Apache
Under GNU General Public License
2012-05-24 20:19 @38.107.179.240 Crawled by CCBot/1.0 (+http://www.commoncrawl.org/bot.html)
Valid XHTML 1.0!Valid CSS!