com.avalara.avatax.services.tax
Class GetTaxRequest

java.lang.Object
  extended by com.avalara.avatax.services.tax.GetTaxRequest
All Implemented Interfaces:
java.io.Serializable

public class GetTaxRequest
extends java.lang.Object
implements java.io.Serializable

Data to pass to TaxSvcSoap.getTax(com.avalara.avatax.services.tax.GetTaxRequest).

See Also:
GetTaxResult, Serialized Form

Constructor Summary
GetTaxRequest()
          Initializes a new instance of the class.
 
Method Summary
 boolean equals(java.lang.Object obj)
           
 ArrayOfBaseAddress getAddresses()
          Gets the addresses value for this GetTaxRequest.
 java.lang.String getBatchCode()
          Gets the batchCode value for this GetTaxRequest.
 boolean getCommit()
          Gets the commit value for this GetTaxRequest.
 java.lang.String getCompanyCode()
          Gets the client application company reference code.
 java.lang.String getCurrencyCode()
          Gets the currencyCode value for this GetTaxRequest.
 java.lang.String getCustomerCode()
          The client application customer reference code.
 java.lang.String getCustomerUsageType()
          The client application customer or usage type.
static org.apache.axis.encoding.Deserializer getDeserializer(java.lang.String mechType, java.lang.Class _javaType, javax.xml.namespace.QName _xmlType)
          Get Axis Custom Deserializer; this method is used internally by the adapter and not intended to be used by external implementation code.
 java.lang.String getDestinationCode()
          Used internally by the adapter to reference the Line.getDestinationAddress() **FIX**.
 DetailLevel getDetailLevel()
          Specifies the level of detail to return.
 java.math.BigDecimal getDiscount()
          The discount amount to apply to the document.
 java.lang.String getDocCode()
          Gets the Document Code, i.e., the internal reference code used by the client application.
 java.util.Date getDocDate()
          The date on the invoice, purchase order, etc.
 DocumentType getDocType()
          The document type specifies the category of the document and affects how the document is treated after a tax calculation; see DocumentType for more information about the specific document types.
 java.math.BigDecimal getExchangeRate()
          Gets the exchangeRate value for this GetTaxRequest.
 java.util.Date getExchangeRateEffDate()
          Gets the exchangeRateEffDate value for this GetTaxRequest.
 java.lang.String getExemptionNo()
          Exemption Number for this document
 int getHashCode()
          Gets the hashCode value for this GetTaxRequest.
 ArrayOfLine getLines()
          Document line items list.
 java.lang.String getLocationCode()
          Gets the locationCode value for this GetTaxRequest.
 java.lang.String getOriginCode()
          Used internally by the adapter to reference the Line.getOriginAddress()
 java.util.Date getPaymentDate()
          Gets the paymentDate value for this GetTaxRequest.
 java.lang.String getPurchaseOrderNo()
          Purchase Order Number for this document.
 java.lang.String getReferenceCode()
          For returns (see DocumentType), refers to the getDocCode() of the original invoice.
 java.lang.String getSalespersonCode()
          The client application salesperson reference code.
static org.apache.axis.encoding.Serializer getSerializer(java.lang.String mechType, java.lang.Class _javaType, javax.xml.namespace.QName _xmlType)
          Get Axis Custom Serializer; this method is used internally by the adapter and not intended to be used by external implementation code.
 ServiceMode getServiceMode()
          Gets the serviceMode value for this GetTaxRequest.
 TaxOverride getTaxOverride()
           
static org.apache.axis.description.TypeDesc getTypeDesc()
          Return Axis type metadata object; this method is used internally by the adapter and not intended to be used by external implementation code.
 int hashCode()
          Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.
 void setAddresses(ArrayOfBaseAddress addresses)
          Sets the addresses for this request.
 void setBatchCode(java.lang.String batchCode)
          Sets the batchCode value for this GetTaxRequest.
 void setCommit(boolean commit)
          Sets the commit value for this GetTaxRequest.
 void setCompanyCode(java.lang.String companyCode)
          Sets the client application company reference code.
 void setCurrencyCode(java.lang.String currencyCode)
          Sets the currencyCode value for this GetTaxRequest.
 void setCustomerCode(java.lang.String customerCode)
          The client application customer reference code.
 void setCustomerUsageType(java.lang.String customerUsageType)
          The client application customer or usage type.
 void setDestinationCode(java.lang.String destinationCode)
          Used internally by the adapter to reference the Line.getDestinationAddress() **FIX**.
 void setDetailLevel(DetailLevel detailLevel)
          Specifies the level of detail to return.
 void setDiscount(java.math.BigDecimal discount)
          The discount amount to apply to the document.
 void setDocCode(java.lang.String docCode)
          Sets the Document Code, i.e., the internal reference code used by the client application.
 void setDocDate(java.util.Date docDate)
          The date on the invoice, purchase order, etc.
 void setDocType(DocumentType docType)
          The document type specifies the category of the document and affects how the document is treated after a tax calculation; see DocumentType for more information about the specific document types.
 void setExchangeRate(java.math.BigDecimal exchangeRate)
          Sets the exchangeRate value for this GetTaxRequest.
 void setExchangeRateEffDate(java.util.Date exchangeRateEffDate)
          Sets the exchangeRateEffDate value for this GetTaxRequest.
 void setExemptionNo(java.lang.String exemptionNo)
          Exemption Number for this document
 void setHashCode(int hashCode)
          Sets the hashCode value for this GetTaxRequest.
 void setLines(ArrayOfLine lines)
          Document line items list.
 void setLocationCode(java.lang.String locationCode)
          Sets the locationCode value for this GetTaxRequest.
 void setOriginCode(java.lang.String originCode)
          Used internally by the adapter to reference the Line.getOriginAddress().
 void setPaymentDate(java.util.Date paymentDate)
          Sets the paymentDate value for this GetTaxRequest.
 void setPurchaseOrderNo(java.lang.String purchaseOrderNo)
          Purchase Order Number for this document.
 void setReferenceCode(java.lang.String referenceCode)
          For returns (see DocumentType), refers to the getDocCode() of the original invoice.
 void setSalespersonCode(java.lang.String salespersonCode)
          The client application salesperson reference code.
 void setServiceMode(ServiceMode serviceMode)
          Sets the serviceMode value for this GetTaxRequest.
 void setTaxOverride(TaxOverride taxOverride)
          Sets the taxOverride value for this GetTaxRequest.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GetTaxRequest

public GetTaxRequest()
Initializes a new instance of the class.

Method Detail

getCompanyCode

public java.lang.String getCompanyCode()
Gets the client application company reference code.

Returns:
companyCode

setCompanyCode

public void setCompanyCode(java.lang.String companyCode)
Sets the client application company reference code.

Parameters:
companyCode -

getDocType

public DocumentType getDocType()
The document type specifies the category of the document and affects how the document is treated after a tax calculation; see DocumentType for more information about the specific document types.
Example:
 [Java]
 GetTaxRequest request = new GetTaxRequest();
 request.setDocType(DocumentType.SalesInvoice);
 

Returns:
docType

setDocType

public void setDocType(DocumentType docType)
The document type specifies the category of the document and affects how the document is treated after a tax calculation; see DocumentType for more information about the specific document types.
Example:
 [Java]
 GetTaxRequest request = new GetTaxRequest();
 request.setDocType(DocumentType.SalesInvoice);
 

Parameters:
docType -

getDocCode

public java.lang.String getDocCode()
Gets the Document Code, i.e., the internal reference code used by the client application.

If DocId is specified, this is not needed.

Returns:
Document Code

setDocCode

public void setDocCode(java.lang.String docCode)
Sets the Document Code, i.e., the internal reference code used by the client application.

If DocId is specified, this is not needed.

Parameters:
docCode -

getDocDate

public java.util.Date getDocDate()
The date on the invoice, purchase order, etc.

Returns:
docDate

setDocDate

public void setDocDate(java.util.Date docDate)
The date on the invoice, purchase order, etc.

Parameters:
docDate -

getSalespersonCode

public java.lang.String getSalespersonCode()
The client application salesperson reference code.

Returns:
salespersonCode

setSalespersonCode

public void setSalespersonCode(java.lang.String salespersonCode)
The client application salesperson reference code.

Parameters:
salespersonCode -

getCustomerCode

public java.lang.String getCustomerCode()
The client application customer reference code.

Returns:
customerCode

setCustomerCode

public void setCustomerCode(java.lang.String customerCode)
The client application customer reference code.

Parameters:
customerCode -

getCustomerUsageType

public java.lang.String getCustomerUsageType()
The client application customer or usage type.

Returns:
customerUsageType

setCustomerUsageType

public void setCustomerUsageType(java.lang.String customerUsageType)
The client application customer or usage type.

Setting customerUsageType between 'A' to 'L' will automatically exepmt the transaction

Parameters:
customerUsageType -

getDiscount

public java.math.BigDecimal getDiscount()
The discount amount to apply to the document.

Returns:
discount

setDiscount

public void setDiscount(java.math.BigDecimal discount)
The discount amount to apply to the document.

Parameters:
discount -

getPurchaseOrderNo

public java.lang.String getPurchaseOrderNo()
Purchase Order Number for this document.

This is required for single use exemption certificates to match the order and invoice with the certificate.

Returns:
purchaseOrderNo

setPurchaseOrderNo

public void setPurchaseOrderNo(java.lang.String purchaseOrderNo)
Purchase Order Number for this document.

This is required for single use exemption certificates to match the order and invoice with the certificate.

Parameters:
purchaseOrderNo -

getExemptionNo

public java.lang.String getExemptionNo()
Exemption Number for this document

Returns:
exemptionNo

setExemptionNo

public void setExemptionNo(java.lang.String exemptionNo)
Exemption Number for this document

Parameters:
exemptionNo -

getOriginCode

public java.lang.String getOriginCode()
Used internally by the adapter to reference the Line.getOriginAddress()

Same as the OriginAddress's BaseAddress.getAddressCode() An internally maintained value representing the OriginAddress

Returns:
originCode

setOriginCode

public void setOriginCode(java.lang.String originCode)
Used internally by the adapter to reference the Line.getOriginAddress().

Same as the OriginAddress's BaseAddress.getAddressCode() -- An internally maintained value representing the OriginAddress

Note: Made "setter" private to avoid corrupting the new way of referencing addresses.

Parameters:
originCode -

getDestinationCode

public java.lang.String getDestinationCode()
Used internally by the adapter to reference the Line.getDestinationAddress() **FIX**. Same as the DestinationAddress's BaseAddress.getAddressCode(). An internally maintained value representing the DestinationAddress.

Returns:
destinationCode

setDestinationCode

public void setDestinationCode(java.lang.String destinationCode)
Used internally by the adapter to reference the Line.getDestinationAddress() **FIX**. Same as the DestinationAddress's BaseAddress.getAddressCode() -- An internally maintained value representing the DestinationAddress.

Note: Made "setter" private to avoid corrupting the new way of referencing addresses.

Parameters:
destinationCode -

getAddresses

public ArrayOfBaseAddress getAddresses()
Gets the addresses value for this GetTaxRequest. Address collection for the document. The AddressCode relates to the OriginCode or DestinationCode in the document or line.

Returns:
addresses
See Also:
line items listAddress, Line

setAddresses

public void setAddresses(ArrayOfBaseAddress addresses)
Sets the addresses for this request. These are referenced by AddressCode from the getOriginCode(), getDestinationCode() and Line elements.

Parameters:
addresses -
See Also:
line items listAddress, Line

getLines

public ArrayOfLine getLines()
Document line items list.

Returns:
lines

setLines

public void setLines(ArrayOfLine lines)
Document line items list. Made private to avoid data corruption.

Parameters:
lines -

getDetailLevel

public DetailLevel getDetailLevel()
Specifies the level of detail to return.

Returns:
detailLevel

setDetailLevel

public void setDetailLevel(DetailLevel detailLevel)
Specifies the level of detail to return.

Parameters:
detailLevel -

getReferenceCode

public java.lang.String getReferenceCode()
For returns (see DocumentType), refers to the getDocCode() of the original invoice.

Returns:
referenceCode

setReferenceCode

public void setReferenceCode(java.lang.String referenceCode)
For returns (see DocumentType), refers to the getDocCode() of the original invoice.

Parameters:
referenceCode -

getHashCode

public int getHashCode()
Gets the hashCode value for this GetTaxRequest.

This should be computed by an SDK developer using some standard algorithm out of the content of the object. This value gets stored in the system and can be retrieved for the cross checking [Internal Reconciliation purpose]. See sample code for more details

Returns:
hashCode

setHashCode

public void setHashCode(int hashCode)
Sets the hashCode value for this GetTaxRequest.

This should be computed by an SDK developer using some standard algorithm out of the content of the object. This value gets stored in the system and can be retrieved for the cross checking [Internal Reconciliation purpose]. See sample code for more details

Parameters:
hashCode -

getLocationCode

public java.lang.String getLocationCode()
Gets the locationCode value for this GetTaxRequest.

It is Also referred to as a Store Location, Outlet Id, or Outlet code is a number assigned by the State which identifies a Store location. Some state returns require taxes are broken out separately for Store Locations.

Returns:
locationCode

setLocationCode

public void setLocationCode(java.lang.String locationCode)
Sets the locationCode value for this GetTaxRequest.

It is Also referred to as a Store Location, Outlet Id, or Outlet code is a number assigned by the State which identifies a Store location. Some state returns require taxes are broken out separately for Store Locations.

Parameters:
locationCode -

getCommit

public boolean getCommit()
Gets the commit value for this GetTaxRequest.

Returns:
commit

setCommit

public void setCommit(boolean commit)
Sets the commit value for this GetTaxRequest.

This has been defaulted to false. If this has been set to true AvaTax will commit the document on this call. Seller's system who wants to Save,Post and Commit the document on one call should use this flag.

Also See PostTaxRequest.setCommit(boolean)

Parameters:
commit -

getBatchCode

public java.lang.String getBatchCode()
Gets the batchCode value for this GetTaxRequest.

Returns:
batchCode

setBatchCode

public void setBatchCode(java.lang.String batchCode)
Sets the batchCode value for this GetTaxRequest.

Parameters:
batchCode -

getTaxOverride

public TaxOverride getTaxOverride()

setTaxOverride

public void setTaxOverride(TaxOverride taxOverride)
Sets the taxOverride value for this GetTaxRequest.

TaxOverride indicates to apply tax override to the document.

Also See TaxOverride

Parameters:
taxOverride -

getCurrencyCode

public java.lang.String getCurrencyCode()
Gets the currencyCode value for this GetTaxRequest.

Returns:
currencyCode

setCurrencyCode

public void setCurrencyCode(java.lang.String currencyCode)
Sets the currencyCode value for this GetTaxRequest.

It is 3 character ISO 4217 currency code.

Parameters:
currencyCode -

getServiceMode

public ServiceMode getServiceMode()
Gets the serviceMode value for this GetTaxRequest.

Returns:
serviceMode

setServiceMode

public void setServiceMode(ServiceMode serviceMode)
Sets the serviceMode value for this GetTaxRequest.

This is only supported by AvaLocal servers. It provides the ability to controls whether tax is calculated locally or remotely when using an AvaLocal server. The default is Automatic which calculates locally unless remote is necessary for non-local addresses.

Parameters:
serviceMode -

getPaymentDate

public java.util.Date getPaymentDate()
Gets the paymentDate value for this GetTaxRequest.

Returns:
paymentDate

setPaymentDate

public void setPaymentDate(java.util.Date paymentDate)
Sets the paymentDate value for this GetTaxRequest.

Parameters:
paymentDate -

getExchangeRate

public java.math.BigDecimal getExchangeRate()
Gets the exchangeRate value for this GetTaxRequest.

Returns:
exchangeRate

setExchangeRate

public void setExchangeRate(java.math.BigDecimal exchangeRate)
Sets the exchangeRate value for this GetTaxRequest.

Parameters:
exchangeRate -

getExchangeRateEffDate

public java.util.Date getExchangeRateEffDate()
Gets the exchangeRateEffDate value for this GetTaxRequest.

Returns:
exchangeRateEffDate

setExchangeRateEffDate

public void setExchangeRateEffDate(java.util.Date exchangeRateEffDate)
Sets the exchangeRateEffDate value for this GetTaxRequest.

Parameters:
exchangeRateEffDate -

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.

Overrides:
hashCode in class java.lang.Object
Returns:
hash code for this GetTaxRequest object
See Also:
Object.hashCode()

getTypeDesc

public static org.apache.axis.description.TypeDesc getTypeDesc()
Return Axis type metadata object; this method is used internally by the adapter and not intended to be used by external implementation code.


getSerializer

public static org.apache.axis.encoding.Serializer getSerializer(java.lang.String mechType,
                                                                java.lang.Class _javaType,
                                                                javax.xml.namespace.QName _xmlType)
Get Axis Custom Serializer; this method is used internally by the adapter and not intended to be used by external implementation code.


getDeserializer

public static org.apache.axis.encoding.Deserializer getDeserializer(java.lang.String mechType,
                                                                    java.lang.Class _javaType,
                                                                    javax.xml.namespace.QName _xmlType)
Get Axis Custom Deserializer; this method is used internally by the adapter and not intended to be used by external implementation code.