namespace StardewModdingAPI.Framework.AssemblyRewriting { /// Metadata about a preprocessed assembly. internal class RewriteResult { /********* ** Accessors *********/ /// The original assembly path. public readonly string OriginalAssemblyPath; /// The cache paths. public readonly CachePaths CachePaths; /// The rewritten assembly bytes. public readonly byte[] AssemblyBytes; /// The MD5 hash for the original assembly. public readonly string Hash; /// Whether to use the cached assembly instead of the original assembly. public readonly bool UseCachedAssembly; /// Whether this data is newer than the cache. public readonly bool IsNewerThanCache; /********* ** Public methods *********/ /// Construct an instance. /// /// The cache paths. /// The rewritten assembly bytes. /// The MD5 hash for the original assembly. /// Whether to use the cached assembly instead of the original assembly. /// Whether this data is newer than the cache. public RewriteResult(string originalAssemblyPath, CachePaths cachePaths, byte[] assemblyBytes, string hash, bool useCachedAssembly, bool isNewerThanCache) { this.OriginalAssemblyPath = originalAssemblyPath; this.CachePaths = cachePaths; this.Hash = hash; this.AssemblyBytes = assemblyBytes; this.UseCachedAssembly = useCachedAssembly; this.IsNewerThanCache = isNewerThanCache; } } }