Package com.microstrategy.web.app.beans
Class ReportPreferencePropertyListMapper
- java.lang.Object
-
- com.microstrategy.web.app.beans.ReportPreferencePropertyListMapper
-
- Direct Known Subclasses:
ExportReportPreferencePropertyListMapper,PDFReportPreferencePropertyListMapper,PrintReportPreferencePropertyListMapper
public abstract class ReportPreferencePropertyListMapper extends java.lang.ObjectHelper class to aid on reading and saving Report properties that are also saved as preferences.
The value of a property will be read from: request keys, report property, preference (in this order).
Note: this is used for Exporting, PDF and HTML Printing.- Since:
- MicroStrategy Web 9.0.0
-
-
Nested Class Summary
-
Field Summary
Fields Modifier and Type Field Description protected RequestKeys_rkprotected boolean_settingsPresent
-
Constructor Summary
Constructors Constructor Description ReportPreferencePropertyListMapper(ReportBean rb)ConstructorReportPreferencePropertyListMapper(ReportBean rb, RequestKeys rk)Constructor
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract HashList<java.lang.String,ReportPreferencePropertyListMapper.ReportProperty>createPropertyList()Creates aHashListwith all theReportPreferencePropertyListMapper.ReportPropertyobjects contained on this listjava.lang.StringgetPreferenceValue(java.lang.String preferenceName)Returns the value of a preference/property.
The value returned is as if it were read from preference (i.e.protected ReportPreferencePropertyListMapper.ReportPropertygetPropsPresentReportProperty(java.lang.String propName, java.lang.String propSetName)Returns theReportPreferencePropertyListMapper.ReportPropertyused to determine if the properties have been savedprotected ReportPreferencePropertyListMapper.ReportPropertygetSavePreferencesProperty()Returns theReportPreferencePropertyListMapper.ReportPropertyused to determine whether to save the preferencesprotected abstract java.lang.StringgetSavePreferencesPropertyName()Returns the name of the property used to determine whether to save the preferencesbooleanhasReportProperties()Whether the report contains report properties.
True if property "settingsPresent" is true.voidsaveProperties()Saves all properties on the list to Report Properties If "savePreferences" is found on the request, the values would be save to preferences.
-
-
-
Field Detail
-
_rk
protected RequestKeys _rk
-
_settingsPresent
protected boolean _settingsPresent
-
-
Constructor Detail
-
ReportPreferencePropertyListMapper
public ReportPreferencePropertyListMapper(ReportBean rb, RequestKeys rk)
Constructor- Parameters:
rb- The Report Beanrk- The Request Keys
-
ReportPreferencePropertyListMapper
public ReportPreferencePropertyListMapper(ReportBean rb)
Constructor- Parameters:
rb- The Report Bean
-
-
Method Detail
-
saveProperties
public void saveProperties()
Saves all properties on the list to Report Properties If "savePreferences" is found on the request, the values would be save to preferences.
-
getPreferenceValue
public java.lang.String getPreferenceValue(java.lang.String preferenceName)
Returns the value of a preference/property.
The value returned is as if it were read from preference (i.e. "1"=true)- Parameters:
preferenceName- The preference name- Returns:
- Returns the value of a preference/property
-
hasReportProperties
public boolean hasReportProperties()
Whether the report contains report properties.
True if property "settingsPresent" is true.- Returns:
- Whether the report contains report properties.
-
createPropertyList
protected abstract HashList<java.lang.String,ReportPreferencePropertyListMapper.ReportProperty> createPropertyList()
Creates aHashListwith all theReportPreferencePropertyListMapper.ReportPropertyobjects contained on this list- Returns:
- a
HashListwith all theReportPreferencePropertyListMapper.ReportPropertyobjects contained on this list
-
getPropsPresentReportProperty
protected ReportPreferencePropertyListMapper.ReportProperty getPropsPresentReportProperty(java.lang.String propName, java.lang.String propSetName)
Returns theReportPreferencePropertyListMapper.ReportPropertyused to determine if the properties have been saved- Parameters:
propName- The property namepropSetName- The property set name- Returns:
- the
ReportPreferencePropertyListMapper.ReportPropertyused to determine if the properties have been saved
-
getSavePreferencesPropertyName
protected abstract java.lang.String getSavePreferencesPropertyName()
Returns the name of the property used to determine whether to save the preferences- Returns:
- the name of the property used to determine whether to save the preferences
-
getSavePreferencesProperty
protected ReportPreferencePropertyListMapper.ReportProperty getSavePreferencesProperty()
Returns theReportPreferencePropertyListMapper.ReportPropertyused to determine whether to save the preferences- Returns:
- the
ReportPreferencePropertyListMapper.ReportPropertyused to determine whether to save the preferences
-
-