C# 클래스 DBreeze.Storage.MemoryStorage

Memory storage
상속: IDisposable
파일 보기 프로젝트 열기: hhblaze/DBreeze 1 사용 예제들

공개 메소드들

메소드 설명
Clear ( bool withInternalArrayResize ) : void

Sets EOF pointer to 0.

USE withInternalArrayResize by necessity. If it's true then array will be re-initialized to initial capacity

this also will call GC and the whole process will take some time.

If false, only pointer EOF will be set to 0, capacity of the array will not be changed - very fast

Dispose ( ) : void
GetFullData ( ) : byte[]

Can return null

MemoryStorage ( int initialCapacity, int increaseOnBytes, eMemoryExpandStartegy strategy ) : System

Read ( int offset, int length ) : byte[]

If length = 0 returns new byte[0]

Write_ByOffset ( int offset, byte &data ) : void

Write_ToTheEnd ( byte &data ) : int

Writes_ByOffsets ( byte[]>.Dictionary datas ) : void

비공개 메소드들

메소드 설명
Resize ( int upTo ) : void
Write ( byte data, int offset ) : void

메소드 상세

Clear() 공개 메소드

Sets EOF pointer to 0.

USE withInternalArrayResize by necessity. If it's true then array will be re-initialized to initial capacity

this also will call GC and the whole process will take some time.

If false, only pointer EOF will be set to 0, capacity of the array will not be changed - very fast

public Clear ( bool withInternalArrayResize ) : void
withInternalArrayResize bool
리턴 void

Dispose() 공개 메소드

public Dispose ( ) : void
리턴 void

GetFullData() 공개 메소드

Can return null
public GetFullData ( ) : byte[]
리턴 byte[]

MemoryStorage() 공개 메소드

public MemoryStorage ( int initialCapacity, int increaseOnBytes, eMemoryExpandStartegy strategy ) : System
initialCapacity int Initial Memory Capacity in bytes
increaseOnBytes int Rules is strategy is FIXED_LENGTH_INCREASE, quantity of bytes to increse memory
strategy eMemoryExpandStartegy Memory expand strategy
리턴 System

Read() 공개 메소드

If length = 0 returns new byte[0]
public Read ( int offset, int length ) : byte[]
offset int
length int
리턴 byte[]

Write_ByOffset() 공개 메소드

public Write_ByOffset ( int offset, byte &data ) : void
offset int
data byte
리턴 void

Write_ToTheEnd() 공개 메소드

public Write_ToTheEnd ( byte &data ) : int
data byte
리턴 int

Writes_ByOffsets() 공개 메소드

public Writes_ByOffsets ( byte[]>.Dictionary datas ) : void
datas byte[]>.Dictionary
리턴 void