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

z11.rs.NullToZeroXmlAdapter Maven / Gradle / Ivy

There is a newer version: 1.8
Show newest version
/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package z11.rs;

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

/**
 *
 * @author danny
 */
public class NullToZeroXmlAdapter  extends XmlAdapter {
    @Override
    public Integer unmarshal(Integer v) throws Exception {
        return v;
    }

    @Override
    public Integer marshal(Integer v) throws Exception {
        if (v == null) {
            return 0;
        }
        return v;
    }
    
    
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy