@SuppressWarnings("deprecation")
public void save(OrganizationService service, String user, boolean isnewUser) throws Exception {
UserProfileHandler hanlder = service.getUserProfileHandler();
UserProfile userProfile = hanlder.findUserProfileByName(user);
if (userProfile == null) {
userProfile = hanlder.createUserProfileInstance();
userProfile.setUserName(user);
}
for (UIComponent set : getChildren()) {
UIFormInputSet inputSet = (UIFormInputSet) set;
for (UIComponent uiComp : inputSet.getChildren()) {
UIFormStringInput uiInput = (UIFormStringInput) uiComp;
// if(uiInput.getValue() == null || uiInput.getValue().length() < 1)
// continue;
userProfile.getUserInfoMap().put(uiInput.getName(), uiInput.getValue());
}
}
hanlder.saveUserProfile(userProfile, true);