Class AlmanachSettings


  • public final class AlmanachSettings
    extends Object
    It gathers all the settings and i18n relative to the Almanach component.
    Author:
    Yohann Chastagnier
    • Field Detail

      • COMPONENT_NAME

        public static final String COMPONENT_NAME
        The name of the Almanach component in Silverpeas.
        See Also:
        Constant Field Values
      • SETTINGS_PATH

        public static final String SETTINGS_PATH
        The relative path of the properties file containing the settings of the Almanach component.
        See Also:
        Constant Field Values
      • MESSAGES_PATH

        public static final String MESSAGES_PATH
        The relative path of the i18n bundle of the Almanach component.
        See Also:
        Constant Field Values
      • ICONS_PATH

        public static final String ICONS_PATH
        The relative path of the properties file containing the references of the icons dedicated to the Almanach component.
        See Also:
        Constant Field Values
    • Method Detail

      • getMessagesIn

        public static org.silverpeas.core.util.LocalizationBundle getMessagesIn​(String language)
        Gets all the messages for the Almanach component and translated in the specified language.
        Parameters:
        language - the language in which are written the messages.
        Returns:
        the resource with the translated messages.
      • getSettings

        public static org.silverpeas.core.util.SettingBundle getSettings()
        Gets all the settings of the Almanach component.
        Returns:
        the resource with the different component settings.
      • getIcons

        public static org.silverpeas.core.util.LocalizationBundle getIcons()
        Gets all the icons definitions particular to the Almanach component.
        Returns:
        the resource with icons definition.
      • getZoneId

        public static ZoneId getZoneId()
        Gets the zone identifier of the platform for almanach components.
        Returns:
        a ZoneId instance.
      • isCalendarWeekendVisible

        public static boolean isCalendarWeekendVisible​(String componentInstanceId)
        Indicates if the weekend is visible on calendar for a component instance.
        Parameters:
        componentInstanceId - the identifier of component instance for parameter values.
        Returns:
        true if weekend is visible, false otherwise.
      • getDefaultCalendarView

        public static String getDefaultCalendarView​(String componentInstanceId)
        Gets the default view of the almanach calendar.
        Parameters:
        componentInstanceId - the identifier of component instance for parameter values.
        Returns:
        the default view as string.
      • isPdcUsed

        public static boolean isPdcUsed​(String componentInstanceId)
        Indicates if the PDC is used into the context of the component instance represented bu the given identifier.
        Parameters:
        componentInstanceId - the identifier of component instance for parameter values.
        Returns:
        true if pdc is used, false otherwise.
      • isFilterOnPdcActivated

        public static boolean isFilterOnPdcActivated​(String componentInstanceId)
        Indicates if the PDC filtering is activated into the context of the component instance represented bu the given identifier.
        Parameters:
        componentInstanceId - the identifier of component instance for parameter values.
        Returns:
        true if pdc filtering is activated, false otherwise.
      • getNbOccurrenceLimitOfNextEventView

        public static int getNbOccurrenceLimitOfNextEventView()
        Gets the limit number of occurrences the next event view has to display.
        Returns:
        the limit as int.
      • getNbOccurrenceLimitOfShortNextEventView

        public static int getNbOccurrenceLimitOfShortNextEventView()
        Gets the limit number of occurrences the short next event view has to display.
        Returns:
        the limit as int.
      • getNextEventTimeWindows

        public static Integer[] getNextEventTimeWindows()
        Gets the limit number of occurrences the next event view has to display.
        Returns:
        the limit as int.
      • getAggregationMode

        public static String getAggregationMode()
        Gets the aggregation mode for almanachs.
        Returns:
        the code of the mode as string.