LEONARDI Application Composer - 8.9.0.40 by W4 S.A.

leon.app.behavior
Class LyMetricsChartBehavior

java.lang.Object
  extended by leon.app.behavior.LyBehavior
      extended by leon.app.behavior.LyActionBehavior
          extended by leon.app.behavior.LyChartBehavior
              extended by leon.app.behavior.LyMetricsChartBehavior
All Implemented Interfaces:
LyActionBehaviorInterface, LyBehaviorInterface, LyChartBehaviorInterface, LyFormBehaviorInterface, LyGetSessionInterface, LyComparatorInterface

public class LyMetricsChartBehavior
extends LyChartBehavior
implements LyComparatorInterface

This class implements the default behavior for metrics chart actions.


Field Summary
static java.lang.String ACTIONS_BY_DATE_CHART_ACTION_ID
          Identifier for actions by date chart action.
static java.lang.String MAX_ACTIONS_PARAMETER
          Max actions parameter name.
static java.lang.String MAX_CONNECTED_USERS_CHART_ACTION_ID
          Identifier for max connected users chart action.
static java.lang.String METRIC_ACTION_FIELD_ID
          Identifier for action field.
static java.lang.String METRIC_CLASS_FIELD_ID
          Identifier for class field.
static java.lang.String METRIC_END_DATE_FIELD_ID
          Identifier for end date field.
static java.lang.String METRIC_START_DATE_FIELD_ID
          Identifier for start date field.
static java.lang.String METRIC_TYPE_FIELD_ID
          Identifier for type field.
static java.lang.String METRIC_TYPE_SESSION_OPTION_ID
          Identifier for type session option.
static java.lang.String METRIC_USER_FIELD_ID
          Identifier for user field.
static java.lang.String METRIC_VALUE_FIELD_ID
          Identifier for value field.
static java.lang.String MOST_USED_ACTIONS_CHART_ACTION_ID
          Identifier for most used actions chart action.
static java.lang.String SESSIONS_BY_DATE_CHART_ACTION_ID
          Identifier for sessions by date chart action.
static java.lang.String SESSIONS_BY_HOUR_CHART_ACTION_ID
          Identifier for sessions by hour chart action.
static java.lang.String SESSIONS_BY_HOUR_SORT_CRITERION_ID
          Identifier for sessions by hour sort criterion.
static java.lang.String SESSIONS_DURATION_CHART_ACTION_ID
          Identifier for sessions duration chart action.
 
Fields inherited from class leon.app.behavior.LyChartBehavior
__VERSION
 
Fields inherited from interface leon.info.infointerface.LyComparatorInterface
__VERSION
 
Constructor Summary
LyMetricsChartBehavior()
           
 
Method Summary
 int compare(LySortCriterion criterion, LyObject object1, LyObject object2)
          Implementation of the LyComparatorInterface interface.
 java.lang.Object getStringChartValue(LyGraphicalChartController controller, LyFieldInfo fieldInfo, LyObject object, java.lang.Object value, LyChartInfo.Type typeVar, boolean yAxis)
          Computes a printable string (if the given typeVar is text, number or date) or a Vector of strings (if the given fieldInfo is a multiple choice or relation) from the given value.
 boolean reset(LyAreaController areaController, boolean full)
          The controller resets its content.
 
Methods inherited from class leon.app.behavior.LyChartBehavior
completeChart, displayLegendEmptyValues, generateSensitiveAreas, getBarLegendLabel, getChartContext, getGroupFields, getImage, getScatterPlotLabel, getScatterPlotLegendLabel, getValue, getXFields, getYFields, isDisplayed, isLegendRightPositionned, isViewResizable
 
Methods inherited from class leon.app.behavior.LyActionBehavior
endAction, getClientContext, getContextTitle, getHelpFile, getImage, getImageTooltip, getKeyValue, getMenuItemImage, getTitle, startAction
 
Methods inherited from class leon.app.behavior.LyBehavior
free, getSession, handleDemand, init
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface leon.app.behaviorinterface.LyActionBehaviorInterface
endAction, getClientContext, getContextTitle, getHelpFile, getImage, getImageTooltip, getKeyValue, getMenuItemImage, getTitle, startAction
 
Methods inherited from interface leon.app.behaviorinterface.LyBehaviorInterface
free, handleDemand, init
 

Field Detail

SESSIONS_BY_DATE_CHART_ACTION_ID

public static final java.lang.String SESSIONS_BY_DATE_CHART_ACTION_ID
Identifier for sessions by date chart action.

See Also:
Constant Field Values

SESSIONS_BY_HOUR_CHART_ACTION_ID

public static final java.lang.String SESSIONS_BY_HOUR_CHART_ACTION_ID
Identifier for sessions by hour chart action.

See Also:
Constant Field Values

SESSIONS_DURATION_CHART_ACTION_ID

public static final java.lang.String SESSIONS_DURATION_CHART_ACTION_ID
Identifier for sessions duration chart action.

See Also:
Constant Field Values

ACTIONS_BY_DATE_CHART_ACTION_ID

public static final java.lang.String ACTIONS_BY_DATE_CHART_ACTION_ID
Identifier for actions by date chart action.

See Also:
Constant Field Values

MOST_USED_ACTIONS_CHART_ACTION_ID

public static final java.lang.String MOST_USED_ACTIONS_CHART_ACTION_ID
Identifier for most used actions chart action.

See Also:
Constant Field Values

MAX_CONNECTED_USERS_CHART_ACTION_ID

public static final java.lang.String MAX_CONNECTED_USERS_CHART_ACTION_ID
Identifier for max connected users chart action.

See Also:
Constant Field Values

MAX_ACTIONS_PARAMETER

public static final java.lang.String MAX_ACTIONS_PARAMETER
Max actions parameter name.

See Also:
Constant Field Values

METRIC_START_DATE_FIELD_ID

public static final java.lang.String METRIC_START_DATE_FIELD_ID
Identifier for start date field.

See Also:
Constant Field Values

METRIC_END_DATE_FIELD_ID

public static final java.lang.String METRIC_END_DATE_FIELD_ID
Identifier for end date field.

See Also:
Constant Field Values

METRIC_USER_FIELD_ID

public static final java.lang.String METRIC_USER_FIELD_ID
Identifier for user field.

See Also:
Constant Field Values

METRIC_TYPE_FIELD_ID

public static final java.lang.String METRIC_TYPE_FIELD_ID
Identifier for type field.

See Also:
Constant Field Values

METRIC_TYPE_SESSION_OPTION_ID

public static final java.lang.String METRIC_TYPE_SESSION_OPTION_ID
Identifier for type session option.

See Also:
Constant Field Values

METRIC_ACTION_FIELD_ID

public static final java.lang.String METRIC_ACTION_FIELD_ID
Identifier for action field.

See Also:
Constant Field Values

METRIC_CLASS_FIELD_ID

public static final java.lang.String METRIC_CLASS_FIELD_ID
Identifier for class field.

See Also:
Constant Field Values

METRIC_VALUE_FIELD_ID

public static final java.lang.String METRIC_VALUE_FIELD_ID
Identifier for value field.

See Also:
Constant Field Values

SESSIONS_BY_HOUR_SORT_CRITERION_ID

public static final java.lang.String SESSIONS_BY_HOUR_SORT_CRITERION_ID
Identifier for sessions by hour sort criterion.

See Also:
Constant Field Values
Constructor Detail

LyMetricsChartBehavior

public LyMetricsChartBehavior()
Method Detail

getStringChartValue

public java.lang.Object getStringChartValue(LyGraphicalChartController controller,
                                            LyFieldInfo fieldInfo,
                                            LyObject object,
                                            java.lang.Object value,
                                            LyChartInfo.Type typeVar,
                                            boolean yAxis)
Computes a printable string (if the given typeVar is text, number or date) or a Vector of strings (if the given fieldInfo is a multiple choice or relation) from the given value.

Specified by:
getStringChartValue in interface LyChartBehaviorInterface
Overrides:
getStringChartValue in class LyChartBehavior
Parameters:
controller - the current controller instance
fieldInfo - the concerned field info
object - the concerned object (may be null)
value - the value to transform into a string. It comes from the given fieldInfo
typeVar - the field type defined in LyChartInfo such as LyChartInfo.Type.DATE, LyChartInfo.Type.NUMBER and LyChartInfo.Type.TEXT
yAxis - indicates whether the value is computed for y or x axis
Returns:
a String corresponding to the value, or a Vector of Strings if it is a multiple choice or relation.
See Also:
LyChartInfo

reset

public boolean reset(LyAreaController areaController,
                     boolean full)
The controller resets its content. This method is the right place to add extra processing when the view is set.
The default implementation does nothing and returns true.

Specified by:
reset in interface LyActionBehaviorInterface
Overrides:
reset in class LyActionBehavior
Parameters:
areaController - the current LyAreaController instance
full - indicates if the controller performed a full reset of its content or a partial reset. The meaning of a full reset depends on controller implementation.
Returns:
true

compare

public int compare(LySortCriterion criterion,
                   LyObject object1,
                   LyObject object2)
Implementation of the LyComparatorInterface interface.

Specified by:
compare in interface LyComparatorInterface
Parameters:
criterion - the sort criterion.
object1 - the first object
object2 - the second object
Returns:
O if the two values are equals, a positive value if value of object1 is "greater" than value of object2, a negative value otherwise.

(c) January 2013 - W4 S.A.

Website: W4 S.A., contact us: support@w4global.com