Class TestValue

    • Method Detail

      • convertCondensedResultJsonObject

        public static void convertCondensedResultJsonObject​(com.google.gson.JsonObject object,
                                                            TestGroup rootGroup,
                                                            Map<Integer,​TestGroup> fileList,
                                                            Map<Integer,​TestValue> entityList,
                                                            ContentDetected detected)
        Convert a JSON object containing a condensed result to the plugin construct [DISPLAY LOADING]
        Parameters:
        object - Json Object to convert
        rootGroup - Root group
        fileList - List of files
        entityList - List of generated entities
        detected - Key characteristics fo results
      • convertCondensedParameterJsonObject

        public static void convertCondensedParameterJsonObject​(com.google.gson.JsonObject object,
                                                               TestGroup rootGroup,
                                                               Map<Integer,​TestValue> entityList,
                                                               ContentDetected detected)
        Convert a JSON object containing a parameter to the plugin construct [DISPLAY LOADING]
        Parameters:
        object - Json Object to convert
        rootGroup - Root group
        entityList - List of generated entities
        detected - Key characteristics fo results
      • convertResultJsonObject

        public static void convertResultJsonObject​(int build,
                                                   com.google.gson.JsonObject object,
                                                   TestGroup rootGroup,
                                                   Map<Integer,​TestGroup> fileList,
                                                   Map<Integer,​TestValue> entityList,
                                                   Map<Integer,​TestValue> paramList)
        Convert result/parameter content to the plug-in construct [DISPLAY LOAD]
        Parameters:
        build - Build number
        object - Object to convert
        rootGroup - Root group
        fileList - List of files
        entityList - List of result/parameter entities
        paramList - List of parameters
      • convertParameterJsonObject

        public static void convertParameterJsonObject​(int build,
                                                      com.google.gson.JsonObject object,
                                                      TestGroup rootGroup,
                                                      Map<Integer,​TestValue> entityList)
        Convert result/parameter content to the plug-in construct [DISPLAY LOAD]
        Parameters:
        build - Build number
        object - Object to convert
        rootGroup - Root group
        entityList - List of result/parameter entities
      • getHTMLResult

        public String getHTMLResult​(TreeSet<Integer> builds,
                                    char decimalSeparator)
        Generate the HTML table content for this result [DETAIL PAGE]
        Parameters:
        builds - List of build numbers
        decimalSeparator - Decimal Separator
        Returns:
        HTML content for this result
      • getJsonObject

        public com.google.gson.JsonObject getJsonObject​(int hash)
        Export result property to Json object [EXPORT RAW] Works in combination with getJsonObject() from result specific formats
        Overrides:
        getJsonObject in class TestGroup
        Parameters:
        hash - Result hash
        Returns:
        Json Object
      • getParameterJsonObject

        public com.google.gson.JsonObject getParameterJsonObject​(int hash)
        Create an JSON object from a parameter [EXPORT CONDENSED]
        Parameters:
        hash - Result hash
        Returns:
        JSON object
      • getHTMLDetails

        public String getHTMLDetails​(Integer build,
                                     char decimalSeparator)
        Generate the HTML detail content for this result and for a determined build [DETAIL PAGE]
        Parameters:
        build - Build number
        decimalSeparator - Decimal Separator
        Returns:
        HTML detail for this result
      • getHTMLResult

        public String getHTMLResult​(Integer key,
                                    ContentDetected detected,
                                    TreeSet<Integer> builds,
                                    List<Integer> listNPassed,
                                    List<Integer> listNFailed,
                                    char decimalSeparator)
        Generate the HTML raw table content for this result [TABLE PAGE]
        Parameters:
        key - Result hash value
        detected - Key characteristic of this set of results
        builds - List of build numbers
        listNPassed - Number of passed result test for each build
        listNFailed - Number of passed result test for each build
        decimalSeparator - Decimal Separator
        Returns:
        HTML table content for this result
      • getCSVResult

        public String getCSVResult​(TreeSet<Integer> builds,
                                   ContentDetected detected)
        Generate the CSV table content for this result [CSV EXPORT]
        Parameters:
        builds - List of build numbers
        detected - Key characteristic of this set of results
        Returns:
        CSV table content for result
      • getCSVResultState

        public String getCSVResultState​(Integer key,
                                        ContentDetected detected,
                                        TreeSet<Integer> builds)
        Generate the CSV state content to describe this result state [CSV EXPORT]
        Parameters:
        key - Result hash value
        detected - Key characteristic of this set of results
        builds - List of build numbers
        Returns:
        CSV table state content for result
      • getHTMLParameters

        public String getHTMLParameters​(Integer build,
                                        char decimalSeparator)
        Generate the HTML content for all the parameters for this result at a determined build [DETAIL PAGE]
        Parameters:
        build - Build number
        decimalSeparator - Decimal Separator
        Returns:
        HTML content for all parameters
      • getHTMLParameter

        public String getHTMLParameter​(Integer number,
                                       Integer build,
                                       char decimalSeparator)
        Generate the HTML content for this parameter [DETAIL PAGE]
        Parameters:
        number - Displayed parameter number
        build - Build number
        decimalSeparator - Decimal Separator
        Returns:
        HTML content for this parameter
      • getHTMLCondensed

        public String getHTMLCondensed​(Integer key,
                                       ContentDetected detected,
                                       char decimalSeparator)
        Assemble the HTML content to display the condensed table [TABLE PAGE]
        Parameters:
        key - Result key
        detected - Key characteristics of results
        decimalSeparator - Decimal separator
        Returns:
        HTML content
      • getHTMLCondensedDetail

        public String getHTMLCondensedDetail​(ContentDetected detected,
                                             char decimalSeparator)
        Assemble the HTML content to display the condensed table [DETAIL PAGE]
        Parameters:
        detected - Key characteristics of results
        decimalSeparator - Decimal separator
        Returns:
        HTML content
      • getCSVCondensed

        public String getCSVCondensed​(ContentDetected detected)
        Assemble the CSV content to display the condensed table [CSV EXPORT]
        Parameters:
        detected - Key characteristics of results
        Returns:
        CSV content
      • getCondensedJsonObject

        public com.google.gson.JsonObject getCondensedJsonObject​(int build,
                                                                 int hash)
        Create an JSON object with the condensed information of this result [EXPORT CONDENSED]
        Parameters:
        build - Build number
        hash - Result hash
        Returns:
        JSON object
      • isNumeral

        public Boolean isNumeral()
        Return whether the TestValue is based on numeral values
        Returns:
        Whether class is numeral
      • checkThresholdStatus

        public void checkThresholdStatus​(Double previous,
                                         Double average)
        Check attached thresholds to verify result validity.
        Parameters:
        previous - Previous value
        average - Calculated average
      • setId

        public void setId​(Integer id)
      • setId

        public void setId​(int build,
                          Integer id)
      • setFailedState

        public void setFailedState​(Boolean failed)
      • setFailedState

        public void setFailedState​(int build,
                                   Boolean failed)
      • setMessage

        public void setMessage​(String title,
                               String message)
      • setMessage

        public void setMessage​(int build,
                               String title,
                               String message)
      • setMessages

        public void setMessages​(Map<String,​String> messages)
      • setMessages

        public void setMessages​(int build,
                                Map<String,​String> messages)
      • setParameter

        public void setParameter​(TestValue parameter)
      • setParameter

        public void setParameter​(int build,
                                 TestValue parameter)
      • setParameters

        public void setParameters​(List<TestValue> parameters)
      • setParameters

        public void setParameters​(int build,
                                  List<TestValue> parameters)
      • setGroup

        public void setGroup()
      • setGroup

        public void setGroup​(String group)
      • getGroup

        public String getGroup()
      • getUnit

        public String getUnit()
      • getValueAsString

        public String getValueAsString​(int build)
      • getValueAsLocaleString

        public String getValueAsLocaleString​(int build,
                                             char decimalSeparator)
      • getFailedState

        public Boolean getFailedState()
      • getFailedState

        public Boolean getFailedState​(int build)
      • getId

        public Integer getId​(int build)
      • getParameters

        public List<TestValue> getParameters​(int build)
      • getNumberOfProperties

        public int getNumberOfProperties()