protected virtual void DescribePropertyInfo(FieldBuilder builder, Type type, PropertyInfo propertyInfo) { builder.Hint("net-kind", "property"); builder.Hint("net-assembly", propertyInfo.PropertyType.Assembly.FullName); builder.Hint("net-type", propertyInfo.PropertyType.FullName); var displayName = ClassDescriptionHelper.GetDisplayName(propertyInfo); if (displayName != null) { builder.Hint("display-name", displayName); } }
protected virtual void DescribeFieldInfo(FieldBuilder builder, Type type, FieldInfo fieldInfo) { builder.Hint("net-kind", "field"); builder.Hint("net-assembly", fieldInfo.FieldType.Assembly.FullName); builder.Hint("net-type", fieldInfo.FieldType.FullName); var displayName = ClassDescriptionHelper.GetDisplayName(fieldInfo); if (displayName != null) { builder.Hint("display-name", displayName); } }
protected virtual void DescribePropertyInfo(FieldBuilder builder, Type type, PropertyInfo propertyInfo) { builder.Hint("net-kind", "property"); builder.Hint("net-type", propertyInfo.PropertyType.AssemblyQualifiedName); var displayName = ClassDescriptionHelper.GetDisplayName(propertyInfo); if (displayName != null) { builder.Hint("display-name", displayName); } if (ClassDescriptionHelper.IsRequired(propertyInfo)) { builder.Type.IsNullable = false; } }