Package com.github.cafapi.common.api
Interface ElectionFactory
- All Known Implementing Classes:
NullElectionFactory
public interface ElectionFactory
Factory class for returning Election objects for a specific service election.
-
Method Summary
Modifier and TypeMethodDescriptiongetElection
(String serviceReference, ElectionCallback callback) Request a handle class used to interact with a particular service election.
-
Method Details
-
getElection
Request a handle class used to interact with a particular service election.- Parameters:
serviceReference
- a unique handle for an election, typically a service namecallback
- the object that will be called upon the instance being elected/unelected- Returns:
- an object to interact with for a specific election
-