|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.google.gwt.user.client.ui.UIObject
com.google.gwt.user.client.ui.Widget
com.google.gwt.user.client.ui.Composite
GWTApplication.client.FaultDBForm
class FaultDBForm
This is a base class which supports the forms which are to be displayed by the application. Most of the forms in the application subclass this class.
Field Summary | |
---|---|
protected BusyIndicator |
busyIndicator
This is a panel which will be used to indicate to the user that we are busy at the moment doing something |
private static java.util.ArrayList |
CurrentInstrumentList
This is the list of current instruments which can be selected |
private static java.util.ArrayList |
DEList
This is a list static list of the DEs. |
private static java.util.ArrayList |
FaultStateList
This is the list of fault states |
private static java.util.ArrayList |
FaultTypeList
This is the list of faults |
private static java.util.ArrayList |
FullDEList
This is a list static list of the DEs. |
private static java.util.ArrayList |
FullSAList
This is a list static list of the SAs. |
private static java.util.ArrayList |
FullStaffMemberList
This is a list static list of the staff. |
private static java.util.ArrayList |
FullTOList
This is a list static list of the TOs. |
private static java.util.ArrayList |
InstrumentList
This is the list of all instruments which can be selected |
protected InternationalizationConstants |
internationalizationConstants
This class will be used for internationalization so that we can flick between the locales of English and Spanish. |
static int |
NOLENGTHCHECK
Indicates that we should not check the length of the string |
protected static java.util.ArrayList |
PrinterList
Holds a list of the printers that the servlet knows about. |
private static java.util.ArrayList |
SAList
This is a list static list of the SAs. |
private static java.util.ArrayList |
SeverityList
This is the list of severities |
private static java.util.ArrayList |
SiteList
This is the list of sites which can be selected |
private static java.util.ArrayList |
StaffMemberList
This is a list of all of the staff members |
protected FaultServiceAsync |
svc
This is the service which will be used to access the servlet which is running in the tomcat container |
private static java.util.ArrayList |
SystemList
This is the list of systems which can be selected |
private static java.util.ArrayList |
TOList
This is a list static list of the TOs. |
protected AuthenticationDetails |
UserAuthentication
This is the user authentication details which were provided by the user |
Constructor Summary | |
---|---|
FaultDBForm()
|
Method Summary | |
---|---|
private void |
createDropDownList(java.util.ArrayList staffList,
java.lang.String defaultUser,
com.google.gwt.user.client.ui.ListBox listBox)
Adds the names of the people into the list provided. |
static java.lang.String |
createEmailLink(java.lang.String emailAddress,
int faultId,
java.lang.String faultTitle,
java.lang.String linkText)
This method will be used to return a HTML which can be clicked on to create an email. |
protected void |
fillListBoxWithCurrentInstruments(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String CurrentLocale)
Gets a list of only the current instruments (not decommissioned) from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithDutyTechnicians(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String defaultUser,
boolean IncludeStaffWhichHaveLeft)
Gets a list of the duty technician from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithFaultType(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String CurrentLocale)
Gets a list of the fault types from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithInstruments(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String CurrentLocale)
Gets a list of the all instruments from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithSeverity(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String CurrentLocale)
Gets a list of the severities from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithSites(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String CurrentLocale)
Gets a list of the sites from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithStaffMembers(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String defaultUser,
boolean IncludeStaffWhichHaveLeft)
Gets a list of the staff members from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithStates(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String CurrentLocale)
Gets a list of the fault states from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithSupportAstronomers(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String defaultUser,
boolean IncludeStaffWhichHaveLeft)
Gets a list of the support astronomer from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
protected void |
fillListBoxWithSystems(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String CurrentLocale)
Gets a list of the systems from the tomcat faultdb servlet and initialises the list box which was provided by the caller. |
(package private) void |
fillListBoxWithTelescopeOperators(com.google.gwt.user.client.ui.ListBox listBox,
java.lang.String defaultUser,
boolean IncludeStaffWhichHaveLeft)
Gets a list of the telescope operators from the tomcat faultdb servlet and initialises the list of the telescope operators in the list box which was provided by the caller. |
protected java.lang.String |
getCurrentDate()
Get current date in the format DD/MM/YYYY and return it to the caller. |
protected java.lang.String |
getCurrentTime()
Get current time in the format HH:MM and return it to the caller |
protected java.lang.String |
getFullUserNameFromEmailAddress(java.lang.String emailAddress)
Take an email address and return the full name of the person. |
void |
selectDefaultListOption(java.lang.String KeyValue,
com.google.gwt.user.client.ui.ListBox TargetList)
Called to set the default option in a list box widget. |
protected boolean |
setSelectedItemInListbox(com.google.gwt.user.client.ui.ListBox list,
java.lang.String value)
This method will be used to set the selected value in the listbox specified to the value which has been provided by the caller. |
protected boolean |
stringContainsText(java.lang.String stringToCheck)
Check to see if the string which has been specified is actually empty after being stripped of HTML markup and symbols. |
protected boolean |
verifyDateFormat(java.lang.String DateToVerify)
Used to verify that a field which represents the date has been entered in the correct format of DD/MM/YYYY |
protected boolean |
verifyDateNotInFuture(java.lang.String DateToTest)
Verify that the date that has been specified is not after the current date |
protected boolean |
verifyText(java.lang.String FieldName,
int MaxLength,
java.lang.String TextToVerify)
This will verify that the text field is not empty or too full to fit in the database. |
protected boolean |
verifyTimeFormat(java.lang.String TimeToVerify)
Used to verify that a field which represents the time has been entered in the correct format of HH:MM in 24 hour clock |
Methods inherited from class com.google.gwt.user.client.ui.Composite |
---|
getElement, getWidget, initWidget, isAttached, onAttach, onDetach, setWidget |
Methods inherited from class com.google.gwt.user.client.ui.Widget |
---|
doAttachChildren, doDetachChildren, getParent, onBrowserEvent, onLoad, onUnload, removeFromParent, setElement |
Methods inherited from class com.google.gwt.user.client.ui.UIObject |
---|
addStyleDependentName, addStyleName, getAbsoluteLeft, getAbsoluteTop, getOffsetHeight, getOffsetWidth, getStyleElement, getStyleName, getStyleName, getStylePrimaryName, getStylePrimaryName, getTitle, isVisible, isVisible, removeStyleDependentName, removeStyleName, setHeight, setPixelSize, setSize, setStyleName, setStyleName, setStyleName, setStylePrimaryName, setStylePrimaryName, setTitle, setVisible, setVisible, setWidth, sinkEvents, toString, unsinkEvents |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected BusyIndicator busyIndicator
public static final int NOLENGTHCHECK
private static java.util.ArrayList FaultStateList
private static java.util.ArrayList FaultTypeList
private static java.util.ArrayList StaffMemberList
private static java.util.ArrayList SeverityList
private static java.util.ArrayList SystemList
private static java.util.ArrayList InstrumentList
private static java.util.ArrayList CurrentInstrumentList
private static java.util.ArrayList SiteList
private static java.util.ArrayList TOList
private static java.util.ArrayList SAList
private static java.util.ArrayList DEList
private static java.util.ArrayList FullTOList
private static java.util.ArrayList FullSAList
private static java.util.ArrayList FullDEList
private static java.util.ArrayList FullStaffMemberList
protected AuthenticationDetails UserAuthentication
protected InternationalizationConstants internationalizationConstants
protected FaultServiceAsync svc
protected static java.util.ArrayList PrinterList
Constructor Detail |
---|
FaultDBForm()
Method Detail |
---|
void fillListBoxWithTelescopeOperators(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String defaultUser, boolean IncludeStaffWhichHaveLeft)
listBox
- This is the listbox widget which is to have it's list populateddefaultUser
- This is the default value in the list to be
selected.IncludeStaffWhichHaveLeft
- Include all of the staff in
this group which have left the organisation. =protected void fillListBoxWithSupportAstronomers(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String defaultUser, boolean IncludeStaffWhichHaveLeft)
listBox
- This is the listbox widget which is to have it's list populateddefaultUser
- This is the default value in the list to be
selected.IncludeStaffWhichHaveLeft
- Whether to include staff that
have already left the ING in the listprivate void createDropDownList(java.util.ArrayList staffList, java.lang.String defaultUser, com.google.gwt.user.client.ui.ListBox listBox)
staffList
- An array of type person which is to be
included in the list.defaultUser
- This is the default value in the list to belistBox
- This is the listbox widget which is to have it's list populatedprotected void fillListBoxWithDutyTechnicians(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String defaultUser, boolean IncludeStaffWhichHaveLeft)
listBox
- This is the listbox widget which is to have it's list populateddefaultUser
- This is the default value in the list to be
selected.IncludeStaffWhichHaveLeft
- Include all of the staff in
this group which have left the organisation.public void selectDefaultListOption(java.lang.String KeyValue, com.google.gwt.user.client.ui.ListBox TargetList)
KeyValue
- This is the option which is to be selectedTargetList
- This is the list in which the option is to be
selectedprotected void fillListBoxWithStaffMembers(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String defaultUser, boolean IncludeStaffWhichHaveLeft)
listBox
- This is the listbox widget which is to have it's
list populateddefaultUser
- This is the default value in the list to be
selected.IncludeStaffWhichHaveLeft
- Include all of the staff in
this group which have left the organisation.protected void fillListBoxWithInstruments(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String CurrentLocale)
listBox
- This is the listbox widget which is to have it's list populatedprotected void fillListBoxWithCurrentInstruments(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String CurrentLocale)
listBox
- This is the listbox widget which is to have it's list populatedprotected void fillListBoxWithSites(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String CurrentLocale)
listBox
- This is the listbox widget which is to have it's
list populatedprotected void fillListBoxWithSystems(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String CurrentLocale)
listBox
- This is the listbox widget which is to have it's
list populatedprotected void fillListBoxWithSeverity(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String CurrentLocale)
listBox
- This is the listbox widget which is to have it's
list populatedprotected boolean verifyTimeFormat(java.lang.String TimeToVerify)
TimeToVerify
- This is a string which contains the time
which is to be verified
protected boolean verifyDateNotInFuture(java.lang.String DateToTest)
DateToTest
- This is the date to test specified in the
format DD/MM/YYYY
protected boolean verifyDateFormat(java.lang.String DateToVerify)
DateToVerify
- This is a string which contains the time
which is to be verified
protected java.lang.String getCurrentDate()
protected java.lang.String getCurrentTime()
protected void fillListBoxWithFaultType(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String CurrentLocale)
listBox
- This is the listbox widget which is to have it's
list populatedprotected void fillListBoxWithStates(com.google.gwt.user.client.ui.ListBox listBox, java.lang.String CurrentLocale)
listBox
- This is the listbox widget which is to have it's
list populatedprotected boolean setSelectedItemInListbox(com.google.gwt.user.client.ui.ListBox list, java.lang.String value)
list
- This is the list widget which contains the value which is to be selected.value
- This is the value which is to be selected in the list.
protected boolean stringContainsText(java.lang.String stringToCheck)
stringToCheck
- This is the string to be checked
protected boolean verifyText(java.lang.String FieldName, int MaxLength, java.lang.String TextToVerify) throws FieldInvalidException
FieldName
- This is the name of the fieldMaxLength
- This is the maximum number of characters that
are allowed in the field. If this is set to NOLENGTHCHECK
then
we do not perform the check.TextToVerify
- This is the text which is to be verified
FieldInvalidException
- Throw if the field is not validprotected java.lang.String getFullUserNameFromEmailAddress(java.lang.String emailAddress)
emailAddress
-
public static java.lang.String createEmailLink(java.lang.String emailAddress, int faultId, java.lang.String faultTitle, java.lang.String linkText)
emailAddress
- Email address of recipientfaultId
- Defect number of fault which the email is
associatedfaultTitle
- This is the title of the faultlinkText
- This is the text of the link
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |