-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathScriptExecutionException.cs
More file actions
41 lines (39 loc) · 1019 Bytes
/
ScriptExecutionException.cs
File metadata and controls
41 lines (39 loc) · 1019 Bytes
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
using System;
namespace AlbLib.Scripting
{
/// <summary>
/// Exception which stores additional information when normal exception raises.
/// </summary>
[Serializable]
public class ScriptExecutionException : Exception
{
/// <summary>
/// Line number.
/// </summary>
public int LinePosition{get;private set;}
/// <summary>
/// Actual line.
/// </summary>
public string CurrentLine{get;private set;}
/// <summary>
/// Initializes new instance of this exception.
/// </summary>
/// <param name="line">
/// Line number where did exception occur.
/// </param>
/// <param name="errorline">
/// Actual line.
/// </param>
/// <param name="message">
/// Message which was thrown.
/// </param>
/// <param name="innerException">
/// Inner exception if any.
/// </param>
public ScriptExecutionException(int line, string errorline, string message, Exception innerException) : base(message, innerException)
{
LinePosition = line;
CurrentLine = errorline;
}
}
}