public class

AttributeFormsEditorTransform

extends AbstractEditorTransform
implements LayoutTransform
java.lang.Object
   ↳ com.microstrategy.web.transform.AbstractTransform
     ↳ com.microstrategy.web.transform.AbstractLayoutTransform
       ↳ com.microstrategy.web.app.transforms.AbstractAppTransform
         ↳ com.microstrategy.web.app.transforms.AbstractEditorTransform
           ↳ com.microstrategy.web.app.transforms.AttributeFormsEditorTransform

Class Overview

This class generates the output for the AttributeFormsEditorBean. It is used to allow users to select the forms of an attribute to be displayed in a grid.

The forms are displayed in a "shopping cart" interface, that is, a list of available forms is rendered on the left, and the list of selected forms is rendered on the right. Users can select forms and move them from the available to the selected and the other way around. To display the shopping cart this Transform utilizes a Cart GUI-element which provides all the necessary infrastructure to generate the corresponding HTML.

In some scenarios this Transform may also presents a dropdown list which allows the user to select the corresponding attribute to whom the attribute forms shall be selected. This is controlled by the showAttributeList() method.

This Transform implements LayoutTransform, therefore its render methods can be invoked using a custom layout-xml. When this is the case, the layout-xml specified in the style-catalog controls which methods are called and in which order. Otherwise, the default output of this transform is divided as follows:
     EditorContents
     -----------------------------------------------------
     |   Attribute list  | submitButton                  |
     -----------------------------------------------------
     |                                                   |
     |   Attribute Forms List                            |
     |                                                   |
     |                                                   |
     - - - - - - - - - - - - - - - - - - - - - - - - - - -
 

Summary

[Expand]
Inherited Constants
From class com.microstrategy.web.app.transforms.AbstractEditorTransform
From class com.microstrategy.web.app.transforms.AbstractAppTransform
Fields
public FormalParameter availableSize Specifies the size of the Available listbox of the shopping cart.
public FormalParameter goImage Indicates the image to use for the submit button.
[Expand]
Inherited Fields
From class com.microstrategy.web.app.transforms.AbstractEditorTransform
From class com.microstrategy.web.app.transforms.AbstractAppTransform
Public Constructors
AttributeFormsEditorTransform()
Default empty constructor.
Public Methods
String getDescription()
Returns a textual description of this transform to be used in WYSIWYG tools.
Class getSupportedBeanType()
Returns the class of the bean supported by this transform, in this case:
AttributeFormsEditorBean.class
void initializeImages()
Initialize the images to be used by this transform.
void initializeTransform(Transformable data)
This method initializes the private and protected fields of the transform.
void renderAttributeList(MarkupOutput out)
Generates a dropdown with the list of attributes available in the report.
void renderCart(MarkupOutput out)
Generates the "shopping cart" with the list of available and selected attribute forms.
void renderEditorContents(MarkupOutput out)
Main entry point of this transform.
void renderSubmitButton(MarkupOutput out)
Generates the HTML for the button that applies editor changes.
boolean showAttributeList()
Controls whether the attribute list dropdown should be displayed to the user.
Protected Methods
WebEvent getAttributeFormsProcessEvent()
Returns an instance of the event responsible for processing the editor's actions
Cart getCart()
Creates and initializes the Cart instance used by this Transform.
void initializeCart(Cart cart)
Initializes the Cart instance used by this Transform.
void renderHiddenInputs(MarkupOutput out)
Generates the hidden <INPUT> tags required by the AttributeFormsProcessEvent.
[Expand]
Inherited Methods
From class com.microstrategy.web.app.transforms.AbstractEditorTransform
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

Fields

public FormalParameter availableSize

Specifies the size of the Available listbox of the shopping cart.

public FormalParameter goImage

Indicates the image to use for the submit button.

Public Constructors

public AttributeFormsEditorTransform ()

Default empty constructor. Initialize formal parameters.

Public Methods

public String getDescription ()

Returns a textual description of this transform to be used in WYSIWYG tools.

Returns
  • "This class generates the output for the AttributeFormsEditorBean. It is used to allow users to select the forms of an attribute to be displayed in a grid."

public Class getSupportedBeanType ()

Returns the class of the bean supported by this transform, in this case:

AttributeFormsEditorBean.class

Returns
  • AttributeFormsEditorBean.class

public void initializeImages ()

Initialize the images to be used by this transform.

public void initializeTransform (Transformable data)

This method initializes the private and protected fields of the transform.

Parameters
data bean that will be transformed

public void renderAttributeList (MarkupOutput out)

Generates a dropdown with the list of attributes available in the report.

Parameters
out MarkupOutput to generate the HTML.

public void renderCart (MarkupOutput out)

Generates the "shopping cart" with the list of available and selected attribute forms. This method retrieve the forms list from getAttributeForms(), with it, it populates two CartElements collections and then delegates to the Cart GUI-element the HTML generation.

Parameters
out MarkupOutput to generate the HTML.

public void renderEditorContents (MarkupOutput out)

Main entry point of this transform. Generates the graphical output for this editor.

Parameters
out MarkupOutput to generate the HTML.

public void renderSubmitButton (MarkupOutput out)

Generates the HTML for the button that applies editor changes.

Parameters
out MarkupOutput to generate the HTML.

public boolean showAttributeList ()

Controls whether the attribute list dropdown should be displayed to the user. It will return false in DHTML mode, or the value of the getShowAttributeList() method.

Returns
  • true if the attribute list should be displayed.

Protected Methods

protected WebEvent getAttributeFormsProcessEvent ()

Returns an instance of the event responsible for processing the editor's actions

Returns
  • the EnumAttributeFormsEditorEvents.WebEventAttributeFormsProcess event

protected Cart getCart ()

Creates and initializes the Cart instance used by this Transform.

Returns
  • The Cart object used to render the available and selected attributes forms.

protected void initializeCart (Cart cart)

Initializes the Cart instance used by this Transform.

Parameters
cart Cart to be initialzied.

protected void renderHiddenInputs (MarkupOutput out)

Generates the hidden <INPUT> tags required by the AttributeFormsProcessEvent.

Parameters
out MarkupOutput to generate the HTML.