CssParseOptions Class
Configures how CssSyntaxTree parses text.
public sealed class CssParseOptions : IEquatable<CssParseOptions>- Implements
Constructors
| Name | Description |
|---|---|
| CssParseOptions() |
CssParseOptions()
CssParseOptions.cspublic CssParseOptions()No documentation is available.
Properties
| Name | Description |
|---|---|
| Default | Gets the options used when none are given: a style sheet, with the default depth. |
| MaxDepth | Gets how deeply blocks, functions, selectors, and conditions may nest before the parser reports CSS0016 and keeps the rest as skipped text. Guards against a stack overflow on deeply nested input. |
| SourceKind | Gets what the text holds. |
Default
CssParseOptions.csGets the options used when none are given: a style sheet, with the default depth.
public static CssParseOptions Default { get; }Property value
MaxDepth
CssParseOptions.csGets how deeply blocks, functions, selectors, and conditions may nest before the parser reports CSS0016 and keeps the rest as skipped text. Guards against a stack overflow on deeply nested input.
public int MaxDepth { get; init; }Property value
Exceptions
ArgumentOutOfRangeException- The value is less than one.
Remarks
Raising it is safe: nesting that would not fit on the stack of the thread doing the parsing is reported as CSS0016 as well, whatever the limit says.
SourceKind
CssParseOptions.csGets what the text holds.
public CssSourceKind SourceKind { get; init; }Property value
Exceptions
ArgumentOutOfRangeException- The value is not one of the kinds of
CssSourceKind.
Methods
| Name | Description |
|---|---|
| Equals(CssParseOptions?) | |
| Equals(object?) | |
| GetHashCode() | |
| ToString() |
Equals overloads
Equals(CssParseOptions?)
public bool Equals(CssParseOptions? other)No documentation is available.
Equals(object?)
GetHashCode()
ToString()
Operators
| Name | Description |
|---|---|
| operator ==(CssParseOptions?, CssParseOptions?) | |
| operator !=(CssParseOptions?, CssParseOptions?) |
operator ==(CssParseOptions?, CssParseOptions?)
public static bool operator ==(CssParseOptions? left, CssParseOptions? right)No documentation is available.
operator !=(CssParseOptions?, CssParseOptions?)
public static bool operator !=(CssParseOptions? left, CssParseOptions? right)No documentation is available.
Constants
| Name | Description |
|---|---|
| DefaultMaxDepth | The default value of CssParseOptions.MaxDepth. |
DefaultMaxDepth
The default value of CssParseOptions.MaxDepth.
public const int DefaultMaxDepth = 128