intl

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 25, 2025 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var UnifiedFS embed.FS

Functions

func FileExists

func FileExists(filename string) bool

FileExists 检查嵌入式文件是否存在

func FindResource

func FindResource(levelName, base, arch, ext string) ([]byte, error)

FindResource 查找嵌入式资源文件,支持架构特定查找

func GetFileContent

func GetFileContent(filename string) ([]byte, error)

GetFileContent 获取嵌入式文件内容

func GetLevelEntryFile

func GetLevelEntryFile(levelName, entryFile string) ([]byte, error)

GetLevelEntryFile 获取指定级别的入口文件内容

func GetLevelManifest

func GetLevelManifest(levelName string) ([]byte, error)

GetLevelManifest 获取指定级别的manifest文件内容

func GetLevelResource

func GetLevelResource(levelName, resourceName string) ([]byte, error)

GetLevelResource 获取指定级别的资源文件内容

func GetResourcePath

func GetResourcePath(levelName, filename string) string

GetResourcePath 获取嵌入式资源的embed://路径格式

func ListLevels

func ListLevels() ([]string, error)

ListLevels 列出所有可用的级别(community, professional, custom)

func ParseEmbedPath

func ParseEmbedPath(embedPath string) (levelName, filePath string, err error)

ParseEmbedPath 解析embed://路径,返回level和文件路径

func ReadDir

func ReadDir(dirname string) ([]fs.DirEntry, error)

ReadDir 读取嵌入式目录内容

func ReadEmbedResource

func ReadEmbedResource(embedPath string) ([]byte, error)

ReadEmbedResource 根据embed://路径读取嵌入式资源

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL