################################################################################
##  General TODO
################################################################################

    * Build a test that will state with modules are missing at the beginning, 
      then the rest of the tests can be quiet.

    * Remove requirement for Cache::FileCache, but put it as an optional installation
      in the documentation for users of Online modules, if they want to use the 
      cache feature.
      - It is required for Tracking and Tracking::*
  
    * [Enh] Enhance the CPAN distro
      - Test::Distribution - Various tests
      - Test::Signature - makes sure your SIGNATURE file is cryptographically valid.
      - Module::Signature

    * [Bug] New 'Ground Residential' service name doesn't work for UPS_Offline:
      Error: Zone 'u' lookup failed, type 'Ground Residential' not found

    * [Bug] Bundle::Business::Shipping::*
      - It tries to build and install Business::Shipping before anything else,
        when that should be the last module that it installs.  If CPAN is set 
        to install modules that are listed in the makefile, then it will proceed
        correctly, but is there some way to specify the order so it doesn't have
        to?
        
    * [Bug] On a clean 5.8.5, trying to install Bundle::Business::Shipping::UPS_Offline
      results in:
        - tests that try to load Cache::FileCache:
          10
          21
          22
        t/10_init    tries to load Cache::FileCache (un-necessary for UPS_Offline).
        t/21_preload tries to load Cache::FileCache.
        (because of Business::Shipping::Tracking, perhaps?)
     
    * [Enh] Move main documentation into 'Business::Shipping::Manual'?
    
    * [Enh] Allow a "Company" name to be placed in the results.  So that the user
      sees "UPS" instead of "UPS_Online".

    * [Enh] Instead of returning a results hash, allow the user to request a results
      object.  It could overcome the inelegance of dereferencing the AOH.
      
    * [Enh] Logging enhancement: allow printf() style message passing arguments
      so that if a value is undefined, there will not be an error.
    
    * Clean and apply 'shop rates' patch by selena brewington <computers@chrisking.com>
    
    * UPS Tracking Numbers appear in the following formats:
       1Z 999 999 99 9999 999 9
       9999 9999 999 9
       T999 9999 999 

    * USPS tracking formats:
      - http://hdusps.esecurecare.net/cgi-bin/hdusps.cfg/php/enduser/std_adp.php?p_faqid=1125&p_created=1052781743&p_sid=LjOKtaqh&p_lva=&p_sp=cF9zcmNoPSZwX3NvcnRfYnk9JnBfZ3JpZHNvcnQ9JnBfcm93X2NudD0zNiZwX3Byb2RfbHZsMT01MSZwX3Byb2RfbHZsMj0mcF9wYWdlPTE*&p_li=
       
    * [Bug] http://ppm.activestate.com/BuildStatus/5.6plus/solaris/Business-Shipping-1.54.txt
    
    * [Bug] http://ppm.activestate.com/BuildStatus/5.8-hpux/hpux-pa-risc-5.8/Business-Shipping-1.54.txt
    
    * [Enh] Switch to Config::General
    
    * [Enh] Evaluate OODoc
    
    * [Enh] Country Support
      - Which origin countries do UPS_Online and UPS_Offline support?
    
    * [Enh] Test on Sourceforge Compile Farm systems.
      - Also test using older perl versions (e.g. 5.6.x).
 
    * [Enh] Auto-generate a todo-list addendum from the "# TODO:" comments 
      strewn throughout the source code.

    * [Enh] Build a replacement for ClassInfo and ClassAttribs that will be more 
      simple, efficient, and portable.  Should work for static or dynamic 
      generation of Required, Optional, Unique, and other metadata.
  
    * [Enh] Profile the application
      - How long does it take to load the required modules?
      - What are the slowest parts of the system?
      - Memory usage:
        +6.5 MB at the time of "use Business::Shipping::UPS_Offline::RateRequest"
        +1.5 MB at the time of submit() for an UPS_Offline::RateRequest. 
    
    * [Enh] Unit tests for each class.
      - Preferably stored in the .pm with the class.
      
    * Make the configuration file optional for *_Online shipping classes.
      - But still have new, additional configuration parameters, e.g.:
        + How long to wait for a response
        + How long between retries
	+ How many retries
      - Have a configuration object ($Business::Shipping::Cfg) that starts out
        with default values (stored in Config.pm), but can be overridden by 
	installing the Config::Ini module, and then using config/*.ini files. 
	However, if the Config::Ini module is not installed, then everything 
	will still work via the defaults.  (Offline modules have too much 
	configuration data to work without a configuration module).
  
    * [Enh] Conform to coding style: private methods should be prefixed with an
      underscore. 
 
    * [Enh] Handle alternate units (kilograms, etc.).

    * [Enh] Look into Params::Validate and/or Class::Contract
 
    * [Enh] Add Test::Inline tests

* [Enh] Consider using Locale::Country (5.8.x+) & Locale::SubCountry (CPAN), or 
   Geography::States & Geography::Countries.

* [Enh] KLogging: Allow error format to specified 
  - With/without caller, line numbers.

* [Enh] Allow the user to set the timeout for http requests.  Sometimes 30
   seconds is too long.

* [Enh] Is non-ssl communication with either online provider possible?
 
* [Enh] Business::Shipping::UPS_Legacy
    - Doesn't require signup (no username/password, etc.)
    - Interface for Business::UPS 2.0.
 
* [Enh] New feature ideas:
 	- Address Verification
	- Shipping status (package tracking)
	- Service Availability
	- Electronic Merchandise Return?
	- Shipping label generation?
	- Customs forms?
	- Shipping time (how long till it gets there)?
	- Delivery/Signature confirmation?

* [Enh] Allow the user to enable one shipper as a secondary shipper, if the 
  first should fail.  For example, if the UPS/USPS servers are down, it will
  automatically utilize the table-lookup method.
   
* [Enh] Many of the functions that are currently in 
  Shipping::RateRequest::UPS_Offline should probably be moved somewhere else.
  They work on one shipment at a time, and having them in the RateRequest 
  object makes it seem like they should be able to work on multiple shipments
  at once.  Perhaps make the first parameter the given shipment to be worked 
  on?
 
* [Enh] Find or create some module that will automatically update the "=head1 
  VERSION" POD based on the CVS "Revision" keyword or the perl $VERSION 
  variable in the same file.
  
* [Doc] Need to create a list of common errors that will be encountered.
 
* [Enh] Setup a proper "announce", "commits", and "discussion" mailing list 
  where users can sign up for updates and get information.
 
* [Enh] Build/use a more advanced configuration system, with more config-file
  flexibility.
 
* [Enh] Test for thread-safety-ness.

* [Enh] Add support back in for multi-package API.

* [Enh] Allow the user to configure whether all modules are loaded at startup 
  (as would be desirable for mod_perl), or when they are needed.  
   
* [Enh] Put all the currently supported modules in the config.ini file, to make
  them easier to add. 
  
* [Enh] Have an API for "give me all shipping options and prices for this 
  source, destination, and weight".
  
	use Business::Shipping;
	
	my $rate_request = Business::Shipping->rate_request(
		shipper 	=> 'All',
		to_zip 		=> '...',
		from_zip	=> '...',
	);
	
	my $results = $rate_request->go() or die $rate_requet->error();
	
	foreach my $shipper ( $@results ) {
		print "Shipper Name: $shipper->{name}\n";
		
		foreach my $service ( $shipper->{ 'services' } ) {
			print "  Service: $service->{name}\n";
			print "  Price:   $service->{total_charges}\n";
		}
	}
 
* [Doc] Documentation Ehancements:
   Look into OODoc or Pod::Tree
   Use Pod::HtmlEasy to generate CPAN-style (i.e. pretty) HTML docs.
 
    * [Enh] Log4Perl enhancement
      - Remove "Business::Shipping" from the first part of logging output.
      - Perhaps via Log::Log4perl::NDC->pop() ?
      - Perhaps via a Filter object?

    * Try generating HTML using CPAN style:
      - "generated by TUCS::Pod2HTML v, using Pod::Simple::PullParser v2.02"

################################################################################
##  USPS_Offline TODO
################################################################################
 
 * [Enh] Add First-Class Mail
   - http://www.usps.com/consumers/domestic.htm#first
   - Can be done via an off-line calculation.

################################################################################
##  USPS_Online TODO
################################################################################
    
    * [Enh] New 'All' domestic service type returns all rates with one call.
      - See new docs

    * [Bug] USPS_Online EMS bug reported by Micah Gersten <micah@davka.com>
      > It is using the 'Economy (Surface) Parcel Post' rate instead of 'Global 
      > Express Mail (EMS)'.

      The bug is somewhere near this:

      File: lib/Business/Shipping/RateRequest/Online/USPS.pm
      Line: 300

   * [Bug] Find a better way to correlate "Air mail" with all the various names
     it is called by each country.
 
   * [Bug] Not correctly realizing when there is an error (<Error><Number>...)
     - Perhaps because we don't ( KeepRoot => 1, ) on the XMLin()?

   * [Enh] Enable Cache for USPS.
  
   * [Enh] Support get_charges( 'service' ) for domestic types.

   * [Enh] Use the International Country Listing
     - http://pe.usps.gov/cpim/ftp/manuals/Imm/Immctry.pdf
     
   * [Enh] USPS_Online::Shipment: Move the country translator data into config. 

   * [Known Bug] USPS_Online and no internet connection.
     - You will get the following error if there is no connection to the net 
       when using USPS_Online:
       + Business::Shipping::USPS_Online::RateRequest::_handle_response: ()
         File does not exist:  at .../USPS_Online/RateRequest.pm ...
	 
   * [Enh] Printable labels
   
################################################################################
##  UPS_Offline TODO
################################################################################

    * [Enh] Generate advanced table representations from source material
      - Convert the files that are recieved from shippers into a format that 
        provides a faster lookup mechanism, such as SQLLite, Storable, etc.
      - The converted version of the files will be the ones that are distributed
        with Business::Shipping::Data.
      - (This would work well for the zone files, but I'm not sure about the
         rate files.)
    
    * [Enh] Allow customization of memory usage / execution speed 
      -  "optimize for smaller memory footprint, slower execution speed"
      -  "optimize for faster execution speed, larger memory footprint"
      -  If it is optimized for memory footprint, then it will read the 
         representation off the disk, (getting a benefit from OS filesystem 
	 cache, probably), then run the calculation, then delete the in-memory
	 representation (which perl may or may not free immediately).
  
      -  If optimized for speed, then it will read the representation off the 
	 disk and keep it in memory.

 * [Bug] Delivery Area Surcharge: check xarea table instead of always applying.
   
 * [Bug] Serbia: see t/manual/offline_ups_intl_other.pl

 * [Enh] http://perlmonks.org/index.pl?node_id=366587

 * [Enh] Add charges based on pickup type.  
   An alternate set of data is available for people who don't have an account 
   with UPS.  Is the only difference a $4.00 surcharge?

 * [Enh] From Canada to Alaska (and other destinations)
                99663 = Seldovia, Alaska
		my $rate_request = Business::Shipping->rate_request(
                       shipper         => 'Online::UPS',
                       from_canada     => 'CA',
                       from_country    => 'CA',
                       from_zip        => 'v6h3y8',
                       to_country      => 'US',
                       to_zip          => '99663',
                       weight          =>  5.00,
                       user_id         => 'userid',
                       password        => 'pass',
                       service         => 'XPD',
                       access_key       => 'XXXXXX',
               );
				
 * [Enh] Performance enhancement: instead of transforming the data with
   calc_zone_data() everytime, just re-write the data file.
 
 * [Enh] Allow user to specify "use default" or "quiet" for Makefile.PL, which 
   will cause it to use defaults.
 
 * [Enh] Change from_state to a Shipment function, which will calculate and set 
   the is_from_west_coast() value, instead of doing from within 
   massage_values().

 * [Enh] Add a simple example script in the bin directory.

 * [Enh] How to find the current fuel surcharge rate:
   - http://www.ups.com/content/us/en/resources/find/cost/fuel_surcharge.html	
   - m/Effective.+: ?(\d\.\d\d\)%/
   
 * [Enh] Modify the system so that the easy-to-read data is read into memory
         just once, and then is optimized for lookup speed, so the sequential
         lookups will be as fast as possible.  (Increases memory footprint, but
         it should be worth it).
 
 * [Enh] Canada needs to check for EAS surcharge (see canww.csv->'EAS' column)
 
 * [Enh] Add test for the support files directory.  (Just warn, because they 
         may be running the test as a non-priveledged user).
 
 * [Enh] Re-write the calc_zone_data() and calc_cost() routines.

 * [Enh] New table design?

        zone table:
		
 	zone_from_exactly	zone_from_lt	zone_from_gt	zip_to_exactly
	zip_to_lt	zip_to_gt	service
	
        weight table:
	
        weight	zone	amt

 * [Enh] Add tests for Alaska, Hawaii, Canada, and International.
         Add tests for 1DAP.

 * [Enh] Look at the zone file comments to determine which zone file to use.
   (i.e. 970.csv has "970-01 to 972-99" -- means it actually does 972.csv too).
 
 * [Enh] Utilize GDBM or SQL, if available, to speed up lookups.

################################################################################
##  UPS_Online TODO
################################################################################
 
    * [Bug] Return error message if trying to ship to military americas:
      - USP does not ship to APO or FPO addresses.
   
    * [Bug] Be able to handle "mal-formed XML doc" error return from UPS.  
      - Right now, it still tries to parse as an XML doc.

    * [Enh] Allow user-friendly names, like "One Day Air" instead of 1DA.
      - Names for packaging instead of numbers.
 
    * [Enh] UPS support for sending multiple simultaneous requests
      - (USPS had built-in support in the API for Intl)
      - If they don't support it, try LWP::Parallel::UserAgent.
      - Selena Brewington: better yet, use "Rate Shopping"
 
    * [Enh] Implement a multi-package API for UPS.   
      Move to a different XML generation scheme, since all the packages 
      in a multi-package shipment currently have the name "Package".
   
    * [Enh] Business::Shipping::UPS_XML
      - Add to documentation as an alternative to Business::Shipping
      - Maybe utilize the Parser code?

    * [Enh] Ed LaFrance UPS usertag
      - Maybe utilize Ed's Parser code?
	
################################################################################
##  Interchange UserTag TODO
################################################################################

    * [Enh] Test for ability to use within Safe?
   
################################################################################
##  Other Shippers to consider 
################################################################################


    * FedEx
      - http://www.fedex.com/us/solutions/wis/index.html/
      - http://www.synesmedia.com/twiki/bin/view/Cyc/FedExShipManager      
      - [Enh] FedEx module: Christopher L Wenham from Synesmedia has created an 
        Interchange usertag that uses FedEx::DirectConnect for various functions.
      - [Enh] Francois Belanger, francois@sitepak.com has also created a FedEx 
        module (see FedEx.pm).
      - See FedEx::DirectConnect
      - Business::FedEx (Win32 Only, unless you configure a proxy)
      - PHP: http://freshmeat.net/projects/fedexdc/
      - PHP: http://freshmeat.net/projects/phpfedex/
      - PHP: http://freshmeat.net/projects/phorsale/
    * DHL & Airborne
      - API docs available, but no one has expressed interest.
    * CanadaPost
      - PHP module: http://freshmeat.net/projects/canship/
    * FreightQuote

      
################################################################################
##  Tracking
################################################################################

    * Tests

################################################################################
##  General Ideas
################################################################################

    * Other software:
    * Cold Fushion: UPSRateMonger by Matt Robertson (http://www.mysecretbase.com)
    * Cold Fushion: FedExMonger by Matt Robertson (http://www.mysecretbase.com)
