6026f53d8e339675cb51e2792b05a7649d9959f0
[mono.git] / mcs / class / referencesource / mscorlib / system / reflection / manifestresourceinfo.cs
1 // ==++==
2 // 
3 //   Copyright (c) Microsoft Corporation.  All rights reserved.
4 // 
5 // ==--==
6 /*=============================================================================
7 **
8 ** Class: ManifestResourceInfo
9 ** 
10 ** <OWNER>Microsoft</OWNER>
11 **
12 **
13 ** Purpose: For info regarding a manifest resource's topology.
14 **
15 **
16 =============================================================================*/
17
18 namespace System.Reflection {
19     using System;
20     
21 [System.Runtime.InteropServices.ComVisible(true)]
22     public class ManifestResourceInfo {
23         private Assembly _containingAssembly;
24         private String _containingFileName;
25         private ResourceLocation _resourceLocation;
26
27         public ManifestResourceInfo(Assembly containingAssembly,
28                                       String containingFileName,
29                                       ResourceLocation resourceLocation)
30         {
31             _containingAssembly = containingAssembly;
32             _containingFileName = containingFileName;
33             _resourceLocation = resourceLocation;
34         }
35
36         public virtual Assembly ReferencedAssembly
37         {
38             get {
39                 return _containingAssembly;
40             }
41         }
42
43         public virtual String FileName
44         {
45             get {
46                 return _containingFileName;
47             }
48         }
49
50         public virtual ResourceLocation ResourceLocation
51         {
52             get {
53                 return _resourceLocation;
54             }
55         }
56     }
57
58     // The ResourceLocation is a combination of these flags, set or not.
59     // Linked means not Embedded.
60 [Serializable]
61     [Flags]
62 [System.Runtime.InteropServices.ComVisible(true)]
63     public enum ResourceLocation
64     {
65         Embedded = 0x1,
66         ContainedInAnotherAssembly = 0x2,
67         ContainedInManifestFile = 0x4
68     }
69 }