Table of Contents

ManifestResourceMatch Enum

Definition

Namespace
Cuemon.Reflection
Assemblies
Cuemon.Core.dll
Source
src/Cuemon.Core/Reflection/ManifestResourceMatch.cs

Specifies the way of finding and returning an embedded resource.

public enum ManifestResourceMatch

Fields

ContainsExtension = 3

Specifies a partial match on the file extension contained within the file name of the embedded resource.

ContainsName = 1

Specifies a partial match on the file name of the embedded resource.

Extension = 2

Specifies an exact match on the file extension contained within the file name of the embedded resource.

Name = 0

Specifies an exact match on the file name of the embedded resource.

Examples

The following example demonstrates how to use to specify how to locate embedded assembly resources.

// Program.cs
using System;
using Cuemon.Reflection;

var match = ManifestResourceMatch.Extension;

switch (match)
{
    case ManifestResourceMatch.Name:
        Console.WriteLine("Match by exact resource name.");
        break;
    case ManifestResourceMatch.ContainsName:
        Console.WriteLine("Match by partial name match.");
        break;
    case ManifestResourceMatch.Extension:
        Console.WriteLine("Match by file extension (e.g., .json).");
        break;
    case ManifestResourceMatch.ContainsExtension:
        Console.WriteLine("Match by partial extension match.");
        break;

}