net.authorize.cim
Class Transaction

java.lang.Object
  extended by net.authorize.Transaction
      extended by net.authorize.cim.Transaction
All Implemented Interfaces:
Serializable

public class Transaction
extends Transaction

Transaction object for CIM.

See Also:
Serialized Form

Field Summary
protected  Map<String,String> extraOptions
           
protected  Map<HostedProfileSettingType,String> hostedProfileSettings
           
static String XML_NAMESPACE
           
 
Fields inherited from class net.authorize.Transaction
BRACKET_PIPE_DELIMITER, CURRENCY_DECIMAL_PLACES, EMPTY_STRING, ENCAP_CHAR_DELIMITER, FALSE, MAX_AUTH_CODE_LENGTH, QUANTITY_DECIMAL_PLACES, TRANSACTION_FIELD_DELIMITER, TRUE, VERSION, ZERO_AMOUNT, ZERO_STRING
 
Method Summary
 void addExtraOption(String key, String value)
          Add extra option to the extra options map.
 void addHostedProfileSetting(HostedProfileSettingType settingName, String settingValue)
          Add hosted profile setting to the hosted profile settings map.
 void addPaymentProfile(PaymentProfile paymentProfile)
          Add a payment profile.
static Transaction createTransaction(Merchant merchant, TransactionType transactionType)
          Creates a transaction.
static Transaction createTransaction(Transaction transaction, BasicXmlDocument response)
          Create a transaction from a response.
 BasicXmlDocument getCurrentRequest()
          Returns the current request.
 BasicXmlDocument getCurrentResponse()
          Returns the current response.
 ArrayList<PaymentProfile> getPaymentProfileList()
           
 String getRefId()
           
 TransactionType getTransactionType()
           
 ValidationModeType getValidationMode()
          Get the validation mode.
 void setCardCode(String cardCode)
          Set the card code for specific transactions.
 void setCustomerPaymentProfileId(String customerPaymentProfileId)
          Set the customer payment profile id.
 void setCustomerProfile(CustomerProfile customerProfile)
          Set the customer profile.
 void setCustomerProfileId(String customerProfileId)
          Set the customer profile id.
 void setCustomerShippingAddressId(String customerShippingAddressId)
          Set the customer shipping address id.
 void setExtraOptions(Map<String,String> extraOptions)
          Sets the extra options.
 void setHostedProfileSettings(Map<HostedProfileSettingType,String> settings)
          Sets the hosted profile settings.
 void setPaymentProfileList(ArrayList<PaymentProfile> paymentProfileList)
           
 void setPaymentTransaction(PaymentTransaction paymentTransaction)
          Set the payment transaction.
 void setRefId(String refId)
           
 void setShipTo(Address shipTo)
          Set shipping information.
 void setValidationMode(ValidationModeType validationMode)
          Set the validation mode for the request.
 String toXMLString()
          Convert request to XML.
 
Methods inherited from class net.authorize.Transaction
getDecodedString, getEncodedString, setEncapCharDelimiter, setTransactionFieldDelimiter, toNVPString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

XML_NAMESPACE

public static String XML_NAMESPACE

extraOptions

protected Map<String,String> extraOptions

hostedProfileSettings

protected Map<HostedProfileSettingType,String> hostedProfileSettings
Method Detail

createTransaction

public static Transaction createTransaction(Merchant merchant,
                                            TransactionType transactionType)
Creates a transaction.

Parameters:
merchant -
transactionType -
Returns:
Transaction

createTransaction

public static final Transaction createTransaction(Transaction transaction,
                                                  BasicXmlDocument response)
Create a transaction from a response.

Parameters:
transaction -
response -
Returns:
a Transaction

getTransactionType

public TransactionType getTransactionType()
Returns:
the transactionType

getCurrentRequest

public BasicXmlDocument getCurrentRequest()
Returns the current request.

Returns:
BasicXmlDocument containing the request

getCurrentResponse

public BasicXmlDocument getCurrentResponse()
Returns the current response.

Returns:
BasicXmlDocument containing the response

toXMLString

public String toXMLString()
Convert request to XML.

Overrides:
toXMLString in class Transaction

getRefId

public String getRefId()
Returns:
the refId

setRefId

public void setRefId(String refId)
Parameters:
refId - the refId to set

getPaymentProfileList

public ArrayList<PaymentProfile> getPaymentProfileList()
Returns:
the paymentProfileList

setPaymentProfileList

public void setPaymentProfileList(ArrayList<PaymentProfile> paymentProfileList)
Parameters:
paymentProfileList - the paymentProfileList to set

addPaymentProfile

public void addPaymentProfile(PaymentProfile paymentProfile)
Add a payment profile.

Parameters:
paymentProfile -

setShipTo

public void setShipTo(Address shipTo)
Set shipping information.

Parameters:
shipTo -

getValidationMode

public ValidationModeType getValidationMode()
Get the validation mode.

Returns:
the validationMode

setValidationMode

public void setValidationMode(ValidationModeType validationMode)
Set the validation mode for the request.

Parameters:
validationMode - the validationMode to set

setCustomerProfile

public void setCustomerProfile(CustomerProfile customerProfile)
Set the customer profile.

Parameters:
customerProfile - the customerProfile to set

setCustomerProfileId

public void setCustomerProfileId(String customerProfileId)
Set the customer profile id.

Parameters:
customerProfileId -

setCustomerPaymentProfileId

public void setCustomerPaymentProfileId(String customerPaymentProfileId)
Set the customer payment profile id.

Parameters:
customerPaymentProfileId -

setCustomerShippingAddressId

public void setCustomerShippingAddressId(String customerShippingAddressId)
Set the customer shipping address id.

Parameters:
customerShippingAddressId -

setCardCode

public void setCardCode(String cardCode)
Set the card code for specific transactions.

Parameters:
cardCode -

setPaymentTransaction

public void setPaymentTransaction(PaymentTransaction paymentTransaction)
Set the payment transaction.

Parameters:
paymentTransaction - the paymentTransaction to set

setExtraOptions

public void setExtraOptions(Map<String,String> extraOptions)
Sets the extra options.

Parameters:
extraOptions - the extraOptions to set

addExtraOption

public void addExtraOption(String key,
                           String value)
Add extra option to the extra options map.

Parameters:
key -
value -

setHostedProfileSettings

public void setHostedProfileSettings(Map<HostedProfileSettingType,String> settings)
Sets the hosted profile settings.

Parameters:
settings - the settings to set

addHostedProfileSetting

public void addHostedProfileSetting(HostedProfileSettingType settingName,
                                    String settingValue)
Add hosted profile setting to the hosted profile settings map.

Parameters:
settingName -
settingValue -


Copyright © 2014. All Rights Reserved.