// Multiple repositories: ok to use public repo since only non-repository-specific things are needed
LRepository repository = repositoryMgr.getDefaultRepository();
List<MutationCondition> result = new ArrayList<MutationCondition>();
SystemFields systemFields = SystemFields.getInstance(repository.getTypeManager(), repository.getIdGenerator());
for (int i = 0; i < conditions.size(); i++) {
JsonNode conditionNode = conditions.get(i);
if (!conditionNode.isObject()) {
throw new JsonFormatException("Each element in the conditions array should be an object.");
}
QName fieldName = QNameConverter.fromJson(JsonUtil.getString(conditionNode, "field"), namespaces);
JsonNode valueNode = conditionNode.get("value");
Object value = null;
if (!valueNode.isNull()) {
FieldType fieldType = systemFields.isSystemField(fieldName) ? systemFields.get(fieldName) :
repository.getTypeManager().getFieldTypeByName(fieldName);
value = RecordReader.INSTANCE.readValue(
new RecordReader.ValueHandle(valueNode, "value", fieldType.getValueType()),
new RecordReader.ReadContext(repositoryMgr.getDefaultRepository(), namespaces,linkTransformer));
}