Sets a 32-bit integer in the given byte array at the given offset.
507095
public static void setInt32(byte[] dst, int offset, long value)
            throws IllegalArgumentException {
        
        assert value <= Integer.MAX_VALUE : "value out of range";
        
        dst[offset + 0] = (byte) (value & 0xFF);
        dst[offset + 1] = (byte) ((value >>> 8) & 0xFF);
        dst[offset + 2] = (byte) ((value >>> 16) & 0xFF);
        dst[offset + 3] = (byte) ((value >>> 24) & 0xFF);
    }
722617
public static void writeInt64(final long value, final byte[] buffer, int offset)
    {
        buffer[offset++] = (byte) (value >>> 56);
        buffer[offset++] = (byte) (value >>> 48);
        buffer[offset++] = (byte) (value >>> 40);
        buffer[offset++] = (byte) (value >>> 32);
        buffer[offset++] = (byte) (value >>> 24);
        buffer[offset++] = (byte) (value >>> 16);
        buffer[offset++] = (byte) (value >>> 8);
        buffer[offset] = (byte) (value >>> 0);
    }
451057
public static void writeInt(byte[] b, int offset, int value) {
    b[offset++] = (byte) (value >>> 24);
    b[offset++] = (byte) (value >>> 16);
    b[offset++] = (byte) (value >>> 8);
    b[offset] = (byte)value;
  }
463068
public static void setLong(final byte[] b, final long n, final int offset) {
        b[offset + 0] = (byte) (n >>> 56);
        b[offset + 1] = (byte) (n >>> 48);
        b[offset + 2] = (byte) (n >>> 40);
        b[offset + 3] = (byte) (n >>> 32);
        b[offset + 4] = (byte) (n >>> 24);
        b[offset + 5] = (byte) (n >>> 16);
        b[offset + 6] = (byte) (n >>> 8);
        b[offset + 7] = (byte) (n >>> 0);
    }
1152244
public static long bytes_to_uint(byte[] bytes, int offset) {
		if(bytes.length-offset<4)
			throw new PickleException("too few bytes to convert to long");
		long i = bytes[3+offset] & 0xff;
		i <<= 8;
		i |= bytes[2+offset] & 0xff;
		i <<= 8;
		i |= bytes[1+offset] & 0xff;
		i <<= 8;
		i |= bytes[0+offset] & 0xff;
		return i;
	}
644762
public static void intToBytes(int value, byte[] bytes, int offset) {
        bytes[offset + 3] = (byte) (value >>> 0);
        bytes[offset + 2] = (byte) (value >>> 8);
        bytes[offset + 1] = (byte) (value >>> 16);
        bytes[offset + 0] = (byte) (value >>> 24);
    }
977705
public void toBytes(byte[] b, int offset) {
    ByteConverter.float8(b, offset, x);
    ByteConverter.float8(b, offset + 8, y);
  }
734945
public static void setShort(final byte[] b, final short n, final int offset) {
        b[offset + 0] = (byte) (n >>> 8);
        b[offset + 1] = (byte) (n >>> 0);
    }
808944
public void setShort(int offset, int value)
  {
    byte []code = getCode();
    
    code[offset + 0]  = (byte) (value >> 8);
    code[offset + 1]  = (byte) (value);
  }
918470
def setbit(self, key, offset, value):
        
        key = self._encode(key)
        index, bits, mask = self._get_bits_and_offset(key, offset)

        if index >= len(bits):
            bits.extend(b"\x00" * (index + 1 - len(bits)))

        prev_val = 1 if (bits[index] & mask) else 0

        if value:
            bits[index] |= mask
        else:
            bits[index] &= ~mask

        self.redis[key] = bytes(bits)

        return prev_val
370213
public static int bytesToInt(byte[] bytes, int offset) {
        return ((bytes[offset + 3] & 0xFF) << 0) + ((bytes[offset + 2] & 0xFF) << 8)
                        + ((bytes[offset + 1] & 0xFF) << 16) + ((bytes[offset + 0] & 0xFF) << 24);
    }
501439
public static void putShortBE(final byte[] array, final int offset, final short value) {
    array[offset + 1] = (byte) (value       );
    array[offset    ] = (byte) (value >>>  8);
  }
1221175
private static int put(byte[] block, int offset, byte[] b, int off, int len) {
    System.arraycopy(b, off, block, offset, len);
    return len;
  }
1079790
public static void writeInt32LE(final int value, final byte[] buffer, int offset)
    {
        buffer[offset++] = (byte) ((value >>> 0) & 0xFF);
        buffer[offset++] = (byte) ((value >>> 8) & 0xFF);
        buffer[offset++] = (byte) ((value >>> 16) & 0xFF);
        buffer[offset] = (byte) ((value >>> 24) & 0xFF);
    }
475812
public static int writeUnsignedInt(byte[] bytes, int offset, int i) {
      int localOffset = offset;
      while ((i & ~0x7F) != 0) {
         bytes[localOffset++] = (byte) ((i & 0x7f) | 0x80);
         i >>>= 7;
      }
      bytes[localOffset++] = (byte) i;
      return localOffset - offset;
   }
599429
private static void writeInt(byte[] buffer, int offset, int value) {
    buffer[offset    ] = (byte) (value >> 24);
    buffer[offset + 1] = (byte) (value >> 16);
    buffer[offset + 2] = (byte) (value >> 8);
    buffer[offset + 3] = (byte) value;
  }
1020062
public static int writeInt(byte[] target, int offset, int value) {
        target[offset] = (byte) (value >>> 24);
        target[offset + 1] = (byte) (value >>> 16);
        target[offset + 2] = (byte) (value >>> 8);
        target[offset + 3] = (byte) value;
        return Integer.BYTES;
    }