All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.mule.samples.voipservice.to.ServiceParamTO Maven / Gradle / Ivy

/*
 * $Id: ServiceParamTO.java 7976 2007-08-21 14:26:13Z dirk.olmes $
 * --------------------------------------------------------------------------------------
 * Copyright (c) MuleSource, Inc.  All rights reserved.  http://www.mulesource.com
 *
 * The software in this package is published under the terms of the CPAL v1.0
 * license, a copy of which has been included with this distribution in the
 * LICENSE.txt file.
 */

package org.mule.samples.voipservice.to;

import org.mule.samples.voipservice.LocaleMessage;

import java.io.Serializable;

/**
 * @author Binildas Christudas
 */
public class ServiceParamTO implements Serializable
{
    /**
     * Serial version
     */
    private static final long serialVersionUID = -4807303917627749519L;

    private CustomerTO customerTO;
    private CreditCardTO creditCardTO;

    public ServiceParamTO()
    {
        super();
    }

    public ServiceParamTO(CustomerTO customerTO, CreditCardTO creditCardTO)
    {
        this.customerTO = customerTO;
        this.creditCardTO = creditCardTO;
    }

    public void setCustomer(CustomerTO customerTO)
    {
        this.customerTO = customerTO;
    }

    public CustomerTO getCustomer()
    {
        return customerTO;
    }

    public void setCreditCard(CreditCardTO creditCardTO)
    {
        this.creditCardTO = creditCardTO;
    }

    public CreditCardTO getCreditCard()
    {
        return creditCardTO;
    }

    public String toString()
    {
        StringBuffer stringBuffer = new StringBuffer();
        if (this.customerTO != null)
        {
            stringBuffer.append(LocaleMessage.getCustomerCaption(customerTO));
        }
        if (this.creditCardTO != null)
        {
            stringBuffer.append(LocaleMessage.getCardCaption(creditCardTO));
        }

        return stringBuffer.toString();
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy