org.neo4j.cluster
Class ConnectedStateMachines
java.lang.Object
org.neo4j.cluster.ConnectedStateMachines
- All Implemented Interfaces:
- org.neo4j.cluster.com.message.MessageProcessor, org.neo4j.cluster.com.message.MessageSource
public class ConnectedStateMachines
- extends Object
- implements org.neo4j.cluster.com.message.MessageProcessor, org.neo4j.cluster.com.message.MessageSource
Combines a set of state machines into one. This will
typically receive messages from the network and then delegate
to the correct state machine based on what type of message comes in.
Only one message at a time can be processed.
|
Constructor Summary |
ConnectedStateMachines(org.neo4j.cluster.com.message.MessageSource source,
org.neo4j.cluster.com.message.MessageProcessor sender,
org.neo4j.cluster.timeout.TimeoutStrategy timeoutStrategy,
DelayedDirectExecutor executor)
|
ConnectedStateMachines
public ConnectedStateMachines(org.neo4j.cluster.com.message.MessageSource source,
org.neo4j.cluster.com.message.MessageProcessor sender,
org.neo4j.cluster.timeout.TimeoutStrategy timeoutStrategy,
DelayedDirectExecutor executor)
getTimeouts
public org.neo4j.cluster.timeout.Timeouts getTimeouts()
addStateMachine
public void addStateMachine(org.neo4j.cluster.statemachine.StateMachine stateMachine)
removeStateMachine
public void removeStateMachine(org.neo4j.cluster.statemachine.StateMachine stateMachine)
getStateMachines
public Iterable<org.neo4j.cluster.statemachine.StateMachine> getStateMachines()
addMessageProcessor
public void addMessageProcessor(org.neo4j.cluster.com.message.MessageProcessor messageProcessor)
- Specified by:
addMessageProcessor in interface org.neo4j.cluster.com.message.MessageSource
getOutgoing
public org.neo4j.cluster.ConnectedStateMachines.OutgoingMessageProcessor getOutgoing()
process
public void process(org.neo4j.cluster.com.message.Message<? extends org.neo4j.cluster.com.message.MessageType> message)
- Specified by:
process in interface org.neo4j.cluster.com.message.MessageProcessor
addStateTransitionListener
public void addStateTransitionListener(org.neo4j.cluster.statemachine.StateTransitionListener stateTransitionListener)
removeStateTransitionListener
public void removeStateTransitionListener(org.neo4j.cluster.statemachine.StateTransitionListener stateTransitionListener)
toString
public String toString()
- Overrides:
toString in class Object
getStateMachine
public org.neo4j.cluster.statemachine.StateMachine getStateMachine(Class<? extends org.neo4j.cluster.com.message.MessageType> messageType)
Copyright © 2002-2012 The Neo4j Graph Database Project. All Rights Reserved.