public class

FolderCreateReportXHTMLTransform

extends FolderIconRadioButtonTransform
java.lang.Object
   ↳ com.microstrategy.web.transform.AbstractTransform
     ↳ com.microstrategy.web.transform.AbstractLayoutTransform
       ↳ com.microstrategy.web.app.transforms.AbstractAppTransform
         ↳ com.microstrategy.web.app.transforms.AbstractObjectInfoListTransform
           ↳ com.microstrategy.web.app.transforms.AbstractFolderTransform
             ↳ com.microstrategy.web.app.transforms.FolderIconRadioButtonTransform
               ↳ com.microstrategy.web.app.transforms.FolderCreateReportXHTMLTransform
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

This class extends the FolderIconRadioButtonTransform by specializing in showing the new Reports folder content. It has two sections, showing the blank report on top, and on the bottom the rest of the items on the folder.
The output of this Transform generates well-formed XHTML, and it's designed to use external css files for all formatting.

Summary

Constants
String FP_BLANK_REPORT_ID Constant specifying the name of the formal parameter for defining the ID of the blank report.
String FP_BLANK_VIEW_REPORT_ID Constant specifying the name of the formal parameter for defining the ID of the blank report.
String FP_BLANK_XDA_REPORT_ID
[Expand]
Inherited Constants
From class com.microstrategy.web.app.transforms.FolderIconRadioButtonTransform
From class com.microstrategy.web.app.transforms.AbstractFolderTransform
From class com.microstrategy.web.app.transforms.AbstractObjectInfoListTransform
From class com.microstrategy.web.app.transforms.AbstractAppTransform
Fields
protected WebObjectInfo _blankObject
protected String _blankObjectDesc Property for holding a description for the blank object
protected String _blankObjectHeaderDesc Property for holding a header description for the blank object
protected WebObjectInfo _blankViewReport
protected String _templateHeaderDesc Property for holding a header description for the templates to show with this transform
public FormalParameter blankObjectId Indicates the object ID of the Blank Report.
public FormalParameter blankViewReportId Indicates the object ID of the View Blank Report.
public FormalParameter blankXdaObjectId Indicates the object ID of the Blank XDA Report.
public FormalParameter displaySection Specifies which sections are to be displayed in the Create Report page (Create Report, Other Reports).
public FormalParameter promptCreateStyle Specifies the name of prompt style to use for transforming selected prompted template in Design Mode.
public FormalParameter promptExecuteStyle Specifies the name of prompt style to use for transforming selected prompted template in View Mode.
public FormalParameter promptStyle Specifies the name of prompt style to use for transforming selected prompted template in Create Repor page.
public FormalParameter valueDesignModeCheck Specifies value for checkbox indicating whether or not to run Report/RWD in Design mode.
[Expand]
Inherited Fields
From class com.microstrategy.web.app.transforms.FolderIconRadioButtonTransform
From class com.microstrategy.web.app.transforms.AbstractFolderTransform
From class com.microstrategy.web.app.transforms.AbstractObjectInfoListTransform
From class com.microstrategy.web.app.transforms.AbstractAppTransform
Public Constructors
FolderCreateReportXHTMLTransform()
Default no-argument constructor.
Public Methods
String getCssName(WebObjectInfo object)
Overwrites the parent method by providing a special css style to the blank object.
String getObjectDescription(WebObjectInfo object)
Overwrites the parent method by supplying a default description for the blank object as indicated on the blankObjectId formal parameter
String getObjectName(WebObjectInfo object)
Overwrites the parent method by supplying a default name for the blank object as indicated on the blankObjectId formal parameter
boolean hasCreateBlankObjectPrivileges()
Determines if the user has enough privileges for viewing the blank report option with this transform
boolean hasCreateReportPrivileges()
boolean hasCreateViewReportPrivileges()
boolean hasCreateXdaReportPrivileges()
void initializeTransform(Transformable data)
Extends the parent method by searching for the blank report within the content of the folder, as specified on the blankObjectId formal parameter.
boolean isEmptyList()
Returns true if the list of elements from this folder available for display (getSortedList()) is empty or not.
boolean isEmptyList(WebDisplayUnits list)
This method is deprecated. please use isEmptyList() instead, where the list to be analyzed is the one obtained from getSortedChildUnits().
boolean isObjectVisible(WebObjectInfo object)
Extends parent method by returning false if the object is the blank report.
void renderBlankObject(MarkupOutput out)
Renders the first part of the transform, that is the part where the user might pick a "blank" report to start working.
void renderButtonOptions(MarkupOutput out)
If the user has enough privileges, this method will display by default the option for allowing to run the selected report on design mode.
void renderIconInfo(MarkupOutput out, WebObjectInfo object)
Overwrites the parent method by rendering only the image of the object as an anchor if it's of DssXmlTypeFolder type.
void renderList(MarkupOutput out, WebDisplayUnits list)
This method is deprecated. This method will later on not be called from by default logic on the application, please overwrite the renderList(MarkupOutput) method instead for customizations, the list of elements that the equivalent method for renderTemplateList will obtain the children to display from the getSortedList() output.
void renderNameInfo(MarkupOutput out, WebObjectInfo object)
Overwrites the parent method by rendering only the name of the object if it's of DssXmlTypeFolder type.
void renderTemplateList(MarkupOutput out, WebDisplayUnits list)
Renders the list of templates in this folder.
void renderTemplateList(MarkupOutput out)
Renders the list of templates in this folder.
Protected Methods
Tag generateRadioButtonForObject(WebEvent openEvent, WebObjectInfo object, boolean selected)
Overwrites the parent method by assigning JavaScript code to the onclick event of the input tag if the user is on DHTML mode.
String getArgumentName(WebEvent event, int argumentID)
For the given event, returns the name of the argument with the given ID.
WebEvent getOpenObjectEvent()
Overwrites the original method for returning the WebEventEditReport event instead.
boolean isDesignModeOptionChecked()
Indicates whether or not Design mode checkbox is checked.
void renderDesignModeOption(MarkupOutput out, WebEvent createEvent, boolean designMode)
Render a check box giving the option to have the report selected run in design mode.
void setBoneProperties(JsonGenerator boneProps)
Sets the necessary properties to the bone assigned to this transform (based on the scriptClass formal parameter)
Usually called by renderRegisterBone(MarkupOutput)
Can be overwritten to add or modify bone properties.
[Expand]
Inherited Methods
From class com.microstrategy.web.app.transforms.FolderIconRadioButtonTransform
From class com.microstrategy.web.app.transforms.AbstractFolderTransform
From class com.microstrategy.web.app.transforms.AbstractObjectInfoListTransform
From class com.microstrategy.web.app.transforms.AbstractAppTransform
From class com.microstrategy.web.transform.AbstractLayoutTransform
From class com.microstrategy.web.transform.AbstractTransform
From class java.lang.Object
From interface com.microstrategy.web.app.transforms.AppTransform
From interface com.microstrategy.web.transform.LayoutTransform
From interface com.microstrategy.web.transform.Transform

Constants

public static final String FP_BLANK_REPORT_ID

Constant specifying the name of the formal parameter for defining the ID of the blank report. Value is blankObjectId.

Constant Value: "blankObjectId"

public static final String FP_BLANK_VIEW_REPORT_ID

Constant specifying the name of the formal parameter for defining the ID of the blank report. Value is blankObjectId.

Constant Value: "blankViewReportId"

public static final String FP_BLANK_XDA_REPORT_ID

Constant Value: "blankXdaObjectId"

Fields

protected WebObjectInfo _blankObject

protected String _blankObjectDesc

Property for holding a description for the blank object

protected String _blankObjectHeaderDesc

Property for holding a header description for the blank object

protected WebObjectInfo _blankViewReport

protected String _templateHeaderDesc

Property for holding a header description for the templates to show with this transform

public FormalParameter blankObjectId

Indicates the object ID of the Blank Report.
If found, it will display it inside its own box while rendering the contents of the folder.

public FormalParameter blankViewReportId

Indicates the object ID of the View Blank Report.
If found, it will display it inside its own box while rendering the contents of the folder.

public FormalParameter blankXdaObjectId

Indicates the object ID of the Blank XDA Report.

public FormalParameter displaySection

Specifies which sections are to be displayed in the Create Report page (Create Report, Other Reports).
This formal parameters will denote a number to be used as a flag for the two sections of this page.

public FormalParameter promptCreateStyle

Specifies the name of prompt style to use for transforming selected prompted template in Design Mode.
This formal parameters will denote a text to be used as the name of the prompt style that tells to display 'Save' button in prompted report or Document.

public FormalParameter promptExecuteStyle

Specifies the name of prompt style to use for transforming selected prompted template in View Mode.
This formal parameters will denote a text to be used as the name of the prompt style that tells to display 'Save' button in prompted report or Document.

public FormalParameter promptStyle

Specifies the name of prompt style to use for transforming selected prompted template in Create Repor page.
This formal parameters will denote a text to be used as the name of the prompt style. This value will be passed as an event argument for EnumPageEvents.WebEventEditReport event which will be set in getOpenObjectEvent method.
that tells to display 'Save' button in prompted report or Document.

public FormalParameter valueDesignModeCheck

Specifies value for checkbox indicating whether or not to run Report/RWD in Design mode.
This formal parameter can take any of the following values:

  • 0 - Unchecked
  • 1 - Checked

Keep in mind that this FP will indicate whether or not to check this checkbox. However, there another rule which user must have WebFeatureWebModifyReportList feature enabled.

Public Constructors

public FolderCreateReportXHTMLTransform ()

Default no-argument constructor. Initializes formal parameters.

Public Methods

public String getCssName (WebObjectInfo object)

Overwrites the parent method by providing a special css style to the blank object.

Parameters
object The WebObjectInfo for which it's image name is required.
Returns
  • a String with the name of the CSS class that should be associated with the WebObjectInfo information to display. If the type specified does not match the predefined list of styles, then it returns an empty string. If the object analyzed corresponds to the one specified on the blankObjectId formal parameter then returns "blank".

public String getObjectDescription (WebObjectInfo object)

Overwrites the parent method by supplying a default description for the blank object as indicated on the blankObjectId formal parameter

Parameters
object WebObjectInfo instance from where to retrieve the description
Returns
  • String with the object's description as defined, or a specific descriptor if the object being analyzed is the one defined on the blankObjectId formal parameter.

public String getObjectName (WebObjectInfo object)

Overwrites the parent method by supplying a default name for the blank object as indicated on the blankObjectId formal parameter

Parameters
object WebObjectInfo instance from where to retrieve the name
Returns
  • String with the object's name as defined, or a specific descriptor if the object being analyzed is the one defined on the blankObjectId formal parameter.

public boolean hasCreateBlankObjectPrivileges ()

Determines if the user has enough privileges for viewing the blank report option with this transform

Returns
  • boolean value indicating if the blank object should be available to the user or not.

public boolean hasCreateReportPrivileges ()

Returns
  • boolean value indicating if the blank view report should be available to the user.

public boolean hasCreateViewReportPrivileges ()

Returns
  • boolean value indicating if the blank view report should be available to the user.

public boolean hasCreateXdaReportPrivileges ()

Returns
  • boolean value indicating if the XDA blank report should be available to the user.

public void initializeTransform (Transformable data)

Extends the parent method by searching for the blank report within the content of the folder, as specified on the blankObjectId formal parameter.

Parameters
data Transformable instance with the bean to be transformed.

public boolean isEmptyList ()

Returns true if the list of elements from this folder available for display (getSortedList()) is empty or not.

Returns
  • true if the underlying object list is empty.

public boolean isEmptyList (WebDisplayUnits list)

This method is deprecated.
please use isEmptyList() instead, where the list to be analyzed is the one obtained from getSortedChildUnits().

Indicates if there will be objects to display from the instance sent in as parameter. The check by default is the count of report objects included on the list.

Parameters
list WebDisplayUnits list instance initialized with the objects to render
Returns
  • boolean value indicating if there are objects to be displayed out of this list.

public boolean isObjectVisible (WebObjectInfo object)

Extends parent method by returning false if the object is the blank report. We don't want to display this object as part of the template list since it has already been rendered by its own.

Parameters
object WebObjectInfo instance to check for.
Returns
  • True if object requested is visible, otherwise returns False

public void renderBlankObject (MarkupOutput out)

Renders the first part of the transform, that is the part where the user might pick a "blank" report to start working. If the option is to be shown to the user, it then calls for the renderObject(MarkupOutput, WebObjectInfo) method for the blank template.

Parameters
out MarkupOutput instance to modify with the transform's output. be rendered by this transform, as contents of the folder being analyzed.

public void renderButtonOptions (MarkupOutput out)

If the user has enough privileges, this method will display by default the option for allowing to run the selected report on design mode.

Parameters
out MarkupOutput instance to modify with the transform's output.

public void renderIconInfo (MarkupOutput out, WebObjectInfo object)

Overwrites the parent method by rendering only the image of the object as an anchor if it's of DssXmlTypeFolder type.

Parameters
out MarkupOutput instance to modify with the transform's output.
object WebObjectInfo to have its image rendered.

public void renderList (MarkupOutput out, WebDisplayUnits list)

This method is deprecated.
This method will later on not be called from by default logic on the application, please overwrite the renderList(MarkupOutput) method instead for customizations, the list of elements that the equivalent method for renderTemplateList will obtain the children to display from the getSortedList() output.

Extends the original method by calling instead two methods to render the folder contents to show to the user: renderBlankObject(MarkupOutput) and renderTemplateList(MarkupOutput, WebDisplayUnits)

Parameters
out MarkupOutput instance to modify with the transform's output.
list WebDisplayUnits instance with the list of objects that will be rendered by this transform, as contents of the folder being analyzed.

public void renderNameInfo (MarkupOutput out, WebObjectInfo object)

Overwrites the parent method by rendering only the name of the object if it's of DssXmlTypeFolder type. No radio button is to be created for it.

Parameters
out MarkupOutput instance to modify with the transform's output.
object WebObjectInfo to have its name rendered.

public void renderTemplateList (MarkupOutput out, WebDisplayUnits list)

Renders the list of templates in this folder.

Parameters
out MarkupOutput instance to modify with the transform's output.
list WebDisplayUnits instance with the list of objects that will be rendered by this transform, as contents of the folder being analyzed.

public void renderTemplateList (MarkupOutput out)

Renders the list of templates in this folder. Calls for the other interface of the method sending the sorted child list as parameter.

Parameters
out MarkupOutput instance to modify with the transform's output. be rendered by this transform, as contents of the folder being analyzed.
Throws
WebBeanException if an error happens while rendering this information
WebObjectsException if an error happens while rendering this information

Protected Methods

protected Tag generateRadioButtonForObject (WebEvent openEvent, WebObjectInfo object, boolean selected)

Overwrites the parent method by assigning JavaScript code to the onclick event of the input tag if the user is on DHTML mode.

Parameters
openEvent WebEvent representing the action to do with the given object
object WebObjectInfo currently being processed
selected boolean indicating if the radio button should be selected or not
Returns
  • the Tag initialized instance corresponding to the radio button generated.

protected String getArgumentName (WebEvent event, int argumentID)

For the given event, returns the name of the argument with the given ID. When overriding an specific getEvent method, clients can override this method as well to provide the corresponding argument for the new event. Since the getOpenObjectEvent() method was redefined, this method is also updated for returning the correct object identifier argument from it.

Parameters
event WebEvent from which retrieve the argument
argumentID argument Id from where to get its name.
Returns
  • the argument name as defined by the event.

protected WebEvent getOpenObjectEvent ()

Overwrites the original method for returning the WebEventEditReport event instead.

Returns
  • a WebEvent instance intialized if the application supports it. Otherwise, returns null

protected boolean isDesignModeOptionChecked ()

Indicates whether or not Design mode checkbox is checked.
It reads valueDesignModeCheck which is a custom property end-user can toggled on or off checkbox.

Returns
  • boolean value indicating if the design mode option is checked or not.

protected void renderDesignModeOption (MarkupOutput out, WebEvent createEvent, boolean designMode)

Render a check box giving the option to have the report selected run in design mode. If the event has been customized, then this method should also be overwritten for the event argument identifiers to be correct.

Parameters
out MarkupOutput where the HTML output will be saved
createEvent WebEvent representing the action to do with the given object
designMode boolean indicating if design mode is selected.

protected void setBoneProperties (JsonGenerator boneProps)

Sets the necessary properties to the bone assigned to this transform (based on the scriptClass formal parameter)
Usually called by renderRegisterBone(MarkupOutput)
Can be overwritten to add or modify bone properties.

Parameters
boneProps the JsonGenerator object that contains the collection of bone properties.