bufferStuff/writers/IWriter.ts

20 lines
675 B
TypeScript
Raw Permalink Normal View History

2023-04-28 16:47:02 +01:00
export interface IWriter {
toBuffer(): Buffer,
toString(): string,
writeBuffer(buffer:Buffer): IWriter,
writeUint8Array(array:Uint8Array): IWriter,
writeByte(value:number): IWriter,
writeUByte(value:number): IWriter,
writeBool(value:boolean|number): IWriter,
writeShort(value:number): IWriter,
writeUShort(value:number): IWriter,
writeInt(value:number): IWriter,
writeUInt(value:number): IWriter,
writeLong(value:number|bigint): IWriter,
2023-04-28 16:47:02 +01:00
writeULong(value:number): IWriter,
writeFloat(value:number): IWriter,
writeDouble(value:number): IWriter,
2023-05-02 10:12:40 +01:00
writeShortString(text:string): IWriter,
2023-04-28 16:47:02 +01:00
writeString(text:string): IWriter,
2023-05-02 10:12:40 +01:00
writeString16(text:string): IWriter,
2023-04-28 16:47:02 +01:00
}