Package org.apache.directory.server.core.api.interceptor.context

Examples of org.apache.directory.server.core.api.interceptor.context.LookupOperationContext


            return;
        }

        // Get the modified entry
        CoreSession session = modifyContext.getSession();
        LookupOperationContext lookupContext = new LookupOperationContext( session, modifyContext.getDn(),
            SchemaConstants.ALL_ATTRIBUTES_ARRAY );

        Entry alteredEntry = directoryService.getPartitionNexus().lookup( lookupContext );
        modifyContext.setAlteredEntry( alteredEntry );
View Full Code Here


            return;
        }

        // Get the modified entry
        CoreSession session = renameContext.getSession();
        LookupOperationContext lookupContext = new LookupOperationContext( session, renameContext.getNewDn(),
            SchemaConstants.ALL_ATTRIBUTES_ARRAY );

        Entry alteredEntry = directoryService.getPartitionNexus().lookup( lookupContext );
        renameContext.setModifiedEntry( alteredEntry );
View Full Code Here

    private void modify( Entry remoteEntry, int rid ) throws Exception
    {
        String[] attributes = computeAttributes( config.getAttributes(), SchemaConstants.ALL_OPERATIONAL_ATTRIBUTES );

        LookupOperationContext lookupCtx =
            new LookupOperationContext( session, remoteEntry.getDn(), attributes );

        lookupCtx.setSyncreplLookup( true );

        Entry localEntry = session.getDirectoryService().getOperationManager().lookup( lookupCtx );

        if ( config.isMmrMode() )
        {
View Full Code Here

                    SchemaConstants.SCHEMA_MODIFICATIONS_DN );

                generateSchemaSubentry(
                    directoryService.getSchemaManager(),
                    directoryService.getSchemaPartition().lookup(
                        new LookupOperationContext( null, schemaModificationAttributesDn ) ) );
            }

            return schemaSubentry.clone();
        }
    }
View Full Code Here

                SchemaConstants.SCHEMA_MODIFICATIONS_DN );

            generateSchemaSubentry(
                directoryService.getSchemaManager(),
                directoryService.getSchemaPartition().lookup(
                    new LookupOperationContext( null, schemaModificationAttributesDn ) ) );
        }

        return schemaSubentry.clone();
    }
View Full Code Here

            Dn schemaModificationAttributesDn = new Dn( directoryService.getSchemaManager(),
                SchemaConstants.SCHEMA_MODIFICATIONS_DN );

            Entry mods =
                directoryService.getSchemaPartition().lookup(
                    new LookupOperationContext( null, schemaModificationAttributesDn,
                        SchemaConstants.ALL_ATTRIBUTES_ARRAY ) );

            // @todo enable this optimization at some point but for now it
            // is causing some problems so I will just turn it off
            //          Attribute modifyTimeDisk = mods.get( SchemaConstants.MODIFY_TIMESTAMP_AT );
View Full Code Here

        Rdn rdn = new Rdn( "sn=James" );

        store.rename( dn, rdn, true, null );

        dn = new Dn( schemaManager, "sn=James,ou=Engineering,o=Good Times Co." );
        Entry renamed = store.lookup( new LookupOperationContext( session, dn ) );
        assertNotNull( renamed );
        assertEquals( "James", renamed.getDn().getRdn().getValue().getString() );
    }
View Full Code Here

     * {@inheritDoc}
     */
    public Entry lookup( Dn dn, String... attrIds ) throws LdapException
    {
        OperationManager operationManager = directoryService.getOperationManager();
        LookupOperationContext lookupContext = new LookupOperationContext( this, dn, attrIds );

        Entry entry = operationManager.lookup( lookupContext );

        return entry;
    }
View Full Code Here

     * {@inheritDoc}
     */
    public Entry lookup( Dn dn, Control[] controls, String... attrIds ) throws LdapException
    {
        OperationManager operationManager = directoryService.getOperationManager();
        LookupOperationContext lookupContext = new LookupOperationContext( this, dn, attrIds );

        if ( controls != null )
        {
            lookupContext.addRequestControls( controls );
        }

        Entry entry = operationManager.lookup( lookupContext );

        return entry;
View Full Code Here

     * Get the administrativePoint role
     */
    private void checkAdministrativeRole( OperationContext opContext, Dn apDn ) throws LdapException
    {
        CoreSession session = opContext.getSession();
        LookupOperationContext lookupContext = new LookupOperationContext( session, apDn,
            SchemaConstants.ALL_ATTRIBUTES_ARRAY );

        Entry administrationPoint = directoryService.getPartitionNexus().lookup( lookupContext );

        // The administrativeRole AT must exist and not be null
View Full Code Here

TOP

Related Classes of org.apache.directory.server.core.api.interceptor.context.LookupOperationContext

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.