Package javax.naming.directory

Examples of javax.naming.directory.Attribute.clear()


                    attributeName = claimURI;
                }
                Attribute currentUpdatedAttribute = new BasicAttribute(attributeName);
                /*if updated attribute value is null, remove its values.*/
                if (EMPTY_ATTRIBUTE_STRING.equals(claimEntry.getValue())) {
                    currentUpdatedAttribute.clear();
                } else {
                    currentUpdatedAttribute.add(claimEntry.getValue());
                }
                updatedAttributes.put(currentUpdatedAttribute);
            }
View Full Code Here


              attr2modify = new BasicAttribute(item.getAttribute().getID(), item.getAttribute().get());
            }
            attributes.put(attr2modify);
          } else {
            // changer la valeur de l'attribut
            attr2modify.clear();
            if (item.getAttribute().size() > 1) {             
              for (int j = 0; j < item.getAttribute().size(); j++) {
              attr2modify.add(item.getAttribute().get(j));
            }
            } else {
View Full Code Here

        // if the attribute exists in LDAP then replace the value,
        // otherwise create a new attribute
        Attribute ldapAttribute = ldapAttributes.get(sLdapKey);
        if (ldapAttribute != null) {
          if (!ldapAttribute.isOrdered()) {
            ldapAttribute.clear();
            ldapAttribute.add(sLocalValue);
          } else {
            ldapAttribute.set(0,sLocalValue);
          }
          modItem = new ModificationItem(DirContext.REPLACE_ATTRIBUTE,ldapAttribute);
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.