01: /*
02: * All content copyright (c) 2003-2007 Terracotta, Inc., except as may otherwise be noted in a separate copyright
03: * notice. All rights reserved.
04: */
05: package com.tc.net.protocol.delivery;
06:
07: import com.tc.async.api.AbstractEventHandler;
08: import com.tc.async.api.EventContext;
09: import com.tc.async.api.EventHandlerException;
10:
11: public class OOOEventHandler extends AbstractEventHandler {
12:
13: public void handleEvent(EventContext context)
14: throws EventHandlerException {
15: if (!(context instanceof StateMachineRunner))
16: throw new EventHandlerException("Unexpected EventContext: "
17: + ((context == null) ? "null" : context.getClass()
18: .getName()));
19: StateMachineRunner smr = (StateMachineRunner) context;
20: smr.run();
21: }
22:
23: }
|