Extend your cassette configuration class:
- Checks. Use the BankCassetteConfig class.
- Credit cards. Use the CreditCardCassetteConfig class.
If the common configuration parameters defined in the CreditCardCassetteConfig or BankCassetteConfig classes cannot meet your requirements, then implement CassetteConfig.setDefaultAttributeList() to define a list of parameters of type com.edocs.common.payment.cassette.config.Attribute to configure the cassette. These parameters display on the Payment Settings page in the Command Center. The following example shows an extended CreditCardCassetteConfig class:
public class customCassetteConfig extends CreditCardCassetteConfig
{
public void setDefaultAttributeList()
{
Attribute at = new Attribute(
"Custom files 1", //the display name shown in Payment Settings
"Custom key1", //the key value of attribute
Attribute.Text); //the type of attribute
at.setRequire(true); //flag indicate that whether the attribute is required, default is false
at.addDefaultValue("default value"); //set default value
at.setNeedEncrypt(true); //decide whether the value need to be encrypted when stored in db, default is false.
defaultAttributeList.add(at); // Add Attribute to default attribute list
at = new Attribute("Custom files2", //the display name shown in Payment Settings
"Custom key2", //the key value of attribute
Attribute.Text); //the type of attribute
at.addDefaultValue("default value2");
defaultAttributeList.add(at); // Add Attribute to default attribute list
}
}
For more information about updating payment settings in the Command Center, see Administration Guide for Oracle Self-Service E-Billing.
Set the custom config class in the constructor method of the custom payment cassette class so that the custom config class can be recognized when the payment cassette is created. For example:
public class CustomPaymentCassette extends CreditCardCassette
{
Public CustomPaymentCassette()
{
this.setCassetteConfig(new CustomCassetteConfig()); //set cassette config
}
public ICreditCardTransaction submit(CreditCardCassetteParams ccardCassetteParams) throws CassetteException;
{
//TODO implemented by customer
}
public List<ICreditCardTransaction> batchSubmit(CreditCardCassetteParams ccardCassetteParams) throws CassetteException;
{
//TODO implemented by customer
}
}