Skip to content
Prev Previous commit
Next Next commit
Address comments
  • Loading branch information
live1206 committed Feb 20, 2025
commit dd7c4d63d6c42817a3f0ba9b8fe1abaa9c06ae3e
Original file line number Diff line number Diff line change
Expand Up @@ -93,17 +93,10 @@ public string RelativeFilePath

private string? _relativeFilePath;

/// <summary>
/// Gets and sets the name of the type.
/// </summary>
public string Name
{
get => _name ??= CustomCodeView?.Name ?? BuildName();
set
{
_name = value;
}
}
public string Name =>
_type is not null
? _type.Name
: _name ??= CustomCodeView?.Name ?? BuildName();

private string? _name;

Expand Down Expand Up @@ -352,7 +345,9 @@ public void Update(
IEnumerable<FieldProvider>? fields = null,
IEnumerable<TypeProvider>? serializations = null,
IEnumerable<TypeProvider>? nestedTypes = null,
XmlDocProvider? xmlDocs = null)
XmlDocProvider? xmlDocs = null,
TypeSignatureModifiers? modifiers = null,
string? relativeFilePath = null)
{
if (methods != null)
{
Expand Down Expand Up @@ -382,6 +377,14 @@ public void Update(
{
XmlDocs = xmlDocs;
}
if (modifiers != null)
{
_declarationModifiers = modifiers;
}
if (relativeFilePath != null)
{
_relativeFilePath = relativeFilePath;
}
}
public IReadOnlyList<EnumTypeMember> EnumValues => _enumValues ??= BuildEnumValues();

Expand Down
Loading