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

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


                    // We're only adding the entry if the two DNs are equal
                    if ( suffixDn.equals( contextEntryDn ) )
                    {
                        // Looking for the current context entry
                        Entry suffixEntry = lookup( new LookupOperationContext( null, suffixDn ) );

                        // We're only adding the context entry if it doesn't already exist
                        if ( suffixEntry == null )
                        {
                            // Checking of the context entry is schema aware
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();
        return operationManager.lookup( new LookupOperationContext( this, dn, attrIds ) );
    }
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 );
        lookupContext.addRequestControls( controls );

        return operationManager.lookup( lookupContext );
    }
View Full Code Here

    {
        Entry entry = modifyContext.getEntry();

        if ( entry == null )
        {
            LookupOperationContext lookupCtx = new LookupOperationContext( modifyContext.getSession(),
                modifyContext.getDn() );
            entry = wrapped.lookup( lookupCtx );
            modifyContext.setEntry( entry );
        }
View Full Code Here

    public void move( MoveOperationContext moveContext ) throws LdapException
    {
        boolean cascade = moveContext.hasRequestControl( Cascade.OID );

        CoreSession session = moveContext.getSession();
        LookupOperationContext lookupContext = new LookupOperationContext( session, moveContext.getDn(),
            SchemaConstants.ALL_ATTRIBUTES_ARRAY );
        Entry entry = session.getDirectoryService().getPartitionNexus().lookup( lookupContext );
        synchronizer.move( moveContext, entry, cascade );
        wrapped.move( moveContext );
        updateSchemaModificationAttributes( moveContext );
View Full Code Here

     */
    public void moveAndRename( MoveAndRenameOperationContext moveAndRenameContext ) throws LdapException
    {
        boolean cascade = moveAndRenameContext.hasRequestControl( Cascade.OID );
        CoreSession session = moveAndRenameContext.getSession();
        LookupOperationContext lookupContext = new LookupOperationContext( session, moveAndRenameContext.getDn(),
            SchemaConstants.ALL_ATTRIBUTES_ARRAY );
        Entry entry = session.getDirectoryService().getPartitionNexus().lookup( lookupContext );
        synchronizer.moveAndRename( moveAndRenameContext, entry, cascade );
        wrapped.moveAndRename( moveAndRenameContext );
        updateSchemaModificationAttributes( moveAndRenameContext );
View Full Code Here

            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

                // We're only adding the entry if the two DNs are equal
                if ( suffixDn.equals( contextEntryDn ) )
                {
                    // Looking for the current context entry
                    Entry suffixEntry = lookup( new LookupOperationContext( null, suffixDn ) );

                    // We're only adding the context entry if it doesn't already exist
                    if ( suffixEntry == null )
                    {
                        // Checking of the context entry is schema aware
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.