-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Added full functions mentioned on https://www.odata.org/documentation/odata-version-2-0/uri-conventions/ * Added features to allow function overloading * Included documentation of functions and operations supported to readme Co-authored-by: Alex Davies <[email protected]>
- Loading branch information
1 parent
18342e6
commit 229e016
Showing
9 changed files
with
448 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
src/StringToExpression/Exceptions/FunctionOverloadNotFoundException.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
using StringToExpression.Util; | ||
using System; | ||
|
||
namespace StringToExpression.Exceptions | ||
{ | ||
/// <summary> | ||
/// Exception when a cannot find correct overlaod for function | ||
/// </summary> | ||
public class FunctionOverlaodNotFoundException : ParseException | ||
{ | ||
/// <summary> | ||
/// String segment that contains the bracket that contains the incorrect number of operands. | ||
/// </summary> | ||
public readonly StringSegment FunctionStringSegment; | ||
|
||
/// <summary> | ||
/// Actual type of operands. | ||
/// </summary> | ||
public readonly Type[] ActualArgumentTypes; | ||
|
||
/// <summary> | ||
/// Initializes a new instance of the <see cref="FunctionOverlaodNotFoundException"/> class. | ||
/// </summary> | ||
/// <param name="bracketStringSegment">The location of the function</param> | ||
public FunctionOverlaodNotFoundException(StringSegment functionStringSegment) | ||
: base(functionStringSegment, $"Function '{functionStringSegment.Value}' is not defiend wtih those input types") | ||
{ | ||
FunctionStringSegment = functionStringSegment; | ||
|
||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.