View on
MetaCPAN
search.cpan.org is shutting down
For details read Perl NOC. After June 25th this page will redirect to MetaCPAN.org
David Shao Lin Zhuo > Google-Checkout-1.1.1 > Google::Checkout::Notification::OrderStateChange

Download:
Google-Checkout-1.1.1.tar.gz

Dependencies

Annotate this POD

CPAN RT

New  7
Open  1
View/Report Bugs
Source  

NAME ^

Google::Checkout::Notification::OrderStateChange

SYNOPSIS ^

  use Google::Checkout::General::GCO;
  use Google::Checkout::Notification::OrderStateChange;
  use Google::Checkout::General::Util qw/is_gco_error/;

  my $xml = "/xml/order_state_change_notification.xml";

  #--
  #-- $xml can either be a file or a complete XML doc string
  #--
  my $state_change = Google::Checkout::Notification::OrderStateChange->new(xml => $xml);
  die $state_change if is_gco_error $state_change;

  print $state_change->get_new_fulfillment_order_state, "\n",
        $state_change->get_previous_fulfillment_order_state, "\n",
        $state_change->get_new_financial_order_state, "\n", 
        $state_change->get_previous_financial_order_state, "\n",
        $state_change->get_reason,"\n";

DESCRIPTION ^

Sub-class of google::Checkout::Notification::GCONotification. This module can be used to extract various state change information when the order state change notification is received.

new XML => ...

Constructor. Takes either a XML file or XML doc as data string. If the XML is invalid (syntax error for example), Google::Checkout::General::Error is returned.

type

Always return Google::Checkout::XML::Constants::ORDER_STATE_CHANGE_NOTIFICATION.

get_new_fulfillment_order_state

Returns the new fulfillment order state.

get_new_financial_order_state

Returns the new financial order state.

get_previous_fulfillment_order_state

Returns the previous filfillment order state.

get_previous_financial_order_state

Returns the previous financial order state.

get_reason

Returns the reason for the state change.

COPYRIGHT ^

Copyright 2006 Google. All rights reserved.

SEE ALSO ^

Google::Checkout::Notification::GCONotification

syntax highlighting: