net.sf.webmancer.widget
Class Page

java.lang.Object
  extended by net.sf.webmancer.widget.AbstractWidget
      extended by net.sf.webmancer.widget.AbstractContainer
          extended by net.sf.webmancer.widget.Page
All Implemented Interfaces:
IModelable, IWidget, org.springframework.beans.factory.BeanNameAware, org.springframework.web.servlet.mvc.Controller

public class Page
extends AbstractContainer
implements org.springframework.web.servlet.mvc.Controller

Author:
Michal Burda

Field Summary
static java.lang.String APPLICATION_TITLE_ATTRIBUTE
           
static java.lang.String APPLICATION_VERSION_ATTRIBUTE
           
static java.lang.String AUTHOR_ATTRIBUTE
           
static java.lang.String PAGE_ELEMENT
           
static java.lang.String PAGE_TITLE_ATTRIBUTE
           
 
Constructor Summary
Page()
           
 
Method Summary
 void build(IModelBuilder builder)
           
protected  Event createInitializationEvent()
           
protected  Event createRequestEvent(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
 IApplicationInformation getApplicationInformation()
          Returns the applicationInformation.
 java.lang.String getDescription()
          Returns the description.
protected  IEventQueue getEventQueue()
          Returns the eventQueue.
 java.lang.String getKeywords()
          Returns the keywords.
protected  IModeler getModeler()
          Returns the modeler.
 java.lang.String getTitle()
          Gets the title.
 org.springframework.web.servlet.ModelAndView handleRequest(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
           
protected  void processEventLoop(Event event)
           
protected  org.springframework.web.servlet.ModelAndView processModeling()
           
 void putEvent(Event event)
          Add the given event to the queue of events to be handled.
 void setApplicationInformation(IApplicationInformation applicationInformation)
          Sets the applicationInformation.
 void setDescription(java.lang.String description)
          Sets the description.
 void setEventQueue(IEventQueue eventQueue)
          Sets the eventQueue.
 void setKeywords(java.lang.String keywords)
          Sets the keywords.
 void setModeler(IModeler modeler)
          Sets the modeler.
 void setParent(IWidget parent)
          Set the parent of this widget.
 void setTitle(java.lang.String title)
          Sets the title.
 
Methods inherited from class net.sf.webmancer.widget.AbstractContainer
addChild, buildChild, handleEvent, setChildren
 
Methods inherited from class net.sf.webmancer.widget.AbstractWidget
getBeanName, getParent, setBeanName, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PAGE_ELEMENT

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

AUTHOR_ATTRIBUTE

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

APPLICATION_VERSION_ATTRIBUTE

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

APPLICATION_TITLE_ATTRIBUTE

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

PAGE_TITLE_ATTRIBUTE

public static final java.lang.String PAGE_TITLE_ATTRIBUTE
See Also:
Constant Field Values
Constructor Detail

Page

public Page()
Parameters:
id -
title -
Method Detail

setParent

public void setParent(IWidget parent)
Description copied from interface: IWidget
Set the parent of this widget.

Specified by:
setParent in interface IWidget
Overrides:
setParent in class AbstractWidget
Parameters:
parent - the parent widget
See Also:
AbstractWidget.setParent(net.sf.webmancer.widget.IWidget)

getDescription

public java.lang.String getDescription()
Returns the description.

Returns:
the description

setDescription

public void setDescription(java.lang.String description)
Sets the description.

Parameters:
description - the description to set

getKeywords

public java.lang.String getKeywords()
Returns the keywords.

Returns:
the keywords

setKeywords

public void setKeywords(java.lang.String keywords)
Sets the keywords.

Parameters:
keywords - the keywords to set

getTitle

public java.lang.String getTitle()
Gets the title.

Returns:
the title

setTitle

public void setTitle(java.lang.String title)
Sets the title.

Parameters:
title - the title to set

getApplicationInformation

public IApplicationInformation getApplicationInformation()
Returns the applicationInformation.

Returns:
the applicationInformation

setApplicationInformation

public void setApplicationInformation(IApplicationInformation applicationInformation)
Sets the applicationInformation.

Parameters:
applicationInformation - the applicationInformation to set

getModeler

protected IModeler getModeler()
Returns the modeler.

Returns:
the modeler

setModeler

public void setModeler(IModeler modeler)
Sets the modeler.

Parameters:
modeler - the modeler to set

getEventQueue

protected IEventQueue getEventQueue()
Returns the eventQueue.

Returns:
the eventQueue

setEventQueue

public void setEventQueue(IEventQueue eventQueue)
Sets the eventQueue.

Parameters:
eventQueue - the eventQueue to set

putEvent

public void putEvent(Event event)
Description copied from interface: IWidget
Add the given event to the queue of events to be handled. Implementations often simply call the putEvent() of the parent widget. Usually, only root widgets hold the event queue and control the event handling mechanism.

Specified by:
putEvent in interface IWidget
Overrides:
putEvent in class AbstractWidget
Parameters:
event - an event to be added to the queue of events.
See Also:
AbstractWidget.putEvent(net.sf.webmancer.base.Event)

build

public void build(IModelBuilder builder)
           throws ModelingException
Specified by:
build in interface IModelable
Overrides:
build in class AbstractContainer
Throws:
ModelingException
See Also:
AbstractContainer.build(net.sf.webmancer.model.IModelBuilder)

handleRequest

public org.springframework.web.servlet.ModelAndView handleRequest(javax.servlet.http.HttpServletRequest request,
                                                                  javax.servlet.http.HttpServletResponse response)
                                                           throws java.lang.Exception
Specified by:
handleRequest in interface org.springframework.web.servlet.mvc.Controller
Throws:
java.lang.Exception
See Also:
Controller.handleRequest(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)

processEventLoop

protected void processEventLoop(Event event)
Parameters:
event -

processModeling

protected org.springframework.web.servlet.ModelAndView processModeling()
                                                                throws ModelingException
Returns:
Throws:
ModelingException

createInitializationEvent

protected Event createInitializationEvent()
Returns:

createRequestEvent

protected Event createRequestEvent(javax.servlet.http.HttpServletRequest request,
                                   javax.servlet.http.HttpServletResponse response)
Parameters:
request -
response -
Returns:


Copyright © 2006-2007. All Rights Reserved.