2 // generic.cs: Support classes for generics to reduce differences from GMCS
5 // Raja R Harinath <rharinath@novell.com>
7 // (C) 2006 Novell, Inc.
10 using System.Reflection;
11 using System.Reflection.Emit;
12 using System.Collections;
16 public abstract class GenericConstraints
18 public abstract string TypeParameter {
22 public bool IsReferenceType {
23 get { throw new NotSupportedException (); }
27 public abstract class Constraints : GenericConstraints
29 public abstract Location Location {
33 public abstract void VerifyClsCompliance ();
36 public class TypeParameter : MemberCore, IMemberContainer
38 public TypeParameter (DeclSpace parent, DeclSpace decl, string name,
39 Constraints constraints, Attributes attrs, Location loc)
40 : base (parent, new MemberName (name, loc), attrs)
42 throw new NotImplementedException ();
45 public static string GetSignatureForError (TypeParameter[] tp)
47 throw new NotImplementedException ();
54 public override bool Define ()
59 public override void ApplyAttributeBuilder (Attribute a,
60 CustomAttributeBuilder cb)
62 throw new NotImplementedException ();
65 public override AttributeTargets AttributeTargets {
66 get { throw new NotImplementedException (); }
69 public override string[] ValidAttributeTargets {
71 return new string [] { "type parameter" };
75 public Constraints Constraints {
81 public override string DocCommentHeader {
82 get { throw new NotImplementedException (); }
85 public bool Resolve (DeclSpace ds)
87 throw new NotImplementedException ();
90 public bool DefineType (IResolveContext ec)
92 throw new NotImplementedException ();
95 public bool DefineType (IResolveContext ec, MethodBuilder builder,
96 MethodInfo implementing, bool is_override)
98 throw new NotImplementedException ();
101 public bool CheckDependencies ()
103 throw new NotImplementedException ();
106 public bool UpdateConstraints (IResolveContext ec, Constraints new_constraints)
108 throw new NotImplementedException ();
115 Type IMemberContainer.Type {
116 get { throw new NotImplementedException (); }
119 string IMemberContainer.Name {
120 get { throw new NotImplementedException (); }
123 MemberCache IMemberContainer.BaseCache {
124 get { throw new NotImplementedException (); }
127 bool IMemberContainer.IsInterface {
128 get { throw new NotImplementedException (); }
131 MemberList IMemberContainer.GetMembers (MemberTypes mt, BindingFlags bf)
133 throw new NotImplementedException ();
136 MemberCache IMemberContainer.MemberCache {
137 get { throw new NotImplementedException (); }
140 public bool IsSubclassOf (Type t)
142 throw new NotImplementedException ();
145 public MemberList FindMembers (MemberTypes mt, BindingFlags bf,
146 MemberFilter filter, object criteria)
148 throw new NotImplementedException ();
152 public class TypeParameterExpr : TypeExpr
154 public override string Name {
155 get { throw new NotImplementedException (); }
158 public override string FullName {
159 get { throw new NotImplementedException (); }
162 public TypeParameterExpr (TypeParameter type_parameter, Location loc)
164 throw new NotImplementedException ();
167 protected override TypeExpr DoResolveAsTypeStep (IResolveContext ec)
173 public class TypeParameterName : SimpleName
175 Attributes attributes;
177 public TypeParameterName (string name, Attributes attrs, Location loc)
183 public Attributes OptAttributes {
190 public class ConstructedType : TypeExpr
192 public ConstructedType (FullNamedExpression fname, TypeArguments args, Location l)
194 throw new NotImplementedException ();
197 public ConstructedType (Type t, TypeParameter[] type_params, Location l)
199 throw new NotImplementedException ();
202 public ConstructedType (Type t, TypeArguments args, Location l)
204 throw new NotImplementedException ();
207 public override string Name {
208 get { throw new NotImplementedException (); }
211 public override string FullName {
212 get { throw new NotImplementedException (); }
215 protected override TypeExpr DoResolveAsTypeStep (IResolveContext ec)
217 throw new NotImplementedException ();
220 public bool CheckConstraints (IResolveContext ec)
222 throw new NotImplementedException ();
226 public abstract class GenericMethod : DeclSpace
228 public GenericMethod (NamespaceEntry ns, DeclSpace parent, MemberName name,
229 Expression return_type, Parameters parameters)
230 : base (ns, parent, name, null)
232 throw new NotImplementedException ();
235 public bool DefineType (EmitContext ec, MethodBuilder mb,
236 MethodInfo implementing, bool is_override)
238 throw new NotImplementedException ();
241 public void EmitAttributes ()
243 throw new NotImplementedException ();
247 public new void VerifyClsCompliance ()
249 throw new NotImplementedException ();
253 public class TypeArguments
255 public TypeArguments (Location loc)
257 throw new NotImplementedException ();
260 public void Add (Expression type)
262 throw new NotImplementedException ();
265 public void Add (TypeArguments new_args)
267 throw new NotImplementedException ();
270 public bool Resolve (IResolveContext ec)
272 throw new NotImplementedException ();
275 public Type[] Arguments {
276 get { throw new NotImplementedException (); }
280 get { throw new NotImplementedException (); }
283 public bool IsUnbound {
284 get { throw new NotImplementedException (); }
287 public TypeParameterName[] GetDeclarations ()
289 throw new NotImplementedException ();