Class Coverage

    • Constructor Detail

      • Coverage

        public Coverage​(int missed,
                        int covered)
      • Coverage

        public Coverage()
    • Method Detail

      • getMissed

        @Exported
        public int getMissed()
      • getCovered

        @Exported
        public int getCovered()
      • getTotal

        @Exported
        public int getTotal()
      • toString

        public String toString()
        Gets "missed/covered (%)" representation.
        Overrides:
        toString in class Object
      • getPercentage

        @Exported
        public int getPercentage()
        Gets the percentage as an integer between 0 and 100.
        Returns:
        the coverage percentage as a rounded integer between 0 and 100.
        See Also:
        getPercentageFloat()
      • getPercentageFloat

        @Exported
        public float getPercentageFloat()
        Gets the percentage as a float between 0f and 100f.
        Returns:
        the coverage percentage as a float between 0f and 100f. returns 100f if no coverage data was recorded at all, i.e. covered and missed are zero
        See Also:
        getPercentage()
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • accumulate

        public void accumulate​(int missed,
                               int covered)
        Adds the given missed and covered values to the ones already contained in this ratio.
        Parameters:
        missed - The amount to add to the missed.
        covered - The amount to add to the covered.
      • accumulatePP

        public void accumulatePP​(int missed,
                                 int covered)
      • isInitialized

        public boolean isInitialized()