This commit was manufactured by cvs2svn to create branch 'mono-1-0'.
[mono.git] / mono / metadata / private.h
1 #ifndef __MONO_METADATA_PRIVATE_H__
2 #define __MONO_METADATA_PRIVATE_H__
3
4 /*
5  * This enumeration is used to describe the data types in the metadata
6  * tables
7  */
8 enum {
9         MONO_MT_END,
10
11         /* Sized elements */
12         MONO_MT_UINT32,
13         MONO_MT_UINT16,
14         MONO_MT_UINT8,
15
16         /* Index into Blob heap */
17         MONO_MT_BLOB_IDX,
18
19         /* Index into String heap */
20         MONO_MT_STRING_IDX,
21
22         /* GUID index */
23         MONO_MT_GUID_IDX,
24
25         /* Pointer into a table */
26         MONO_MT_TABLE_IDX,
27
28         /* HasConstant:Parent pointer (Param, Field or Property) */
29         MONO_MT_CONST_IDX,
30
31         /* HasCustomAttribute index.  Indexes any table except CustomAttribute */
32         MONO_MT_HASCAT_IDX,
33         
34         /* CustomAttributeType encoded index */
35         MONO_MT_CAT_IDX,
36
37         /* HasDeclSecurity index: TypeDef Method or Assembly */
38         MONO_MT_HASDEC_IDX,
39
40         /* Implementation coded index: File, Export AssemblyRef */
41         MONO_MT_IMPL_IDX,
42
43         /* HasFieldMarshal coded index: Field or Param table */
44         MONO_MT_HFM_IDX,
45
46         /* MemberForwardedIndex: Field or Method */
47         MONO_MT_MF_IDX,
48
49         /* TypeDefOrRef coded index: typedef, typeref, typespec */
50         MONO_MT_TDOR_IDX,
51
52         /* MemberRefParent coded index: typeref, moduleref, method, memberref, typesepc, typedef */
53         MONO_MT_MRP_IDX,
54
55         /* MethodDefOrRef coded index: Method or Member Ref table */
56         MONO_MT_MDOR_IDX,
57
58         /* HasSemantic coded index: Event or Property */
59         MONO_MT_HS_IDX,
60
61         /* ResolutionScope coded index: Module, ModuleRef, AssemblytRef, TypeRef */
62         MONO_MT_RS_IDX
63 };
64
65 typedef struct {
66         int   code;
67         const char *def;
68 } MonoMetaTable;
69
70 const char *mono_meta_table_name (int table);
71
72 /* Internal functions */
73 void           mono_metadata_compute_table_bases (MonoImage *meta);
74
75 const MonoMetaTable *mono_metadata_get_table    (MonoMetaTableEnum table);
76
77 #endif /* __MONO_METADATA_PRIVATE_H__ */
78