forked from florentbr/SeleniumBasic
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathArgumentErrors.cs
More file actions
53 lines (42 loc) · 1.34 KB
/
ArgumentErrors.cs
File metadata and controls
53 lines (42 loc) · 1.34 KB
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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
using System;
namespace Selenium.Errors {
/// <summary>
///
/// </summary>
public class ArgumentError : SeleniumError {
const int CODE = 200;
internal ArgumentError(string message, params object[] args)
: this(CODE, message, args) { }
internal ArgumentError(int code, string message, params object[] args)
: base(CODE + code, message, args) { }
}
/// <summary>
///
/// </summary>
public class ArgumentTypeError : ArgumentError {
internal ArgumentTypeError(Type extected, Type got)
: base(1, "Invalid type. Was expecting a {0}, got a {1} intead", extected.Name, got.Name) { }
}
/// <summary>
///
/// </summary>
public class ArgumentRangeError : ArgumentError {
internal ArgumentRangeError(string arg)
: base(2, "Argument out of range: {0}", arg) {
}
}
/// <summary>
///
/// </summary>
public class InvalideCommandError : ArgumentError {
internal InvalideCommandError(string message)
: base(3, message) { }
}
/// <summary>
///
/// </summary>
public class InvalideModifierKeyError : ArgumentError {
internal InvalideModifierKeyError()
: base(56, "Invalid modifier key.\nOnly shift, ctrl or alt are allowed.") { }
}
}