C# 클래스 DarkMapleLib.Helpers.ArrayWriter

Class to handle writing data to an byte array
파일 보기 프로젝트 열기: enguard/Ecalia

Private Properties

프로퍼티 타입 설명
EnsureCapacity void

공개 메소드들

메소드 설명
ArrayWriter ( int initialBufferSize = 0x50 ) : System

Creates a new instance of a ArrayWriter

SetBool ( bool value, int position ) : void

Sets a bool in the buffer

SetByte ( byte value, int position ) : void

Sets a unsigned byte in the buffer

SetBytes ( byte bytes, int position ) : void

Sets bytes in the buffer

SetInt ( int value, int position ) : void

Sets a signed int in the buffer

SetLong ( long value, int position ) : void

Sets a signed long in the buffer

SetSByte ( sbyte value, int position ) : void

Sets a signed byte in the buffer

SetShort ( short value, int position ) : void

Sets a signed short in the buffer

SetUInt ( uint value, int position ) : void

Sets a unsigned int in the buffer

SetULong ( ulong value, int position ) : void

Sets a unsigned long in the buffer

SetUShort ( ushort value, int position ) : void

Sets a unsigned short in the buffer

ToArray ( bool direct = false ) : byte[]

Creates an byte array of the current ArrayWriter

WriteBool ( bool value ) : void

Writes a bool to the buffer

WriteByte ( byte value ) : void

Writes a unsigned byte to the buffer

WriteBytes ( byte bytes ) : void

Writes bytes to the buffer

WriteInt ( int value ) : void

Writes a signed int to the buffer

WriteLong ( long value ) : void

Writes a signed long to the buffer

WriteMapleString ( string mString ) : void

Write a string as maplestring to the buffer

WriteSByte ( sbyte value ) : void

Writes a signed byte to the buffer

WriteShort ( short value ) : void

Writes a signed short to the buffer

WriteUInt ( uint value ) : void

Writes a unsigned int to the buffer

WriteULong ( ulong value ) : void

Writes a unsigned long to the buffer

WriteUShort ( ushort value ) : void

Writes a unsigned short to the buffer

WriteZeroBytes ( int count ) : void

Writes a number of empty bytes to the buffer

비공개 메소드들

메소드 설명
EnsureCapacity ( int length ) : void

Prevents the buffer being to small

메소드 상세

ArrayWriter() 공개 메소드

Creates a new instance of a ArrayWriter
public ArrayWriter ( int initialBufferSize = 0x50 ) : System
initialBufferSize int Sets the initial size of the buffer
리턴 System

SetBool() 공개 메소드

Sets a bool in the buffer
public SetBool ( bool value, int position ) : void
value bool
position int
리턴 void

SetByte() 공개 메소드

Sets a unsigned byte in the buffer
public SetByte ( byte value, int position ) : void
value byte
position int
리턴 void

SetBytes() 공개 메소드

Sets bytes in the buffer
public SetBytes ( byte bytes, int position ) : void
bytes byte
position int
리턴 void

SetInt() 공개 메소드

Sets a signed int in the buffer
public SetInt ( int value, int position ) : void
value int
position int
리턴 void

SetLong() 공개 메소드

Sets a signed long in the buffer
public SetLong ( long value, int position ) : void
value long
position int
리턴 void

SetSByte() 공개 메소드

Sets a signed byte in the buffer
public SetSByte ( sbyte value, int position ) : void
value sbyte
position int
리턴 void

SetShort() 공개 메소드

Sets a signed short in the buffer
public SetShort ( short value, int position ) : void
value short
position int
리턴 void

SetUInt() 공개 메소드

Sets a unsigned int in the buffer
public SetUInt ( uint value, int position ) : void
value uint
position int
리턴 void

SetULong() 공개 메소드

Sets a unsigned long in the buffer
public SetULong ( ulong value, int position ) : void
value ulong
position int
리턴 void

SetUShort() 공개 메소드

Sets a unsigned short in the buffer
public SetUShort ( ushort value, int position ) : void
value ushort
position int
리턴 void

ToArray() 공개 메소드

Creates an byte array of the current ArrayWriter
public ToArray ( bool direct = false ) : byte[]
direct bool If true, returns a direct reference of the buffer
리턴 byte[]

WriteBool() 공개 메소드

Writes a bool to the buffer
public WriteBool ( bool value ) : void
value bool
리턴 void

WriteByte() 공개 메소드

Writes a unsigned byte to the buffer
public WriteByte ( byte value ) : void
value byte
리턴 void

WriteBytes() 공개 메소드

Writes bytes to the buffer
public WriteBytes ( byte bytes ) : void
bytes byte
리턴 void

WriteInt() 공개 메소드

Writes a signed int to the buffer
public WriteInt ( int value ) : void
value int
리턴 void

WriteLong() 공개 메소드

Writes a signed long to the buffer
public WriteLong ( long value ) : void
value long
리턴 void

WriteMapleString() 공개 메소드

Write a string as maplestring to the buffer
public WriteMapleString ( string mString ) : void
mString string String to write
리턴 void

WriteSByte() 공개 메소드

Writes a signed byte to the buffer
public WriteSByte ( sbyte value ) : void
value sbyte
리턴 void

WriteShort() 공개 메소드

Writes a signed short to the buffer
public WriteShort ( short value ) : void
value short
리턴 void

WriteUInt() 공개 메소드

Writes a unsigned int to the buffer
public WriteUInt ( uint value ) : void
value uint
리턴 void

WriteULong() 공개 메소드

Writes a unsigned long to the buffer
public WriteULong ( ulong value ) : void
value ulong
리턴 void

WriteUShort() 공개 메소드

Writes a unsigned short to the buffer
public WriteUShort ( ushort value ) : void
value ushort
리턴 void

WriteZeroBytes() 공개 메소드

Writes a number of empty bytes to the buffer
public WriteZeroBytes ( int count ) : void
count int Number of empty (zero) bytes to write
리턴 void