Skip to content

[fix-finder] Add XML documentation to DatePickerDialog.UpdateDate(DateTime) #12129

Description

@github-actions

Problem

The hand-written, .NET-friendly overload DatePickerDialog.UpdateDate (DateTime date) in the shipped Mono.Android.dll has no XML documentation. It is a public API developers consume, and lacks a <summary> and <param> describing its behavior (it converts the .NET DateTime to Android's year/month/day form, adjusting for Android's 0-based month).

Location

  • File(s): src/Mono.Android/Android.App/DatePickerDialog.cs
  • Line(s): 33-36

Current Code

public void UpdateDate (DateTime date)
{
	UpdateDate (date.Year, date.Month - 1, date.Day);
}

Suggested Fix

Add /// XML documentation directly above the method:

/// <summary>
/// Sets the current date shown by the dialog using a <see cref="System.DateTime" />.
/// </summary>
/// <remarks>
/// This is a .NET-friendly overload that forwards to
/// <see cref="UpdateDate(int, int, int)" />, converting the 1-based
/// <see cref="System.DateTime.Month" /> to Android's 0-based month value.
/// </remarks>
/// <param name="date">The date to display in the dialog.</param>
public void UpdateDate (DateTime date)
{
	UpdateDate (date.Year, date.Month - 1, date.Day);
}

Guidelines

  • Follow dotnet/android formatting conventions (tabs, space before ().
  • This is a purely additive, documentation-only change; do not alter any behavior.
  • See the Android reference for DatePickerDialog.updateDate).

Acceptance Criteria

  • UpdateDate (DateTime date) has a <summary> and <param> XML doc comment.
  • No behavior changes.
  • All tests pass
  • No new warnings introduced

Fix-finder metadata

  • Script: 04-missing-xml-docs
  • Score: 30/30 (actionability: 10, safety: 10, scope: 10)

Generated by Nightly Fix Finder · 55.9 AIC · ⌖ 17.2 AIC · ⊞ 9.4K ·

  • expires on Jul 23, 2026, 2:25 AM UTC

Metadata

Metadata

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions