Package org.apache.directory.shared.ldap.schema.parsers

Examples of org.apache.directory.shared.ldap.schema.parsers.MatchingRuleUseDescription


         */
        public boolean select( Viewer viewer, Object parentElement, Object element )
        {
            if ( element instanceof MatchingRuleUseDescription )
            {
                MatchingRuleUseDescription mrud = ( MatchingRuleUseDescription ) element;
                boolean matched = SchemaUtils.toString( mrud ).toLowerCase().indexOf(
                    filterText.getText().toLowerCase() ) != -1
                    || mrud.getNumericOid().toLowerCase().indexOf( filterText.getText().toLowerCase() ) != -1;
                return matched;
            }
            return false;
        }
View Full Code Here


    /**
     * {@inheritDoc}
     */
    public void setInput( Object input )
    {
        MatchingRuleUseDescription mrud = null;
        if ( input instanceof MatchingRuleUseDescription )
        {
            mrud = ( MatchingRuleUseDescription ) input;
        }

        // create main content
        this.createMainContent( mrud );

        // set flag
        isObsoleteText.setEnabled( mrud != null && mrud.isObsolete() );

        // create contents of dynamic sections
        this.createAppliesContents( mrud );
        super.createRawContents( mrud );

View Full Code Here

                    mrd.addExtension( RAW_SCHEMA_DEFINITION_LDIF_VALUE, ldifValues );
                    addMatchingRuleDescription( mrd );
                }
                else if ( attributeName.equalsIgnoreCase( SchemaConstants.MATCHING_RULE_USE_AT ) )
                {
                    MatchingRuleUseDescription mrud = mrudParser.parseMatchingRuleUseDescription( value );
                    mrud.addExtension( RAW_SCHEMA_DEFINITION_LDIF_VALUE, ldifValues );
                    addMatchingRuleUseDescription( mrud );
                }
                else if ( attributeName.equalsIgnoreCase( SchemaConstants.CREATE_TIMESTAMP_AT ) )
                {
                    setCreateTimestamp( value );
View Full Code Here

            return DEFAULT_SCHEMA.getMatchingRuleUseDescription( nameOrOid );
        }
        else
        {
            // DUMMY
            MatchingRuleUseDescription mrud = new MatchingRuleUseDescription();
            mrud.setNumericOid( nameOrOid );
            mrud.setExtensions( DUMMY_EXTENSIONS );
            return mrud;
        }
    }
View Full Code Here

       
        int pos = 0;
       
        for ( Value<?> value:attr )
        {
            MatchingRuleUseDescription desc = null;
           
            try
            {
                desc = matchingRuleUseParser.parseMatchingRuleUseDescription( value.getString() );
            }
            catch ( ParseException e )
            {
                LdapInvalidAttributeValueException iave = new LdapInvalidAttributeValueException(
                    "The following does not conform to the matchingRuleUseDescription syntax: " + value.getString(),
                    ResultCodeEnum.INVALID_ATTRIBUTE_SYNTAX );
                iave.setRootCause( e );
                throw iave;
            }
           
            MatchingRuleUseImpl mru = new MatchingRuleUseImpl( desc.getNumericOid(), globalRegistries );
            mru.setApplicableAttributesOids( desc.getApplicableAttributes().toArray( EMPTY ) );
            setSchemaObjectProperties( desc, mru );
           
            matchingRuleUses[pos++] = mru;
        }
View Full Code Here

TOP

Related Classes of org.apache.directory.shared.ldap.schema.parsers.MatchingRuleUseDescription

Copyright © 2018 www.massapicom. 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.