Class ZipFileExternalDataMapper
Provides an external data mapping strategy for extracting data from Zip files.
This mapper searches through the entries of a Zip file (provided via custom context data)
for an entry whose short filename matches the specified originalFilename
.
If a match is found, it opens a stream for that Zip entry.
Inherited Members
Namespace: TriLibCore.Mappers
Assembly: Assembly-CSharp.dll
Syntax
public class ZipFileExternalDataMapper : ExternalDataMapper
Methods
Map(AssetLoaderContext, string, out string)
Attempts to locate and open the data resource corresponding to
originalFilename
in the context of a TriLib model load.
Implementers can check the file system, network sources, or other data repositories
to resolve the file path.
Declaration
public override Stream Map(AssetLoaderContext assetLoaderContext, string originalFilename, out string finalPath)
Parameters
Type | Name | Description |
---|---|---|
AssetLoaderContext | assetLoaderContext | The AssetLoaderContext containing loading settings, callbacks, and references to the model’s assets and hierarchy. |
string | originalFilename | The name or partial path of the resource as referenced in the source file (e.g., a texture filename or other embedded data pointer). |
string | finalPath | Outputs the resolved, absolute path to the located resource.
Returns |
Returns
Type | Description |
---|---|
Stream | A Stream to the resource if located successfully; otherwise,
|