public class StreamingUtils extends Object
| 构造器和说明 |
|---|
StreamingUtils() |
| 限定符和类型 | 方法和说明 |
|---|---|
static byte[] |
intToBytes(int value) |
static byte[] |
intToBytesBigending(int value) |
static byte[] |
longToBytes(long value) |
static byte |
readByte(InputStream stream) |
static void |
readBytes(byte[] buffer,
int offset,
int count,
InputStream stream) |
static byte[] |
readBytes(int count,
InputStream stream) |
static double |
readDouble(InputStream stream) |
static int |
readInt(byte[] src) |
static int |
readInt(byte[] src,
int offset) |
static int |
readInt(InputStream stream) |
static int |
readIntBigending(byte[] src,
int offset) |
static int |
readIntBigending(InputStream stream) |
static long |
readLong(byte[] src,
int offset) |
static long |
readLong(InputStream stream) |
static long |
readLongBigending(byte[] src,
int offset) |
static long |
readLongBigending(InputStream stream) |
static boolean |
readTLBool(InputStream inputStream) |
static byte[] |
readTLBytes(InputStream stream) |
static String |
readTLString(InputStream stream) |
static long |
readUInt(byte[] src) |
static long |
readUInt(byte[] src,
int offset) |
static long |
readUInt(InputStream stream)
Reading uint from stream
|
static long |
readUIntBigending(byte[] src,
int offset) |
static long |
readUIntBigending(InputStream stream) |
static void |
skipBytes(int count,
InputStream stream) |
static void |
writeByte(Byte v,
OutputStream stream) |
static void |
writeByte(int v,
OutputStream stream) |
static void |
writeByteArray(byte[] data,
int offset,
int len,
OutputStream stream) |
static void |
writeByteArray(byte[] data,
OutputStream stream) |
static void |
writeDouble(Double v,
OutputStream stream) |
static void |
writeInt(int v,
byte[] buffer,
int offset) |
static void |
writeInt(Integer v,
OutputStream stream) |
static void |
writeIntBigending(int v,
byte[] buffer,
int offset) |
static void |
writeIntBigending(int v,
OutputStream stream) |
static void |
writeLong(long v,
byte[] buffer,
int offset) |
static void |
writeLong(Long v,
OutputStream stream) |
static void |
writeLongBigending(long v,
byte[] buffer,
int offset) |
static void |
writeLongBigending(long v,
OutputStream stream) |
static void |
writeTLBool(Boolean v,
OutputStream stream) |
static void |
writeTLBytes(byte[] v,
OutputStream stream) |
static void |
writeTLBytes(TLBytes v,
OutputStream stream) |
static void |
writeTLString(String v,
OutputStream stream) |
public static void writeByte(int v,
OutputStream stream)
throws IOException
IOExceptionpublic static void writeByte(Byte v, OutputStream stream) throws IOException
IOExceptionpublic static byte readByte(InputStream stream) throws IOException
IOExceptionpublic static void writeInt(Integer v, OutputStream stream) throws IOException
IOExceptionpublic static void writeInt(int v,
byte[] buffer,
int offset)
public static void writeIntBigending(int v,
OutputStream stream)
throws IOException
IOExceptionpublic static void writeIntBigending(int v,
byte[] buffer,
int offset)
public static void writeLong(Long v, OutputStream stream) throws IOException
IOExceptionpublic static void writeLong(long v,
byte[] buffer,
int offset)
public static void writeLongBigending(long v,
OutputStream stream)
throws IOException
IOExceptionpublic static void writeLongBigending(long v,
byte[] buffer,
int offset)
public static void writeDouble(Double v, OutputStream stream) throws IOException
IOExceptionpublic static void writeByteArray(byte[] data,
OutputStream stream)
throws IOException
IOExceptionpublic static void writeByteArray(byte[] data,
int offset,
int len,
OutputStream stream)
throws IOException
IOExceptionpublic static void writeTLString(String v, OutputStream stream) throws IOException
IOExceptionpublic static void writeTLBool(Boolean v, OutputStream stream) throws IOException
IOExceptionpublic static boolean readTLBool(InputStream inputStream) throws IOException
IOExceptionpublic static void writeTLBytes(byte[] v,
OutputStream stream)
throws IOException
IOExceptionpublic static void writeTLBytes(TLBytes v, OutputStream stream) throws IOException
IOExceptionpublic static int readInt(InputStream stream) throws IOException
IOExceptionpublic static int readIntBigending(InputStream stream) throws IOException
IOExceptionpublic static long readUInt(InputStream stream) throws IOException
stream - source streamIOException - reading exceptionpublic static long readUIntBigending(InputStream stream) throws IOException
IOExceptionpublic static long readLong(InputStream stream) throws IOException
IOExceptionpublic static long readLongBigending(InputStream stream) throws IOException
IOExceptionpublic static double readDouble(InputStream stream) throws IOException
IOExceptionpublic static String readTLString(InputStream stream) throws IOException
IOExceptionpublic static byte[] readBytes(int count,
InputStream stream)
throws IOException
IOExceptionpublic static void skipBytes(int count,
InputStream stream)
throws IOException
IOExceptionpublic static void readBytes(byte[] buffer,
int offset,
int count,
InputStream stream)
throws IOException
IOExceptionpublic static byte[] readTLBytes(InputStream stream) throws IOException
IOExceptionpublic static byte[] intToBytes(int value)
public static byte[] intToBytesBigending(int value)
public static byte[] longToBytes(long value)
public static int readInt(byte[] src)
public static int readInt(byte[] src,
int offset)
public static int readIntBigending(byte[] src,
int offset)
public static long readUInt(byte[] src)
public static long readUInt(byte[] src,
int offset)
public static long readUIntBigending(byte[] src,
int offset)
public static long readLong(byte[] src,
int offset)
public static long readLongBigending(byte[] src,
int offset)
Copyright © 2018. All rights reserved.