/// <summary>
/// Wipes all user data cached locally, including identity id, session
/// credentials, dataset metadata, and all records. Any data that hasn't been
/// synced will be lost. This method is usually used when customer logs out.
/// <param name="wipeCredentialsAndID">Wipe Credentials and IdentityID. Defaults as true</param>
/// </summary>
public void WipeData(bool wipeCredentialsAndID = true)
{
Local.WipeData();
if (wipeCredentialsAndID)
{
cognitoCredentials.Clear();
_logger.InfoFormat("All datasets and records have been wiped");
}
else
{
_logger.InfoFormat("All data has been wiped");
}
}