atg.integrations.taxware
Class VeraZipCaller

java.lang.Object
  extended by atg.integrations.taxware.VeraZipCaller

public class VeraZipCaller
extends java.lang.Object

VeraZipCaller provides an higher level interface to TaxWare's zipcode verification software.

See Also:
ZipRequest, ZipResultItem, ZipResult

Field Summary
static java.lang.String CLASS_VERSION
           
protected static boolean m_bOpen
          whether TaxWare's files are open or not
protected static atg.integrations.taxware.VeraZipCaller.InputHeader m_inputHeader
          Input header re-used for each request
protected static java.lang.reflect.Method m_methodCalculateTax
          method for calculating tax
protected static java.lang.Object[] m_rgobjArgs
          argument array
protected static java.lang.StringBuffer m_strbufInput
          StringBuffer re-used for each request
 
Constructor Summary
VeraZipCaller()
           
 
Method Summary
static ZipResult calculate(ZipRequest request)
          Verify a city/state/zipcode triplet when given a ZipRequest object.
protected static atg.integrations.taxware.VeraZipCaller.OutputHeader calculateInternal(ZipRequest request, java.lang.StringBuffer strbuf)
          Does all the stuff for verifying a zip that needs to be synchronized.
protected static atg.integrations.taxware.VeraZipCaller.OutputHeader callCalculate(java.lang.String stringRequest, java.lang.StringBuffer strbuf)
          Calls the verify zipcode function.
protected static java.lang.StringBuffer createBuffer(int cRequests)
          Create a string buffer already pre-filled to the appropriate size.
protected static void createInputHeader()
           
protected static void createInputStringBuffer()
          Create our static input string buffer
static void main(java.lang.String[] rgArgs)
          Perform some basic tests.
static ZipResult QuickVerifyZip(java.lang.String strCity, java.lang.String strState, java.lang.String strZip, boolean bDumpResults)
          A wrapper used for testing.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static java.lang.String CLASS_VERSION

m_strbufInput

protected static java.lang.StringBuffer m_strbufInput
StringBuffer re-used for each request


m_inputHeader

protected static atg.integrations.taxware.VeraZipCaller.InputHeader m_inputHeader
Input header re-used for each request


m_bOpen

protected static boolean m_bOpen
whether TaxWare's files are open or not


m_methodCalculateTax

protected static java.lang.reflect.Method m_methodCalculateTax
method for calculating tax


m_rgobjArgs

protected static java.lang.Object[] m_rgobjArgs
argument array

Constructor Detail

VeraZipCaller

public VeraZipCaller()
Method Detail

createInputStringBuffer

protected static void createInputStringBuffer()
Create our static input string buffer


createInputHeader

protected static void createInputHeader()

createBuffer

protected static java.lang.StringBuffer createBuffer(int cRequests)
Create a string buffer already pre-filled to the appropriate size.


callCalculate

protected static atg.integrations.taxware.VeraZipCaller.OutputHeader callCalculate(java.lang.String stringRequest,
                                                                                   java.lang.StringBuffer strbuf)
                                                                            throws TaxwareMinorException,
                                                                                   TaxwareCriticalException
Calls the verify zipcode function.

Throws:
TaxwareCriticalException - Thrown if installation problem.
TaxwareMinorException - Thrown if error returned from VeraZip.

calculateInternal

protected static atg.integrations.taxware.VeraZipCaller.OutputHeader calculateInternal(ZipRequest request,
                                                                                       java.lang.StringBuffer strbuf)
                                                                                throws TaxwareMinorException,
                                                                                       TaxwareCriticalException
Does all the stuff for verifying a zip that needs to be synchronized.

Throws:
TaxwareCriticalException - Thrown if installation problem.
TaxwareMinorException - Thrown if error returned from VeraZip.

calculate

public static ZipResult calculate(ZipRequest request)
                           throws TaxwareMinorException,
                                  TaxwareCriticalException
Verify a city/state/zipcode triplet when given a ZipRequest object.

Parameters:
request - a ZipRequest object
Returns:
the ZipResult object representing the result
Throws:
TaxwareCriticalException - Thrown if installation problem.
TaxwareMinorException - Thrown if error returned from VeraZip.

QuickVerifyZip

public static final ZipResult QuickVerifyZip(java.lang.String strCity,
                                             java.lang.String strState,
                                             java.lang.String strZip,
                                             boolean bDumpResults)
A wrapper used for testing.


main

public static void main(java.lang.String[] rgArgs)
Perform some basic tests.