Package com.google.code.or.net.impl.packet

Examples of com.google.code.or.net.impl.packet.OKPacket


    if(response.getPacketBody()[0] == ErrorPacket.PACKET_MARKER) {
      final ErrorPacket error = ErrorPacket.valueOf(response);
      LOGGER.info("login failed, user: {}, error: {}", this.user, error);
      throw new TransportException(error);
    } else if(response.getPacketBody()[0] == OKPacket.PACKET_MARKER) {
      final OKPacket ok = OKPacket.valueOf(response);
      LOGGER.info("login successfully, user: {}, detail: {}", this.user, ok);
    } else {
      LOGGER.warn("login failed, unknown packet: ", response);
      throw new NestableRuntimeException("assertion failed, invalid packet: " + response);
    }
View Full Code Here


    if(response.getPacketBody()[0] == ErrorPacket.PACKET_MARKER) {
      final ErrorPacket error = ErrorPacket.valueOf(response);
      LOGGER.info("login failed, user: {}, error: {}", this.user, error);
      throw new TransportException(error);
    } else if(response.getPacketBody()[0] == OKPacket.PACKET_MARKER) {
      final OKPacket ok = OKPacket.valueOf(response);
      LOGGER.info("login successfully, user: {}, detail: {}", this.user, ok);
    } else {
      LOGGER.warn("login failed, unknown packet: ", response);
      throw new RuntimeException("assertion failed, invalid packet: " + response);
    }
View Full Code Here

TOP

Related Classes of com.google.code.or.net.impl.packet.OKPacket

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.