Examples of EntryValue


Examples of com.sugarcrm.ws.soap.EntryValue

            protected String fetch() {
                UserAuth userAuth = new UserAuth();
                userAuth.setUserName(username);
                userAuth.setPassword(md5password);
                logger.debug("Logging in as '{}', with application name '{}'", username, applicationName);
                EntryValue response = _service.login(userAuth, applicationName, new NameValueList());
                String sessionId = response.getId();
                logger.info("Started session with SugarCRM. Session ID: {}", sessionId);
                return sessionId;
            }
        };
    }
View Full Code Here

Examples of org.apache.activegroups.command.EntryValue

                    : false;
        }
    }

    public boolean containsValue(Object value) {
        EntryValue entryValue = new EntryValue(null, value);
        synchronized (this.mapMutex) {
            return this.localMap != null ? this.localMap
                    .containsValue(entryValue) : false;
        }
    }
View Full Code Here

Examples of org.apache.activegroups.command.EntryValue

        }
        waitForElection();
        if (!isCoordinator() || entryMsg.isSync()) {
            if (containsKey) {
                if (key.isLockExpired()) {
                    EntryValue old = this.localMap.get(key.getKey());
                    if (old != null) {
                        old.getKey().setLocked(false);
                    }
                } else {
                    EntryValue<V> old = null;
                    if (insert) {
                        synchronized (this.mapMutex) {
                            old = this.localMap.put(key.getKey(), value);
                        }
                    } else {
                        synchronized (this.mapMutex) {
                            old = this.localMap.remove(key.getKey());
                            value.setValue(null);
                        }
                    }
                    fireMapChanged(key.getOwner(), key.getKey(),
                            old.getValue(), value.getValue(), entryMsg
                                    .isExpired());
                }
            } else {
                if (insert) {
                    synchronized (this.mapMutex) {
View Full Code Here

Examples of org.openengsb.core.services.internal.security.model.EntryValue

                    entryElement.setValue(LdapUtils.extractAttributeEmptyCheck(propertyValue.getEntry(),
                            SchemaConstants.STRING_ATTRIBUTE));
                    entryElements.add(entryElement);
                }
                String key = LdapUtils.extractAttributeEmptyCheck(property.getEntry(), SchemaConstants.CN_ATTRIBUTE);
                EntryValue entryValue = new EntryValue(key, entryElements);
                attributes.put(key, entryValue); // TODO why need key 2x?
            }
            String type = LdapUtils.extractAttributeEmptyCheck(permission.getEntry(),
                    SchemaConstants.JAVA_CLASS_NAME_ATTRIBUTE);
            PermissionData data = new PermissionData();
View Full Code Here

Examples of org.openengsb.core.services.internal.security.model.EntryValue

    }

    @Override
    public List<Object> getUserAttribute(String username, String attributename) throws UserNotFoundException {
        UserData user = doFindUser(username);
        EntryValue entryValue = user.getAttributes().get(attributename);
        if (entryValue == null) {
            return null;
        }
        List<EntryElement> value = entryValue.getValue();
        return EntryUtils.convertAllEntryElementsToObject(value);
    }
View Full Code Here

Examples of org.openengsb.core.services.internal.security.model.EntryValue

    }

    @Override
    public void setUserAttribute(String username, String attributename, Object... value) throws UserNotFoundException {
        UserData user = doFindUser(username);
        EntryValue entryValue = new EntryValue();
        entryValue.setKey(attributename);
        List<EntryElement> entryElementList = EntryUtils.makeEntryElementList(value);
        entryValue.setValue(entryElementList);
        user.getAttributes().put(attributename, entryValue);
        synchronized (entityManager) {
            entityManager.merge(user);
        }
    }
View Full Code Here

Examples of org.openengsb.core.services.internal.security.model.EntryValue

    }

    @Override
    public void removeUserAttribute(String username, String attributename) throws UserNotFoundException {
        UserData user = doFindUser(username);
        EntryValue entryValue = user.getAttributes().get(attributename);
        if (entryValue == null) {
            // silently fail if attribute is not present
            LOGGER.warn("user does not have attribute, " + attributename);
            return;
        }
View Full Code Here

Examples of org.openengsb.core.services.internal.security.model.EntryValue

        public EntryValue transformEntry(String key, Object value) {
            if (value == null) {
                return null;
            }
            if (value instanceof Collection) {
                return new EntryValue(key, convertAllObjectsToEntryElements((Collection<Object>) value));
            }
            if (value.getClass().isArray()) {
                return new EntryValue(key, convertAllObjectsToEntryElements((Object[]) value));
            }
            return new EntryValue(key, Arrays.asList(transformObjectToEntryElement(value)));
        }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.