com.ge.research.acuity.ui.helpers
Class PresentationParameterToUIEditPropertyMap

java.lang.Object
  extended bycom.ge.research.acuity.ui.helpers.PresentationParameterToUIEditPropertyMap

public class PresentationParameterToUIEditPropertyMap
extends java.lang.Object

This class holds all of the information necessary to render an input mechanism for modifying the value of a PresentationObject's parameters.

Version:
$Revision: 1.2 $ $Date: 2007/03/08 16:14:15 $
Author:
garbiras
Created on:
Feb 17, 2005

Constructor Summary
PresentationParameterToUIEditPropertyMap()
           
 
Method Summary
static boolean allowsChoices(java.lang.Class cls)
          Tests to see if the argument class supports the concept of allowing slectable choices.
static java.util.Map getEditChoices(java.lang.String attributeName, java.lang.Class poCls)
          Returns the set of possible choices for the argument presentation parameter constant.
static java.lang.String getEditNature(java.lang.String attributeName)
          Returns the presentation nature to be used for the input mechanism for the argument presentation parameter.
static java.lang.Class getEditObjectClass(java.lang.String nature)
          Returns the acuity ui class to be used for an input mechanism of the argument nature.
static java.lang.String getEditPrompt(java.lang.String attributeName)
          Returns the prompt to be used for user manipulation of parameter values.
static boolean isPresentationParameter(java.lang.String attributeName)
          Tests to see if the supplied test case is one of the presentation parameter constant values defined
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PresentationParameterToUIEditPropertyMap

public PresentationParameterToUIEditPropertyMap()
Method Detail

allowsChoices

public static boolean allowsChoices(java.lang.Class cls)
Tests to see if the argument class supports the concept of allowing slectable choices.

Parameters:
cls - the acuity ui class to test for the ability to support selectable choices
Returns:
true if the argument class is one that supports the concept of selectable choices

isPresentationParameter

public static boolean isPresentationParameter(java.lang.String attributeName)
Tests to see if the supplied test case is one of the presentation parameter constant values defined

Parameters:
attributeName - the test case to identify as a known presentation parameter or not
Returns:
true if the argument represents a known presentation parameter; false otherwise.
See Also:
PresentationParameterConstants.isPresentationParameter(java.lang.String)

getEditNature

public static java.lang.String getEditNature(java.lang.String attributeName)
Returns the presentation nature to be used for the input mechanism for the argument presentation parameter.

Parameters:
attributeName - the presentation parameter to get the input mechanism presentation nature for
Returns:
The presentation nature for the input mechanism associated with the argument presentation parameter.

getEditObjectClass

public static java.lang.Class getEditObjectClass(java.lang.String nature)
Returns the acuity ui class to be used for an input mechanism of the argument nature.

Parameters:
nature - the presentation nature for the input mechanism
Returns:
The acuity ui class associated with rendering the input mechanism for the argument nature.

getEditChoices

public static java.util.Map getEditChoices(java.lang.String attributeName,
                                           java.lang.Class poCls)
Returns the set of possible choices for the argument presentation parameter constant. The class argument is used when the request presentation parameter is the PresentationParameterConstants.NATURE parameter, to filter the list of possible choices to those valid for the requesting class type.

Parameters:
attributeName - the presentation parameter constant to get possible values for
poCls - the acuity ui class for which the presentation parameter choices is being sought
Returns:
A mapping of possible choice values to their display strings, for the argument presentation parameter constant, if they exist. null if no choices can be found for the presentation parameter.

getEditPrompt

public static java.lang.String getEditPrompt(java.lang.String attributeName)
Returns the prompt to be used for user manipulation of parameter values.

Parameters:
attributeName - the presentation parameter to get the user propmt for
Returns:
The user propmt for the input mechanism for the presentation parameter value.