Package org.apache.directory.shared.ldap.model.message

Examples of org.apache.directory.shared.ldap.model.message.SearchResultEntryImpl.addControl()


            if ( pushInRealTime )
            {
                SearchResultEntry resultEntry = new SearchResultEntryImpl( searchRequest.getMessageId() );
                resultEntry.setObjectName( moveContext.getDn() );
                resultEntry.setEntry( entry );
                resultEntry.addControl( modDnControl );

                SyncStateValue syncModify = createControl( directoryService, SyncStateTypeEnum.MODDN, entry );

                sendResult( resultEntry, entry, null, syncModify, modDnControl );
            }
View Full Code Here


            if ( pushInRealTime )
            {
                SearchResultEntry resultEntry = new SearchResultEntryImpl( searchRequest.getMessageId() );
                resultEntry.setObjectName( entry.getDn() );
                resultEntry.setEntry( entry );
                resultEntry.addControl( modDnControl );

                SyncStateValue syncModify = createControl( directoryService, SyncStateTypeEnum.MODDN, entry );

                sendResult( resultEntry, entry, null, syncModify, modDnControl );
            }
View Full Code Here

            if ( pushInRealTime )
            {
                SearchResultEntry resultEntry = new SearchResultEntryImpl( searchRequest.getMessageId() );
                resultEntry.setObjectName( entry.getDn() );
                resultEntry.setEntry( entry );
                resultEntry.addControl( modDnControl );

                SyncStateValue syncModify = createControl( directoryService, SyncStateTypeEnum.MODDN, entry );
               
                // In this case, the cookie is different
                syncModify.setCookie( getCookie( entry ) );
View Full Code Here

                    session.getLdapServer().getDirectoryService().getLdapCodecService() );
                syncAdd.setSyncStateType( SyncStateTypeEnum.ADD );
                syncAdd
                    .setEntryUUID( Strings.uuidToBytes(entry.get(SchemaConstants.ENTRY_UUID_AT).getString()) );
                syncAdd.setCookie( getCookie( entry ) );
                respEntry.addControl( syncAdd );

                WriteFuture future = session.getIoSession().write( respEntry );
                handleWriteFuture( future, entry, EventType.ADD, null );
            }
            else
View Full Code Here

                    session.getLdapServer().getDirectoryService().getLdapCodecService() );
                syncDelete.setSyncStateType( SyncStateTypeEnum.DELETE );
                syncDelete.setEntryUUID( Strings.uuidToBytes(entry.get(SchemaConstants.ENTRY_UUID_AT)
                        .getString()) );
                syncDelete.setCookie( getCookie( entry ) );
                respEntry.addControl( syncDelete );

                WriteFuture future = session.getIoSession().write( respEntry );

                handleWriteFuture( future, entry, EventType.DELETE, null );
            }
View Full Code Here

                    session.getLdapServer().getDirectoryService().getLdapCodecService() );
                syncModify.setSyncStateType( SyncStateTypeEnum.MODIFY );
                syncModify.setEntryUUID( Strings.uuidToBytes(alteredEntry.get(SchemaConstants.ENTRY_UUID_AT)
                        .getString()) );
                syncModify.setCookie( getCookie( alteredEntry ) );
                respEntry.addControl( syncModify );

                WriteFuture future = session.getIoSession().write( respEntry );

                // store altered entry cause that holds the updated CSN
                handleWriteFuture( future, alteredEntry, EventType.MODIFY, null );
View Full Code Here

                    session.getLdapServer().getDirectoryService().getLdapCodecService() );
                syncModify.setSyncStateType( SyncStateTypeEnum.MODDN );
                syncModify.setEntryUUID( Strings.uuidToBytes(entry.get(SchemaConstants.ENTRY_UUID_AT)
                        .getString()) );
                syncModify.setCookie( getCookie( entry ) );
                respEntry.addControl( syncModify );
                respEntry.addControl( modDnControl );

                WriteFuture future = session.getIoSession().write( respEntry );

                handleWriteFuture( future, entry, null, modDnControl );
View Full Code Here

                syncModify.setSyncStateType( SyncStateTypeEnum.MODDN );
                syncModify.setEntryUUID( Strings.uuidToBytes(entry.get(SchemaConstants.ENTRY_UUID_AT)
                        .getString()) );
                syncModify.setCookie( getCookie( entry ) );
                respEntry.addControl( syncModify );
                respEntry.addControl( modDnControl );

                WriteFuture future = session.getIoSession().write( respEntry );

                handleWriteFuture( future, entry, null, modDnControl );
            }
View Full Code Here

                    session.getLdapServer().getDirectoryService().getLdapCodecService() );
                syncModify.setSyncStateType( SyncStateTypeEnum.MODDN );
                syncModify.setEntryUUID( Strings.uuidToBytes(alteredEntry.get(SchemaConstants.ENTRY_UUID_AT)
                        .getString()) );
                syncModify.setCookie( getCookie( alteredEntry ) );
                respEntry.addControl( syncModify );
                respEntry.addControl( modDnControl );

                WriteFuture future = session.getIoSession().write( respEntry );

                handleWriteFuture( future, alteredEntry, null, modDnControl );
View Full Code Here

                syncModify.setSyncStateType( SyncStateTypeEnum.MODDN );
                syncModify.setEntryUUID( Strings.uuidToBytes(alteredEntry.get(SchemaConstants.ENTRY_UUID_AT)
                        .getString()) );
                syncModify.setCookie( getCookie( alteredEntry ) );
                respEntry.addControl( syncModify );
                respEntry.addControl( modDnControl );

                WriteFuture future = session.getIoSession().write( respEntry );

                handleWriteFuture( future, alteredEntry, null, modDnControl );
            }
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.