Added copyright notices.
[mono.git] / mcs / class / corlib / System.Reflection.Emit / MethodBuilder.cs
1
2 //
3 // System.Reflection.Emit/MethodBuilder.cs
4 //
5 // Author:
6 //   Paolo Molaro (lupus@ximian.com)
7 //
8 // (C) 2001 Ximian, Inc.  http://www.ximian.com
9 //
10
11 using System;
12 using System.Reflection;
13 using System.Reflection.Emit;
14 using System.Globalization;
15 using System.Runtime.CompilerServices;
16
17 namespace System.Reflection.Emit {
18         public sealed class MethodBuilder : MethodInfo {
19                 private IntPtr _impl;
20                 private Type rtype;
21                 private Type[] paremeters;
22                 private MethodAttributes attrs;
23                 private string name;
24                 private RuntimeMethodHandle mhandle;
25                 
26                 public override Type ReturnType {get {return rtype;}}
27                 public override Type ReflectedType {get {return null;}}
28                 public override Type DeclaringType {get {return null;}}
29                 public override string Name {get {return name;}}
30                 public override RuntimeMethodHandle MethodHandle {get {return mhandle;}}
31                 public override MethodAttributes Attributes {get {return attrs;}}
32                 public override ICustomAttributeProvider ReturnTypeCustomAttributes {
33                         get {return null;}
34                 }
35
36                 
37                 public override MethodInfo GetBaseDefinition() {
38                         return null;
39                 }
40                 public override MethodImplAttributes GetMethodImplementationFlags() {
41                         return (MethodImplAttributes)0;
42                 }
43                 public override ParameterInfo[] GetParameters() {
44                         return null;
45                 }
46                 
47                 /*
48                  * FIXME: this method signature needs to be expanded to handle also
49                  * a ILGenerator.
50                  */
51                 [MethodImplAttribute(MethodImplOptions.InternalCall)]
52                 private static extern void set_method_body (MethodBuilder method, byte[] il, int count);
53                 
54                 public void CreateMethodBody( byte[] il, int count) {
55                         set_method_body (this, il, count);
56                 }
57                 public override Object Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) {
58                         return null;
59                 }
60                 public override bool IsDefined (Type attribute_type, bool inherit) {
61                         return false;
62                 }
63                 public override object[] GetCustomAttributes( bool inherit) {
64                         return null;
65                 }
66                 public override object[] GetCustomAttributes( Type attributeType, bool inherit) {
67                         return null;
68                 }
69
70
71
72
73         }
74 }
75