Package java.io

Examples of java.io.DataInputStream.readUnsignedByte()


        while (! parent.finished) {

          sleep(10);
          while (r.available() > 0) {

            int b = r.readUnsignedByte() ;
            if (b != '\r') {

              if (b == '\n') {

                println(tmp.toString()) ;
View Full Code Here


      data = null;
      ip = null;

      DataInputStream di = new DataInputStream(in);

      version = di.readUnsignedByte();
      command = di.readUnsignedByte();
      if(clientMode && command != 0)
        throw new SocksException(command);

      int reserved = di.readUnsignedByte();
View Full Code Here

      ip = null;

      DataInputStream di = new DataInputStream(in);

      version = di.readUnsignedByte();
      command = di.readUnsignedByte();
      if(clientMode && command != 0)
        throw new SocksException(command);

      int reserved = di.readUnsignedByte();
      addrType = di.readUnsignedByte();
View Full Code Here

      version = di.readUnsignedByte();
      command = di.readUnsignedByte();
      if(clientMode && command != 0)
        throw new SocksException(command);

      int reserved = di.readUnsignedByte();
      addrType = di.readUnsignedByte();

      byte addr[];

      switch(addrType){
View Full Code Here

      command = di.readUnsignedByte();
      if(clientMode && command != 0)
        throw new SocksException(command);

      int reserved = di.readUnsignedByte();
      addrType = di.readUnsignedByte();

      byte addr[];

      switch(addrType){
         case SOCKS_ATYP_IPV4:
View Full Code Here

           di.readFully(addr);
           host = bytes2IPV6(addr,0);
         break;
         case SOCKS_ATYP_DOMAINNAME:
           //System.out.println("Reading ATYP_DOMAINNAME");
           addr = new byte[di.readUnsignedByte()];//Next byte shows the length
           di.readFully(addr);
           host = new String(addr);
         break;
         default:
            throw(new SocksException(Proxy.SOCKS_JUST_ERROR));
View Full Code Here

                int type = SourceDescription.SOURCE_DESC_CNAME;

                while (type != 0) {

                    type = stream.readUnsignedByte();

                    if (type != 0) {

                        int len = stream.readUnsignedByte();
View Full Code Here

                    type = stream.readUnsignedByte();

                    if (type != 0) {

                        int len = stream.readUnsignedByte();

                        byte[] desc = new byte[len];

                        stream.readFully(desc);
View Full Code Here

                data, offset, length));

        ssrc = stream.readInt() & RTPHeader.UINT_TO_LONG_CONVERT;

        fractionLost = stream.readUnsignedByte();

        numLost = (stream.readUnsignedShort() << 8) | stream.readUnsignedByte();

        xtndSeqNum = stream.readInt() & RTPHeader.UINT_TO_LONG_CONVERT;
View Full Code Here

        ssrc = stream.readInt() & RTPHeader.UINT_TO_LONG_CONVERT;

        fractionLost = stream.readUnsignedByte();

        numLost = (stream.readUnsignedShort() << 8) | stream.readUnsignedByte();

        xtndSeqNum = stream.readInt() & RTPHeader.UINT_TO_LONG_CONVERT;

        jitter = stream.readInt() & RTPHeader.UINT_TO_LONG_CONVERT;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.