Class CacheStats

    • Constructor Detail

      • CacheStats

        public CacheStats​(String instanceName,
                          Debug debugObject)
    • Method Detail

      • createInstance

        public static CacheStats createInstance​(String instanceName,
                                                Debug debugObject)
        Creates a new CacheStats object, adds the object as a listener to the Stats class and returns the object.
        Parameters:
        instanceName - name associated with the CacheStats instance.
        debugObject - the debug instance to which the CacheStats object will be associated.
        Returns:
        a CacheStats object
      • getName

        public String getName()
      • updateHitCount

        public void updateHitCount​(int sizeOfCache)
      • incrementRequestCount

        public void incrementRequestCount​(int sizeOfCache)
      • getIntervalCount

        protected int getIntervalCount()
      • printStats

        public void printStats()
        Description copied from interface: StatsListener
        This method will be invoked when the stats time interval elapsed.
        Specified by:
        printStats in interface StatsListener