public class IlvFacesGanttServletSupport extends IlvGanttServletSupport implements IlvFacesDHTMLGanttConstants
IlvFacesGanttServletSupport
is the implementation of
IlvGanttServletSupport
for the JViews Gantt Faces package.Modifier and Type | Field and Description |
---|---|
static String |
PARAM_DATASOURCE
The request parameter name of a data source ID.
|
static String |
PARAM_PROJECT
The request parameter name of a Gantt Designer project URL.
|
static String |
PARAM_STYLESHEETS
The request parameter name of a style sheet URL.
|
ACTION_PARAM, CAP_FORMAT_PARAM, CAPABILITIES_REQUEST, CHART_COMPONENT, COMPONENT_PARAM, END_TIME_PARAM, HEIGHT, HITMAP_REQUEST, HORZ_POSITION_PARAM, HTML_CAP_FORMAT, IMAGE_FORMAT_PARAM, IMAGE_REQUEST, JPEG_IMAGE_FORMAT, JSON_CAP_FORMAT, OCTET_CAP_FORMAT, PNG_IMAGE_FORMAT, REQUEST_PARAM, SHEET_COMPONENT, START_TIME_PARAM, TABLE_COMPONENT, VALID_CAP_FORMATS, VALID_COMPONENTS, VERBOSE_PARAM, VERT_POSITION_PARAM, WIDTH
AUTO_UPDATE_CAPABILITIES, COLUMN_RESIZE_MESSAGE, FILENAME, PARAM_COMPID, SESSION_ID_PREFIX, UPDATE_INTERVAL
DATA_SOURCE, DATA_SOURCE_ID, DIVIDER_LOCATION, EDITABLE, END_VISIBLE_INTERVAL, H_SHEET_SCROLLABLE, HIERARCHY_CHART, MESSAGEBOX, MESSAGEBOX_ID, PROPERTY_ACCESSOR, REFRESH_DATA, RESIZE_ACTIVITY, RESIZE_HEADER_ACTION_NAME, ROW_EXPAND_COLLAPSE_ACTION_NAME, ROW_SELECT_ACTION_NAME, SHEET_H_SCROLL_BACKGROUND_CLICK_EXTENT, SHEET_INTERACTOR, SHEET_INTERACTOR_ID, SPLITTER_ARROWS_VISIBLE, START_VISIBLE_INTERVAL, STYLE_SHEET, STYLE_SHEETS, TABLE_INTERACTOR, TABLE_INTERACTOR_ID, V_SHEET_SCROLLABLE, ZOOM_FACTOR
ACCESSIBLE, ACTION_NAME, AUTO_SUBMIT, BACKGROUND_COLOR, CAPABILITIES_LOADED_HANDLER, COMPONENT, DO_ACTION_ON_BG_DESELECT, ERROR_MESSAGE, GENERATE_IMAGE_MAP, HOTKEYS, IMAGE_FORMAT, IMAGE_LOADED_HANDLER, IMAGE_MAP_GENERATOR, IMAGE_MAP_GENERATOR_CLASS, IMAGE_MAP_VISIBLE, IMAGE_SERVLET_CONTEXT, INVOCATION_CONTEXT, JSF_CONTEXT, ON_CLICK, ON_SELECTION_CHANGED, PARTIAL_SUBMIT, PORTLET_CONTEXT_KEY, PORTLET_SESSION_KEY, REPLACE_PATTERN, RESIZABLE, SELECTION_RESIZABLE_CLASS, SESSION_EXP_HANDLER, SUBMITTED_VALUE, WAITING_IMAGE
AFTER_HANDLER, BASETEXTDIRECTION, BEFORE_HANDLER, BUTTON_GROUP_ID, BUTTON_TYPE, CHARTS_BUNDLE, CHARTS_MESSAGE_BUNDLE, CORE_BUNDLE, CORE_MESSAGE_BUNDLE, CURSOR, DATA, DECODED_PROPERTY, DEFAULT_LINE_COLOR, DELETION_ALLOWED, DIAGRAMMER_BUNDLE, DIAGRAMMER_MESSAGE_BUNDLE, ENABLED, EVENT_TYPE, FILL_ON, FORCE_UPDATE_PROPERTIES, FRAMEWORK_BUNDLE, FRAMEWORK_MESSAGE_BUNDLE, GANTT_BUNDLE, GANTT_MESSAGE_BUNDLE, HEIGHT, IMAGE, IMAGE_MODE, INFO_PROVIDER_MB, INT_NOT_DEFINED, INTERACTORS, INTERCEPT_INTERACTOR, ITEM_DISABLED_STYLE_CLASS, ITEM_HIGHLIGHTED_STYLE_CLASS, ITEM_STYLE_CLASS, LINE_COLOR, LINE_WIDTH, MAPS_BUNDLE, MAPS_MESSAGE_BUNDLE, MENU_MODEL_ID, MESSAGE, MESSAGE_BOX, MESSAGE_BOX_ID, MOVE_ALLOWED, OBJECT_FINDER, PARAM_DATA, PARAM_KEY, PARAM_NAMESPACE, PARAM_RESOURCE, PARAM_SERVICE, PARAM_TYPE, POPUP_MENU, POPUP_MENU_FACTORY, POPUP_MENU_FACTORY_CLASS, PORTLET_NAMESPACE, PROGRESSIVE_ZOOM, PROJECT, RENDER, RESOURCES_PATH, RESOURCES_PATH_PREFIX, ROLLOVER_IMAGE, SCROLL_BAR, SELECTED, SELECTED_IMAGE, SERVICE_FORWARD, SERVICE_FORWARD_INT, SERVLET, SERVLET_CLASS, SERVLET_URL, STYLE, STYLE_CLASS, TGO_BUNDLE, TGO_MESSAGE_BUNDLE, TITLE, TOGGLE, VALUE, VIEW, VIEW_ID, WIDTH
Constructor and Description |
---|
IlvFacesGanttServletSupport(jakarta.servlet.ServletContext context)
Creates a new
IlvFacesGanttServletSupport . |
Modifier and Type | Method and Description |
---|---|
protected void |
addDefaultActions()
Adds the default row expand/collapse, row select and resize header default
actions.
|
protected IlvPopupMenuServletSupport |
createPopupMenuSupport()
Creates a new instance of pop-up menu servlet support.
|
protected IlvSelectionSupport |
createSelectionSupport()
Creates a new instance of selection servlet support.
|
protected Map |
getAdditionalCapabilities(IlvHierarchyChart chart,
IlvServletRequestParameters params)
Allows you to put additional capabilities to the capability request.
|
protected IlvHierarchyChart |
getChart(jakarta.servlet.http.HttpServletRequest request,
IlvServletRequestParameters params)
Returns the chart used for the specified request.
|
IlvServerAction |
getDefaultJSFSelectAction()
Returns the default row select action.
|
IlvServerAction |
getDefaultResizeActivityAction()
Gets the default resize activity action.
|
IlvServerAction |
getDefaultResizeHeaderAction()
Returns the default resize header action.
|
IlvServerAction |
getDefaultRowExpandCollapseAction()
Returns the default row expand/collapse action.
|
IlvServerAction |
getDefaultRowSelectAction()
Returns the default row select action.
|
protected jakarta.faces.context.FacesContext |
getFacesContext(jakarta.servlet.http.HttpServletRequest request,
jakarta.servlet.http.HttpServletResponse response,
boolean forceCreation)
Returns a dummy faces context to retrieve value bindings.
|
protected Object |
getLock(jakarta.servlet.http.HttpServletRequest request)
Returns a lock object to synchronize the request processing.
|
protected IlvMenuFactory |
getMenuFactory(jakarta.servlet.http.HttpServletRequest request,
jakarta.servlet.http.HttpServletResponse response)
Retrieves or creates the menu factory used in this pop-up menu request.
|
boolean |
handleRequest(jakarta.servlet.http.HttpServletRequest request,
jakarta.servlet.http.HttpServletResponse response)
This method is the main entry point for handling HTTP requests.
|
protected void |
removeDefaultActions()
Removes the default server actions added by the
addDefaultActions method. |
protected void |
setDataSource(jakarta.servlet.http.HttpServletRequest request,
String dataSourceId)
Sets the Gantt data model identified by the
dataSourceId
parameter in the session to the current hierarchy chart. |
void |
setDefaultJSFSelectAction(IlvServerAction defaultRowSelectAction)
Sets the default row select action.
|
void |
setDefaultResizeActivityAction(IlvServerAction defaultResizeActivityAction)
Sets the default resize activity action.
|
void |
setDefaultResizeHeaderAction(IlvServerAction defaultResizeHeaderAction)
Sets the default resize header action.
|
void |
setDefaultRowExpandCollapseAction(IlvServerAction defaultRowExpandCollapseAction)
Sets the default row expand/collapse action.
|
void |
setDefaultRowSelectAction(IlvServerAction defaultRowSelectAction)
Sets the default row select action.
|
protected void |
setProject(jakarta.servlet.http.HttpServletRequest request,
String projectURL)
Sets the project URL to the current hierarchy chart.
|
protected void |
setStyleSheets(jakarta.servlet.http.HttpServletRequest request,
String styleSheets)
Sets the comma separated Cascading Style Sheet list to the current
hierarchy chart.
|
additionalBinaryCapabilities, additionalTextCapabilities, addServerAction, generateImage, getConfigParameters, getContext, getDataInterval, getHitmapSupport, getImageEncoder, getObjectAt, getPopupMenuSupport, getSelectionSupport, getServletContext, getTimestamp, isPopupEnabled, isSelectionEnabled, isVerbose, prepareChart, removeServerAction, setConfigParameters, setImageEncoder, setPopupEnabled, setSelectionEnabled, setServletContext
doGetScriptMessage, getParameterValidationListener, getScriptMessageSupport, setParameterValidationListener
public static final String PARAM_DATASOURCE
public static final String PARAM_PROJECT
public static final String PARAM_STYLESHEETS
public IlvFacesGanttServletSupport(jakarta.servlet.ServletContext context)
IlvFacesGanttServletSupport
.context
- The servlet context.protected jakarta.faces.context.FacesContext getFacesContext(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response, boolean forceCreation)
request
- The HTTP request.response
- The HTTP response.forceCreation
- Force creation of faces context even if
FacesContext.getCurrentInstance()
doesn't return null
.null
.protected IlvPopupMenuServletSupport createPopupMenuSupport()
createPopupMenuSupport
in class IlvGanttServletSupport
protected IlvSelectionSupport createSelectionSupport()
createSelectionSupport
in class IlvGanttServletSupport
protected void addDefaultActions()
removeDefaultActions
method.
Each subclass can override this method to register its specific default
server actions or can override the getters of the default row
expand/collapse, row select, header resize actions.protected void removeDefaultActions()
addDefaultActions
method.protected IlvHierarchyChart getChart(jakarta.servlet.http.HttpServletRequest request, IlvServletRequestParameters params) throws jakarta.servlet.ServletException
getChart
in class IlvGanttServletSupport
request
- The current HTTP request.params
- The parameters parsed from the request.jakarta.servlet.ServletException
protected Object getLock(jakarta.servlet.http.HttpServletRequest request)
request
- The HTTP request.protected IlvMenuFactory getMenuFactory(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) throws jakarta.servlet.ServletException
request
- The HTTP request.response
- The HTTP response.jakarta.servlet.ServletException
public boolean handleRequest(jakarta.servlet.http.HttpServletRequest request, jakarta.servlet.http.HttpServletResponse response) throws IOException, jakarta.servlet.ServletException
You can override this method to provide a new request type like this:
public boolean handleRequest(HttpServletRequest request, HttpServletResponse response) throws IOException, ServletException { if (super.handleRequest(request, response)) return true; IlvServletRequestParameters params = new IlvServletRequestParameters(request); String requestType = params.getString(REQUEST_PARAM, null); if ("somethingImportant".equals(requestType)) { doSomethingImportant(request, response, params); return true; } return false; }
handleRequest
in class IlvGanttServletSupport
request
- The current HTTP request.response
- The HTTP response.true
if a recognized request was handled
successfully, or false
if the request type was not
recognized. If a recognized request is not handled
successfully, an exception will be thrown.IOException
- if an input or output error is detected when the
servlet handles the request.jakarta.servlet.ServletException
- if the request could not be handled.protected void setProject(jakarta.servlet.http.HttpServletRequest request, String projectURL) throws jakarta.servlet.ServletException
request
- The request processed by this servlet.projectURL
- The URL of the project to set.jakarta.servlet.ServletException
protected void setStyleSheets(jakarta.servlet.http.HttpServletRequest request, String styleSheets) throws jakarta.servlet.ServletException
request
- The request processed by this servlet.styleSheets
- The style sheet list.jakarta.servlet.ServletException
protected void setDataSource(jakarta.servlet.http.HttpServletRequest request, String dataSourceId) throws jakarta.servlet.ServletException
dataSourceId
parameter in the session to the current hierarchy chart.request
- The request processed by this servlet.dataSourceId
- The identifier of the Gantt data model in the session.jakarta.servlet.ServletException
protected Map getAdditionalCapabilities(IlvHierarchyChart chart, IlvServletRequestParameters params) throws jakarta.servlet.ServletException
Map
should contains pairs of propertyName
and propertyValue
for each additional capability.getAdditionalCapabilities
in class IlvGanttServletSupport
chart
- The chart returned by getChart
.params
- The parameters parsed from the current HTTP request.null if none
).jakarta.servlet.ServletException
public IlvServerAction getDefaultResizeHeaderAction()
This implementation returns an IlvTableHeaderResizeAction
instance.
This method is called by the
addDefaultAction
method.
addDefaultActions()
public void setDefaultResizeHeaderAction(IlvServerAction defaultResizeHeaderAction)
defaultResizeHeaderAction
- The new default resize header default
server action.addDefaultActions()
public IlvServerAction getDefaultRowExpandCollapseAction()
This implementation returns an IlvRowExpandCollapseAction
instance.
This method is called by the
addDefaultAction
method.
addDefaultActions()
public void setDefaultRowExpandCollapseAction(IlvServerAction defaultRowExpandCollapseAction)
defaultRowExpandCollapseAction
- The new default row expand and
collapse server action.addDefaultActions()
public IlvServerAction getDefaultJSFSelectAction()
This implementation returns an IlvFacesGanttSelectAction
instance.
This method is called by the
addDefaultAction
method.
addDefaultActions()
public void setDefaultJSFSelectAction(IlvServerAction defaultRowSelectAction)
defaultRowSelectAction
- The default row select server action.addDefaultActions()
public IlvServerAction getDefaultRowSelectAction()
This implementation returns an IlvRowSelectAction
instance.
This method is called by the
addDefaultAction
method.
addDefaultActions()
public void setDefaultRowSelectAction(IlvServerAction defaultRowSelectAction)
defaultRowSelectAction
- The default row select server action.addDefaultActions()
public void setDefaultResizeActivityAction(IlvServerAction defaultResizeActivityAction)
defaultResizeActivityAction
- the default resize activity action.public IlvServerAction getDefaultResizeActivityAction()
IlvServerAction
.© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.