com.atlassian.jira.charts.portlet
Class AbstractChartPortlet

java.lang.Object
  extended by com.atlassian.jira.portal.PortletImpl
      extended by com.atlassian.jira.charts.portlet.AbstractChartPortlet
All Implemented Interfaces:
LazyLoadingPortlet, Portlet
Direct Known Subclasses:
AbstractTimeChartPortlet, AverageAgeChartPortlet, CreatedVsResolvedChartPortlet, PieChartPortlet, RecentlyCreatedChartPortlet, TimeSinceChartPortlet

public abstract class AbstractChartPortlet
extends PortletImpl
implements LazyLoadingPortlet

Abstract chart to be extended by others

Since:
v4.0

Field Summary
protected  ChartUtils chartUtils
           
protected  VelocityRequestContextFactory velocityRequestContextFactory
           
 
Fields inherited from class com.atlassian.jira.portal.PortletImpl
applicationProperties, authenticationContext, permissionManager
 
Constructor Summary
AbstractChartPortlet(JiraAuthenticationContext authenticationContext, PermissionManager permissionManager, ApplicationProperties applicationProperties, VelocityRequestContextFactory velocityRequestContextFactory, ChartUtils chartUtils)
           
 
Method Summary
 java.util.Map<java.lang.String,java.lang.Object> generateCommonParameters(PortletConfiguration portletConfiguration)
           
protected  int getDaysPrevious(PortletConfiguration portletConfiguration)
           
 java.lang.String getLoadingHtml(PortletConfiguration portletConfiguration)
          This method should return temporary HTML
 java.lang.String getStaticHtml(PortletConfiguration portletConfiguration)
          All JavaScript should be returned by this method.
 
Methods inherited from class com.atlassian.jira.portal.PortletImpl
equals, getCornerThumbnail, getCornerThumbnailPath, getDescription, getDescriptor, getId, getIssueConstant, getListFromMultiSelectValue, getName, getObjectConfiguration, getPermission, getTemplateLocation, getThumbnailfile, getThumbnailPath, getVelocityParams, getViewHtml, hashCode, hasPermission, init, isEditablePortletConfig
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.atlassian.jira.portal.Portlet
getCornerThumbnail, getDescription, getDescriptor, getId, getName, getObjectConfiguration, getPermission, getTemplateLocation, getThumbnailfile, getViewHtml, hasPermission, init
 

Field Detail

velocityRequestContextFactory

protected final VelocityRequestContextFactory velocityRequestContextFactory

chartUtils

protected final ChartUtils chartUtils
Constructor Detail

AbstractChartPortlet

public AbstractChartPortlet(JiraAuthenticationContext authenticationContext,
                            PermissionManager permissionManager,
                            ApplicationProperties applicationProperties,
                            VelocityRequestContextFactory velocityRequestContextFactory,
                            ChartUtils chartUtils)
Method Detail

getDaysPrevious

protected int getDaysPrevious(PortletConfiguration portletConfiguration)
                       throws ObjectConfigurationException
Throws:
ObjectConfigurationException

generateCommonParameters

public java.util.Map<java.lang.String,java.lang.Object> generateCommonParameters(PortletConfiguration portletConfiguration)

getLoadingHtml

public java.lang.String getLoadingHtml(PortletConfiguration portletConfiguration)
Description copied from interface: LazyLoadingPortlet
This method should return temporary HTML

Specified by:
getLoadingHtml in interface LazyLoadingPortlet
Parameters:
portletConfiguration - The portlet configuration for the current request
Returns:
A HTML fragment

getStaticHtml

public java.lang.String getStaticHtml(PortletConfiguration portletConfiguration)
Description copied from interface: LazyLoadingPortlet
All JavaScript should be returned by this method. If the JavaScript is not returned by this method it may not bound in the when you try and invoke it from your portlet. This method should return any HTML that will not be swapped out because of lazy loading. The resultant HTML returned by this method will be displayed regardless of whether lazy loading is active or not. The static HTML will placed in front of the Loading HTML.

Specified by:
getStaticHtml in interface LazyLoadingPortlet
Returns:
A HTML fragment


Copyright © 2002-2010 Atlassian. All Rights Reserved.