Interface IModuleCompareResult


  • public interface IModuleCompareResult
    Contains statistics for a particular module and methods belonging to it.
    • Method Detail

      • isFullStatisticCorrect

        boolean isFullStatisticCorrect()
        Checks if statistics for full time are computed correctly and can be used.
        Call this method before calling any of these methods: Otherwise no guarantees of correct results for statistics using full durabilities are provided.
        Returns:
        true if full durabilities and their diffs are computed correctly, false otherwise.
      • getPureDurability

        long getPureDurability​(CompareSide side)
        Gets pure durability of execution of lines belonging to this module.
        Parameters:
        side - BASE if should return pure durability if this module in base result (the result used as base for comparing), COMPARED otherwise.
        Returns:
        Pure durability of execution of lines belonging to this module. Always greater of equal to 0.
      • getPureDurabilities

        Map<DebugTargetType,​Long> getPureDurabilities​(CompareSide side)
        Gets pure durabilities of this module's calls grouped by debug targets.
        Parameters:
        side - Compare side to get pure durabilities of calls for. Cannot be null.
        Returns:
        Map with pure durabilities of calls grouped by debug targets. Never null.
      • getDurability

        long getDurability​(CompareSide side)
        Gets full time of execution of lines belonging to this module.
        Parameters:
        side - BASE if should return durability if this module in base result (the result used as base for comparing), COMPARED otherwise.
        Returns:
        Full time of execution of lines belonging to this module. Always greater or equal to 0.
      • getDurabilities

        Map<DebugTargetType,​Long> getDurabilities​(CompareSide side)
        Gets durabilities of this module's calls grouped by debug targets.
        Parameters:
        side - Compare side to get durabilities of calls for. Cannot be null.
        Returns:
        Map with durabilities of calls grouped by debug targets. Never null.
      • getPureDurabilityDiff

        double getPureDurabilityDiff()
        Gets the diff of pure durability (in percents, relative to the pure durability of base result). For example, if the pure durabilities of base and compared results are 100ms and 125ms, then the diff will be (125 - 100) / 100 = 25%.
        Returns:
        The diff of pure durabilities in percents relative to the pure durability of base result.
      • getPureDurabilityDiffs

        Map<DebugTargetType,​Double> getPureDurabilityDiffs()
        Gets diffs of pure durability grouped by debug targets. By default diff value for every debug target is initialized with 0.0. For example, if the pure durabilities of base and compared results on server are 100ms and 125ms, and on managed client are 50ms and 75ms, then this method will return {SERVER=25.0, MANAGED_CLIENT=50.0, SERVER_EMULATION=0.0, CLIENT=0.0, ... }.
        Returns:
        Diffs of pure durabilities grouped by debug targets. Never null.
      • getDurabilityDiff

        double getDurabilityDiff()
        Gets the diff of full durability (in percents, relative to the full durability of base result). For example, if the full durabilities of base and compared results are 100ms and 125ms, then the diff will be (125 - 100) / 100 = 25%.
        Returns:
        The diff of full durabilities in percents relative to the full durability of base result.
      • getDurabilityDiffs

        Map<DebugTargetType,​Double> getDurabilityDiffs()
        Gets diffs of durability grouped by debug targets. By default diff value for every debug target is initialized with 0.0. For example, if the pure durabilities of base and compared results on server are 100ms and 125ms, and on managed client are 50ms and 75ms, then this method will return {SERVER=25.0, MANAGED_CLIENT=50.0, SERVER_EMULATION=0.0, CLIENT=0.0, ... }.
        Returns:
        Diffs of durabilities grouped by debug targets. Never null.
      • getMethodCompareResult

        IMethodCompareResult getMethodCompareResult​(String methodName)
        Gets compare result for method with specified name that belongs to the module associated with this result.
        Parameters:
        methodName - The name (not a signature) of method to find compare result for. Cannot be null.
        Returns:
        Method compare result or null if there is no such result.
      • getMethodsCompareResults

        List<IMethodCompareResult> getMethodsCompareResults()
        Gets list with all methods' statistics (from both results).
        Returns:
        List with methods' statistics from both results. Never null, but can be empty.
      • getOwnerClass

        org.eclipse.emf.ecore.EClass getOwnerClass()
        Gets the class of the owner of module associated with this result.
        Returns:
        owner The class of the owner of module. Never null.
      • getModuleName

        String getModuleName()
        Gets the name of module associated with this object.
        Returns:
        The name of module associated with this object or dummy string if module is not found.
      • getModuleId

        BSLModuleIdInternal getModuleId()
        Gets module ID for the module this result is associated with.
        Returns:
        Module ID for the module this result is associated with. Never null.
      • getDebugTargets

        Set<DebugTargetType> getDebugTargets()
        Gets debug targets that executed code from this module.
        Returns:
        Set with debug targets that executed code from this module. Never null.