C# 클래스 TagTool.Cache.TagCache

Provides methods for easily editing tags.dat files.
파일 보기 프로젝트 열기: TheGuardians/TagTool 1 사용 예제들

공개 메소드들

메소드 설명
AllocateTag ( ) : TagInstance

Allocates a new tag at the end of the tag list without updating the file. The tag's group will be null until it is assigned data. You can give the tag data by using one of the overwrite functions.

AllocateTag ( TagGroup type ) : TagInstance

Allocates a new tag at the end of the tag list without updating the file. You can give the tag data by using one of the overwrite functions.

DuplicateTag ( Stream stream, TagInstance tag ) : TagInstance

Duplicates a tag.

ExtractTag ( Stream stream, TagInstance tag ) : TagData

Reads a tag's data from the file.

ExtractTagRaw ( Stream stream, TagInstance tag ) : byte[]

Reads a tag's raw data from the file, including its header.

SetTagData ( Stream stream, TagInstance tag, TagData data ) : void

Overwrites a tag's data.

SetTagDataRaw ( Stream stream, TagInstance tag, byte data ) : void

Overwrites a tag's raw data, including its header.

TagCache ( Stream stream ) : System

Opens a tags.dat file from a stream.

UpdateTagOffsets ( BinaryWriter writer ) : void

Updates the tag offset table in the file.

비공개 메소드들

메소드 설명
BuildTagDescription ( Stream stream, TagInstance tag, uint &dataOffset ) : TagData

Builds a description for a tag's data without extracting anything.

FixTagOffsets ( long startOffset, long sizeDelta, TagInstance ignore ) : void

Fixes tag offsets after a resize operation.

GetNewTagOffset ( int index ) : long

Gets the offset that a new tag should be inserted at so that the tags are stored in order by index.

GetTagDataEndOffset ( ) : long

Gets the tag data end offset.

Load ( BinaryReader reader ) : void

Reads the tags.dat file.

ResizeBlock ( Stream stream, TagInstance tag, long startOffset, long oldSize, long newSize ) : void

Resizes a block of data in the file.

UpdateFileHeader ( BinaryWriter writer, long offsetTableOffset ) : void

Updates the file header.

메소드 상세

AllocateTag() 공개 메소드

Allocates a new tag at the end of the tag list without updating the file. The tag's group will be null until it is assigned data. You can give the tag data by using one of the overwrite functions.
public AllocateTag ( ) : TagInstance
리턴 TagTool.TagGroups.TagInstance

AllocateTag() 공개 메소드

Allocates a new tag at the end of the tag list without updating the file. You can give the tag data by using one of the overwrite functions.
public AllocateTag ( TagGroup type ) : TagInstance
type TagGroup The tag's type information.
리턴 TagTool.TagGroups.TagInstance

DuplicateTag() 공개 메소드

Duplicates a tag.
public DuplicateTag ( Stream stream, TagInstance tag ) : TagInstance
stream Stream The stream to write to.
tag TagTool.TagGroups.TagInstance The tag to duplicate.
리턴 TagTool.TagGroups.TagInstance

ExtractTag() 공개 메소드

Reads a tag's data from the file.
public ExtractTag ( Stream stream, TagInstance tag ) : TagData
stream Stream The stream to read from.
tag TagTool.TagGroups.TagInstance The tag to read.
리턴 TagData

ExtractTagRaw() 공개 메소드

Reads a tag's raw data from the file, including its header.
public ExtractTagRaw ( Stream stream, TagInstance tag ) : byte[]
stream Stream The stream to read from.
tag TagTool.TagGroups.TagInstance The tag to read.
리턴 byte[]

SetTagData() 공개 메소드

Overwrites a tag's data.
public SetTagData ( Stream stream, TagInstance tag, TagData data ) : void
stream Stream The stream to write to.
tag TagTool.TagGroups.TagInstance The tag to overwrite.
data TagData The data to store.
리턴 void

SetTagDataRaw() 공개 메소드

Overwrites a tag's raw data, including its header.
tag
public SetTagDataRaw ( Stream stream, TagInstance tag, byte data ) : void
stream Stream The stream to write to.
tag TagTool.TagGroups.TagInstance The tag to overwrite.
data byte The data to overwrite the tag with.
리턴 void

TagCache() 공개 메소드

Opens a tags.dat file from a stream.
public TagCache ( Stream stream ) : System
stream Stream The stream to open.
리턴 System

UpdateTagOffsets() 공개 메소드

Updates the tag offset table in the file.
public UpdateTagOffsets ( BinaryWriter writer ) : void
writer System.IO.BinaryWriter The stream to write to.
리턴 void