-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathSyncExceptions.cs
26 lines (23 loc) · 1.06 KB
/
SyncExceptions.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
using System;
using System.Reflection;
namespace NETCoreSyncServer
{
public class NETCoreSyncServerException : Exception
{
public NETCoreSyncServerException(string message) : base(message)
{
}
}
public class NETCoreSyncServerMissingSyncPropertyAttributeException : Exception
{
public NETCoreSyncServerMissingSyncPropertyAttributeException(SyncPropertyAttribute.PropertyIndicatorEnum propertyIndicator, Type type) : base($"Missing Property with {nameof(SyncPropertyAttribute)} ({nameof(SyncPropertyAttribute.PropertyIndicator)}: {propertyIndicator.ToString()}) defined for Type: {type.FullName}")
{
}
}
public class NETCoreSyncServerMismatchPropertyTypeException : Exception
{
public NETCoreSyncServerMismatchPropertyTypeException(PropertyInfo propertyInfo, Type expectedType, Type type) : base($"Mismatch Property Type for Property: {propertyInfo.Name} ({propertyInfo.PropertyType.Name}) for Type: {type.FullName}. Expected Property Type: {expectedType.ToString()}")
{
}
}
}