Interface ElectionTimerFactory

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface ElectionTimerFactory
  • Method Summary

    Modifier and Type
    Method
    Description
    create(Runnable triggerElection, org.slf4j.Logger logger)
    Creates a new ElectionTimer
  • Method Details

    • create

      ElectionTimer create(Runnable triggerElection, org.slf4j.Logger logger)
      Creates a new ElectionTimer
      Parameters:
      triggerElection - - A runnable which start election by sending the poll requests.
      logger - - A logger for logging
      Returns:
      an ElectionTimer