Interface IReportService
Collects data to be included in build reports.
public interface IReportService
Remarks
This service acts as a central repository for all reportable information generated during a build. Data is collected and can be retrieved for rendering by an IOutcomeReportWriter. Implementations are safe to call from multiple threads.
Methods
AddReportData(IReportData, string?)
Adds a report data item, optionally associating it with a specific target.
void AddReportData(IReportData reportData, string? targetName = null)
Parameters
reportDataIReportDataThe report data to add.
targetNamestringThe name of the target to associate the data with, or
nullto store it without a target.
GetReportData()
Retrieves all report data items collected during the build.
IReadOnlyList<IReportData> GetReportData()
Returns
- IReadOnlyList<IReportData>
A snapshot of all IReportData items, grouped by target in the order each target first reported.
GetReportData(string?)
Retrieves the report data items associated with a specific target.
IReadOnlyList<IReportData> GetReportData(string? targetName)
Parameters
targetNamestringThe name of the target, or
nullfor data stored without a target.
Returns
- IReadOnlyList<IReportData>
A snapshot of the IReportData items for the target, in the order they were added.