public static CustomUserInfoValueImpl convert(final SCustomUserInfoValue sValue) { if (sValue == null) { return null; } final CustomUserInfoValueImpl value = new CustomUserInfoValueImpl(); value.setDefinitionId(sValue.getDefinitionId()); value.setUserId(sValue.getUserId()); value.setValue(sValue.getValue()); return value; }
protected void addCustomUserInfoValues(final long userId, final ExportedUserBuilder clientUserbuilder, final Map<Long, String> userInfoDefinitionNames) throws SBonitaReadException { final List<SCustomUserInfoValue> userInfoValues = getAllCustomUserInfoForUser(userId); for (final SCustomUserInfoValue infoValue : userInfoValues) { final String definitionName = userInfoDefinitionNames.get(infoValue.getDefinitionId()); clientUserbuilder.addCustomUserInfoValue(new ExportedCustomUserInfoValue(definitionName, infoValue.getValue())); } }
public SCustomUserInfoValue update(SCustomUserInfoValue value, CustomUserInfoValueUpdater updater) throws SIdentityException { assertNoNull("Cannot update a value based on null parameters", value, updater); service.updateCustomUserInfoValue(value, updaterFactory.createNewInstance() .updateValue(updater.getValue()) .done()); return service.getCustomUserInfoValue(value.getId()); }
private Map<Long, CustomUserInfoValue> transform(final List<SCustomUserInfoValue> values) { Map<Long, CustomUserInfoValue> map = new HashMap<Long, CustomUserInfoValue>(); for (SCustomUserInfoValue value : values) { map.put(value.getDefinitionId(), ModelConvertor.convert(value)); } return map; }
protected void addCustomUserInfoValues(final long userId, final ExportedUserBuilder clientUserbuilder, final Map<Long, String> userInfoDefinitionNames) throws SBonitaReadException { final List<SCustomUserInfoValue> userInfoValues = getAllCustomUserInfoForUser(userId); for (final SCustomUserInfoValue infoValue : userInfoValues) { final String definitionName = userInfoDefinitionNames.get(infoValue.getDefinitionId()); clientUserbuilder.addCustomUserInfoValue(new ExportedCustomUserInfoValue(definitionName, infoValue.getValue())); } }
public SCustomUserInfoValue update(SCustomUserInfoValue value, CustomUserInfoValueUpdater updater) throws SIdentityException { assertNoNull("Cannot update a value based on null parameters", value, updater); service.updateCustomUserInfoValue(value, updaterFactory.createNewInstance() .updateValue(updater.getValue()) .done()); return service.getCustomUserInfoValue(value.getId()); }
private Map<Long, CustomUserInfoValue> transform(final List<SCustomUserInfoValue> values) { Map<Long, CustomUserInfoValue> map = new HashMap<Long, CustomUserInfoValue>(); for (SCustomUserInfoValue value : values) { map.put(value.getDefinitionId(), ModelConvertor.convert(value)); } return map; }
public static CustomUserInfoValueImpl convert(final SCustomUserInfoValue sValue) { if (sValue == null) { return null; } final CustomUserInfoValueImpl value = new CustomUserInfoValueImpl(); value.setDefinitionId(sValue.getDefinitionId()); value.setUserId(sValue.getUserId()); value.setValue(sValue.getValue()); return value; }