Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BuildConfig ¶
type BuildConfig struct { Root ContentHash Install ContentHash InstallSize uint64 Download ContentHash DownloadSize uint64 Encoding BuildConfigEncoding EncodingSize BuildConfigEncodingSize Patch ContentHash PatchSize uint64 PatchConfig CDNHash }
A BuildConfig contains information on the current root, install, and download files, as well as the encoding file, and the currently available patch.
type BuildConfigEncoding ¶
type BuildConfigEncoding struct { ContentHash ContentHash CDNHash CDNHash }
A BuildConfigEncoding contains the content and CDN hashes of an encoding file.
type BuildConfigEncodingSize ¶
A BuildConfigEncodingSize contains the BLTE-encoded and raw sizes of the encoding file.
type CDNConfig ¶
type CDNConfig struct { Archives []CDNHash ArchiveGroup CDNHash PatchArchives []CDNHash PatchArchiveGroup CDNHash }
A CDNConfig contains information on the archives, which are used to bundle smaller files together on the CDN.
type CDNHash ¶
type CDNHash hash
A CDNHash is usually an MD5 hash of the BLTE header of a data file. Blizzard uses these to generate filenames for storage on the CDN.
type CDNInfo ¶
A CDNInfo contains information on which CDNs hold data for which regions, as well as what path the data is stored under.
type ContentHash ¶
type ContentHash hash
A ContentHash is an MD5 hash of the raw contents of a file, before it is BLTE-encoded. These must be looked up in the encoding table to get a CDNHash before files can be downloaded.
func (ContentHash) Equal ¶
func (h ContentHash) Equal(o ContentHash) bool
func (ContentHash) Less ¶
func (h ContentHash) Less(o ContentHash) bool
type ContentType ¶
type ContentType string
A ContentType is a type of thing stored on the CDN.
Each separate content type is stored under a different directory.
const ( ContentTypeConfig ContentType = "config" ContentTypeData ContentType = "data" ContentTypePatch ContentType = "patch" )
The content types below are believed to be exhaustive.
type FilenameMapper ¶
type FilenameMapper interface {
ToContentHash(fn string) (h ContentHash, ok bool)
}
A FilenameMapper represents a way for mapping filenames to content hashes.
This might be implemented by a listfile, or MNDX, or any of the myriad other ways Blizzard has deigned to refer to files.
type ProgramCode ¶
type ProgramCode string
A ProgramCode is a reference to a particular game or game release channel.
Blizzard tracks release and PTR as separate program codes, even though they usually refer to the same underlying CDN storage.
const ( // ProgramHotS is the ProgramCode for Heroes of the Storm. ProgramHotS ProgramCode = "hero" // ProgramHotSTest is the ProgramCode for the PTR of Heroes of the Storm. ProgramHotSTest ProgramCode = "herot" )