little-endian or intel format.
433354
public static int readIntegerLittleEndian(byte[] buffer, int offset) {
		int value;
		value = (buffer[offset] & 0xFF);
		value |= (buffer[offset + 1] & 0xFF) << 8;
		value |= (buffer[offset + 2] & 0xFF) << 16;
		value |= (buffer[offset + 3] & 0xFF) << 24;
		return value;
	}
410919
public static void setLong(long n, byte[] b, int off, boolean littleEndian) {
		if (littleEndian) {
			setInt((int) n, b, off, LITTLE_ENDIAN);
			setInt((int) (n >>> 32), b, off + 4, LITTLE_ENDIAN);
		} else {
			setInt((int) (n >>> 32), b, off, BIG_ENDIAN);
			setInt((int) n, b, off + 4, BIG_ENDIAN);
		}
	}
888673
def _detect_endian(cls, stream):
        
        stream.seek(0)
        endian_str = stream.read(2)
        return BIG_ENDIAN if endian_str == b'MM' else LITTLE_ENDIAN
1255566
def encode_int(v):
    """"""
    if not is_numeric(v) or v < 0 or v >= TT256:
        raise Exception("Integer invalid or out of range: %r" % v)
    return int_to_big_endian(v)
1087224
function amf3decUI29(buf) {
    var val = 0;
    var len = 1;
    var b;

    do {
        b = buf.readUInt8(len++);
        val = (val << 7) + (b & 0x7F);
    } while (len < 5 || b > 0x7F);

    if (len == 5) val = val | b; // Preserve the major bit of the last byte

    return { len: len, value: val }
}
261238
private long build64(int i1, int i2)
	{
		long	msi = (long)i1;
		long	lsi = (long)i2 & 0xFFFFFFFFL;
		return	(msi << 32) + lsi;
	}
1328570
public static int readIntegerLittleEndian(InputStream io) throws IOException {
		int value = io.read();
		if (value < 0) throw new EOFException();
		int i = io.read();
		if (i < 0) throw new EOFException();
		value |= i << 8;
		i = io.read();
		if (i < 0) throw new EOFException();
		value |= i << 16;
		i = io.read();
		if (i < 0) throw new EOFException();
		value |= i << 24;
		return value;
	}
1369512
def write_uint32(self, value, little_endian=True):
        
        if little_endian:
            endian = "<"
        else:
            endian = ">"
        return self.pack('%sI' % endian, value)
134152
public static void writeUnsignedShortLittleEndian(IO.WritableByteStream io, int value) throws IOException {
		io.write((byte)(value & 0xFF));
		io.write((byte)((value >> 8) & 0xFF));
	}
1360793
def little_endian(self):
        
        if not self._ptr:
            raise BfdException("BFD not initialized")

        return _bfd.get_bfd_attribute(self._ptr, BfdAttributes.IS_LITTLE_ENDIAN)
206513
public static void writeShortLittleEndian(ByteBuffer io, short value) {
		io.put((byte)(value & 0xFF));
		io.put((byte)((value >> 8) & 0xFF));
	}
570322
def read_uint32(self, little_endian=True):
        
        if little_endian:
            endian = "<"
        else:
            endian = ">"
        return self.unpack('%sI' % endian, 4)
67053
public static void writeUnsignedIntegerBigEndian(IO.WritableByteStream io, long value) throws IOException {
		io.write((byte)((value >> 24) & 0xFF));
		io.write((byte)((value >> 16) & 0xFF));
		io.write((byte)((value >> 8) & 0xFF));
		io.write((byte)(value & 0xFF));
	}
57681
def read_int8(self, little_endian=True):
        
        if little_endian:
            endian = "<"
        else:
            endian = ">"
        return self.unpack('%sb' % endian)
1160435
def read_uint16(self, little_endian=True):
        
        if little_endian:
            endian = "<"
        else:
            endian = ">"
        return self.unpack('%sH' % endian, 2)
1261993
public static int toInt(byte[] b, int off, boolean littleEndian) {
		if (littleEndian) {
			return (b[off] & 0xFF) | ((b[off + 1] & 0xFF) << 8) |
					((b[off + 2] & 0xFF) << 16) | ((b[off + 3] & 0xFF) << 24);
		}
		return ((b[off] & 0xFF) << 24) | ((b[off + 1] & 0xFF) << 16) |
				((b[off + 2] & 0xFF) << 8) | (b[off + 3] & 0xFF);
	}
1184791
public static void writeIntegerBigEndian(byte[] buffer, int offset, int value) {
		buffer[offset++] = (byte)((value >> 24) & 0xFF);
		buffer[offset++] = (byte)((value >> 16) & 0xFF);
		buffer[offset++] = (byte)((value >> 8) & 0xFF);
		buffer[offset] = (byte)(value & 0xFF);
	}