Smdn.Reflection.ReverseGenerating version 1.1.0
·
446 commits
to main
since this release
Released package
Release notes
The full release notes are available at gist.
Change log
Change log in this release:
- 2022-07-09 update assembly version
- 2022-07-08 bump Smdn.Fundamental.Reflection up to 3.3.0
- 2022-07-05 suppress warning CS8602
- 2022-07-05 fix generating 'virtual' modifier of properties with non-public accessor
- 2022-07-05 fix argument name
- 2022-07-05 add support for showing
newmodifier on member declarations - 2022-07-05 add GeneratorOptions.AttributeDeclarationOptions.OmitAttributeSuffix
- 2022-07-04 add support for generating generic attributes
- 2022-07-04 reduce allocations
- 2022-07-04 simplify generating member modifiers
- 2022-07-04 add support for generating implementation members of static interface member
- 2022-07-04 bump Smdn.Fundamental.Reflection up to 3.2.0
- 2022-07-03 add support for static interface members and TSelf constraints
- 2022-07-02 mark as
sealed - 2022-07-02 add support for showing
readonlymodifier on struct property declarations - 2022-07-02 add support for showing
newmodifier on type declarations - 2022-07-02 add support for generating array and param array attribute args
- 2022-07-01 add workaround for .NET Framework
- 2022-07-01 reduce duplicate codes
- 2022-07-01 apply ValueFormatOptions.TranslateLanguagePrimitiveType on default value and constant field value
- 2022-07-01 add support for formatting values of System.Type
- 2022-07-01 add GeneratorOptions.ParameterDeclarationOptions for formatting parameter type names
- 2022-07-01 fix formatting nested type full name
- 2022-07-01 add GeneratorOptions.ValueDeclarationOptions.WithNamespace/WithDeclaringTypeName for formatting type name of values
- 2022-06-30 add GeneratorOptions.MethodDeclarationOptions.AccessorBody
- 2022-06-30 add support for generating attribute list of event accessor parameters
- 2022-06-30 reduce duplicate codes
- 2022-06-30 add support for specifying attribute section format of method and delegate (return) parameters
- 2022-06-30 remove unusing codes
- 2022-06-30 add support for specifying attribute section format of property and event accessors
- 2022-06-30 add support for generating event accessor methods
- 2022-06-29 add support for specifying attribute section format of accessor parameters, backing fields and generic parameters
- 2022-06-29 add GeneratorOptions.AttributeDeclarationOptions.WithDeclaringTypeName for formatting nested attribute type names
- 2022-06-29 add support for generating attribute list of generic method parameter
- 2022-06-29 add support for generating attribute list of generic type parameter
- 2022-06-29 reduce specifying 'showVariance' arguments
- 2022-06-29 use record struct instead
- 2022-06-29 add support for generating attribute list of event backing fields
- 2022-06-29 use StringBuilder.Append+String.Join if StringBuilder.AppendJoin is not available
- 2022-06-27 add support for generating attribute list of property accessor methods and backing fields
- 2022-06-26 fix not to generate constant field of primitive types on attribute arguments
- 2022-06-26 add support for cloning GeneratorOptions
- 2022-06-26 commonize process of generating method and delegate declarations
- 2022-06-22 fix formatting result of single-elemented value tuples
- 2022-06-22 add support for formatting delegates with nullability annotation
- 2022-06-22 add GeneratorOptions.TypeDeclarationOptions.NullabilityInfoContext
- 2022-06-22 add GeneratorOptions.MemberDeclarationOptions.NullabilityInfoContext
- 2022-06-22 add overloads of CSharpFormatter.FormatParameter/FormatParameterList() which accepts NullabilityInfoContext
- 2022-06-22 rename parameter of NullabilityInfoContext
- 2022-06-22 make parameter nullable
- 2022-06-22 add overloads of FormatTypeName()
- 2022-06-22 specify attribute provider of target
- 2022-06-22 add support for formatting property type name with nullability annotations
- 2022-06-21 add support for formatting event type name with nullability annotations
- 2022-06-21 add partial support for formatting parameter type name with nullability annotations
- 2022-06-20 simplify formatting by-ref modifiers of parameter
- 2022-06-20 refactor
- 2022-06-20 fix not to format declaring type name of generic parameters
- 2022-06-19 remove comment
- 2022-06-19 split implementations into individual files
- 2022-06-19 add support for formatting field type name with nullability annotations
- 2022-06-10 refactor
- 2022-06-10 add MethodBodyOption.ThrowNull
- 2022-06-09 add support for 'async' method modifier
- 2022-06-09 reformat
- 2022-06-09 enable nullability annotations
- 2022-06-09 update descrption
- 2022-06-09 add TODO comment
- 2022-06-09 reformat
- 2022-06-09 enable nullability warnings
- 2022-06-08 reformat
- 2022-06-08 bump Smdn.Fundamental.Reflection up to 3.1.0
- 2022-06-08 make lambdas static
- 2022-06-08 use String.Concat(ReadOnlySpan, ReadOnlySpan) if available
- 2022-06-08 add target framework net6.0
- 2022-03-08 update package tags
- 2022-03-08 update assembly descriptions
- 2022-03-08 split property groups
API changes
API changes in this release:
diff --git a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net45.apilist.cs b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net45.apilist.cs
index c02a07a..e778cb9 100644
--- a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net45.apilist.cs
+++ b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net45.apilist.cs
@@ -1,90 +1,136 @@
-// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.0.5)
+// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.1.0)
// Name: Smdn.Reflection.ReverseGenerating
-// AssemblyVersion: 1.0.5.0
-// InformationalVersion: 1.0.5+dd9591cbed8623f61349f46c833f14f1578db406
+// AssemblyVersion: 1.1.0.0
+// InformationalVersion: 1.1.0+074a83ab64ee9e829c2f3835cf0c03af8af0f59d
// TargetFramework: .NETFramework,Version=v4.5
// Configuration: Release
using System;
using System.Collections.Generic;
using System.Reflection;
+using System.Runtime.CompilerServices;
using Smdn.Reflection;
using Smdn.Reflection.ReverseGenerating;
namespace Smdn.Reflection.ReverseGenerating {
public delegate bool AttributeTypeFilter(Type type, ICustomAttributeProvider attributeProvider);
+ public enum AttributeSectionFormat : int {
+ Discrete = 1,
+ List = 0,
+ }
+
public enum MethodBodyOption : int {
EmptyImplementation = 1,
None = 0,
ThrowNotImplementedException = 2,
+ ThrowNull = 3,
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class CSharpFormatter {
public static string EscapeString(string s, bool escapeSingleQuote = false, bool escapeDoubleQuote = false) {}
public static string FormatAccessibility(Accessibility accessibility) {}
public static string FormatParameter(ParameterInfo p, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(MethodBase m, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(ParameterInfo[] parameterList, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatSpecialNameMethod(MethodBase methodOrConstructor, out MethodSpecialName nameType) {}
- public static string FormatTypeName(this Type t, ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
- public static string FormatValueDeclaration(object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
+ public static string FormatTypeName(this EventInfo ev, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this FieldInfo f, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this ParameterInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this PropertyInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this Type t, [Nullable(2)] ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatValueDeclaration([Nullable(2)] object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
public static bool IsLanguagePrimitiveType(Type t, out string primitiveTypeName) {}
public static IEnumerable<string> ToNamespaceList(Type t) {}
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class Generator {
- public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateMemberDeclaration(MemberInfo member, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateTypeDeclaration(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ [return: Nullable(2)] public static string GenerateMemberDeclaration(MemberInfo member, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateTypeDeclaration(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
}
- public class GeneratorOptions {
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
+ public class GeneratorOptions : ICloneable {
+ [Nullable(byte.MinValue)]
+ [NullableContext(2)]
public class AttributeDeclarationOptions {
public AttributeDeclarationOptions() {}
+ public AttributeSectionFormat AccessorFormat { get; set; }
+ public AttributeSectionFormat AccessorParameterFormat { get; set; }
+ public AttributeSectionFormat BackingFieldFormat { get; set; }
+ public AttributeSectionFormat DelegateParameterFormat { get; set; }
+ public AttributeSectionFormat GenericParameterFormat { get; set; }
+ public AttributeSectionFormat MethodParameterFormat { get; set; }
+ public bool OmitAttributeSuffix { get; set; }
public AttributeTypeFilter TypeFilter { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
public bool WithNamedArguments { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class MemberDeclarationOptions {
public MemberDeclarationOptions() {}
+ public MethodBodyOption AccessorBody { get; set; }
public MethodBodyOption MethodBody { get; set; }
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
+ public class ParameterDeclarationOptions {
+ public ParameterDeclarationOptions() {}
+
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [NullableContext(byte.MinValue)]
public class TypeDeclarationOptions {
public TypeDeclarationOptions() {}
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class ValueDeclarationOptions {
public ValueDeclarationOptions() {}
public bool UseDefaultLiteral { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
}
public GeneratorOptions() {}
- public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; }
+ public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; init; }
public bool IgnorePrivateOrAssembly { get; set; }
+ [Nullable(2)]
public string Indent { get; set; }
- public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; }
+ public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; init; }
+ public GeneratorOptions.ParameterDeclarationOptions ParameterDeclaration { get; init; }
public bool TranslateLanguagePrimitiveTypeDeclaration { get; set; }
- public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; }
- public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; }
+ public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; init; }
+ public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; init; }
+
+ public virtual GeneratorOptions Clone() {}
+ object ICloneable.Clone() {}
}
}
diff --git a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net47.apilist.cs b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net47.apilist.cs
index 6e7284d..e225fc4 100644
--- a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net47.apilist.cs
+++ b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net47.apilist.cs
@@ -1,90 +1,136 @@
-// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.0.5)
+// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.1.0)
// Name: Smdn.Reflection.ReverseGenerating
-// AssemblyVersion: 1.0.5.0
-// InformationalVersion: 1.0.5+dd9591cbed8623f61349f46c833f14f1578db406
+// AssemblyVersion: 1.1.0.0
+// InformationalVersion: 1.1.0+074a83ab64ee9e829c2f3835cf0c03af8af0f59d
// TargetFramework: .NETFramework,Version=v4.7
// Configuration: Release
using System;
using System.Collections.Generic;
using System.Reflection;
+using System.Runtime.CompilerServices;
using Smdn.Reflection;
using Smdn.Reflection.ReverseGenerating;
namespace Smdn.Reflection.ReverseGenerating {
public delegate bool AttributeTypeFilter(Type type, ICustomAttributeProvider attributeProvider);
+ public enum AttributeSectionFormat : int {
+ Discrete = 1,
+ List = 0,
+ }
+
public enum MethodBodyOption : int {
EmptyImplementation = 1,
None = 0,
ThrowNotImplementedException = 2,
+ ThrowNull = 3,
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class CSharpFormatter {
public static string EscapeString(string s, bool escapeSingleQuote = false, bool escapeDoubleQuote = false) {}
public static string FormatAccessibility(Accessibility accessibility) {}
public static string FormatParameter(ParameterInfo p, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(MethodBase m, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(ParameterInfo[] parameterList, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatSpecialNameMethod(MethodBase methodOrConstructor, out MethodSpecialName nameType) {}
- public static string FormatTypeName(this Type t, ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
- public static string FormatValueDeclaration(object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
+ public static string FormatTypeName(this EventInfo ev, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this FieldInfo f, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this ParameterInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this PropertyInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this Type t, [Nullable(2)] ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatValueDeclaration([Nullable(2)] object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
public static bool IsLanguagePrimitiveType(Type t, out string primitiveTypeName) {}
public static IEnumerable<string> ToNamespaceList(Type t) {}
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class Generator {
- public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateMemberDeclaration(MemberInfo member, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateTypeDeclaration(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ [return: Nullable(2)] public static string GenerateMemberDeclaration(MemberInfo member, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateTypeDeclaration(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
}
- public class GeneratorOptions {
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
+ public class GeneratorOptions : ICloneable {
+ [Nullable(byte.MinValue)]
+ [NullableContext(2)]
public class AttributeDeclarationOptions {
public AttributeDeclarationOptions() {}
+ public AttributeSectionFormat AccessorFormat { get; set; }
+ public AttributeSectionFormat AccessorParameterFormat { get; set; }
+ public AttributeSectionFormat BackingFieldFormat { get; set; }
+ public AttributeSectionFormat DelegateParameterFormat { get; set; }
+ public AttributeSectionFormat GenericParameterFormat { get; set; }
+ public AttributeSectionFormat MethodParameterFormat { get; set; }
+ public bool OmitAttributeSuffix { get; set; }
public AttributeTypeFilter TypeFilter { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
public bool WithNamedArguments { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class MemberDeclarationOptions {
public MemberDeclarationOptions() {}
+ public MethodBodyOption AccessorBody { get; set; }
public MethodBodyOption MethodBody { get; set; }
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
+ public class ParameterDeclarationOptions {
+ public ParameterDeclarationOptions() {}
+
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [NullableContext(byte.MinValue)]
public class TypeDeclarationOptions {
public TypeDeclarationOptions() {}
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class ValueDeclarationOptions {
public ValueDeclarationOptions() {}
public bool UseDefaultLiteral { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
}
public GeneratorOptions() {}
- public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; }
+ public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; init; }
public bool IgnorePrivateOrAssembly { get; set; }
+ [Nullable(2)]
public string Indent { get; set; }
- public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; }
+ public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; init; }
+ public GeneratorOptions.ParameterDeclarationOptions ParameterDeclaration { get; init; }
public bool TranslateLanguagePrimitiveTypeDeclaration { get; set; }
- public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; }
- public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; }
+ public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; init; }
+ public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; init; }
+
+ public virtual GeneratorOptions Clone() {}
+ object ICloneable.Clone() {}
}
}
diff --git a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net5.0.apilist.cs b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net5.0.apilist.cs
index bfaef74..1443d84 100644
--- a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net5.0.apilist.cs
+++ b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net5.0.apilist.cs
@@ -1,90 +1,137 @@
-// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.0.5)
+// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.1.0)
// Name: Smdn.Reflection.ReverseGenerating
-// AssemblyVersion: 1.0.5.0
-// InformationalVersion: 1.0.5+dd9591cbed8623f61349f46c833f14f1578db406
+// AssemblyVersion: 1.1.0.0
+// InformationalVersion: 1.1.0+074a83ab64ee9e829c2f3835cf0c03af8af0f59d
// TargetFramework: .NETCoreApp,Version=v5.0
// Configuration: Release
using System;
using System.Collections.Generic;
+using System.Diagnostics.CodeAnalysis;
using System.Reflection;
+using System.Runtime.CompilerServices;
using Smdn.Reflection;
using Smdn.Reflection.ReverseGenerating;
namespace Smdn.Reflection.ReverseGenerating {
public delegate bool AttributeTypeFilter(Type type, ICustomAttributeProvider attributeProvider);
+ public enum AttributeSectionFormat : int {
+ Discrete = 1,
+ List = 0,
+ }
+
public enum MethodBodyOption : int {
EmptyImplementation = 1,
None = 0,
ThrowNotImplementedException = 2,
+ ThrowNull = 3,
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class CSharpFormatter {
public static string EscapeString(string s, bool escapeSingleQuote = false, bool escapeDoubleQuote = false) {}
public static string FormatAccessibility(Accessibility accessibility) {}
public static string FormatParameter(ParameterInfo p, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(MethodBase m, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(ParameterInfo[] parameterList, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatSpecialNameMethod(MethodBase methodOrConstructor, out MethodSpecialName nameType) {}
- public static string FormatTypeName(this Type t, ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
- public static string FormatValueDeclaration(object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
- public static bool IsLanguagePrimitiveType(Type t, out string primitiveTypeName) {}
+ public static string FormatTypeName(this EventInfo ev, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this FieldInfo f, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this ParameterInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this PropertyInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this Type t, [Nullable(2)] ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatValueDeclaration([Nullable(2)] object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
+ public static bool IsLanguagePrimitiveType(Type t, [MaybeNullWhen(false)] out string primitiveTypeName) {}
public static IEnumerable<string> ToNamespaceList(Type t) {}
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class Generator {
- public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateMemberDeclaration(MemberInfo member, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateTypeDeclaration(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ [return: Nullable(2)] public static string GenerateMemberDeclaration(MemberInfo member, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateTypeDeclaration(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
}
- public class GeneratorOptions {
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
+ public class GeneratorOptions : ICloneable {
+ [Nullable(byte.MinValue)]
+ [NullableContext(2)]
public class AttributeDeclarationOptions {
public AttributeDeclarationOptions() {}
+ public AttributeSectionFormat AccessorFormat { get; set; }
+ public AttributeSectionFormat AccessorParameterFormat { get; set; }
+ public AttributeSectionFormat BackingFieldFormat { get; set; }
+ public AttributeSectionFormat DelegateParameterFormat { get; set; }
+ public AttributeSectionFormat GenericParameterFormat { get; set; }
+ public AttributeSectionFormat MethodParameterFormat { get; set; }
+ public bool OmitAttributeSuffix { get; set; }
public AttributeTypeFilter TypeFilter { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
public bool WithNamedArguments { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class MemberDeclarationOptions {
public MemberDeclarationOptions() {}
+ public MethodBodyOption AccessorBody { get; set; }
public MethodBodyOption MethodBody { get; set; }
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
+ public class ParameterDeclarationOptions {
+ public ParameterDeclarationOptions() {}
+
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [NullableContext(byte.MinValue)]
public class TypeDeclarationOptions {
public TypeDeclarationOptions() {}
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class ValueDeclarationOptions {
public ValueDeclarationOptions() {}
public bool UseDefaultLiteral { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
}
public GeneratorOptions() {}
- public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; }
+ public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; init; }
public bool IgnorePrivateOrAssembly { get; set; }
+ [Nullable(2)]
public string Indent { get; set; }
- public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; }
+ public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; init; }
+ public GeneratorOptions.ParameterDeclarationOptions ParameterDeclaration { get; init; }
public bool TranslateLanguagePrimitiveTypeDeclaration { get; set; }
- public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; }
- public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; }
+ public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; init; }
+ public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; init; }
+
+ public virtual GeneratorOptions Clone() {}
+ object ICloneable.Clone() {}
}
}
diff --git a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net6.0.apilist.cs b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net6.0.apilist.cs
new file mode 100644
index 0000000..7162cd9
--- /dev/null
+++ b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-net6.0.apilist.cs
@@ -0,0 +1,148 @@
+// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.1.0)
+// Name: Smdn.Reflection.ReverseGenerating
+// AssemblyVersion: 1.1.0.0
+// InformationalVersion: 1.1.0+074a83ab64ee9e829c2f3835cf0c03af8af0f59d
+// TargetFramework: .NETCoreApp,Version=v6.0
+// Configuration: Release
+
+using System;
+using System.Collections.Generic;
+using System.Diagnostics.CodeAnalysis;
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using Smdn.Reflection;
+using Smdn.Reflection.ReverseGenerating;
+
+namespace Smdn.Reflection.ReverseGenerating {
+ public delegate bool AttributeTypeFilter(Type type, ICustomAttributeProvider attributeProvider);
+
+ public enum AttributeSectionFormat : int {
+ Discrete = 1,
+ List = 0,
+ }
+
+ public enum MethodBodyOption : int {
+ EmptyImplementation = 1,
+ None = 0,
+ ThrowNotImplementedException = 2,
+ ThrowNull = 3,
+ }
+
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
+ public static class CSharpFormatter {
+ public static string EscapeString(string s, bool escapeSingleQuote = false, bool escapeDoubleQuote = false) {}
+ public static string FormatAccessibility(Accessibility accessibility) {}
+ public static string FormatParameter(ParameterInfo p, [Nullable(2)] NullabilityInfoContext nullabilityInfoContext, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
+ public static string FormatParameter(ParameterInfo p, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
+ public static string FormatParameterList(MethodBase m, [Nullable(2)] NullabilityInfoContext nullabilityInfoContext, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
+ public static string FormatParameterList(MethodBase m, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
+ public static string FormatParameterList(ParameterInfo[] parameterList, [Nullable(2)] NullabilityInfoContext nullabilityInfoContext, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
+ public static string FormatParameterList(ParameterInfo[] parameterList, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
+ public static string FormatSpecialNameMethod(MethodBase methodOrConstructor, out MethodSpecialName nameType) {}
+ public static string FormatTypeName(this EventInfo ev, [Nullable(2)] NullabilityInfoContext nullabilityInfoContext, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this EventInfo ev, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this FieldInfo f, [Nullable(2)] NullabilityInfoContext nullabilityInfoContext, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this FieldInfo f, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this ParameterInfo p, [Nullable(2)] NullabilityInfoContext nullabilityInfoContext, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this ParameterInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this PropertyInfo p, [Nullable(2)] NullabilityInfoContext nullabilityInfoContext, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this PropertyInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this Type t, [Nullable(2)] ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatValueDeclaration([Nullable(2)] object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
+ public static bool IsLanguagePrimitiveType(Type t, [MaybeNullWhen(false)] out string primitiveTypeName) {}
+ public static IEnumerable<string> ToNamespaceList(Type t) {}
+ }
+
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
+ public static class Generator {
+ public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ [return: Nullable(2)] public static string GenerateMemberDeclaration(MemberInfo member, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateTypeDeclaration(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ }
+
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
+ public class GeneratorOptions : ICloneable {
+ [Nullable(byte.MinValue)]
+ [NullableContext(2)]
+ public class AttributeDeclarationOptions {
+ public AttributeDeclarationOptions() {}
+
+ public AttributeSectionFormat AccessorFormat { get; set; }
+ public AttributeSectionFormat AccessorParameterFormat { get; set; }
+ public AttributeSectionFormat BackingFieldFormat { get; set; }
+ public AttributeSectionFormat DelegateParameterFormat { get; set; }
+ public AttributeSectionFormat GenericParameterFormat { get; set; }
+ public AttributeSectionFormat MethodParameterFormat { get; set; }
+ public bool OmitAttributeSuffix { get; set; }
+ public AttributeTypeFilter TypeFilter { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamedArguments { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [Nullable(byte.MinValue)]
+ [NullableContext(2)]
+ public class MemberDeclarationOptions {
+ public MemberDeclarationOptions() {}
+
+ public MethodBodyOption AccessorBody { get; set; }
+ public MethodBodyOption MethodBody { get; set; }
+ public NullabilityInfoContext NullabilityInfoContext { get; set; }
+ public bool OmitEndOfStatement { get; set; }
+ public bool WithAccessibility { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [NullableContext(byte.MinValue)]
+ public class ParameterDeclarationOptions {
+ public ParameterDeclarationOptions() {}
+
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [Nullable(byte.MinValue)]
+ [NullableContext(2)]
+ public class TypeDeclarationOptions {
+ public TypeDeclarationOptions() {}
+
+ public NullabilityInfoContext NullabilityInfoContext { get; set; }
+ public bool OmitEndOfStatement { get; set; }
+ public bool WithAccessibility { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [NullableContext(byte.MinValue)]
+ public class ValueDeclarationOptions {
+ public ValueDeclarationOptions() {}
+
+ public bool UseDefaultLiteral { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ public GeneratorOptions() {}
+
+ public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; init; }
+ public bool IgnorePrivateOrAssembly { get; set; }
+ [Nullable(2)]
+ public string Indent { get; set; }
+ public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; init; }
+ public GeneratorOptions.ParameterDeclarationOptions ParameterDeclaration { get; init; }
+ public bool TranslateLanguagePrimitiveTypeDeclaration { get; set; }
+ public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; init; }
+ public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; init; }
+
+ public virtual GeneratorOptions Clone() {}
+ object ICloneable.Clone() {}
+ }
+}
+
diff --git a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-netstandard2.0.apilist.cs b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-netstandard2.0.apilist.cs
index a13e562..0135654 100644
--- a/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-netstandard2.0.apilist.cs
+++ b/doc/api-list/Smdn.Reflection.ReverseGenerating/Smdn.Reflection.ReverseGenerating-netstandard2.0.apilist.cs
@@ -1,90 +1,136 @@
-// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.0.5)
+// Smdn.Reflection.ReverseGenerating.dll (Smdn.Reflection.ReverseGenerating-1.1.0)
// Name: Smdn.Reflection.ReverseGenerating
-// AssemblyVersion: 1.0.5.0
-// InformationalVersion: 1.0.5+dd9591cbed8623f61349f46c833f14f1578db406
+// AssemblyVersion: 1.1.0.0
+// InformationalVersion: 1.1.0+074a83ab64ee9e829c2f3835cf0c03af8af0f59d
// TargetFramework: .NETStandard,Version=v2.0
// Configuration: Release
using System;
using System.Collections.Generic;
using System.Reflection;
+using System.Runtime.CompilerServices;
using Smdn.Reflection;
using Smdn.Reflection.ReverseGenerating;
namespace Smdn.Reflection.ReverseGenerating {
public delegate bool AttributeTypeFilter(Type type, ICustomAttributeProvider attributeProvider);
+ public enum AttributeSectionFormat : int {
+ Discrete = 1,
+ List = 0,
+ }
+
public enum MethodBodyOption : int {
EmptyImplementation = 1,
None = 0,
ThrowNotImplementedException = 2,
+ ThrowNull = 3,
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class CSharpFormatter {
public static string EscapeString(string s, bool escapeSingleQuote = false, bool escapeDoubleQuote = false) {}
public static string FormatAccessibility(Accessibility accessibility) {}
public static string FormatParameter(ParameterInfo p, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(MethodBase m, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatParameterList(ParameterInfo[] parameterList, bool typeWithNamespace = true, bool useDefaultLiteral = false) {}
public static string FormatSpecialNameMethod(MethodBase methodOrConstructor, out MethodSpecialName nameType) {}
- public static string FormatTypeName(this Type t, ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
- public static string FormatValueDeclaration(object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
+ public static string FormatTypeName(this EventInfo ev, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this FieldInfo f, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this ParameterInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this PropertyInfo p, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatTypeName(this Type t, [Nullable(2)] ICustomAttributeProvider attributeProvider = null, bool typeWithNamespace = true, bool withDeclaringTypeName = true, bool translateLanguagePrimitiveType = true) {}
+ public static string FormatValueDeclaration([Nullable(2)] object val, Type typeOfValue, bool typeWithNamespace = true, bool findConstantField = false, bool useDefaultLiteral = false) {}
public static bool IsLanguagePrimitiveType(Type t, out string primitiveTypeName) {}
public static IEnumerable<string> ToNamespaceList(Type t) {}
}
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
public static class Generator {
- public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateMemberDeclaration(MemberInfo member, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static string GenerateTypeDeclaration(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
- public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateAttributeList(ICustomAttributeProvider attributeProvider, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateGenericArgumentConstraintDeclaration(Type genericArgument, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ [return: Nullable(2)] public static string GenerateMemberDeclaration(MemberInfo member, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static string GenerateTypeDeclaration(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
+ public static IEnumerable<string> GenerateTypeDeclarationWithExplicitBaseTypeAndInterfaces(Type t, [Nullable] ISet<string> referencingNamespaces, GeneratorOptions options) {}
}
- public class GeneratorOptions {
+ [Nullable(byte.MinValue)]
+ [NullableContext(1)]
+ public class GeneratorOptions : ICloneable {
+ [Nullable(byte.MinValue)]
+ [NullableContext(2)]
public class AttributeDeclarationOptions {
public AttributeDeclarationOptions() {}
+ public AttributeSectionFormat AccessorFormat { get; set; }
+ public AttributeSectionFormat AccessorParameterFormat { get; set; }
+ public AttributeSectionFormat BackingFieldFormat { get; set; }
+ public AttributeSectionFormat DelegateParameterFormat { get; set; }
+ public AttributeSectionFormat GenericParameterFormat { get; set; }
+ public AttributeSectionFormat MethodParameterFormat { get; set; }
+ public bool OmitAttributeSuffix { get; set; }
public AttributeTypeFilter TypeFilter { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
public bool WithNamedArguments { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class MemberDeclarationOptions {
public MemberDeclarationOptions() {}
+ public MethodBodyOption AccessorBody { get; set; }
public MethodBodyOption MethodBody { get; set; }
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
+ public class ParameterDeclarationOptions {
+ public ParameterDeclarationOptions() {}
+
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
+ }
+
+ [NullableContext(byte.MinValue)]
public class TypeDeclarationOptions {
public TypeDeclarationOptions() {}
public bool OmitEndOfStatement { get; set; }
public bool WithAccessibility { get; set; }
public bool WithDeclaringTypeName { get; set; }
public bool WithNamespace { get; set; }
}
+ [NullableContext(byte.MinValue)]
public class ValueDeclarationOptions {
public ValueDeclarationOptions() {}
public bool UseDefaultLiteral { get; set; }
+ public bool WithDeclaringTypeName { get; set; }
+ public bool WithNamespace { get; set; }
}
public GeneratorOptions() {}
- public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; }
+ public GeneratorOptions.AttributeDeclarationOptions AttributeDeclaration { get; init; }
public bool IgnorePrivateOrAssembly { get; set; }
+ [Nullable(2)]
public string Indent { get; set; }
- public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; }
+ public GeneratorOptions.MemberDeclarationOptions MemberDeclaration { get; init; }
+ public GeneratorOptions.ParameterDeclarationOptions ParameterDeclaration { get; init; }
public bool TranslateLanguagePrimitiveTypeDeclaration { get; set; }
- public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; }
- public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; }
+ public GeneratorOptions.TypeDeclarationOptions TypeDeclaration { get; init; }
+ public GeneratorOptions.ValueDeclarationOptions ValueDeclaration { get; init; }
+
+ public virtual GeneratorOptions Clone() {}
+ object ICloneable.Clone() {}
}
}
Full Changelog: releases/Smdn.Reflection.ReverseGenerating-1.0.5...releases/Smdn.Reflection.ReverseGenerating-1.1.0