Examples of readUnsignedByte()


Examples of java.io.DataInputStream.readUnsignedByte()

      this.lba = in.readInt();
     
      tmp = in.readUnsignedByte();
      this.groupNumber = tmp & 0x1F;
      this.verificationLength = in.readUnsignedShort();
      super.setControl(in.readUnsignedByte());
   }

   public byte[] encode() throws IOException
   {
      ByteArrayOutputStream cdb = new ByteArrayOutputStream(this.size());
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

   @SuppressWarnings("unchecked")
   public SenseData decode(ByteBuffer buffer) throws IOException
   {
      DataInputStream in = new DataInputStream(new ByteBufferInputStream(buffer));

      int b1 = in.readUnsignedByte();
      ResponseCode code = ResponseCode.valueOf((byte) (b1 & 0x7F)); // throws IOException

      SenseData sense = null;

      switch (code)
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

   public void decode(byte[] header, ByteBuffer input) throws IOException
   {
      DataInputStream in = new DataInputStream(new ByteBufferInputStream(input));
      int tmp;

      int operationCode = in.readUnsignedByte();
      this.DBD = (in.readUnsignedByte() & 0x08) != 0;
      tmp = in.readUnsignedByte();
      this.pageCode = tmp & 0x3F;
      this.PC = tmp >>> 6;
      this.subPageCode = in.readUnsignedByte();
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

   {
      DataInputStream in = new DataInputStream(new ByteBufferInputStream(input));
      int tmp;

      int operationCode = in.readUnsignedByte();
      this.DBD = (in.readUnsignedByte() & 0x08) != 0;
      tmp = in.readUnsignedByte();
      this.pageCode = tmp & 0x3F;
      this.PC = tmp >>> 6;
      this.subPageCode = in.readUnsignedByte();
      setAllocationLength(in.readUnsignedByte());
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

      DataInputStream in = new DataInputStream(new ByteBufferInputStream(input));
      int tmp;

      int operationCode = in.readUnsignedByte();
      this.DBD = (in.readUnsignedByte() & 0x08) != 0;
      tmp = in.readUnsignedByte();
      this.pageCode = tmp & 0x3F;
      this.PC = tmp >>> 6;
      this.subPageCode = in.readUnsignedByte();
      setAllocationLength(in.readUnsignedByte());
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

      int operationCode = in.readUnsignedByte();
      this.DBD = (in.readUnsignedByte() & 0x08) != 0;
      tmp = in.readUnsignedByte();
      this.pageCode = tmp & 0x3F;
      this.PC = tmp >>> 6;
      this.subPageCode = in.readUnsignedByte();
      setAllocationLength(in.readUnsignedByte());

      super.setControl(in.readUnsignedByte());

      if (operationCode != OPERATION_CODE)
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

      this.DBD = (in.readUnsignedByte() & 0x08) != 0;
      tmp = in.readUnsignedByte();
      this.pageCode = tmp & 0x3F;
      this.PC = tmp >>> 6;
      this.subPageCode = in.readUnsignedByte();
      setAllocationLength(in.readUnsignedByte());

      super.setControl(in.readUnsignedByte());

      if (operationCode != OPERATION_CODE)
      {
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

      this.pageCode = tmp & 0x3F;
      this.PC = tmp >>> 6;
      this.subPageCode = in.readUnsignedByte();
      setAllocationLength(in.readUnsignedByte());

      super.setControl(in.readUnsignedByte());

      if (operationCode != OPERATION_CODE)
      {
         throw new IOException("Invalid operation code: " + Integer.toHexString(operationCode));
      }
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

      DataInputStream in = new DataInputStream(new ByteBufferInputStream(input));

      // read in first segment of fixed format sense data
      in.readByte();
      int key = in.readUnsignedByte() & 0x0F; // TODO: FILEMARK, EOM, and ILI are unsupported
      byte[] info = new byte[4];
      in.read(info);
      int length = in.readUnsignedByte() - 10; // length of next segment, minus required read-in
      length = length < 0 ? 0 : length;
View Full Code Here

Examples of java.io.DataInputStream.readUnsignedByte()

      // read in first segment of fixed format sense data
      in.readByte();
      int key = in.readUnsignedByte() & 0x0F; // TODO: FILEMARK, EOM, and ILI are unsupported
      byte[] info = new byte[4];
      in.read(info);
      int length = in.readUnsignedByte() - 10; // length of next segment, minus required read-in
      length = length < 0 ? 0 : length;

      // read in the next segment of the fixed format sense data
      byte[] cmdi = new byte[4];
      in.read(cmdi);
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.