chore(sonar): collapse trivial backing-field properties to auto-properties (S2292)
- WithClause.RecursiveQuery and WithClause.ColumnList had get/set bodies that only forwarded to private backing fields. Convert both to auto-properties and remove the now-orphaned _recursiveQuery / _columnList fields. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.7
parent
1124e91141
commit
e1cdcd77a4
@@ -29,8 +29,6 @@ public class WithClause : SqlClause, IWithClause
|
|||||||
{
|
{
|
||||||
private SqlClauses? _sql;
|
private SqlClauses? _sql;
|
||||||
private IQueryBreakdown? _query;
|
private IQueryBreakdown? _query;
|
||||||
private IQueryBreakdown? _recursiveQuery;
|
|
||||||
private List<string>? _columnList;
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the table name for the CTE.
|
/// Gets or sets the table name for the CTE.
|
||||||
@@ -115,11 +113,7 @@ public class WithClause : SqlClause, IWithClause
|
|||||||
/// Example recursive scenario: traversing an organizational hierarchy where employees reference their managers.
|
/// Example recursive scenario: traversing an organizational hierarchy where employees reference their managers.
|
||||||
/// </para>
|
/// </para>
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
public IQueryBreakdown? RecursiveQuery
|
public IQueryBreakdown? RecursiveQuery { get; set; }
|
||||||
{
|
|
||||||
get => _recursiveQuery;
|
|
||||||
set => _recursiveQuery = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Gets or sets the explicit column list for the CTE.
|
/// Gets or sets the explicit column list for the CTE.
|
||||||
@@ -135,11 +129,7 @@ public class WithClause : SqlClause, IWithClause
|
|||||||
/// </list>
|
/// </list>
|
||||||
/// The number of column names must match the number of columns in the SELECT clause.
|
/// The number of column names must match the number of columns in the SELECT clause.
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
public List<string>? ColumnList
|
public List<string>? ColumnList { get; set; }
|
||||||
{
|
|
||||||
get => _columnList;
|
|
||||||
set => _columnList = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Initializes a new instance of the <see cref="WithClause"/> class.
|
/// Initializes a new instance of the <see cref="WithClause"/> class.
|
||||||
|
|||||||
Reference in New Issue
Block a user