Android Int to Byte Array Convert intsToBytes(int[] values)

Here you can find the source of intsToBytes(int[] values)

Description

ints To Bytes

License

Apache License

Declaration

public static byte[] intsToBytes(int[] values) 

Method Source Code

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

public class Main {
    public static byte[] intsToBytes(int[] values) {
        byte[] ret = new byte[values.length];
        for (int k = 0, len = values.length; k < len; k++)
            ret[k] = (byte) values[k];
        return ret;
    }//from   w  w  w  .j a v a 2s . c o  m
}

Related

  1. toByteArray(int in)
  2. toByteArray(int in, int outSize)
  3. toByteArray(int val, byte[] b, int pos)
  4. ints2bytesBE(int[] val)
  5. ints2bytesLE(int[] val)
  6. getAs_uint16_NetOrder(int theNumber)
  7. getAs_uint32_NetOrder(int theNumber)
  8. toBytes(int integer, byte[] output, int offset)
  9. int2ByteArray(int num)