package ossj.common.cbe.service;

import javax.xml.bind.annotation.adapters.XmlAdapter;

import javax.oss.cbe.service.ServiceValue;

/**
 *
 * @author pm200800
 */
public class ServiceValueAdapter extends XmlAdapter<ServiceValueImpl,ServiceValue>{
    
    public ServiceValue unmarshal(ServiceValueImpl p) throws Exception {
        try {
            ServiceValue r = p;
            return r;
        }
        catch (Exception e)
        {
            e.printStackTrace();
            String msg = "Unable to unmarshall ServiceValue : "+p;
            throw new Exception(msg+" due to "+e);   
        }                
    }

    public ServiceValueImpl marshal(ServiceValue p) throws Exception {
        try {
            ServiceValueImpl r = (ServiceValueImpl)p;
            return r;
        }
        catch (Exception e)
        {
            e.printStackTrace();
            String msg = "Unable to marshall ServiceValueImpl : "+p;
            throw new Exception(msg+" due to "+e);   
        } 
    }
    
}
