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

nlg.wrapper.Field Maven / Gradle / Ivy

There is a newer version: 2.2.0
Show newest version
package nlg.wrapper;


import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlProperty;
import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlRootElement;
import com.fasterxml.jackson.dataformat.xml.annotation.JacksonXmlText;



@JsonPropertyOrder({ "name", "body" })
@JsonInclude(JsonInclude.Include.NON_NULL)
@JacksonXmlRootElement(localName = "field", namespace = Value.BLOCKLY_NS)
public class Field implements BlocklyContents {
    public final static String BLOCKLY_NS = "https://developers.google.com/blockly/xml";

    private String name;
    private String body;

    public Field(String name, String body) {
        this.name = name;
        this.body = body;
    }

    public Field () {}

    @JacksonXmlProperty( isAttribute = true)
    public String getName() {
        return name;
    }

    //@JacksonXmlProperty( namespace =BLOCKLY_NS, isAttribute = true)
    @JacksonXmlText
    public String getBody() {
        return body;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy