C# Class Netronics.PacketBuffer

Inheritance: IDisposable
Mostra file Open project: shlee322/Netronics Class Usage Examples

Protected Properties

Property Type Description
Disposed bool

Public Methods

Method Description
AvailableBytes ( ) : long

Buffer에서 현재 읽을 수 있는 byte 수를 반환하는 메소드

BeginBufferIndex ( ) : void

Buffer의 위치를 0으로 변경하는 메소드

Dispose ( ) : void
EndBufferIndex ( ) : void

Buffer 읽기를 끝내고 지금까지 읽은 데이터를 Buffer내에서 삭제하는 메소드

FindBytes ( byte q ) : long

Buffer내에서 해당 byte[]을 찾는 메소드

GetBytes ( ) : byte[]

Buffer의 데이터를 byte[] 형태로 모두 반환하는 메소드 Netronics 내부 용도이기 때문에 사용을 추천하지 않음

GetStream ( ) : Stream

Buffer에 사용되는 Stream을 반환하는 메소드 Netronics 내부 용도이기 때문에 사용을 추천하지 않음

IsDisposed ( ) : bool

이 객체가 Disposed 되었는지 여부를 반환하는 메소드

Read ( byte buffer, int offset, int count, bool exact = true ) : int
ReadByte ( ) : byte
ReadBytes ( int length ) : byte[]
ReadBytes ( byte buffer ) : void
ReadInt16 ( ) : Int16
ReadInt32 ( ) : Int32
ReadInt64 ( ) : System.Int64
ReadLine ( ) : string
ReadString ( int len, Encoding encoding = null ) : string
ReadUInt16 ( ) : UInt16
ReadUInt32 ( ) : UInt32
ReadUInt64 ( ) : System.UInt64
ResetBufferIndex ( ) : void

Buffer의 위치를 처음으로 변경하는 메소드

SetPosition ( int p ) : void

Buffer의 위치를 해당값으로 변경하는 메소드

Write ( byte buffer, int offset, int count ) : void
Write ( object value ) : void
WriteByte ( byte value ) : void
WriteBytes ( byte value ) : void
WriteInt16 ( Int16 value ) : void
WriteInt32 ( Int32 value ) : void
WriteInt64 ( System.Int64 value ) : void
WriteStream ( Stream stream ) : void
WriteUInt16 ( UInt16 value ) : void
WriteUInt32 ( UInt32 value ) : void
WriteUInt64 ( System.UInt64 value ) : void

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Method Details

AvailableBytes() public method

Buffer에서 현재 읽을 수 있는 byte 수를 반환하는 메소드
public AvailableBytes ( ) : long
return long

BeginBufferIndex() public method

Buffer의 위치를 0으로 변경하는 메소드
public BeginBufferIndex ( ) : void
return void

Dispose() public method

public Dispose ( ) : void
return void

Dispose() protected method

protected Dispose ( bool disposing ) : void
disposing bool
return void

EndBufferIndex() public method

Buffer 읽기를 끝내고 지금까지 읽은 데이터를 Buffer내에서 삭제하는 메소드
public EndBufferIndex ( ) : void
return void

FindBytes() public method

Buffer내에서 해당 byte[]을 찾는 메소드
public FindBytes ( byte q ) : long
q byte 찾을 데이터
return long

GetBytes() public method

Buffer의 데이터를 byte[] 형태로 모두 반환하는 메소드 Netronics 내부 용도이기 때문에 사용을 추천하지 않음
public GetBytes ( ) : byte[]
return byte[]

GetStream() public method

Buffer에 사용되는 Stream을 반환하는 메소드 Netronics 내부 용도이기 때문에 사용을 추천하지 않음
public GetStream ( ) : Stream
return Stream

IsDisposed() public method

이 객체가 Disposed 되었는지 여부를 반환하는 메소드
public IsDisposed ( ) : bool
return bool

Read() public method

public Read ( byte buffer, int offset, int count, bool exact = true ) : int
buffer byte
offset int
count int
exact bool
return int

ReadByte() public method

public ReadByte ( ) : byte
return byte

ReadBytes() public method

public ReadBytes ( int length ) : byte[]
length int
return byte[]

ReadBytes() public method

public ReadBytes ( byte buffer ) : void
buffer byte
return void

ReadInt16() public method

public ReadInt16 ( ) : Int16
return System.Int16

ReadInt32() public method

public ReadInt32 ( ) : Int32
return System.Int32

ReadInt64() public method

public ReadInt64 ( ) : System.Int64
return System.Int64

ReadLine() public method

public ReadLine ( ) : string
return string

ReadString() public method

public ReadString ( int len, Encoding encoding = null ) : string
len int
encoding Encoding
return string

ReadUInt16() public method

public ReadUInt16 ( ) : UInt16
return System.UInt16

ReadUInt32() public method

public ReadUInt32 ( ) : UInt32
return System.UInt32

ReadUInt64() public method

public ReadUInt64 ( ) : System.UInt64
return System.UInt64

ResetBufferIndex() public method

Buffer의 위치를 처음으로 변경하는 메소드
public ResetBufferIndex ( ) : void
return void

SetPosition() public method

Buffer의 위치를 해당값으로 변경하는 메소드
public SetPosition ( int p ) : void
p int
return void

Write() public method

public Write ( byte buffer, int offset, int count ) : void
buffer byte
offset int
count int
return void

Write() public method

public Write ( object value ) : void
value object
return void

WriteByte() public method

public WriteByte ( byte value ) : void
value byte
return void

WriteBytes() public method

public WriteBytes ( byte value ) : void
value byte
return void

WriteInt16() public method

public WriteInt16 ( Int16 value ) : void
value System.Int16
return void

WriteInt32() public method

public WriteInt32 ( Int32 value ) : void
value System.Int32
return void

WriteInt64() public method

public WriteInt64 ( System.Int64 value ) : void
value System.Int64
return void

WriteStream() public method

public WriteStream ( Stream stream ) : void
stream Stream
return void

WriteUInt16() public method

public WriteUInt16 ( UInt16 value ) : void
value System.UInt16
return void

WriteUInt32() public method

public WriteUInt32 ( UInt32 value ) : void
value System.UInt32
return void

WriteUInt64() public method

public WriteUInt64 ( System.UInt64 value ) : void
value System.UInt64
return void

Property Details

Disposed protected_oe property

protected bool Disposed
return bool