Class PropertySetHelper

  • Direct Known Subclasses:
    PropertySetJsHelper

    public class PropertySetHelper
    extends java.lang.Object

    Title: PropertySetHelper.

    Description: This is the helper file for generating the javascript which has the mapping between the HTML property names and the propert set property name

    Copyright: Copyright (c) 2003

    Company: Microstrategy, Inc.

    Since:
    MicroStrategy Web 8.0.0
    • Constructor Detail

      • PropertySetHelper

        public PropertySetHelper()
    • Method Detail

      • getPropertySets

        public static PropertySets getPropertySets()
      • init

        public static void init​(java.lang.String filePath)
        This method initializes the property sets
        Parameters:
        filePath - String
      • destroy

        public static void destroy()
        Destroy the HashSet and other caches, will be called when destroying the sevlet
      • getHasBorderFlag

        public static java.lang.Boolean getHasBorderFlag​(java.lang.String id)
        This function returns a value indicating whether the given object has a border or not
        Parameters:
        id - String
        Returns:
        Boolean
      • generateJavaScriptFile

        protected static void generateJavaScriptFile​(java.lang.String javaScriptFileName)
      • generateFormatJson

        public static JsonGenerator generateFormatJson​(RWUnit rwUnit,
                                                       WebFormat format,
                                                       int dpiConversion,
                                                       java.util.Locale locale,
                                                       int zoomFactor,
                                                       boolean isDesignMode,
                                                       RWBean rwbean)
        Since:
        MicroStrategy Web 8.1.0
      • resolvePanelStackTitleFormat

        public static void resolvePanelStackTitleFormat​(RWUnit rwUnit,
                                                        WebFormat format,
                                                        java.lang.StringBuilder style)
        Since:
        MicroStrategy Web 9.0.0
      • resolvePanelStackTitleFormat

        public static void resolvePanelStackTitleFormat​(RWUnit rwUnit,
                                                        WebFormat format,
                                                        int dpiConversion,
                                                        java.util.Locale locale,
                                                        int zoomFactor,
                                                        boolean isDesignMode,
                                                        java.lang.StringBuilder style,
                                                        AppContext appContext,
                                                        RWBean rwbean,
                                                        int unitType)
      • resolveCss

        public static void resolveCss​(RWUnit rwUnit,
                                      WebFormat format,
                                      int dpiConversion,
                                      java.util.Locale locale,
                                      int zoomFactor,
                                      boolean isDesignMode,
                                      java.lang.StringBuilder style,
                                      AppContext appContext,
                                      RWBean rwbean,
                                      int unitType)
        This method renders the CSS class for report writing objects.
        Parameters:
        rwUnit - RWUnit
        format - WebFormat
        dpiConversion - int the dpi value specified in the users preferences (72, 96 or 120)
        locale - Locale
        zoomFactor - int from 25 to 1000 indicating the zoom percentage value
        isDesignMode - boolean
        style - StringBuilder to capture the style output
        appContext - AppContext
        rwbean - RWBean
        Since:
        MicroStrategy Web 9.0.0
      • appendTextDirectionStyle

        public static void appendTextDirectionStyle​(WebFormat format,
                                                    java.lang.StringBuilder filterCollection)
        Since:
        MicroStrategy Web 9.0.1
      • appendGradientColorStyle

        public static void appendGradientColorStyle​(WebFormat format,
                                                    java.lang.StringBuilder filterCollection,
                                                    java.lang.String objType)
        Since:
        MicroStrategy Web 9.0.1
      • appendTextDecoration

        public static void appendTextDecoration​(java.lang.StringBuilder style,
                                                RWUnit rwUnit)
        Since:
        MicroStrategy Web 9.0.0
      • appendTextDecoration

        public static void appendTextDecoration​(java.lang.StringBuilder style,
                                                WebFormat format,
                                                int unitType)
        Since:
        MicroStrategy Web 9.0.0
      • generateStyle

        public static void generateStyle​(RWUnit rwUnit,
                                         java.lang.String propertySetName,
                                         java.lang.String propertyName,
                                         java.lang.StringBuilder style,
                                         int dpiConversion,
                                         java.util.Locale locale,
                                         int zoomFactor,
                                         boolean isDesignMode,
                                         RWBean rwbean)
        Parameters:
        rwUnit -
        propertySetName -
        propertyName -
        style -
        dpiConversion -
        locale -
        zoomFactor -
        isDesignMode -
        rwbean -
        Since:
        MicroStrategy Web 9.0.0
      • getStyleValue

        public static java.lang.String getStyleValue​(Property property,
                                                     RWUnit rwUnit,
                                                     java.lang.String propertyValue,
                                                     WebFormat format,
                                                     int dpiConversion,
                                                     java.util.Locale locale,
                                                     int zoomFactor,
                                                     boolean isDesignMode,
                                                     RWBean rwbean)
        Since:
        MicroStrategy Web 8.1.0
      • getInlineStyle

        public static void getInlineStyle​(java.lang.String propertySetName,
                                          java.lang.String propertyName,
                                          WebFormat format,
                                          java.lang.StringBuilder style,
                                          java.lang.String objType)
        Since:
        MicroStrategy Web 9.0.0
      • getDocStyle

        @Deprecated
        public static void getDocStyle​(java.lang.String propertySetName,
                                       java.lang.String propertyName,
                                       java.lang.String propertyValue,
                                       java.lang.StringBuffer style,
                                       int dpiConversion,
                                       java.util.Locale locale,
                                       int zoomFactor)
        This method renders the CSS class for the report writing document object
        Parameters:
        propertySetName - String
        propertyName - String
        propertyValue - String
        style - StringBuffer to capture the style output
        dpiConversion - int the dpi value specified in the users preferences (72, 96 or 120)
        locale - Locale
        zoomFactor - int from 25 to 1000 indicating the zoom percentage value
      • getDocStyle

        public static void getDocStyle​(java.lang.String propertySetName,
                                       java.lang.String propertyName,
                                       java.lang.String propertyValue,
                                       java.lang.StringBuilder style,
                                       int dpiConversion,
                                       java.util.Locale locale,
                                       int zoomFactor)
        This method renders the CSS class for the report writing document object
        Parameters:
        propertySetName - String
        propertyName - String
        propertyValue - String
        style - StringBuffer to capture the style output
        dpiConversion - int the dpi value specified in the users preferences (72, 96 or 120)
        locale - Locale
        zoomFactor - int from 25 to 1000 indicating the zoom percentage value
        Since:
        MicroStrategy Web 9.0.0
      • getDocPropertyValue

        public static java.lang.String getDocPropertyValue​(java.lang.String propertySetName,
                                                           java.lang.String propertyName,
                                                           java.lang.String propertyValue,
                                                           int dpiConversion,
                                                           java.util.Locale locale,
                                                           int zoomFactor)
        Returns the property's html value of the document, i.e for borderStyle this returns '1pt dashed' instead of the encoded value (i.e 1-5)
        Parameters:
        propertySetName - String
        propertyName - String
        propertyValue - String
        dpiConversion - int
        locale - Locale
        zoomFactor - int
        Returns:
        String
      • extractBorderWidthFromStyle

        public static double extractBorderWidthFromStyle​(WebFormat format,
                                                         java.lang.String propertySet,
                                                         java.lang.String property)