package eu.eudat.logic.utilities.documents.xml.dmpXml.dmpProfileModel;

import javax.xml.bind.annotation.XmlAttribute;
import javax.xml.bind.annotation.XmlRootElement;

@XmlRootElement(name = "datatype")
public class DMPProfileFieldDataType {

    private int datatype;

    @XmlAttribute(name = "datatype")
    public int getDatatype() {
        return datatype;
    }

    public void setDatatype(int datatype) {
        this.datatype = datatype;
    }

    public eu.eudat.models.data.entities.xmlmodels.dmpprofiledefinition.types.DMPProfileFieldDataType toDmpProfileCompositeModel() {
        return eu.eudat.models.data.entities.xmlmodels.dmpprofiledefinition.types.DMPProfileFieldDataType.fromInteger(datatype);
    }
}
