public static SimpleTextTranslationCache GetTranslationCache <TAsset>(this IRedirectorHandler handler, string calculatedModificationPath, TAsset asset, IAssetOrResourceLoadedContext context, bool includeStreams = true) where TAsset : Object { var defaultTranslationFile = Path.Combine(calculatedModificationPath, DefaultTranslationFileName); var streams = GetRedirectionStreams(calculatedModificationPath, asset, context, handler.EnableFallbackMapping); if (!includeStreams) { return(new SimpleTextTranslationCache( defaultTranslationFile, false)); } return(new SimpleTextTranslationCache( defaultTranslationFile, streams, false, true)); }
public static ConfigEntry <TConf> ConfigEntryBind <TConf>(this IRedirectorHandler handler, string key, TConf defaultValue, ConfigDescription description) { return(handler.Plugin.Config.Bind <TConf>(handler.ConfigSectionName, key, defaultValue, description)); }
public static SimpleTextTranslationCache GetDumpCache <TAsset>(this IRedirectorHandler handler, string calculatedModificationPath, TAsset asset, IAssetOrResourceLoadedContext context) where TAsset : Object { return(handler.GetTranslationCache(calculatedModificationPath, asset, context, false)); }