Class CountryDataLoadResult
Wrapper around CountryDataCollection to provide consistent result API Matches the expected interface for integration with CountrySystem
public class CountryDataLoadResult
- Inheritance
-
objectCountryDataLoadResult
Properties
Countries
The loaded country data collection
public CountryDataCollection Countries { get; }
Property Value
ErrorMessage
Error message if loading failed
public string ErrorMessage { get; }
Property Value
- string
IsSuccess
Whether the loading operation was successful
public bool IsSuccess { get; }
Property Value
- bool
Statistics
Additional loading statistics and metadata
public LoadingStatistics Statistics { get; }
Property Value
Methods
Dispose()
Clean up resources
public void Dispose()
Failure(string)
Create a failed result
public static CountryDataLoadResult Failure(string errorMessage)
Parameters
errorMessagestring
Returns
GetSummary()
Get summary information about the loaded data
public string GetSummary()
Returns
- string
Success(CountryDataCollection, LoadingStatistics)
Create a successful result
public static CountryDataLoadResult Success(CountryDataCollection countries, LoadingStatistics stats = null)
Parameters
countriesCountryDataCollectionstatsLoadingStatistics
Returns
Validate()
Validate that the result contains valid data
public List<string> Validate()
Returns
- List<string>