Class InterpolatedStringParser
- Namespace
- Utils.Expressions
- Assembly
- Utils.dll
Parses an interpolated string into its constituent parts, which can be either literals or formatted expressions.
public class InterpolatedStringParser : IEnumerable<IInterpolatedStringPart>, IEnumerable
- Inheritance
-
InterpolatedStringParser
- Implements
- Inherited Members
- Extension Methods
Constructors
InterpolatedStringParser(string)
Initializes a new instance of InterpolatedStringParser by parsing the provided interpolated string.
public InterpolatedStringParser(string interpolatedString)
Parameters
interpolatedStringstringThe interpolated string to parse.
Exceptions
- FormatException
Thrown when the string contains unmatched or incorrect braces.
Methods
GetEnumerator()
Returns an enumerator over the parsed string parts.
public IEnumerator<IInterpolatedStringPart> GetEnumerator()