org.millstone.webadapter
Class DebugWindow

java.lang.Object
  |
  +--org.millstone.base.ui.AbstractComponent
        |
        +--org.millstone.base.ui.AbstractComponentContainer
              |
              +--org.millstone.base.ui.Panel
                    |
                    +--org.millstone.base.ui.Window
                          |
                          +--org.millstone.webadapter.DebugWindow
All Implemented Interfaces:
Component, ComponentContainer, ComponentContainer.ComponentAttachListener, ComponentContainer.ComponentDetachListener, java.util.EventListener, MethodEventSource, Paintable, ParameterHandler, Scrollable, Sizeable, URIHandler, VariableOwner

public class DebugWindow
extends Window

This class provides a debugging window where one may view the UIDL of the current window, or in a tabset the UIDL of an active frameset. It is primarily inteded for creating and debugging themes.

Since:
3.0
Version:
3.0.3
Author:
IT Mill Ltd.

Nested Class Summary
 
Nested classes inherited from class org.millstone.base.ui.ComponentContainer
ComponentContainer.ComponentAttachEvent, ComponentContainer.ComponentAttachListener, ComponentContainer.ComponentDetachEvent, ComponentContainer.ComponentDetachListener
 
Nested classes inherited from class org.millstone.base.ui.Component
Component.Event, Component.Listener
 
Nested classes inherited from class org.millstone.base.terminal.Paintable
Paintable.RepaintRequestEvent, Paintable.RepaintRequestListener
 
Field Summary
protected static java.lang.String WINDOW_NAME
           
 
Fields inherited from class org.millstone.base.ui.Window
BORDER_DEFAULT, BORDER_MINIMAL, BORDER_NONE
 
Fields inherited from interface org.millstone.base.terminal.Sizeable
UNIT_SYMBOLS, UNITS_CM, UNITS_EM, UNITS_EX, UNITS_INCH, UNITS_MM, UNITS_PERCENTAGE, UNITS_PICAS, UNITS_PIXELS, UNITS_POINTS
 
Constructor Summary
protected DebugWindow(Application debuggedApplication, javax.servlet.http.HttpSession session, WebAdapterServlet servlet)
          Create new debug window for an application.
 
Method Summary
 void clearSession()
           
 void commitTheme()
           
protected  Select createSelect(java.lang.String caption, java.lang.Object[] keys, java.lang.String[] names)
           
protected  java.lang.String getHTMLFormattedUIDL(java.lang.String caption, java.lang.String uidl)
           
protected  WebAdapterServlet getServlet()
          Returns the servlet.
protected  javax.servlet.http.HttpSession getSession()
          Returns the session.
protected static java.lang.String replace(java.lang.String text, int start, int end, java.lang.String str)
          Replaces the characters in a substring of this String with characters in the specified String.
protected static java.lang.String replaceAll(java.lang.String text, java.lang.String oldStr, java.lang.String newStr)
           
 void restartApplication()
           
 void saveUIDL()
           
protected  void setDebuggedApplication(Application application)
          Sets the application.
protected  void setServlet(WebAdapterServlet servlet)
          Sets the servlet.
protected  void setSession(javax.servlet.http.HttpSession session)
          Sets the session.
protected  void setWindowUIDL(Window window, java.lang.String uidl)
           
 
Methods inherited from class org.millstone.base.ui.Window
addParameterHandler, addURIHandler, getApplication, getBorder, getName, getParent, getTag, getTerminal, getTheme, getURL, getWindow, handleParameters, handleURI, open, open, open, paintContent, removeParameterHandler, removeURIHandler, setApplication, setBorder, setHeightUnits, setName, setParent, setTerminal, setTheme, setWidthUnits
 
Methods inherited from class org.millstone.base.ui.Panel
addComponent, changeVariables, componentAttachedToContainer, componentDetachedFromContainer, getComponentIterator, getHeight, getHeightUnits, getLayout, getScrollOffsetX, getScrollOffsetY, getWidth, getWidthUnits, isScrollable, removeComponent, replaceComponent, setHeight, setLayout, setScrollable, setScrollOffsetX, setScrollOffsetY, setWidth
 
Methods inherited from class org.millstone.base.ui.AbstractComponentContainer
addListener, addListener, attach, detach, fireComponentAttachEvent, fireComponentDetachEvent, moveComponentsFrom, removeAllComponents, removeListener, removeListener
 
Methods inherited from class org.millstone.base.ui.AbstractComponent
addListener, addListener, addListener, addListener, childRequestedRepaint, dependsOn, fireComponentEvent, fireEvent, getCaption, getComponentError, getDescription, getDirectDependencies, getErrorMessage, getIcon, getLocale, getStyle, isEnabled, isImmediate, isReadOnly, isVisible, paint, removeDirectDependency, removeListener, removeListener, removeListener, removeListener, removeListener, requestRepaint, requestRepaintRequests, setCaption, setComponentError, setDescription, setEnabled, setIcon, setImmediate, setLocale, setReadOnly, setStyle, setVisible
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.millstone.base.ui.Component
addListener, childRequestedRepaint, getCaption, getIcon, getLocale, getStyle, isEnabled, isImmediate, isReadOnly, isVisible, removeListener, setEnabled, setReadOnly, setStyle, setVisible
 
Methods inherited from interface org.millstone.base.terminal.Paintable
addListener, paint, removeListener, requestRepaint, requestRepaintRequests
 
Methods inherited from interface org.millstone.base.terminal.VariableOwner
dependsOn, getDirectDependencies, removeDirectDependency
 

Field Detail

WINDOW_NAME

protected static java.lang.String WINDOW_NAME
Constructor Detail

DebugWindow

protected DebugWindow(Application debuggedApplication,
                      javax.servlet.http.HttpSession session,
                      WebAdapterServlet servlet)
Create new debug window for an application.

Parameters:
debuggedApplication - Application to be debugged.
session - Session to be debugged.
servlet - Servlet to be debugged.
Method Detail

createSelect

protected Select createSelect(java.lang.String caption,
                              java.lang.Object[] keys,
                              java.lang.String[] names)

saveUIDL

public void saveUIDL()

commitTheme

public void commitTheme()

clearSession

public void clearSession()

restartApplication

public void restartApplication()

setWindowUIDL

protected void setWindowUIDL(Window window,
                             java.lang.String uidl)

getHTMLFormattedUIDL

protected java.lang.String getHTMLFormattedUIDL(java.lang.String caption,
                                                java.lang.String uidl)

replace

protected static java.lang.String replace(java.lang.String text,
                                          int start,
                                          int end,
                                          java.lang.String str)
Replaces the characters in a substring of this String with characters in the specified String. The substring begins at the specified start and extends to the character at index end - 1 or to the end of the String if no such character exists. First the characters in the substring are removed and then the specified String is inserted at start. (The StringBuffer will be lengthened to accommodate the specified String if necessary.)

NOTE: This operation is slow.

Parameters:
start - The beginning index, inclusive.
end - The ending index, exclusive.
str - String that will replace previous contents.
Returns:
This string buffer.
Throws:
java.lang.StringIndexOutOfBoundsException - if start is negative, greater than length(), or greater than end.

replaceAll

protected static java.lang.String replaceAll(java.lang.String text,
                                             java.lang.String oldStr,
                                             java.lang.String newStr)

setDebuggedApplication

protected void setDebuggedApplication(Application application)
Sets the application.

Parameters:
application - The application to set

getServlet

protected WebAdapterServlet getServlet()
Returns the servlet.

Returns:
WebAdapterServlet

getSession

protected javax.servlet.http.HttpSession getSession()
Returns the session.

Returns:
HttpSession

setServlet

protected void setServlet(WebAdapterServlet servlet)
Sets the servlet.

Parameters:
servlet - The servlet to set

setSession

protected void setSession(javax.servlet.http.HttpSession session)
Sets the session.

Parameters:
session - The session to set


Copyright © 2000,2001,2002 IT Mill Ltd. All Rights Reserved.