Enum Class DisplayResultView

java.lang.Object
java.lang.Enum<DisplayResultView>
org.silverpeas.components.survey.control.DisplayResultView
All Implemented Interfaces:
Serializable, Comparable<DisplayResultView>, Constable

public enum DisplayResultView extends Enum<DisplayResultView>
Definition of the different views of result page a survey can display.
Author:
silveryocha
  • Enum Constant Details

  • Method Details

    • values

      public static DisplayResultView[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static DisplayResultView valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • fromString

      public static DisplayResultView fromString(String name)
      Gets the DisplayResultView instance that matches the specified result view name or code.
      Parameters:
      name - the enum name or the full name of a predefined result view in survey component.
      Returns:
      the DisplayResultView instance having as name the specified role name or DETAIL if no such role exists.
    • fromMainViewOnly

      public static List<DisplayResultView> fromMainViewOnly(String mainView)
      Gets a list of DisplayResultView instance from a main view part of identifier.
      Parameters:
      mainView - a main view part of identifier.
      Returns:
      a list of DisplayResultView instance.
    • getIdentifier

      public String getIdentifier()
      The code of the view is a combination of the main and sub view separated by an underscore.
      Returns:
      a code as string.
    • getMainView

      public String getMainView()
      Gets the main view.
      Returns:
      a string.
    • getSecondaryLevelView

      public String getSecondaryLevelView()
      Gets the secondary level view.
      Returns:
      a string.
    • getMainViewBundleKey

      public String getMainViewBundleKey()
      Gets the bundle key of main view.
      Returns:
      a string representing a bundle key.
    • getSecondaryViewBundleKey

      public String getSecondaryViewBundleKey()
      Gets the bundle key of secondary level view.
      Returns:
      a string representing a bundle key.