org.apertereports
Class AbstractReportingApplication<T extends com.vaadin.ui.Panel>

java.lang.Object
  extended by com.vaadin.Application
      extended by eu.livotov.tpt.TPTApplication
          extended by org.apertereports.AbstractReportingApplication<T>
Type Parameters:
T - Type of main panel
All Implemented Interfaces:
com.vaadin.service.ApplicationContext.TransactionListener, com.vaadin.terminal.gwt.server.PortletApplicationContext2.PortletListener, com.vaadin.terminal.Terminal.ErrorListener, com.vaadin.terminal.URIHandler, Serializable
Direct Known Subclasses:
CyclicReportsApplication, DashboardPortletApplication, InvokerApplication, ManagerApplication, ReportOrderApplication

public abstract class AbstractReportingApplication<T extends com.vaadin.ui.Panel>
extends eu.livotov.tpt.TPTApplication
implements com.vaadin.terminal.gwt.server.PortletApplicationContext2.PortletListener

This is a stub abstract class for all application portlets. Extending classes should initialize themselves by overriding portletInit().

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class com.vaadin.Application
com.vaadin.Application.ApplicationError, com.vaadin.Application.CustomizedSystemMessages, com.vaadin.Application.SystemMessages, com.vaadin.Application.UserChangeEvent, com.vaadin.Application.UserChangeListener, com.vaadin.Application.WindowAttachEvent, com.vaadin.Application.WindowAttachListener, com.vaadin.Application.WindowDetachEvent, com.vaadin.Application.WindowDetachListener
 
Nested classes/interfaces inherited from interface com.vaadin.terminal.URIHandler
com.vaadin.terminal.URIHandler.ErrorEvent
 
Field Summary
protected  T mainPanel
          Main panel
protected  com.vaadin.ui.Window mainWindow
          Main window object
 
Constructor Summary
AbstractReportingApplication()
           
 
Method Summary
 void applicationInit()
          Initializes the application context.
 void close()
           
 void firstApplicationStartup()
          This method should be overriden to implement a custom behavior on a first application startup.
 Locale getArLocale()
          Returns application locale
 org.apertereports.common.users.User getArUser()
          Returns the user of the last request
 void handleActionRequest(javax.portlet.ActionRequest request, javax.portlet.ActionResponse response, com.vaadin.ui.Window window)
          Handles portlet action request however not used in the application.
 void handleEventRequest(javax.portlet.EventRequest request, javax.portlet.EventResponse response, com.vaadin.ui.Window window)
          Handles portlet event request however not used in the application.
 void handleRenderRequest(javax.portlet.RenderRequest request, javax.portlet.RenderResponse response, com.vaadin.ui.Window window)
          Provides information about user and the locale for the application.
 void handleResourceRequest(javax.portlet.ResourceRequest request, javax.portlet.ResourceResponse response, com.vaadin.ui.Window window)
          Handles portlet resource request however not used in the application.
protected abstract  void portletInit()
          Initializes the portlet GUI.
protected abstract  void reinitUserData(org.apertereports.common.users.User user)
          Reinitializes user data when the user is logged on or logged off.
 void terminalError(com.vaadin.terminal.Terminal.ErrorEvent event)
          Logs uncaught exceptions to logger and presents them to the user.
 
Methods inherited from class eu.livotov.tpt.TPTApplication
getCurrentApplication, getSelf, init, invokeLater, setTheme, transactionEnd, transactionStart
 
Methods inherited from class com.vaadin.Application
addListener, addListener, addListener, addResource, addWindow, getContext, getErrorHandler, getLocale, getLogoutURL, getMainWindow, getProperty, getPropertyNames, getRelativeLocation, getSystemMessages, getTheme, getURL, getUser, getVersion, getWindow, getWindows, handleURI, isRunning, removeListener, removeListener, removeListener, removeResource, removeWindow, setErrorHandler, setLocale, setLogoutURL, setMainWindow, setUser, start
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

mainWindow

protected com.vaadin.ui.Window mainWindow
Main window object


mainPanel

protected T extends com.vaadin.ui.Panel mainPanel
Main panel

Constructor Detail

AbstractReportingApplication

public AbstractReportingApplication()
Method Detail

applicationInit

public void applicationInit()
Initializes the application context.

Specified by:
applicationInit in class eu.livotov.tpt.TPTApplication

close

public void close()
Overrides:
close in class eu.livotov.tpt.TPTApplication

portletInit

protected abstract void portletInit()
Initializes the portlet GUI.


reinitUserData

protected abstract void reinitUserData(org.apertereports.common.users.User user)
Reinitializes user data when the user is logged on or logged off.

Parameters:
user - User, can be null when user is not logged

firstApplicationStartup

public void firstApplicationStartup()
This method should be overriden to implement a custom behavior on a first application startup.

Specified by:
firstApplicationStartup in class eu.livotov.tpt.TPTApplication

terminalError

public void terminalError(com.vaadin.terminal.Terminal.ErrorEvent event)
Logs uncaught exceptions to logger and presents them to the user.

Specified by:
terminalError in interface com.vaadin.terminal.Terminal.ErrorListener
Overrides:
terminalError in class com.vaadin.Application
Parameters:
event - Error event

handleRenderRequest

public void handleRenderRequest(javax.portlet.RenderRequest request,
                                javax.portlet.RenderResponse response,
                                com.vaadin.ui.Window window)
Provides information about user and the locale for the application.

Specified by:
handleRenderRequest in interface com.vaadin.terminal.gwt.server.PortletApplicationContext2.PortletListener
Parameters:
request - Render request
response - Render response
window - Vaadin window

handleActionRequest

public void handleActionRequest(javax.portlet.ActionRequest request,
                                javax.portlet.ActionResponse response,
                                com.vaadin.ui.Window window)
Handles portlet action request however not used in the application.

Specified by:
handleActionRequest in interface com.vaadin.terminal.gwt.server.PortletApplicationContext2.PortletListener
Parameters:
request - Render request
response - Render response
window - Vaadin window

handleEventRequest

public void handleEventRequest(javax.portlet.EventRequest request,
                               javax.portlet.EventResponse response,
                               com.vaadin.ui.Window window)
Handles portlet event request however not used in the application.

Specified by:
handleEventRequest in interface com.vaadin.terminal.gwt.server.PortletApplicationContext2.PortletListener
Parameters:
request - Render request
response - Render response
window - Vaadin window

handleResourceRequest

public void handleResourceRequest(javax.portlet.ResourceRequest request,
                                  javax.portlet.ResourceResponse response,
                                  com.vaadin.ui.Window window)
Handles portlet resource request however not used in the application.

Specified by:
handleResourceRequest in interface com.vaadin.terminal.gwt.server.PortletApplicationContext2.PortletListener
Parameters:
request - Render request
response - Render response
window - Vaadin window

getArUser

public org.apertereports.common.users.User getArUser()
Returns the user of the last request

Returns:
The user

getArLocale

public Locale getArLocale()
Returns application locale

Returns:
Locale


Copyright © 2011-2013. All Rights Reserved.