* ILParser.jay: Use type instead of params for calli signatures.
[mono.git] / mcs / ilasm / codegen / ExternTypeRef.cs
1 //
2 // Mono.ILASM.ExternTypeRef
3 //
4 // Author(s):
5 //  Jackson Harper (Jackson@LatitudeGeo.com)
6 //
7 // (C) 2003 Jackson Harper, All rights reserved
8 //
9
10
11 using System;
12
13 namespace Mono.ILASM {
14
15         /// <summary>
16         /// A reference to a type in another assembly
17         /// </summary>
18         public class ExternTypeRef : PeapiTypeRef, IClassRef {
19
20                 public ExternTypeRef (PEAPI.ClassRef extern_type,
21                                 string full_name) : base (extern_type, full_name)
22                 {
23
24                 }
25
26                 public PEAPI.Class PeapiClass {
27                         get {
28                                 return PeapiType as PEAPI.Class;
29                         }
30                 }
31
32                 public PEAPI.ClassRef PeapiClassRef {
33                         get {
34                                 return PeapiType as PEAPI.ClassRef;
35                         }
36                 }
37
38                 public IMethodRef GetMethodRef (ITypeRef ret_type, PEAPI.CallConv call_conv,
39                                 string name, ITypeRef[] param)
40                 {
41                         return new ExternMethodRef (this, ret_type, call_conv, name, param);
42                 }
43
44                 public IFieldRef GetFieldRef (ITypeRef ret_type, string name)
45                 {
46                         return new ExternFieldRef (this, ret_type, name);
47                 }
48
49                 public IClassRef AsClassRef (CodeGen code_gen)
50                 {
51                         return this;
52                 }
53         }
54
55 }
56