Help-Site Computer Manuals
Software
Hardware
Programming
Networking
  Algorithms & Data Structures   Programming Languages   Revision Control
  Protocols
  Cameras   Computers   Displays   Keyboards & Mice   Motherboards   Networking   Printers & Scanners   Storage
  Windows   Linux & Unix   Mac

/var/sites/help-site.com/auto/tmp/CPAN/9677/Google-Checkout-1.1.1/lib/Google/Checkout/General/ShoppingCart.pm

/var/sites/help-site.com/auto/tmp/CPAN/9677/Google-Checkout-1.1.1/lib/Google/Checkout/General/ShoppingCart.pm


NAME

Google::Checkout::General::ShoppingCart


SYNOPSIS


  use Google::Checkout::General::GCO;

  use Google::Checkout::General::ShoppingCart;

  use Google::Checkout::General::Util qw/is_gco_error/;

  my $cart = Google::Checkout::General::ShoppingCart->new(

             expiration    => "+1 month",

             private       => "Private data",

             checkout_flow => $checkout_flow);

  my $response = Google::Checkout::General::GCO->new->checkout($cart);

  die $response if is_gco_error $response;

  #--

  #-- Redirect URL

  #--

  print $response,"\n";


DESCRIPTION

This module is responsible for writing the <shopping-cart> XML.

new EXPIRATION => ..., PRIVATE => ..., CHECKOUT_FLOW => ...
Constructor. EXPIRATION can be any valid date/time string recognized by Date::Manip. PRIVATE can be any custom private data provided by the merchant. CHECKOUT_FLOW should be a Google::Checkout::General::MerchantCheckoutFlow object.

get_expiration
Returns the expiration time for this shopping cart.

set_expiration DATE_TIME_STRING
Sets the expiration date for this shopping cart. DATE_TIME_STRING can be anything recognized by the Date::Manip module. perldoc Date::Manip for more detail.

get_private
Returns the private data (as array reference).

add_private PRIVATE_DATA
Adds another private data to the shopping cart.

get_items
Returns all the merchant items added to this shopping cart so far. It's returned as an array reference where each element is an object of Google::Checkout::General::MerchantItem.

add_item ITEM
Adds another merchant item to the shopping cart. ITEM should be an object of Google::Checkout::General::MerchantItem.

get_checkout_flow
Returns the Google::Checkout::General::MerchantCheckoutFlow object.

set_checkout_flow
Sets the Google::Checkout::General::MerchantCheckoutFlow object.


COPYRIGHT

Copyright 2006 Google. All rights reserved.


SEE ALSO

Google::Checkout::General::MerchantItem Google::Checkout::General::MerchantCheckoutFlow

Programminig
Wy
Wy
yW
Wy
Programming
Wy
Wy
Wy
Wy