Class SchemaElementImpl

    • Field Detail

      • oid

        protected String oid
        The schema element oid
      • description

        protected String description
        The schema element description
      • names

        protected List<String> names
        The list of names for this schemaElements
      • obsolete

        protected boolean obsolete
        The obsolete flag
    • Constructor Detail

      • SchemaElementImpl

        public SchemaElementImpl()
    • Method Detail

      • isObsolete

        public boolean isObsolete()
        Tells if the attributeType is obsolete
        Specified by:
        isObsolete in interface SchemaElement
        Returns:
        true if the schema element is obsolete, folse otherwise
      • setObsolete

        public void setObsolete​(boolean obsolete)
        Set the obsolete flag
        Specified by:
        setObsolete in interface SchemaElement
        Parameters:
        obsolete - The value to be set
      • setDescription

        public void setDescription​(String description)
        Set the schema element's description
        Specified by:
        setDescription in interface SchemaElement
        Parameters:
        description - The schema element's description
      • setNames

        public void setNames​(List<String> names)
        Set a list of names for a schemaElement
        Specified by:
        setNames in interface SchemaElement
        Parameters:
        names - The list of names of this schemaElement
      • getExtension

        public List<String> getExtension​(String key)
        Specified by:
        getExtension in interface SchemaElement
        Parameters:
        key - the Extension key
        Returns:
        The list of a values for a given extension
      • setExtensions

        public void setExtensions​(Map<String,​List<String>> extensions)
        Set a list of extensions for a schemaElement
        Specified by:
        setExtensions in interface SchemaElement
        Parameters:
        extensions - The list of extensions of this schemaElement
      • dnToLdif

        public abstract String dnToLdif​(String schemaName)
                                 throws LdapException
        Transform a Schema Element to a LDIF String
        Parameters:
        schemaName - The schema element to transform
        Returns:
        The Schema Element as a ldif String
        Throws:
        LdapException - If the conversion goes wrong
      • extensionsToLdif

        protected String extensionsToLdif​(String id)
                                   throws LdapException
        Return the extensions formated as Ldif lines
        Parameters:
        id - The attributeId : can be m-objectClassExtension or m-attributeTypeExtension
        Returns:
        The extensions formated as ldif lines
        Throws:
        LdapException - If the conversion goes wrong
      • schemaToLdif

        protected String schemaToLdif​(String schemaName,
                                      String type)
                               throws LdapException
        Transform a Schema to a LDIF formated String
        Parameters:
        schemaName - The schema to transform
        type - The ObjectClass type
        Returns:
        A LDIF String representing the schema
        Throws:
        LdapException - If the transformation can't be done