Java Integer to intToOneByte(int i)

Here you can find the source of intToOneByte(int i)

Description

int To One Byte

License

Apache License

Declaration

public static byte[] intToOneByte(int i) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static byte[] intToOneByte(int i) {
        byte[] b = new byte[1];
        b[0] = (byte) (i & 0xff);
        return b;
    }/*from w  w w  . j a  va 2 s.c  om*/
}

Related

  1. intToNetworkByteOrder(int num, byte[] buf, int start, int count)
  2. intToNetworkByteOrder(int num, int count)
  3. intToNumericFormat(int src)
  4. intToOctal(int value)
  5. IntToOctString(final int value)
  6. intToOneByte(int value)
  7. intToOneByteArray(int number)
  8. IntToPackage(int pack)
  9. intToPaddedString(int value, int pad)