public void createClient()

in plugins/org.apache.geronimo.st.v30.ui/src/main/java/org/apache/geronimo/st/v30/ui/sections/SecurityAdvancedSection.java [80:223]


    public void createClient() {
        Section section = getSection();
        section.setText(getTitle());
        section.setDescription(getDescription());
        section.setLayoutData(new GridData(SWT.FILL, SWT.FILL, false, false));
        Composite clientComposite = createComposite(getSection(), 3);
        section.setClient(clientComposite);

        Composite composite1 = createComposite(clientComposite, 2);
        composite1.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, false, 3, 1));

        doAsCurrentCaller = toolkit.createButton(composite1, CommonMessages.securityDoasCurrentCaller,
                SWT.CHECK);
        doAsCurrentCaller.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false, 1, 1));
        doAsCurrentCaller.addSelectionListener(new SelectionAdapter() {
            public void widgetSelected(SelectionEvent e) {
                setDoAsCurrentCaller();
                markDirty();
            }
        });
        doAsCurrentCaller.setSelection(isDoasCurrentCaller());

        useContextHandler = toolkit.createButton(composite1, CommonMessages.securityUseContextHandler,
                SWT.CHECK);
        useContextHandler.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false, 1, 1));
        useContextHandler.addSelectionListener(new SelectionAdapter() {
            public void widgetSelected(SelectionEvent e) {
                setUseContextHandler();
                markDirty();
            }
        });
        useContextHandler.setSelection(isUseContextHandler());

        createLabel(clientComposite, CommonMessages.securityCredentialStore);
        credentialStoreRef = new Combo(clientComposite, SWT.READ_ONLY| SWT.BORDER);
   //   credentialStoreRef.setText("<credential store ref name will go here>");
        GridData gridData = new GridData(SWT.FILL, SWT.CENTER, false, false);
        gridData.widthHint = 300;
        credentialStoreRef.setLayoutData(gridData);
        populateCredentialStores();
        credentialStoreRef.addSelectionListener(new SelectionAdapter(){

            public void widgetSelected(SelectionEvent arg0) {
                setCredentialStoreRef();
                populateDefaultSubjectRealmName();
                populateDefaultSubjectId();
                toggleAdvancedSettings();
                markDirty();
            }
            
        });

        Composite composite2 = toolkit.createComposite(clientComposite);
        GridLayout layout = new GridLayout();
        layout.numColumns = 2;
        layout.marginHeight = 5;
        layout.marginWidth = 0;
        layout.verticalSpacing = 5;
        layout.horizontalSpacing = 5;
        composite2.setLayout(layout);
        composite2.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, false));
    /*    specifyCredentialStoreRefButton = toolkit.createButton(composite2, CommonMessages.edit, SWT.NONE);
        specifyCredentialStoreRefButton.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false));
        specifyCredentialStoreRefButton.addSelectionListener(new SelectionAdapter() {
            @Override
            public void widgetSelected(SelectionEvent e) {
                Wizard wizard = getCredentialStoreRefWizard();
                WizardDialog dialog = new WizardDialog(Display.getCurrent().getActiveShell(), wizard);
                dialog.open();
                if (dialog.getReturnCode() == Dialog.OK) {
                    setCredentialStoreRef();
                    toggleAdvancedSettings();
                    markDirty();
                }
            }
        });
        deleteCredentialStoreRefButton = toolkit.createButton(composite2, CommonMessages.remove, SWT.NONE);
        deleteCredentialStoreRefButton.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, false, false));
        deleteCredentialStoreRefButton.addSelectionListener(new SelectionAdapter(){
            @Override
            public void widgetSelected(SelectionEvent e) {
            }
        });*/

        createLabel(clientComposite, CommonMessages.securityDefaultSubject);
        createLabel(clientComposite, "");
        createLabel(clientComposite, "");
        //group = createGroup(clientComposite, CommonMessages.securityDefaultSubject);

        //createLabel(clientComposite, "");
        //Composite composite3 = createComposite(clientComposite, 2);
        //composite3.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, false, 2, 1));
        createLabel(clientComposite, CommonMessages.securityDefaultSubjectRealmName).setLayoutData(
                new GridData(SWT.RIGHT, SWT.CENTER, false, false));
        defaultSubjectRealmName = new Combo(clientComposite, SWT.SINGLE | SWT.DROP_DOWN |SWT.READ_ONLY);
        populateDefaultSubjectRealmName();
        gridData = new GridData(SWT.LEFT, SWT.CENTER, false, false, 2, 1);
        gridData.widthHint = 100;
        defaultSubjectRealmName.setLayoutData(gridData);
        defaultSubjectRealmName.addSelectionListener(new SelectionAdapter() {
            public void widgetSelected(SelectionEvent arg0) {
                populateDefaultSubjectId();
                markDirty();
            }
        });
        defaultSubjectRealmName.pack();

        //createLabel(clientComposite, "");
        //Composite composite4 = createComposite(clientComposite, 2);
        //composite4.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, false, 2, 1));
        createLabel(clientComposite, CommonMessages.securityDefaultSubjectId).setLayoutData(
                new GridData(SWT.RIGHT, SWT.CENTER, false, false));
        defaultSubjectId = new Combo(clientComposite, SWT.SINGLE | SWT.DROP_DOWN |SWT.READ_ONLY);
        defaultSubjectId.add(getDefaultSubjectId());
        gridData = new GridData(SWT.LEFT, SWT.CENTER, false, false, 2, 1);
        gridData.widthHint = 100;
        defaultSubjectId.setLayoutData(gridData);
        populateDefaultSubjectId();
        defaultSubjectId.addSelectionListener(new SelectionAdapter() {
            public void widgetSelected(SelectionEvent arg0) {
                setDefaultSubject();
                markDirty();
            }
        });
        defaultSubjectId.pack();

        //group = createGroup(clientComposite, CommonMessages.securityRunAsSubjects);
        createLabel(clientComposite, "").setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, false, 3, 1));
        createLabel(clientComposite, CommonMessages.securityRunAsSubjects).setLayoutData(
                new GridData(SWT.LEFT, SWT.TOP, false, false));
        createViewer(clientComposite);
        viewer.setContentProvider(getContentProvider());
        viewer.setLabelProvider(getLabelProvider());
        viewer.setInput(getInput());

        Composite buttonComposite = createButtonComposite(clientComposite);
        createAddButton(buttonComposite);
        createRemoveButton(buttonComposite);
        createEditButton(buttonComposite);
        activateButtons();

        section.setExpanded(false);
        toggleAdvancedSettings();
    }