30%
This commit is contained in:
parent
b66ac1589e
commit
2c1605cadc
21
DumpTruck/DumpTruck/StorageOverException.cs
Normal file
21
DumpTruck/DumpTruck/StorageOverException.cs
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Runtime.Serialization;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace DumpTruck.Exceptions
|
||||||
|
{
|
||||||
|
[Serializable]
|
||||||
|
internal class StorageOverException : ApplicationException
|
||||||
|
{
|
||||||
|
public StorageOverException(int count) : base($"В наборе превышено допустимое количество: { count}") { }
|
||||||
|
public StorageOverException() : base() { }
|
||||||
|
public StorageOverException(string message) : base(message) { }
|
||||||
|
public StorageOverException(string message, Exception exception)
|
||||||
|
: base(message, exception) { }
|
||||||
|
protected StorageOverException(SerializationInfo info,
|
||||||
|
StreamingContext contex) : base(info, contex) { }
|
||||||
|
}
|
||||||
|
}
|
19
DumpTruck/DumpTruck/TruckNotFoundException.cs
Normal file
19
DumpTruck/DumpTruck/TruckNotFoundException.cs
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Runtime.Serialization;
|
||||||
|
using System.Text;
|
||||||
|
using System.Threading.Tasks;
|
||||||
|
|
||||||
|
namespace DumpTruck.Exceptions
|
||||||
|
{
|
||||||
|
[Serializable]
|
||||||
|
internal class TruckNotFoundException : ApplicationException
|
||||||
|
{
|
||||||
|
public TruckNotFoundException(int i) : base($"Не найден объект по позиции { i}") { }
|
||||||
|
public TruckNotFoundException() : base() { }
|
||||||
|
public TruckNotFoundException(string message) : base(message) { }
|
||||||
|
public TruckNotFoundException(string message, Exception exception) : base(message, exception) { }
|
||||||
|
protected TruckNotFoundException(SerializationInfo info, StreamingContext contex) : base(info, contex) { }
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user