de.matthias_burbach.flux4eclipse.properties
Class FluxPropertyPage

java.lang.Object
  extended byorg.eclipse.jface.dialogs.DialogPage
      extended byorg.eclipse.jface.preference.PreferencePage
          extended byorg.eclipse.ui.dialogs.PropertyPage
              extended byde.matthias_burbach.flux4eclipse.properties.FluxPropertyPage
All Implemented Interfaces:
org.eclipse.jface.dialogs.IDialogPage, org.eclipse.jface.dialogs.IMessageProvider, org.eclipse.jface.preference.IPreferencePage, org.eclipse.ui.IWorkbenchPropertyPage

public class FluxPropertyPage
extends org.eclipse.ui.dialogs.PropertyPage

This class represents the Flux property page that is contributed to the context of the struts-config-*.xml files.

Author:
Matthias Burbach

Field Summary
static java.lang.String DEFAULT_FORM_NAME_DEFAULT
           
static java.lang.String DEFAULT_FORM_NAME_PROPERTY
           
private static java.lang.String DEFAULT_FORM_NAME_TITLE
           
static java.lang.String DEFAULT_PACKAGE_DEFAULT
           
static java.lang.String DEFAULT_PACKAGE_PROPERTY
           
private static java.lang.String DEFAULT_PACKAGE_TITLE
           
private  org.eclipse.swt.widgets.Text defaultFormText
           
private  org.eclipse.swt.widgets.Text defaultPackageText
           
static boolean GENERATE_PAGE_PREPROCESSINGS_DEFAULT
           
static java.lang.String GENERATE_PAGE_PREPROCESSINGS_PROPERTY
           
private static java.lang.String GENERATE_PAGE_PREPROCESSINGS_TITLE
           
private  org.eclipse.swt.widgets.Button generatePagePreprocessingsButton
           
static java.lang.String MODEL_FILE_DEFAULT
           
static java.lang.String MODEL_FILE_PROPERTY
           
private static java.lang.String MODEL_FILE_TITLE
           
private  org.eclipse.jface.preference.FileFieldEditor modelFileFieldEditor
           
static boolean OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_DEFAULT
           
static java.lang.String OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_PROPERTY
           
private static java.lang.String OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_TITLE
           
private  org.eclipse.swt.widgets.Button overrideGeneratePagePreprocessingsButton
           
private static java.lang.String PATH_TITLE
           
private static int TEXT_FIELD_WIDTH
           
 
Fields inherited from class org.eclipse.ui.dialogs.PropertyPage
 
Fields inherited from class org.eclipse.jface.preference.PreferencePage
 
Fields inherited from class org.eclipse.jface.dialogs.DialogPage
 
Fields inherited from interface org.eclipse.jface.dialogs.IMessageProvider
ERROR, INFORMATION, NONE, WARNING
 
Constructor Summary
FluxPropertyPage()
          Constructor for FluxPropertyPage.
 
Method Summary
private  void addFirstSection(org.eclipse.swt.widgets.Composite parent)
           
private  void addSecondSection(org.eclipse.swt.widgets.Composite parent)
           
private  void addSeparator(org.eclipse.swt.widgets.Composite parent)
           
private  java.lang.String booleanToString(boolean value)
           
private  org.eclipse.swt.widgets.Button createCheckBox(org.eclipse.swt.widgets.Composite composite, java.lang.String title, java.lang.String propertyName, boolean defaultValue)
           
protected  org.eclipse.swt.widgets.Control createContents(org.eclipse.swt.widgets.Composite parent)
           
private  org.eclipse.swt.widgets.Composite createDefaultComposite(org.eclipse.swt.widgets.Composite parent)
           
private  org.eclipse.jface.preference.FileFieldEditor createFileFieldEditor(org.eclipse.swt.widgets.Composite composite, java.lang.String name, java.lang.String title, java.lang.String propertyName, java.lang.String defaultValue)
           
private  org.eclipse.swt.widgets.Text createTextField(org.eclipse.swt.widgets.Composite composite, java.lang.String title, java.lang.String propertyName, java.lang.String defaultValue)
           
protected  void performDefaults()
          Populates the fields with their default values
 boolean performOk()
          Stores the values of the fields as persistent properties
private  boolean storePersistentProperty(org.eclipse.core.runtime.QualifiedName key, java.lang.String value)
           
 
Methods inherited from class org.eclipse.ui.dialogs.PropertyPage
getElement, setElement
 
Methods inherited from class org.eclipse.jface.preference.PreferencePage
computeSize, contributeButtons, createControl, createDescriptionLabel, createNoteComposite, doComputeSize, doGetPreferenceStore, getApplyButton, getContainer, getDefaultsButton, getPreferenceStore, isValid, noDefaultAndApplyButton, okToLeave, performApply, performCancel, performHelp, setContainer, setErrorMessage, setMessage, setPreferenceStore, setSize, setTitle, setValid, toString, updateApplyButton
 
Methods inherited from class org.eclipse.jface.dialogs.DialogPage
convertHeightInCharsToPixels, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, convertWidthInCharsToPixels, dispose, getControl, getDescription, getDialogFontName, getErrorMessage, getFont, getImage, getMessage, getMessageType, getShell, getTitle, getToolTipText, initializeDialogUnits, isControlCreated, setButtonLayoutData, setControl, setDescription, setImageDescriptor, setMessage, setVisible
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.eclipse.jface.preference.IPreferencePage
computeSize, isValid, okToLeave, performCancel, setContainer, setSize
 
Methods inherited from interface org.eclipse.jface.dialogs.IDialogPage
createControl, dispose, getControl, getDescription, getErrorMessage, getImage, getMessage, getTitle, performHelp, setDescription, setImageDescriptor, setTitle, setVisible
 

Field Detail

PATH_TITLE

private static final java.lang.String PATH_TITLE
See Also:
Constant Field Values

MODEL_FILE_TITLE

private static final java.lang.String MODEL_FILE_TITLE
See Also:
Constant Field Values

MODEL_FILE_PROPERTY

public static final java.lang.String MODEL_FILE_PROPERTY
See Also:
Constant Field Values

MODEL_FILE_DEFAULT

public static final java.lang.String MODEL_FILE_DEFAULT
See Also:
Constant Field Values

DEFAULT_FORM_NAME_TITLE

private static final java.lang.String DEFAULT_FORM_NAME_TITLE
See Also:
Constant Field Values

DEFAULT_FORM_NAME_PROPERTY

public static final java.lang.String DEFAULT_FORM_NAME_PROPERTY
See Also:
Constant Field Values

DEFAULT_FORM_NAME_DEFAULT

public static final java.lang.String DEFAULT_FORM_NAME_DEFAULT
See Also:
Constant Field Values

DEFAULT_PACKAGE_TITLE

private static final java.lang.String DEFAULT_PACKAGE_TITLE
See Also:
Constant Field Values

DEFAULT_PACKAGE_PROPERTY

public static final java.lang.String DEFAULT_PACKAGE_PROPERTY
See Also:
Constant Field Values

DEFAULT_PACKAGE_DEFAULT

public static final java.lang.String DEFAULT_PACKAGE_DEFAULT
See Also:
Constant Field Values

OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_TITLE

private static final java.lang.String OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_TITLE
See Also:
Constant Field Values

OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_PROPERTY

public static final java.lang.String OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_PROPERTY
See Also:
Constant Field Values

OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_DEFAULT

public static final boolean OVERRIDE_GENERATE_PAGE_PREPROCESSINGS_DEFAULT
See Also:
Constant Field Values

GENERATE_PAGE_PREPROCESSINGS_TITLE

private static final java.lang.String GENERATE_PAGE_PREPROCESSINGS_TITLE
See Also:
Constant Field Values

GENERATE_PAGE_PREPROCESSINGS_PROPERTY

public static final java.lang.String GENERATE_PAGE_PREPROCESSINGS_PROPERTY
See Also:
Constant Field Values

GENERATE_PAGE_PREPROCESSINGS_DEFAULT

public static final boolean GENERATE_PAGE_PREPROCESSINGS_DEFAULT
See Also:
Constant Field Values

TEXT_FIELD_WIDTH

private static final int TEXT_FIELD_WIDTH
See Also:
Constant Field Values

modelFileFieldEditor

private org.eclipse.jface.preference.FileFieldEditor modelFileFieldEditor

defaultFormText

private org.eclipse.swt.widgets.Text defaultFormText

defaultPackageText

private org.eclipse.swt.widgets.Text defaultPackageText

overrideGeneratePagePreprocessingsButton

private org.eclipse.swt.widgets.Button overrideGeneratePagePreprocessingsButton

generatePagePreprocessingsButton

private org.eclipse.swt.widgets.Button generatePagePreprocessingsButton
Constructor Detail

FluxPropertyPage

public FluxPropertyPage()
Constructor for FluxPropertyPage.

Method Detail

addFirstSection

private void addFirstSection(org.eclipse.swt.widgets.Composite parent)

addSeparator

private void addSeparator(org.eclipse.swt.widgets.Composite parent)

addSecondSection

private void addSecondSection(org.eclipse.swt.widgets.Composite parent)

createCheckBox

private org.eclipse.swt.widgets.Button createCheckBox(org.eclipse.swt.widgets.Composite composite,
                                                      java.lang.String title,
                                                      java.lang.String propertyName,
                                                      boolean defaultValue)

createFileFieldEditor

private org.eclipse.jface.preference.FileFieldEditor createFileFieldEditor(org.eclipse.swt.widgets.Composite composite,
                                                                           java.lang.String name,
                                                                           java.lang.String title,
                                                                           java.lang.String propertyName,
                                                                           java.lang.String defaultValue)

createTextField

private org.eclipse.swt.widgets.Text createTextField(org.eclipse.swt.widgets.Composite composite,
                                                     java.lang.String title,
                                                     java.lang.String propertyName,
                                                     java.lang.String defaultValue)

createContents

protected org.eclipse.swt.widgets.Control createContents(org.eclipse.swt.widgets.Composite parent)
See Also:
PreferencePage#createContents(Composite)

createDefaultComposite

private org.eclipse.swt.widgets.Composite createDefaultComposite(org.eclipse.swt.widgets.Composite parent)

performDefaults

protected void performDefaults()
Populates the fields with their default values


performOk

public boolean performOk()
Stores the values of the fields as persistent properties


storePersistentProperty

private boolean storePersistentProperty(org.eclipse.core.runtime.QualifiedName key,
                                        java.lang.String value)

booleanToString

private java.lang.String booleanToString(boolean value)