-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathMathResult.cs
More file actions
30 lines (26 loc) · 1.01 KB
/
MathResult.cs
File metadata and controls
30 lines (26 loc) · 1.01 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
namespace ScriptedEvents.Structures
{
using System;
/// <summary>
/// Represents the result of a call to <see cref="API.Features.ConditionHelperV2.TryMath(string, out MathResult)"/>.
/// </summary>
public class MathResult
{
/// <summary>
/// Gets or sets a value indicating whether or not the math was executed successfully.
/// </summary>
public bool Success { get; set; }
/// <summary>
/// Gets or sets the result of the math equation.
/// </summary>
public float Result { get; set; }
/// <summary>
/// Gets or sets the exception, if <see cref="Success"/> is <see langword="false"/>.
/// </summary>
public Exception Exception { get; set; }
/// <summary>
/// Gets the <see cref="Exception.Message"/> of the exception, if <see cref="Exception"/> is not <see langword="null"/>.
/// </summary>
public string Message => Exception.Message;
}
}