Java Integer Convert To convertInt2Bytes(int data)

Here you can find the source of convertInt2Bytes(int data)

Description

convert Int Bytes

License

Open Source License

Declaration

public static byte[] convertInt2Bytes(int data) 

Method Source Code

//package com.java2s;

public class Main {
    public static byte[] convertInt2Bytes(int data) {
        byte[] bytes = new byte[] { convertInt2Byte(data) };
        return bytes;
    }/*  w w w  .  j  a  v  a  2 s .  c o m*/

    public static byte convertInt2Byte(int data) {
        return (byte) (0xFF & data);
    }
}

Related

  1. convertInt(String str, int radix)
  2. convertInt(String value)
  3. convertInt(String valueAsString)
  4. convertInt(String[] idArray)
  5. convertInt2Byte(int data)
  6. convertInt32(int v, boolean isLE)
  7. convertInt8(int v)
  8. convertIntArray(int[] arr)
  9. convertIntArray(int[] in)