Examples of AllAttributeValuesItem


Examples of org.apache.directory.api.ldap.aci.protectedItem.AllAttributeValuesItem

                values.add( attributeType.getName() );
            }
        }
        else if ( item.getClass() == AllAttributeValuesItem.class )
        {
            AllAttributeValuesItem aav = ( AllAttributeValuesItem ) item;
            for ( Iterator<AttributeType> it = aav.iterator(); it.hasNext(); )
            {
                AttributeType attributeType = it.next();
                values.add( attributeType.toString() );
            }
        }
View Full Code Here

Examples of org.apache.directory.api.ldap.aci.protectedItem.AllAttributeValuesItem

                if ( scope != OperationScope.ATTRIBUTE_TYPE_AND_VALUE )
                {
                    continue;
                }

                AllAttributeValuesItem aav = ( AllAttributeValuesItem ) item;

                for ( Iterator<AttributeType> iterator = aav.iterator(); iterator.hasNext(); )
                {
                    AttributeType attr = iterator.next();

                    if ( oid.equals( attr.getOid() ) )
                    {
View Full Code Here

Examples of org.apache.directory.api.ldap.aci.protectedItem.AllAttributeValuesItem

        Collection<ProtectedItem> rangeOfValues = new ArrayList<ProtectedItem>();
        Collection<ProtectedItem> allUserAttributeTypes = new ArrayList<ProtectedItem>();
        Collection<ProtectedItem> allUserAttributeTypesAndValues = new ArrayList<ProtectedItem>();

        attributeType.add( new AttributeTypeItem( EMPTY_STRING_COLLECTION ) );
        allAttributeValues.add( new AllAttributeValuesItem( EMPTY_STRING_COLLECTION ) );
        selfValue.add( new SelfValueItem( EMPTY_STRING_COLLECTION ) );
        attributeValue.add( new AttributeValueItem( EMPTY_ATTRIBUTE_COLLECTION ) );
        rangeOfValues.add( new RangeOfValuesItem( new PresenceNode( ( String ) null ) ) );
        allUserAttributeTypes.add( ProtectedItem.ALL_USER_ATTRIBUTE_TYPES );
        allUserAttributeTypesAndValues.add( ProtectedItem.ALL_USER_ATTRIBUTE_TYPES_AND_VALUES );
View Full Code Here

Examples of org.apache.directory.api.ldap.aci.protectedItem.AllAttributeValuesItem

        Set<AttributeType> colC = new HashSet<AttributeType>();
        colC.add( new AttributeType( "bb" ) );
        colC.add( new AttributeType( "cc" ) );
        colC.add( new AttributeType( "dd" ) );

        allAttributeValuesA = new AllAttributeValuesItem( colA );
        allAttributeValuesACopy = new AllAttributeValuesItem( colA );
        allAttributeValuesB = new AllAttributeValuesItem( colB );
        allAttributeValuesC = new AllAttributeValuesItem( colC );
    }
View Full Code Here

Examples of org.apache.directory.api.ldap.aci.protectedItem.AllAttributeValuesItem

    @Test
    public void testAllAttributeValues() throws Exception
    {
        Set<AttributeType> attrTypes = new HashSet<AttributeType>();
        attrTypes.add( CN_AT );
        Collection<ACITuple> tuples = getTuples( new AllAttributeValuesItem( attrTypes ) );

        // Test wrong scope
        AciContext aciContext = new AciContext( null, null );
        aciContext.setAciTuples( tuples );
        aciContext.setUserDn( USER_NAME );
        aciContext.setAttributeType( CN_AT );

        assertEquals( 0, filterA.filter( aciContext, OperationScope.ENTRY, null ).size() );

        tuples = getTuples( new AllAttributeValuesItem( attrTypes ) );

        aciContext = new AciContext( null, null );
        aciContext.setAciTuples( tuples );
        aciContext.setUserDn( USER_NAME );
        aciContext.setAttributeType( CN_AT );
View Full Code Here

Examples of org.apache.directory.shared.ldap.aci.protectedItem.AllAttributeValuesItem

                if ( scope != OperationScope.ATTRIBUTE_TYPE_AND_VALUE )
                {
                    continue;
                }

                AllAttributeValuesItem aav = ( AllAttributeValuesItem ) item;

                for ( Iterator<AttributeType> iterator = aav.iterator(); iterator.hasNext(); )
                {
                    AttributeType attr = iterator.next();
                   
                    if ( oid.equals( attr.getOid() ) )
                    {
View Full Code Here

Examples of org.apache.directory.shared.ldap.aci.protectedItem.AllAttributeValuesItem

    @Test
    public void testAllAttributeValues() throws Exception
    {
        Set<AttributeType> attrTypes = new HashSet<AttributeType>();
        attrTypes.add( CN_AT );
        Collection<ACITuple> tuples = getTuples( new AllAttributeValuesItem( attrTypes ) );

        // Test wrong scope
        AciContext aciContext = new AciContext( null, null );
        aciContext.setAciTuples( tuples );
        aciContext.setUserDn( USER_NAME );
        aciContext.setAttributeType( CN_AT );

        assertEquals( 0, filterA.filter( aciContext, OperationScope.ENTRY, null ).size() );

        tuples = getTuples( new AllAttributeValuesItem( attrTypes ) );

        aciContext = new AciContext( null, null );
        aciContext.setAciTuples( tuples );
        aciContext.setUserDn( USER_NAME );
        aciContext.setAttributeType( CN_AT );
View Full Code Here

Examples of org.apache.directory.shared.ldap.aci.protectedItem.AllAttributeValuesItem

        Collection<ProtectedItem> rangeOfValues = new ArrayList<ProtectedItem>();
        Collection<ProtectedItem> allUserAttributeTypes = new ArrayList<ProtectedItem>();
        Collection<ProtectedItem> allUserAttributeTypesAndValues = new ArrayList<ProtectedItem>();

        attributeType.add( new AttributeTypeItem( EMPTY_STRING_COLLECTION ) );
        allAttributeValues.add( new AllAttributeValuesItem( EMPTY_STRING_COLLECTION ) );
        selfValue.add( new SelfValueItem( EMPTY_STRING_COLLECTION ) );
        attributeValue.add( new AttributeValueItem( EMPTY_ATTRIBUTE_COLLECTION ) );
        rangeOfValues.add( new RangeOfValuesItem( new PresenceNode( ( String ) null ) ) );
        allUserAttributeTypes.add( ProtectedItem.ALL_USER_ATTRIBUTE_TYPES );
        allUserAttributeTypesAndValues.add( ProtectedItem.ALL_USER_ATTRIBUTE_TYPES_AND_VALUES );
View Full Code Here

Examples of org.apache.directory.shared.ldap.aci.protectedItem.AllAttributeValuesItem

                if ( scope != OperationScope.ATTRIBUTE_TYPE_AND_VALUE )
                {
                    continue;
                }

                AllAttributeValuesItem aav = ( AllAttributeValuesItem ) item;

                for ( Iterator<AttributeType> iterator = aav.iterator(); iterator.hasNext(); )
                {
                    AttributeType attr = iterator.next();

                    if ( oid.equals( attr.getOid() ) )
                    {
View Full Code Here

Examples of org.apache.directory.shared.ldap.aci.protectedItem.AllAttributeValuesItem

        Set<AttributeType> colC = new HashSet<AttributeType>();
        colC.add( new AttributeType( "bb" ) );
        colC.add( new AttributeType( "cc" ) );
        colC.add( new AttributeType( "dd" ) );

        allAttributeValuesA = new AllAttributeValuesItem( colA );
        allAttributeValuesACopy = new AllAttributeValuesItem( colA );
        allAttributeValuesB = new AllAttributeValuesItem( colB );
        allAttributeValuesC = new AllAttributeValuesItem( colC );
    }
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.