1 /*2 * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright notice. All rights reserved.3 */4 package com.tc.object.net;5 6 import com.tc.async.api.Sink;7 import com.tc.net.MaxConnectionsExceededException;8 import com.tc.net.protocol.tcm.ChannelEventListener;9 import com.tc.net.protocol.tcm.ChannelIDProvider;10 import com.tc.net.protocol.tcm.ClientMessageChannel;11 import com.tc.net.protocol.tcm.TCMessageType;12 import com.tc.object.msg.AcknowledgeTransactionMessageFactory;13 import com.tc.object.msg.ClientHandshakeMessageFactory;14 import com.tc.object.msg.CommitTransactionMessageFactory;15 import com.tc.object.msg.JMXMessage;16 import com.tc.object.msg.LockRequestMessageFactory;17 import com.tc.object.msg.ObjectIDBatchRequestMessageFactory;18 import com.tc.object.msg.RequestManagedObjectMessageFactory;19 import com.tc.object.msg.RequestRootMessageFactory;20 import com.tc.util.TCTimeoutException;21 22 import java.io.IOException ;23 import java.net.UnknownHostException ;24 25 public interface DSOClientMessageChannel {26 27 public void addClassMapping(TCMessageType messageType, Class messageClass);28 29 public ChannelIDProvider getChannelIDProvider();30 31 public void addListener(ChannelEventListener listener);32 33 public void routeMessageType(TCMessageType messageType, Sink destSink, Sink hydrateSink);34 35 public void open() throws MaxConnectionsExceededException, TCTimeoutException, UnknownHostException , IOException ;36 37 public boolean isConnected();38 39 public void close();40 41 public ClientMessageChannel channel();42 43 public LockRequestMessageFactory getLockRequestMessageFactory();44 45 public RequestRootMessageFactory getRequestRootMessageFactory();46 47 public RequestManagedObjectMessageFactory getRequestManagedObjectMessageFactory();48 49 public ObjectIDBatchRequestMessageFactory getObjectIDBatchRequestMessageFactory();50 51 public CommitTransactionMessageFactory getCommitTransactionMessageFactory();52 53 public ClientHandshakeMessageFactory getClientHandshakeMessageFactory();54 55 public AcknowledgeTransactionMessageFactory getAcknowledgeTransactionMessageFactory();56 57 public JMXMessage getJMXMessage();58 59 }60