internal static MemberDataBase FieldDataFromReflection(FieldDefinition fieldDefinition, DeclaringTypeData declaringType)
        {
            var accessibility = fieldDefinition.GetAccessibility();

            if (accessibility == null)
            {
                return(null);
            }

            return(new FieldData(fieldDefinition, accessibility.Value, declaringType));
        }
Beispiel #2
0
 internal OperatorData(MethodDefinition methodDefinition, DeclaringTypeData declaringType)
     : base(methodDefinition, MemberAccessibility.Public, declaringType)
 {
 }
 private ConstantData(FieldDefinition fieldDefinition, MemberAccessibility accessibility, DeclaringTypeData declaringType)
     : base(fieldDefinition, accessibility, fieldDefinition.FieldType, fieldDefinition.IsDynamicType(), MemberFlags.Static, declaringType)
 {
     this.Value = Utilities.PreprocessConstantValue(fieldDefinition.FieldType, fieldDefinition.Constant);
 }
 internal MethodDataBase(MethodDefinition methodDefinition, MemberAccessibility accessibility, DeclaringTypeData declaringType)
     : base(methodDefinition, accessibility, methodDefinition.ReturnType, methodDefinition.IsReturnTypeDynamic(), Utilities.GetMemberFlags(methodDefinition), declaringType)
 {
     this.Parameters = new ParameterCollection(methodDefinition.Parameters, this);
 }