private Opcode toOpcode(byte opcode) {
		switch (opcode) {
		case 0:
			return Opcode.CONTINIOUS;
		case 1:
			return Opcode.TEXT;
		case 2:
			return Opcode.BINARY;
			// 3-7 are not yet defined
		case 8:
			return Opcode.CLOSING;
		case 9:
			return Opcode.PING;
		case 10:
			return Opcode.PONG;
			// 11-15 are not yet defined
		default:
			return null;
		}
	}