package com.eactive.eai.adapter.socket2.protocol.login;

import com.eactive.eai.adapter.socket2.config.SocketAdapterContext;
import com.eactive.eai.adapter.socket2.protocol.TcpAdapterClient;
import com.eactive.eai.adapter.socket2.protocol.login.codec.BindCodecFactory;
import com.eactive.eai.adapter.socket2.protocol.login.handshake.BindClientFilter;
import org.apache.mina.filter.codec.ProtocolCodecFilter;


public class BindClient extends TcpAdapterClient {
	boolean isForceStop = true;
	
	public BindClient(SocketAdapterContext context) throws Exception {
		super(context);
		this.handler = new BindHandler(this);
		config.getFilterChain().addFirst("codec", new ProtocolCodecFilter(new BindCodecFactory(this)));
		config.getFilterChain().addAfter("codec", "bind.codec", new BindClientFilter(this));
	}
	
}
