com.sas.dataselectors.filters.timebased.olap
Interface OLAPTimeBasedFilterAdapterInterface

All Superinterfaces:
java.lang.Cloneable, SelectorCommitInterface
All Known Implementing Classes:
OLAPTimeBasedFilterAdapter

public interface OLAPTimeBasedFilterAdapterInterface
extends SelectorCommitInterface, java.lang.Cloneable

Defines methods and properties required for an adapter implementation of the OLAPTimeBasedFilterSelector.

Since:
3.1.4
See Also:
com.sas.servlet.tbeans.dataselectors.filters.timebased.olap.html.OLAPtimeBasedFilterSelector, com.sas.servlet.tbeans.dataselectors.filters.timebased.olap.html.OLAPtimeBasedFilterSelectorPanel

Field Summary
 
Fields inherited from interface com.sas.dataselectors.SelectorCommitInterface
EXCEPTION_OCCURRED
 
Method Summary
 java.lang.Object clone()
          Returns a duplicate and seperate instance of the implementing object.
 java.lang.String getCurrentFirstPeriod()
           
 java.lang.String getCurrentFirstPeriodLabel()
           
 java.lang.String getCurrentLastPeriod()
           
 java.lang.String getCurrentLastPeriodLabel()
           
 java.lang.String getDefaultEndingPeriodOption()
          Returns the default ending period option.
 java.lang.String getDefaultNumberOfPeriods()
          Returns the default number of periods.
 java.lang.String getDefaultSelectOption()
          Returns the default select option.
 java.lang.String getDefaultShowOption()
          Returns the default show option.
 java.lang.String getDefaultStartingPeriodOption()
          Returns the default starting period option.
 java.lang.String getEndingPeriodLabel()
          Returns the localized ending period label for the currently defined period.
 java.lang.String getEndingPeriodOption()
          Returns the the currently selected 'Ending -period-:' option
 java.util.List getEndingPeriodOptionsList()
          Returns the list of options the user can choose for a ending period.
 javax.swing.tree.TreeModel getEndTreeModel()
           
 java.lang.Object getFilterExpression()
          Returns the filter expression associated with the adapter.
 java.util.List getFullShowOptionsList()
          Returns the list of all possible viewing options the user can choose from regardless of the period type.
 java.util.Locale getLocale()
          Returns the locale
 java.lang.String getLocalizedAcrossLabelFirstParameter()
           
 java.lang.String getLocalizedAcrossLabelSecondParameter()
           
 java.lang.String getLocalizedNPeriodsLabelParameter()
           
 java.lang.String getLocalizedPeriodType()
           
 java.lang.String getLocalizedRangeLabelParameter()
           
 java.lang.String getLocalizedSelectLabelParameter()
           
 java.lang.String getNumberOfPeriods()
          Returns the number of periods entered for the 'N -periods- where N =' view
 java.lang.String getPeriodType()
          Returns the period type currently selected
 int getPeriodType(java.lang.String uniquePeriodName)
          Returns the integer period type for the specified period name.
 java.util.List getPeriodTypes()
          Returns the list of period types which the user can choose from
 java.util.List getSelectablePeriods()
          Returns a List of selectable periods used to populate the 'Select' CheckBoxList.
 java.lang.String getSelectedEndingPeriod()
          Returns the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.
 java.lang.String getSelectedEndingPeriodLabel()
          Returns the label of the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.
 java.lang.String[] getSelectedPeriods()
          Returns the values selected in the 'Select -periods-:' TreeView.
 java.lang.String getSelectedStartingPeriod()
          Returns the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.
 java.lang.String getSelectedStartingPeriodLabel()
          Returns the label of the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.
 java.lang.String getSelectOption()
          Returns the the currently selected 'Select:' option
 java.util.List getSelectOptionsList()
          Returns the list of options the user can choose for a date range.
 java.lang.String getShowOption()
          Returns the currently selected show option
 java.util.List getShowOptionsList()
          Returns the list of viewing options the user can choose from for a specific period type.
 java.lang.String getStartingPeriodLabel()
          Returns the localized starting period label for the currently defined period.
 java.lang.String getStartingPeriodOption()
          Returns the the currently selected 'Starting -period-:' option
 java.util.List getStartingPeriodOptionsList()
          Returns the list of options the user can choose for a starting period.
 javax.swing.tree.TreeModel getStartTreeModel()
           
 boolean isModified()
          Returns true if the user explicitally modified the initial values, false otherwise.
 boolean isPanelVisible()
           
 void resetValuesToDefault()
          Resets the values in the adapter to their default.
 void setEndingPeriodOption(java.lang.String value)
          Sets the selected 'Ending -period-:' option
 void setFilterExpression(java.lang.Object filterExpression)
          Sets the filter expression associated with the adapter.
 void setFilterStep(java.lang.Object step)
          Sets the filter step associated with the adapter.
 void setLocale(java.util.Locale locale)
          Sets the locale
 void setModified(boolean modified)
          Sets the modified flag.
 void setNumberOfPeriods(java.lang.String value)
          Sets the number of periods entered for the 'N -periods- where N =' view
 void setPanelVisible(boolean visible)
          To indicates if the OLAPTimeBasedFilterSelectorPanel should or should not be displayed
 void setPeriodType(java.lang.String value)
          Sets the period type
 void setSelectedEndingPeriod(java.lang.String value)
          Sets the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.
 void setSelectedEndingPeriod(javax.swing.tree.TreeNode treeNode)
          Sets the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.
 void setSelectedPeriods(java.lang.String[] values)
          Sets the values selected in the 'Select -periods-:' TreeView.
 void setSelectedStartingPeriod(java.lang.String value)
          Sets the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.
 void setSelectedStartingPeriod(javax.swing.tree.TreeNode treeNode)
          Sets the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.
 void setSelectOption(java.lang.String value)
          Sets the selected 'Select:' option
 void setShowOption(java.lang.String value)
          Sets the selected show option
 void setStartingPeriodOption(java.lang.String value)
          Sets the selected 'Starting -period-:' option
 
Methods inherited from interface com.sas.dataselectors.SelectorCommitInterface
commit, getPropertiesBean
 

Method Detail

setLocale

void setLocale(java.util.Locale locale)
Sets the locale

Parameters:
locale - The locale.

getLocale

java.util.Locale getLocale()
Returns the locale

Returns:
The locale.

setFilterExpression

void setFilterExpression(java.lang.Object filterExpression)
Sets the filter expression associated with the adapter. Used for the Swing version of the selector that uses this adapter.

Parameters:
filterExpression - A filter expression to associate with the adapter.

getFilterExpression

java.lang.Object getFilterExpression()
Returns the filter expression associated with the adapter. Used for the Swing version of the selector that uses this adapter.

Returns:
The associated filter expression.

setFilterStep

void setFilterStep(java.lang.Object step)
Sets the filter step associated with the adapter. Used for the Web version of the selector that uses this adapter.

Parameters:
step - the filter step associated with the adapter.

getPeriodTypes

java.util.List getPeriodTypes()
Returns the list of period types which the user can choose from

Returns:
a List of String[2] elements where the first String is the localized text and the second String is a unique id associated to the localized text. Example [0] = "Years" and [1] = "YEAR".

getPeriodType

int getPeriodType(java.lang.String uniquePeriodName)
Returns the integer period type for the specified period name.

Parameters:
uniquePeriodName - A string representing the unique name of the period to query.
Returns:
The integer value representing the period type.

getPeriodType

java.lang.String getPeriodType()
Returns the period type currently selected

Returns:
something like

setPeriodType

void setPeriodType(java.lang.String value)
Sets the period type

Parameters:
value - the period type

getShowOptionsList

java.util.List getShowOptionsList()
Returns the list of viewing options the user can choose from for a specific period type.
Example for a period type like Month, the user can choose to see either 'N months' or 'Months across years' or 'Range of months' etc.
While for a period type like Year, the user can only choose to see either 'N years' or 'Range of years'.

Returns:
a List of String[2] elements where the first String is the localized text and the second String is a unique id associated to the localized text. Example [0] = "Months across years" and [1] = "OTFS_SHOW_RADIO_ACROSS_VALUE".

getFullShowOptionsList

java.util.List getFullShowOptionsList()
Returns the list of all possible viewing options the user can choose from regardless of the period type.
For example 'N months' or 'Months across years' or 'Range of months' etc. It's a utility method only used to initially populate the JSP version of the 'Show:' radio box with all the possible values. At run time those values will be hidden/displayed depending on the selected period type.
Internal API only.

Returns:
a List of String[2] elements where the first String is the localized text and the second String is a unique id associated to the localized text. Example [0] = "Months across years" and [1] = "OTFS_SHOW_RADIO_ACROSS_VALUE".

getShowOption

java.lang.String getShowOption()
Returns the currently selected show option

Returns:
one of OLAPTimeBasedFilterConstants.OTFS_SHOW_RADIO_N_PERIODS_VALUE OLAPTimeBasedFilterConstants.OTFS_SHOW_RADIO_ACROSS_VALUE OLAPTimeBasedFilterConstants.OTFS_SHOW_RADIO_RANGE_OF_PERIODS_VALUE

setShowOption

void setShowOption(java.lang.String value)
Sets the selected show option

Parameters:
value - one of OLAPTimeBasedFilterConstants.OTFS_SHOW_RADIO_N_PERIODS_VALUE OLAPTimeBasedFilterConstants.OTFS_SHOW_RADIO_ACROSS_VALUE OLAPTimeBasedFilterConstants.OTFS_SHOW_RADIO_RANGE_OF_PERIODS_VALUE

getNumberOfPeriods

java.lang.String getNumberOfPeriods()
Returns the number of periods entered for the 'N -periods- where N =' view

Returns:
a String containing an integer number

setNumberOfPeriods

void setNumberOfPeriods(java.lang.String value)
Sets the number of periods entered for the 'N -periods- where N =' view

Parameters:
value - the number of periods

getSelectOptionsList

java.util.List getSelectOptionsList()
Returns the list of options the user can choose for a date range. Example either 'Starting period' or 'Ending period'.

Returns:
a List of String[2] elements where the first String is the localized text and the second String is a unique id associated to the localized text. Example [0] = "Starting period" and [1] = "OTFS_SELECT_RADIO_STARTING_PERIOD_VALUE".

getSelectOption

java.lang.String getSelectOption()
Returns the the currently selected 'Select:' option

Returns:
one of OLAPTimeBasedFilterConstants.OTFS_SELECT_RADIO_STARTING_PERIOD_VALUE OLAPTimeBasedFilterConstants.OTFS_SELECT_RADIO_ENDING_PERIOD_VALUE

setSelectOption

void setSelectOption(java.lang.String value)
Sets the selected 'Select:' option

Parameters:
value - one of OLAPTimeBasedFilterConstants.OTFS_SELECT_RADIO_STARTING_PERIOD_VALUE OLAPTimeBasedFilterConstants.OTFS_SELECT_RADIO_ENDING_PERIOD_VALUE

getStartingPeriodLabel

java.lang.String getStartingPeriodLabel()
Returns the localized starting period label for the currently defined period. Examples: "Starting year:", "Starting month:", etc.

Returns:
The starting label for the current period

getStartingPeriodOptionsList

java.util.List getStartingPeriodOptionsList()
Returns the list of options the user can choose for a starting period. Example either 'The first -period-' or 'Selected -period-'.

Returns:
a List of String[2] elements where the first String is the localized text and the second String is a unique id associated to the localized text. Example [0] = "The first month" and [1] = "OTFS_STARTING_RADIO_FIRST_PERIOD_VALUE".

getStartingPeriodOption

java.lang.String getStartingPeriodOption()
Returns the the currently selected 'Starting -period-:' option

Returns:
one of OLAPTimeBasedFilterConstants.OTFS_STARTING_RADIO_FIRST_PERIOD_VALUE OLAPTimeBasedFilterConstants.OTFS_STARTING_ENDING_RADIO_SELECTED_PERIOD_VALUE

setStartingPeriodOption

void setStartingPeriodOption(java.lang.String value)
Sets the selected 'Starting -period-:' option

Parameters:
value - one of OLAPTimeBasedFilterConstants.OTFS_STARTING_RADIO_FIRST_PERIOD_VALUE OLAPTimeBasedFilterConstants.OTFS_STARTING_ENDING_RADIO_SELECTED_PERIOD_VALUE

getEndingPeriodLabel

java.lang.String getEndingPeriodLabel()
Returns the localized ending period label for the currently defined period. Examples: "Ending year:", "Ending month:", etc.

Returns:
The ending label for the current period

getEndingPeriodOptionsList

java.util.List getEndingPeriodOptionsList()
Returns the list of options the user can choose for a ending period. Example either 'The last -period-' or 'Selected -period-'.

Returns:
a List of String[2] elements where the first String is the localized text and the second String is a unique id associated to the localized text. Example [0] = "The last month" and [1] = "OTFS_ENDING_RADIO_LAST_PERIOD_VALUE".

getEndingPeriodOption

java.lang.String getEndingPeriodOption()
Returns the the currently selected 'Ending -period-:' option

Returns:
one of OLAPTimeBasedFilterConstants.OTFS_ENDING_RADIO_LAST_PERIOD_VALUE OLAPTimeBasedFilterConstants.OTFS_STARTING_ENDING_RADIO_SELECTED_PERIOD_VALUE

setEndingPeriodOption

void setEndingPeriodOption(java.lang.String value)
Sets the selected 'Ending -period-:' option

Parameters:
value - one of OLAPTimeBasedFilterConstants.OTFS_ENDING_RADIO_LAST_PERIOD_VALUE OLAPTimeBasedFilterConstants.OTFS_STARTING_ENDING_RADIO_SELECTED_PERIOD_VALUE

getLocalizedSelectLabelParameter

java.lang.String getLocalizedSelectLabelParameter()
Returns:
the localized parameter to put into the label of the Select radiobox, something like 'months' or 'years' so that we can create the full localized label for the Select radiobox, something like 'Select months:' or 'Select years:' An empty string is returned if it cannot provide with a localized one.

getLocalizedNPeriodsLabelParameter

java.lang.String getLocalizedNPeriodsLabelParameter()
Returns:
the localized parameter to put into the label of the 'N Periods' item of th 'Show' radiobox, something like 'months' or 'years' so that we can create the full localized label for that item, something like 'N months where N =' or 'N years where N =' An empty string is returned if it cannot provide with a localized one.

getLocalizedAcrossLabelFirstParameter

java.lang.String getLocalizedAcrossLabelFirstParameter()
Returns:
the localized first parameter to put into the label of the 'Across periods' item of th 'Show' radiobox, something like 'Months' or 'Days' so that we can create the full localized label for that item, something like 'Months across years' or 'Days across months' An empty string is returned if it cannot provide with a localized one.

getLocalizedAcrossLabelSecondParameter

java.lang.String getLocalizedAcrossLabelSecondParameter()
Returns:
the localized second parameter to put into the label of the 'Across periods' item of th 'Show' radiobox, something like 'years' or 'months' so that we can create the full localized label for that item, something like 'Months across years' or 'Days across months' An empty string is returned if it cannot provide with a localized one.

getLocalizedRangeLabelParameter

java.lang.String getLocalizedRangeLabelParameter()
Returns:
the localized parameter to put into the label of the 'Range of' item of th 'Show' radiobox, something like 'months' or 'years' so that we can create the full localized label for that item, something like 'Range of months' or 'Range of years' An empty string is returned if it cannot provide with a localized one.

getSelectablePeriods

java.util.List getSelectablePeriods()
Returns a List of selectable periods used to populate the 'Select' CheckBoxList.

Returns:
the List of String[2] elements where the first String is the localized text and the second String is a unique id associated to the localized text. Example [0] = "January" and [1] = "DIR_1".

getLocalizedPeriodType

java.lang.String getLocalizedPeriodType()
Returns:
the localized period type, something like 'month' or 'year' so that we can create localized labels like 'The first month', 'The first year', 'The last month', 'The last year', 'Selected month' and 'Selected year'

getCurrentFirstPeriod

java.lang.String getCurrentFirstPeriod()
Returns:
the current value of the 'The first xx' period, something like '[TIME].[All TIME].[2000].[1].[1]' An empty string is returned if it cannot provide with a value.

getCurrentFirstPeriodLabel

java.lang.String getCurrentFirstPeriodLabel()
Returns:
the current label of the 'The first xx' period, something like '2000.1.1' An empty string is returned if it cannot provide with a label.

getStartTreeModel

javax.swing.tree.TreeModel getStartTreeModel()
Returns:
return the model for the 'Starting xx' TreeView

getEndTreeModel

javax.swing.tree.TreeModel getEndTreeModel()
Returns:
return the model for the 'Ending xx' TreeView

getCurrentLastPeriod

java.lang.String getCurrentLastPeriod()
Returns:
the current value of the 'The last xx' period, something like '[TIME].[All TIME].[2001].[4].[12]' An empty string is returned if it cannot provide with a value.

getCurrentLastPeriodLabel

java.lang.String getCurrentLastPeriodLabel()
Returns:
the current label of the 'The last xx' period, something like '2001.4.12' An empty string is returned if it cannot provide with a value.

getSelectedStartingPeriod

java.lang.String getSelectedStartingPeriod()
Returns the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

Returns:
the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

getSelectedStartingPeriodLabel

java.lang.String getSelectedStartingPeriodLabel()
Returns the label of the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

Returns:
the label of the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

setSelectedStartingPeriod

void setSelectedStartingPeriod(java.lang.String value)
Sets the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

Parameters:
value - the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

setSelectedStartingPeriod

void setSelectedStartingPeriod(javax.swing.tree.TreeNode treeNode)
Sets the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

Parameters:
value - A TreeNode representing the value selected in the 'Selected -period-:' TreeView of the 'Starting -period-:' radio box.

getSelectedEndingPeriod

java.lang.String getSelectedEndingPeriod()
Returns the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

Returns:
the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

getSelectedEndingPeriodLabel

java.lang.String getSelectedEndingPeriodLabel()
Returns the label of the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

Returns:
the label of the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

setSelectedEndingPeriod

void setSelectedEndingPeriod(java.lang.String value)
Sets the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

Parameters:
value - the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

setSelectedEndingPeriod

void setSelectedEndingPeriod(javax.swing.tree.TreeNode treeNode)
Sets the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

Parameters:
value - A TreeNode representing the value selected in the 'Selected -period-:' TreeView of the 'Ending -period-:' radio box.

getSelectedPeriods

java.lang.String[] getSelectedPeriods()
Returns the values selected in the 'Select -periods-:' TreeView.

Returns:
the values selected in the 'Select -periods-:' TreeView.

setSelectedPeriods

void setSelectedPeriods(java.lang.String[] values)
Sets the values selected in the 'Select -periods-:' TreeView.

Parameters:
values - the values selected in the 'Select -periods-:' TreeView.

setPanelVisible

void setPanelVisible(boolean visible)
To indicates if the OLAPTimeBasedFilterSelectorPanel should or should not be displayed

Parameters:
visible - true if the OLAPTimeBasedFilterSelectorPanel should be displayed, false otherwise

isPanelVisible

boolean isPanelVisible()
Returns:
true if the OLAPTimeBasedFilterSelectorPanel should be displayed, false otherwise

resetValuesToDefault

void resetValuesToDefault()
Resets the values in the adapter to their default.


getDefaultNumberOfPeriods

java.lang.String getDefaultNumberOfPeriods()
Returns the default number of periods.

Returns:
the default number of periods.

getDefaultShowOption

java.lang.String getDefaultShowOption()
Returns the default show option.

Returns:
the default show option.

getDefaultSelectOption

java.lang.String getDefaultSelectOption()
Returns the default select option.

Returns:
the default select option.

getDefaultStartingPeriodOption

java.lang.String getDefaultStartingPeriodOption()
Returns the default starting period option.

Returns:
the default starting period option.

getDefaultEndingPeriodOption

java.lang.String getDefaultEndingPeriodOption()
Returns the default ending period option.

Returns:
the default ending period option.

setModified

void setModified(boolean modified)
Sets the modified flag.

Parameters:
modified - true if the user explicitally modified the initial values, false otherwise.

isModified

boolean isModified()
Returns true if the user explicitally modified the initial values, false otherwise.

Returns:
true if the user explicitally modified the initial values, false otherwise.

clone

java.lang.Object clone()
Returns a duplicate and seperate instance of the implementing object.

Returns:
A clone of the object being called upon.



Copyright © 2009 SAS Institute Inc. All Rights Reserved.