All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.eshore.socketapi.commons.TunnelAction Maven / Gradle / Ivy

There is a newer version: 1.2.8
Show newest version
package com.eshore.socketapi.commons;

public class TunnelAction extends Action {
	static String[] actions=new String[]{
			"d",//data 0
			"c",//connect 1
			"e",//error 2
			"a",//active 3
			"u",//unknow 4
			"l",//login 5
			"s" //shutdown 6
	};
	int type;
	public TunnelAction(int type,byte[] data){
		this.type=type;
		if(type>=actions.length)this.type=4;
		super.setDatas(data);
	}
	public TunnelAction(int type){
		this.type=type;
		if(type>=actions.length)this.type=4;
	}
	
	@Override
	public String getAction() {
		// TODO Auto-generated method stub
		return actions[type];
	}
	

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy