Initial commit.
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
public class AccountSetupCanceledException : System.Exception
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,19 @@
|
||||
using System;
|
||||
using Wino.Core.Domain.Entities;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
/// <summary>
|
||||
/// Thrown when IAuthenticator requires user interaction to fix authentication issues.
|
||||
/// It can be expired and can't restorable token, or some stuff that requires re-authentication.
|
||||
/// </summary>
|
||||
public class AuthenticationAttentionException : Exception
|
||||
{
|
||||
public AuthenticationAttentionException(MailAccount account)
|
||||
{
|
||||
Account = account;
|
||||
}
|
||||
|
||||
public MailAccount Account { get; }
|
||||
}
|
||||
}
|
||||
18
Wino.Core.Domain/Exceptions/AuthenticationException.cs
Normal file
18
Wino.Core.Domain/Exceptions/AuthenticationException.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
/// <summary>
|
||||
/// All exceptions related to authentication.
|
||||
/// </summary>
|
||||
public class AuthenticationException : Exception
|
||||
{
|
||||
public AuthenticationException(string message) : base(message)
|
||||
{
|
||||
}
|
||||
|
||||
public AuthenticationException(string message, Exception innerException) : base(message, innerException)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
/// <summary>
|
||||
/// An exception thrown when the background task execution policies are denied for some reason.
|
||||
/// </summary>
|
||||
public class BackgroundTaskExecutionRequestDeniedException : Exception { }
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
/// <summary>
|
||||
/// An exception thrown when the background task registration is failed.
|
||||
/// </summary>
|
||||
public class BackgroundTaskRegistrationFailedException : Exception { }
|
||||
}
|
||||
11
Wino.Core.Domain/Exceptions/ComposerMimeNotFoundException.cs
Normal file
11
Wino.Core.Domain/Exceptions/ComposerMimeNotFoundException.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
/// <summary>
|
||||
/// Thrown when composer cant find the mime to load.
|
||||
/// </summary>
|
||||
public class ComposerMimeNotFoundException : Exception
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
public class CustomThemeCreationFailedException : Exception
|
||||
{
|
||||
public CustomThemeCreationFailedException(string message) : base(message)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
public class GoogleAuthenticationException : System.Exception
|
||||
{
|
||||
public GoogleAuthenticationException(string message) : base(message) { }
|
||||
}
|
||||
}
|
||||
11
Wino.Core.Domain/Exceptions/ImapClientPoolException.cs
Normal file
11
Wino.Core.Domain/Exceptions/ImapClientPoolException.cs
Normal file
@@ -0,0 +1,11 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
public class ImapClientPoolException : Exception
|
||||
{
|
||||
public ImapClientPoolException(Exception innerException) : base(Translator.Exception_ImapClientPoolFailed, innerException)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,6 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
public class InvalidMoveTargetException : Exception { }
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
public class SynchronizerEntityNotFoundException : Exception
|
||||
{
|
||||
public SynchronizerEntityNotFoundException(string message) : base(message)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
15
Wino.Core.Domain/Exceptions/SynchronizerException.cs
Normal file
15
Wino.Core.Domain/Exceptions/SynchronizerException.cs
Normal file
@@ -0,0 +1,15 @@
|
||||
using System;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
public class SynchronizerException : Exception
|
||||
{
|
||||
public SynchronizerException(string message) : base(message)
|
||||
{
|
||||
}
|
||||
|
||||
public SynchronizerException(string message, Exception innerException) : base(message, innerException)
|
||||
{
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
/// <summary>
|
||||
/// When IMAP account's system folder configuration setup is not done yet.
|
||||
/// </summary>
|
||||
public class SystemFolderConfigurationMissingException : System.Exception { }
|
||||
}
|
||||
@@ -0,0 +1,20 @@
|
||||
using System;
|
||||
using Wino.Core.Domain.Enums;
|
||||
|
||||
namespace Wino.Core.Domain.Exceptions
|
||||
{
|
||||
/// <summary>
|
||||
/// Emitted when special folder is needed for an operation but it couldn't be found.
|
||||
/// </summary>
|
||||
public class UnavailableSpecialFolderException : Exception
|
||||
{
|
||||
public UnavailableSpecialFolderException(SpecialFolderType specialFolderType, Guid accountId)
|
||||
{
|
||||
SpecialFolderType = specialFolderType;
|
||||
AccountId = accountId;
|
||||
}
|
||||
|
||||
public SpecialFolderType SpecialFolderType { get; }
|
||||
public Guid AccountId { get; set; }
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user