Class Parser
A parser that parses Spice expressions.
Inheritance
System.Object
Parser
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: SpiceSharpParser.Parsers.Expression.Implementation
Assembly: SpiceSharpParser.dll
Syntax
public class Parser
Remarks
This is a recursive descent parser.
Methods
| Improve this Doc View SourceParse(Lexer)
Parses the expression using a lexer.
Declaration
public Node Parse(Lexer lexer)
Parameters
Type | Name | Description |
---|---|---|
Lexer | lexer | The lexer. |
Returns
Type | Description |
---|---|
SpiceSharpBehavioral.Parsers.Nodes.Node | The value of the lexed expression. |
Exceptions
Type | Condition |
---|---|
System.Exception | Invalid expression. |
Parse(String)
Parses the expression.
Declaration
public Node Parse(string text)
Parameters
Type | Name | Description |
---|---|---|
System.String | text | The text to parse. |
Returns
Type | Description |
---|---|
SpiceSharpBehavioral.Parsers.Nodes.Node | The value of the lexed expression. |
Exceptions
Type | Condition |
---|---|
System.Exception | Invalid expression. |