Code example for JsonPrimitive

0
 
    public static class ConceptClassSerializer implements JsonSerializer<ConceptClass> {
 
        @Override 
        public JsonElement serialize(ConceptClass src, Type typeOfSrc, JsonSerializationContext context) {
            return new JsonPrimitive(src.getDisplay());
        } 
 
    } 
 
    public String getUuid() {
        return uuid;
    } 
 
    public void setUuid(String uuid) {
        this.uuid = uuid;
    } 
 
    public String getDisplay() {
        return display;