| java.lang.Object com.bostechcorp.cbesb.ui.ide.wizards.ResourceAndContainerGroup
ResourceAndContainerGroup | public class ResourceAndContainerGroup implements Listener(Code) | | Workbench-level composite for resource and container specification by the
user. Services such as field validation are performed by the group. The group
can be configured to accept existing resources, or only new resources.
|
Constructor Summary | |
public | ResourceAndContainerGroup(Composite parent, Listener client, String resourceFieldLabel, String resourceType) Create an instance of the group to allow the user to enter/select a
container and specify a resource name. | public | ResourceAndContainerGroup(Composite parent, Listener client, String resourceFieldLabel, String resourceType, boolean showClosedProjects) Create an instance of the group to allow the user to enter/select a
container and specify a resource name. | public | ResourceAndContainerGroup(Composite parent, Listener client, String resourceFieldLabel, String resourceType, boolean showClosedProjects, int heightHint) Create an instance of the group to allow the user to enter/select a
container and specify a resource name. |
Method Summary | |
public boolean | areAllValuesValid() Returns a boolean indicating whether all controls in this group contain
valid values. | protected void | createContents(Composite parent, String resourceLabelString, int heightHint) Creates this object's visual components. | public IPath | getContainerFullPath() Returns the path of the currently selected container or null if no
container has been selected. | public String | getProblemMessage() Returns an error message indicating the current problem with the value of
a control in the group, or an empty message if all controls in the group
contain valid values. | public int | getProblemType() Returns the type of problem with the value of a control in the group. | public String | getResource() Returns a string that is the path of the currently selected container. | public void | handleEvent(Event e) Handles events for all controls in the group. | public void | setAllowExistingResources(boolean value) Sets the flag indicating whether existing resources are permitted. | public void | setContainerFullPath(IPath path) Sets the value of this page's container. | public void | setFocus() | public void | setResource(String value, String prefix) Sets the value of this page's resource name. | protected boolean | validateContainer() Returns a boolean indicating whether a container name
represents a valid container resource in the workbench. | protected boolean | validateControls() Validates the values for each of the group's controls. | protected boolean | validateFullResourcePath(IPath resourcePath) Returns a boolean indicating whether the specified
resource path represents a valid new resource in the workbench. | protected boolean | validateResourceName() Returns a boolean indicating whether the resource name
rep- resents a valid resource name in the workbench. |
PROBLEM_CONTAINER_EMPTY | final public static int PROBLEM_CONTAINER_EMPTY(Code) | | |
PROBLEM_NAME_INVALID | final public static int PROBLEM_NAME_INVALID(Code) | | |
PROBLEM_NONE | final public static int PROBLEM_NONE(Code) | | |
PROBLEM_PATH_INVALID | final public static int PROBLEM_PATH_INVALID(Code) | | |
PROBLEM_PATH_OCCUPIED | final public static int PROBLEM_PATH_OCCUPIED(Code) | | |
PROBLEM_PROJECT_DOES_NOT_EXIST | final public static int PROBLEM_PROJECT_DOES_NOT_EXIST(Code) | | |
PROBLEM_RESOURCE_CONTAINS_SEPARATOR | final public static int PROBLEM_RESOURCE_CONTAINS_SEPARATOR(Code) | | |
PROBLEM_RESOURCE_EMPTY | final public static int PROBLEM_RESOURCE_EMPTY(Code) | | |
PROBLEM_RESOURCE_EXIST | final public static int PROBLEM_RESOURCE_EXIST(Code) | | |
ResourceAndContainerGroup | public ResourceAndContainerGroup(Composite parent, Listener client, String resourceFieldLabel, String resourceType)(Code) | | Create an instance of the group to allow the user to enter/select a
container and specify a resource name.
Parameters: parent - composite widget to parent the group Parameters: client - object interested in changes to the group's fields value Parameters: resourceFieldLabel - label to use in front of the resource name field Parameters: resourceType - one word, in lowercase, to describe the resource to the user(file, folder, project) |
ResourceAndContainerGroup | public ResourceAndContainerGroup(Composite parent, Listener client, String resourceFieldLabel, String resourceType, boolean showClosedProjects)(Code) | | Create an instance of the group to allow the user to enter/select a
container and specify a resource name.
Parameters: parent - composite widget to parent the group Parameters: client - object interested in changes to the group's fields value Parameters: resourceFieldLabel - label to use in front of the resource name field Parameters: resourceType - one word, in lowercase, to describe the resource to the user(file, folder, project) Parameters: showClosedProjects - whether or not to show closed projects |
ResourceAndContainerGroup | public ResourceAndContainerGroup(Composite parent, Listener client, String resourceFieldLabel, String resourceType, boolean showClosedProjects, int heightHint)(Code) | | Create an instance of the group to allow the user to enter/select a
container and specify a resource name.
Parameters: parent - composite widget to parent the group Parameters: client - object interested in changes to the group's fields value Parameters: resourceFieldLabel - label to use in front of the resource name field Parameters: resourceType - one word, in lowercase, to describe the resource to the user(file, folder, project) Parameters: showClosedProjects - whether or not to show closed projects Parameters: heightHint - height hint for the container selection widget group |
areAllValuesValid | public boolean areAllValuesValid()(Code) | | Returns a boolean indicating whether all controls in this group contain
valid values.
boolean |
createContents | protected void createContents(Composite parent, String resourceLabelString, int heightHint)(Code) | | Creates this object's visual components.
Parameters: parent - org.eclipse.swt.widgets.Composite Parameters: heightHint - height hint for the container selection widget group |
getContainerFullPath | public IPath getContainerFullPath()(Code) | | Returns the path of the currently selected container or null if no
container has been selected. Note that the container may not exist yet if
the user entered a new container name in the field.
|
getProblemMessage | public String getProblemMessage()(Code) | | Returns an error message indicating the current problem with the value of
a control in the group, or an empty message if all controls in the group
contain valid values.
java.lang.String |
getProblemType | public int getProblemType()(Code) | | Returns the type of problem with the value of a control in the group.
one of the PROBLEM_* constants |
getResource | public String getResource()(Code) | | Returns a string that is the path of the currently selected container.
Returns an empty string if no container has been selected.
|
handleEvent | public void handleEvent(Event e)(Code) | | Handles events for all controls in the group.
Parameters: e - org.eclipse.swt.widgets.Event |
setAllowExistingResources | public void setAllowExistingResources(boolean value)(Code) | | Sets the flag indicating whether existing resources are permitted.
|
setContainerFullPath | public void setContainerFullPath(IPath path)(Code) | | Sets the value of this page's container.
Parameters: path - Full path to the container. |
setFocus | public void setFocus()(Code) | | Gives focus to the resource name field and selects its contents
|
setResource | public void setResource(String value, String prefix)(Code) | | Sets the value of this page's resource name.
Parameters: value - new value |
validateContainer | protected boolean validateContainer()(Code) | | Returns a boolean indicating whether a container name
represents a valid container resource in the workbench. An error message
is stored for future reference if the name does not represent a valid
container.
boolean indicating validity of the container name |
validateControls | protected boolean validateControls()(Code) | | Validates the values for each of the group's controls. If an invalid
value is found then a descriptive error message is stored for later
reference. Returns a boolean indicating the validity of all of the
controls in the group.
|
validateFullResourcePath | protected boolean validateFullResourcePath(IPath resourcePath)(Code) | | Returns a boolean indicating whether the specified
resource path represents a valid new resource in the workbench. An error
message is stored for future reference if the path does not represent a
valid new resource path.
Parameters: resourcePath - the path to validate boolean indicating validity of the resource path |
validateResourceName | protected boolean validateResourceName()(Code) | | Returns a boolean indicating whether the resource name
rep- resents a valid resource name in the workbench. An error message is
stored for future reference if the name does not represent a valid
resource name.
boolean indicating validity of the resource name |
|
|