internal FluentPropertyBuilder(_IFluentTypeBuilder typeBuilder, string name, Type type, bool isStatic, bool respectVisibility) { GetMethod = typeBuilder.AddMethod(type, "get_" + name, isStatic, respectVisibility); SetMethod = typeBuilder.AddMethod(typeof(void), "set_" + name, isStatic, respectVisibility); Name = name; PropertyType = type; }
internal FluentEventBuilder(_IFluentTypeBuilder typeBuilder, string name, Type type, bool isStatic, bool respectVisibility) { TypeBuilder = typeBuilder; Name = name; Type = type; IsStatic = isStatic; AddMethod = typeBuilder.AddMethod(typeof(void), "add_" + name, isStatic, respectVisibility); RemoveMethod = typeBuilder.AddMethod(typeof(void), "remove_" + name, isStatic, respectVisibility); }
internal FluentMethodBuilder(_IFluentTypeBuilder typeBuilder, string name, Type returnType, bool isStatic, int creatorThreadId, int delegateIndex, bool respectVisibility) { _creatorThreadId = creatorThreadId; _visitor = new _Visitor(this); _returnTarget = Expression.Label(returnType); TypeBuilder = typeBuilder; _body = new FluentBodyBuilder(this); Name = name; ReturnType = returnType; IsStatic = isStatic; _delegateIndex = delegateIndex; _respectVisibility = respectVisibility; }
internal FluentVoidMethodBuilder(_IFluentTypeBuilder typeBuilder, string name, bool isStatic, int creatorThreadId, int delegateIndex, bool respectVisibility) : base(typeBuilder, name, typeof(void), isStatic, creatorThreadId, delegateIndex, respectVisibility) { }