Ejemplo n.º 1
0
        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;
        }
Ejemplo n.º 2
0
        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);
        }
Ejemplo n.º 3
0
 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;
 }
Ejemplo n.º 4
0
 internal FluentVoidMethodBuilder(_IFluentTypeBuilder typeBuilder, string name, bool isStatic, int creatorThreadId, int delegateIndex, bool respectVisibility) :
     base(typeBuilder, name, typeof(void), isStatic, creatorThreadId, delegateIndex, respectVisibility)
 {
 }