ParseRequest Class
Represents a request for a parsing operation.
public class ParseRequest : IParseRequest
- Inheritance:
- object object
- Implements:
- IParseRequest
Constructors
ParseRequest(string, ITextBufferReader, ISyntaxLanguage, IParseTarget?)
Initializes an instance of the class.
public ParseRequest(string sourceKey, ITextBufferReader textBufferReader, ISyntaxLanguage language, IParseTarget? parseTarget)
| Parameter | Type | Description |
|---|---|---|
| sourceKey | string | A text key, typically a filename, that uniquely identifies the text to parse. |
| textBufferReader | ITextBufferReader | The ITextBufferReader that contains the text to parse. |
| language | ISyntaxLanguage | The ISyntaxLanguage for which this parse request was created. |
| parseTarget | IParseTarget | An IParseTarget indicating the object that will receive the results of the parse. |
ParseRequest(string, ITextBufferReader, IParser, IParseTarget?)
Initializes an instance of the class.
public ParseRequest(string sourceKey, ITextBufferReader textBufferReader, IParser parser, IParseTarget? parseTarget)
| Parameter | Type | Description |
|---|---|---|
| sourceKey | string | A text key, typically a filename, that uniquely identifies the text to parse. |
| textBufferReader | ITextBufferReader | The ITextBufferReader that contains the text to parse. |
| parser | IParser | The IParser that will perform the parsing operation. |
| parseTarget | IParseTarget | An IParseTarget indicating the object that will receive the results of the parse. |
Properties
CreatedDateTime
The DateTime at which the parse request was created.
Language
The ISyntaxLanguage for which this parse request was created.
ParseHashKey
A hash key that uniquely identifies the parse request for a source/target combination.
Parser
The IParser that will perform the parsing operation.
Priority
An integer value describing the priority of the request, where a higher number has a higher priority.
public int Priority { get; set; }
Property Value
- int:
The default value is
ParseRequest.MediumPriority.
RepeatedRequestPause
The number of milliseconds to pause if there are repeated attempts for this same request.
Snapshot
The ITextSnapshot, if available, for which the parse request was created.
SourceKey
A text key, typically a filename, that uniquely identifies the text to parse.
State
The current state of the request.
public ParseRequestState State { get; set; }
Property Value
Remarks
This property should only be set by a IParseRequestDispatcher.
Tag
The object that contains user-defined data about the object.
Target
The IParseTarget that will be notified once the parsing operation is complete.
TextBufferReader
The ITextBufferReader used to read the text that should be parsed.
Methods
GetParseHashKey(ICodeDocument)
Returns the ParseHashKey to use for the specified ICodeDocument.
public static string GetParseHashKey(ICodeDocument document)
| Parameter | Type | Description |
|---|---|---|
| document | ICodeDocument | The ICodeDocument to examine. |
Returns
Fields
HighPriority
Specifies a high priority.
public const int HighPriority = 300
LowPriority
Specifies a low priority.
public const int LowPriority = 100
MediumPriority
Specifies a medium priority.
public const int MediumPriority = 200
Inherited Members
- object.GetType()
- object.MemberwiseClone()
- object.ToString()
- object.Equals(object)
- object.Equals(object, object)
- object.ReferenceEquals(object, object)
- object.GetHashCode()