2022-06-18 18:04:24 +00:00
namespace PKHeX.Core ;
/// <summary>
/// Simple interface representing a <see cref="PKM"/> viewer.
/// </summary>
public interface IPKMView
2018-05-13 19:49:26 +00:00
{
/// <summary>
2022-06-18 18:04:24 +00:00
/// Fetches the currently loaded <see cref="PKM"/> data from the viewer.
2018-05-13 19:49:26 +00:00
/// </summary>
2022-06-18 18:04:24 +00:00
PKM Data { get ; }
2018-05-13 19:49:26 +00:00
2022-06-18 18:04:24 +00:00
/// <summary>
/// Indicates if the Viewer supports using Unicode characters or not.
/// </summary>
bool Unicode { get ; }
2018-05-13 19:49:26 +00:00
2022-06-18 18:04:24 +00:00
/// <summary>
/// Indicates if the Viewer is providing extra flexibility or not.
/// </summary>
bool HaX { get ; }
2018-05-13 19:49:26 +00:00
2022-06-18 18:04:24 +00:00
/// <summary>
/// Indicates if the Viewer's controls are changing their values and should avoid triggering other updates.
/// </summary>
bool ChangingFields { get ; set ; }
2018-05-13 19:49:26 +00:00
2022-06-18 18:04:24 +00:00
/// <summary>
/// Fetches the currently loaded <see cref="PKM"/> data from the viewer by finishing any pending changes or auto-modifications.
/// </summary>
/// <param name="click">Cause the viewer to do extra actions to force validation of its children.</param>
/// <returns>Prepared <see cref="PKM"/> data from the viewer.</returns>
PKM PreparePKM ( bool click = true ) ;
2018-05-13 19:49:26 +00:00
2022-06-18 18:04:24 +00:00
/// <summary>
/// Indicates if the currently loaded <see cref="PKM"/> data is ready for exporting.
/// </summary>
bool EditsComplete { get ; }
2019-09-03 02:30:58 +00:00
2022-06-18 18:04:24 +00:00
/// <summary>
/// Loads a given <see cref="PKM"/> data to the viewer.
/// </summary>
/// <param name="pk">Pokémon data to load.</param>
/// <param name="focus">Cause the viewer to give focus to itself.</param>
/// <param name="skipConversionCheck">Cause the viewer to skip converting the data. Faster if it is known that the format is the same as the previous format.</param>
void PopulateFields ( PKM pk , bool focus = true , bool skipConversionCheck = false ) ;
2018-05-13 19:49:26 +00:00
}