Package org.apache.directory.studio.apacheds.configuration.model.v155

Examples of org.apache.directory.studio.apacheds.configuration.model.v155.ServerXmlIOV155


            public void widgetSelected( SelectionEvent e )
            {
                ExtendedOperationDialog dialog = new ExtendedOperationDialog( extendedOperations );
                if ( Dialog.OK == dialog.open() )
                {
                    ExtendedOperationEnum newExtendedOperation = dialog.getExtendedOperation();
                    extendedOperations.add( newExtendedOperation );
                    viewer.refresh();
                    viewer.setSelection( new StructuredSelection( newExtendedOperation ) );
                    setEditorDirty();
                }
            }
        } );

        deleteButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    ExtendedOperationEnum extendedOperation = ( ExtendedOperationEnum ) selection.getFirstElement();

                    extendedOperations.remove( extendedOperation );
                    viewer.refresh();
                    setEditorDirty();
                }
View Full Code Here


            public void widgetSelected( SelectionEvent e )
            {
                ExtendedOperationDialog dialog = new ExtendedOperationDialog( extendedOperations );
                if ( Dialog.OK == dialog.open() )
                {
                    ExtendedOperationEnum newExtendedOperation = dialog.getExtendedOperation();
                    extendedOperations.add( newExtendedOperation );
                    viewer.refresh();
                    viewer.setSelection( new StructuredSelection( newExtendedOperation ) );
                    setEditorDirty();
                }
            }
        } );

        deleteButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    ExtendedOperationEnum extendedOperation = ( ExtendedOperationEnum ) selection.getFirstElement();

                    extendedOperations.remove( extendedOperation );
                    viewer.refresh();
                    setEditorDirty();
                }
View Full Code Here

    private void editSelectedIndexedAttribute()
    {
        StructuredSelection selection = ( StructuredSelection ) indexedAttributesTableViewer.getSelection();
        if ( !selection.isEmpty() )
        {
            IndexedAttribute indexedAttribute = ( IndexedAttribute ) selection.getFirstElement();

            IndexedAttributeDialog dialog = new IndexedAttributeDialog( indexedAttribute );
            if ( Dialog.OK == dialog.open() && dialog.isDirty() )
            {
                indexedAttributesTableViewer.refresh();
View Full Code Here

                // Default values
                newPartition.setCacheSize( 100 );
                newPartition.setEnableOptimizer( true );
                newPartition.setSynchronizationOnWrite( true );
                List<IndexedAttribute> indexedAttributes = new ArrayList<IndexedAttribute>();
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.1", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.2", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.3", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.4", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.5", 10 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.6", 10 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.7", 10 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "dc", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "ou", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "krb5PrincipalName", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "uid", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "objectClass", 100 ) ); //$NON-NLS-1$
                newPartition.setIndexedAttributes( indexedAttributes );

                partitions.add( newPartition );
                viewer.refresh();
                viewer.setSelection( new StructuredSelection( newPartition ) );
View Full Code Here

    private void editSelectedIndexedAttribute()
    {
        StructuredSelection selection = ( StructuredSelection ) indexedAttributesTableViewer.getSelection();
        if ( !selection.isEmpty() )
        {
            IndexedAttribute indexedAttribute = ( IndexedAttribute ) selection.getFirstElement();

            IndexedAttributeDialog dialog = new IndexedAttributeDialog( indexedAttribute );
            if ( Dialog.OK == dialog.open() && dialog.isDirty() )
            {
                indexedAttributesTableViewer.refresh();
View Full Code Here

                // Default values
                newPartition.setCacheSize( 100 );
                newPartition.setEnableOptimizer( true );
                newPartition.setSynchronizationOnWrite( true );
                List<IndexedAttribute> indexedAttributes = new ArrayList<IndexedAttribute>();
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.1", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.2", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.3", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.4", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.5", 10 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.6", 10 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "1.3.6.1.4.1.18060.0.4.1.2.7", 10 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "dc", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "ou", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "krb5PrincipalName", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "uid", 100 ) ); //$NON-NLS-1$
                indexedAttributes.add( new IndexedAttribute( "objectClass", 100 ) ); //$NON-NLS-1$
                newPartition.setIndexedAttributes( indexedAttributes );

                partitions.add( newPartition );
                viewer.refresh();
                viewer.setSelection( new StructuredSelection( newPartition ) );
View Full Code Here

            public void widgetSelected( SelectionEvent e )
            {
                InterceptorDialog dialog = new InterceptorDialog( interceptors );
                if ( Dialog.OK == dialog.open() )
                {
                    InterceptorEnum newInterceptor = dialog.getInterceptor();
                    interceptors.add( newInterceptor );
                    viewer.refresh();
                    viewer.setSelection( new StructuredSelection( newInterceptor ) );
                    setEditorDirty();
                }
            }
        } );

        deleteButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();
                    interceptors.remove( interceptor );
                    viewer.refresh();
                    setEditorDirty();
                }
            }
        } );

        upButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();

                    int index = interceptors.indexOf( interceptor );
                    if ( index > 0 )
                    {
                        InterceptorEnum interceptorBefore = interceptors.get( index - 1 );
                        if ( interceptorBefore != null )
                        {
                            interceptors.set( index - 1, interceptor );
                            interceptors.set( index, interceptorBefore );
                            viewer.refresh();
                            setEditorDirty();
                            enableDisableUpDownButtons();
                        }
                    }
                }
            }
        } );

        downButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();

                    int index = interceptors.indexOf( interceptor );
                    if ( index < ( interceptors.size() - 1 ) )
                    {
                        InterceptorEnum interceptorAfter = interceptors.get( index + 1 );
                        if ( interceptorAfter != null )
                        {
                            interceptors.set( index + 1, interceptor );
                            interceptors.set( index, interceptorAfter );
View Full Code Here

        upButton.setEnabled( !selection.isEmpty() );
        downButton.setEnabled( !selection.isEmpty() );
        if ( !selection.isEmpty() )
        {
            InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();
            upButton.setEnabled( interceptors.indexOf( interceptor ) != 0 );
            downButton.setEnabled( interceptors.indexOf( interceptor ) != ( interceptors.size() - 1 ) );
        }
    }
View Full Code Here

            public void widgetSelected( SelectionEvent e )
            {
                InterceptorDialog dialog = new InterceptorDialog( interceptors );
                if ( Dialog.OK == dialog.open() )
                {
                    InterceptorEnum newInterceptor = dialog.getInterceptor();
                    interceptors.add( newInterceptor );
                    viewer.refresh();
                    viewer.setSelection( new StructuredSelection( newInterceptor ) );
                    setEditorDirty();
                }
            }
        } );

        deleteButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();
                    interceptors.remove( interceptor );
                    viewer.refresh();
                    setEditorDirty();
                }
            }
        } );

        upButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();

                    int index = interceptors.indexOf( interceptor );
                    if ( index > 0 )
                    {
                        InterceptorEnum interceptorBefore = interceptors.get( index - 1 );
                        if ( interceptorBefore != null )
                        {
                            interceptors.set( index - 1, interceptor );
                            interceptors.set( index, interceptorBefore );
                            viewer.refresh();
                            setEditorDirty();
                            enableDisableUpDownButtons();
                        }
                    }
                }
            }
        } );

        downButton.addSelectionListener( new SelectionAdapter()
        {
            public void widgetSelected( SelectionEvent e )
            {
                StructuredSelection selection = ( StructuredSelection ) viewer.getSelection();
                if ( !selection.isEmpty() )
                {
                    InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();

                    int index = interceptors.indexOf( interceptor );
                    if ( index < ( interceptors.size() - 1 ) )
                    {
                        InterceptorEnum interceptorAfter = interceptors.get( index + 1 );
                        if ( interceptorAfter != null )
                        {
                            interceptors.set( index + 1, interceptor );
                            interceptors.set( index, interceptorAfter );
View Full Code Here

        upButton.setEnabled( !selection.isEmpty() );
        downButton.setEnabled( !selection.isEmpty() );
        if ( !selection.isEmpty() )
        {
            InterceptorEnum interceptor = ( InterceptorEnum ) selection.getFirstElement();
            upButton.setEnabled( interceptors.indexOf( interceptor ) != 0 );
            downButton.setEnabled( interceptors.indexOf( interceptor ) != ( interceptors.size() - 1 ) );
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.directory.studio.apacheds.configuration.model.v155.ServerXmlIOV155

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.