Package java.io

Examples of java.io.DataOutputStream.writeByte()


         // byte 1
         out.writeByte(this.getPageCode());

         // byte 2
         out.writeByte(0);

         // byte 3
         out.writeByte(this.supportedCodes.size());

         // supported codes list
View Full Code Here


         // byte 2
         out.writeByte(0);

         // byte 3
         out.writeByte(this.supportedCodes.size());

         // supported codes list
         for (int code : this.supportedCodes)
         {
            out.writeByte(code);
View Full Code Here

         out.writeByte(this.supportedCodes.size());

         // supported codes list
         for (int code : this.supportedCodes)
         {
            out.writeByte(code);
         }

         return baos.toByteArray();
      }
      catch (IOException e)
View Full Code Here

      ByteArrayOutputStream cdb = new ByteArrayOutputStream(this.size());
      DataOutputStream out = new DataOutputStream(cdb);

      try
      {
         out.writeByte(OPERATION_CODE);

         int msb = (int) (getLogicalBlockAddress() >>> 16) & 0x1F;
         int lss = (int) getLogicalBlockAddress() & 0xFFFF;
         out.writeByte(msb);
         out.writeShort(lss);
View Full Code Here

      {
         out.writeByte(OPERATION_CODE);

         int msb = (int) (getLogicalBlockAddress() >>> 16) & 0x1F;
         int lss = (int) getLogicalBlockAddress() & 0xFFFF;
         out.writeByte(msb);
         out.writeShort(lss);
         if (getTransferLength() == 256)
         {
            out.writeByte(0);
         }
View Full Code Here

         int lss = (int) getLogicalBlockAddress() & 0xFFFF;
         out.writeByte(msb);
         out.writeShort(lss);
         if (getTransferLength() == 256)
         {
            out.writeByte(0);
         }
         else
         {
            out.writeByte((int) getTransferLength());
         }
View Full Code Here

         {
            out.writeByte(0);
         }
         else
         {
            out.writeByte((int) getTransferLength());
         }
         out.writeByte(super.getControl());

         return cdb.toByteArray();
      }
View Full Code Here

         }
         else
         {
            out.writeByte((int) getTransferLength());
         }
         out.writeByte(super.getControl());

         return cdb.toByteArray();
      }
      catch (IOException e)
      {
View Full Code Here

      DataOutputStream out = new DataOutputStream(baos);

      try
      {
         // byte 0
         out.writeByte((this.getPeripheralQualifier() << 5) | this.getPeripheralDeviceType());

         // byte 1
         out.writeByte(this.getPageCode());

         // byte 2 - 3
View Full Code Here

      ByteArrayOutputStream cdb = new ByteArrayOutputStream(this.size());
      DataOutputStream out = new DataOutputStream(cdb);

      try
      {
         out.writeByte(OPERATION_CODE);
         out.writeByte(this.EVPD ? 0x01 : 0x00);
         out.writeByte(this.pageCode);
         out.writeShort((short) getAllocationLength());
         out.writeByte(super.getControl());
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.