code: @Override
    public JsonElement serialize(CMAEntry src, Type type, JsonSerializationContext context) {
      JsonObject fields = new JsonObject();
      for (Map.Entry<String, LinkedHashMap<String, Object>> field : src.getFields().entrySet()) {
        LinkedHashMap<String, Object> value = field.getValue();
        if (value == null) {
          continue;
        }
        String fieldId = field.getKey();
        JsonObject jsonField = serializeField(context, field.getValue());
        if (jsonField != null) {
          fields.add(fieldId, jsonField);
        }
      }
  
      JsonObject result = new JsonObject();
      result.add("fields", fields);
  
      final CMASystem sys = src.getSystem();
      if (sys != null) {
        result.add("sys", context.serialize(sys));
      }
      return result;
    }
docs: Make sure all fields are mapped in the locale - value way.
  
  @param src     the source to be edited.
  @param type    the type to be used.
  @param context the json context to be changed.
  @return a created json element.