private void set(List<XWikiLDAPSearchAttribute> searchAttributes, Map<String, String> userMappings, BaseObject userObject, XWikiContext xcontext) throws XWikiException { if (searchAttributes != null) { // Convert LDAP attributes to a map usable with BaseClass#fromValueMap Map<String, Object> map = toMap(searchAttributes, userMappings, xcontext); // Set properties in the user object userObject.getXClass(xcontext).fromValueMap(map, userObject); } }
Object map = dynamicSession.load(bclass.getName(), Integer.valueOf(object.getId())); bclass.fromValueMap((Map) map, object); handledProps = bclass.getCustomMappingPropertyList(context); for (Iterator it = handledProps.iterator(); it.hasNext();) {
userClass.fromValueMap(map, userObject);