GWTApplication.client
Class SearchResultFormatter.DisplayFullFault

java.lang.Object
  extended by GWTApplication.client.SearchResultFormatter.DisplayFullFault
All Implemented Interfaces:
com.google.gwt.user.client.ui.DisclosureHandler
Enclosing class:
SearchResultFormatter

private class SearchResultFormatter.DisplayFullFault
extends java.lang.Object
implements com.google.gwt.user.client.ui.DisclosureHandler

Inner class which will be used to display the full fault history as the user clicks on a disclosure widget header and opens it for the first time.

Version:
$Id: SearchResultFormatter.java,v 1.26 2007/12/17 12:26:40 cb Exp $
Author:
Craige Bevil

Field Summary
private  BusyIndicator busyIndicator
          This will be used to display whether or not we are busy or not
private  FaultEntryDetails faultHistory
          Contains the full history of the fault
private  int FaultNumber
          This is the defect number which is associated with the fault
(package private)  int noOfSubTasksCompleted
          Whether or not we have the fault information for this fault
private  com.google.gwt.user.client.ui.DisclosurePanel panel
          This is the panel into which we are to put the result once they arrive from the servlet
private  boolean panelInitialised
          If the panel has been initialised
 
Constructor Summary
SearchResultFormatter.DisplayFullFault(int FaultNumber)
          This is the constructor for the class.
 
Method Summary
(package private)  int convertTimeToMinutes(java.lang.String TimeAmount)
          Used to convert the HH:MM field into minutes expressed as an integer.
(package private)  void createFaultDisclosurePanelContent()
          This method will be called to generate the disclosure content panel which contains the full details of the fault which is displayed when the user clicks upon the arrow icon in the disclosure panel in the display.
private  void getFaultDetails()
          This method will be used to get the full details of this fault back from the database and then display them in the content panel of the disclosure panel which is associated with this fault.
 void onClose(com.google.gwt.user.client.ui.DisclosureEvent event)
          Don't do anything when the disclosure panel is closed by the user.
 void onOpen(com.google.gwt.user.client.ui.DisclosureEvent event)
          Called when the user opens the disclosure box and results in the data being extracted from the database and displayed within the disclosure box.
 void setPanelInitialised(boolean State)
          Sets the state of the disclosure panel and whether it is initialied or not
 void updateDisclosurePanel(FaultEntryDetails faultHistory)
          This will be called with the details of the updated fault history and will result in the details in the disclosure panel being updated.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

busyIndicator

private BusyIndicator busyIndicator
This will be used to display whether or not we are busy or not


faultHistory

private FaultEntryDetails faultHistory
Contains the full history of the fault


noOfSubTasksCompleted

int noOfSubTasksCompleted
Whether or not we have the fault information for this fault


FaultNumber

private int FaultNumber
This is the defect number which is associated with the fault


panel

private com.google.gwt.user.client.ui.DisclosurePanel panel
This is the panel into which we are to put the result once they arrive from the servlet


panelInitialised

private boolean panelInitialised
If the panel has been initialised

Constructor Detail

SearchResultFormatter.DisplayFullFault

SearchResultFormatter.DisplayFullFault(int FaultNumber)
This is the constructor for the class.

Method Detail

onOpen

public void onOpen(com.google.gwt.user.client.ui.DisclosureEvent event)
Called when the user opens the disclosure box and results in the data being extracted from the database and displayed within the disclosure box.

Specified by:
onOpen in interface com.google.gwt.user.client.ui.DisclosureHandler

setPanelInitialised

public void setPanelInitialised(boolean State)
Sets the state of the disclosure panel and whether it is initialied or not

Parameters:
State - The state of the panel

createFaultDisclosurePanelContent

void createFaultDisclosurePanelContent()
This method will be called to generate the disclosure content panel which contains the full details of the fault which is displayed when the user clicks upon the arrow icon in the disclosure panel in the display.


convertTimeToMinutes

int convertTimeToMinutes(java.lang.String TimeAmount)
Used to convert the HH:MM field into minutes expressed as an integer.

Parameters:
TimeAmount - Time expressed in HH:MM
Returns:
int The amount expressed in minutes

onClose

public void onClose(com.google.gwt.user.client.ui.DisclosureEvent event)
Don't do anything when the disclosure panel is closed by the user. Obligation of the interface that we have to implement.

Specified by:
onClose in interface com.google.gwt.user.client.ui.DisclosureHandler
Parameters:
DisclosureEvent - The type of event.

getFaultDetails

private void getFaultDetails()
This method will be used to get the full details of this fault back from the database and then display them in the content panel of the disclosure panel which is associated with this fault.


updateDisclosurePanel

public void updateDisclosurePanel(FaultEntryDetails faultHistory)
This will be called with the details of the updated fault history and will result in the details in the disclosure panel being updated.

Parameters:
faultHistory - Containsthe details of the fault