Class DefaultDebouncer

  • All Implemented Interfaces:
    Debouncer

    public class DefaultDebouncer
    extends java.lang.Object
    implements Debouncer
    • Constructor Summary

      Constructors 
      Constructor Description
      DefaultDebouncer​(long waitFor, long maxWaitFor)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void bounce()
      抖动一次。
      boolean isStable()
      抖动是否已稳定。
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • DefaultDebouncer

        public DefaultDebouncer​(long waitFor,
                                long maxWaitFor)
    • Method Detail

      • isStable

        public boolean isStable()
        Description copied from interface: Debouncer
        抖动是否已稳定。
        Specified by:
        isStable in interface Debouncer
        Returns:
        抖动稳定则返回true。
      • bounce

        public void bounce()
        Description copied from interface: Debouncer
        抖动一次。
        Specified by:
        bounce in interface Debouncer