Parser.ParseInput Method

Definition

Overloads

ParseInput(String, Token[], ParseError[])

Parse input that does not come from a file.

ParseInput(String, String, Token[], ParseError[])

Parse input that does not come from a file.

ParseInput(String, Token[], ParseError[])

Parse input that does not come from a file.

public:
 static System::Management::Automation::Language::ScriptBlockAst ^ ParseInput(System::String ^ input, [Runtime::InteropServices::Out] cli::array <System::Management::Automation::Language::Token ^> ^ % tokens, [Runtime::InteropServices::Out] cli::array <System::Management::Automation::Language::ParseError ^> ^ % errors);
public static System.Management.Automation.Language.ScriptBlockAst ParseInput (string input, out System.Management.Automation.Language.Token[] tokens, out System.Management.Automation.Language.ParseError[] errors);
static member ParseInput : string * Token[] * ParseError[] -> System.Management.Automation.Language.ScriptBlockAst
Public Shared Function ParseInput (input As String, ByRef tokens As Token(), ByRef errors As ParseError()) As ScriptBlockAst

Parameters

input
String

The input to parse.

tokens
Token[]

Returns the tokens from parsing the script.

errors
ParseError[]

Returns errors, if any, discovered while parsing the script.

Returns

The ScriptBlockAst that represents the input script file.

Applies to

ParseInput(String, String, Token[], ParseError[])

Parse input that does not come from a file.

public:
 static System::Management::Automation::Language::ScriptBlockAst ^ ParseInput(System::String ^ input, System::String ^ fileName, [Runtime::InteropServices::Out] cli::array <System::Management::Automation::Language::Token ^> ^ % tokens, [Runtime::InteropServices::Out] cli::array <System::Management::Automation::Language::ParseError ^> ^ % errors);
public static System.Management.Automation.Language.ScriptBlockAst ParseInput (string input, string fileName, out System.Management.Automation.Language.Token[] tokens, out System.Management.Automation.Language.ParseError[] errors);
static member ParseInput : string * string * Token[] * ParseError[] -> System.Management.Automation.Language.ScriptBlockAst
Public Shared Function ParseInput (input As String, fileName As String, ByRef tokens As Token(), ByRef errors As ParseError()) As ScriptBlockAst

Parameters

input
String

The input to parse.

fileName
String

The fileName if present or null.

tokens
Token[]

Returns the tokens from parsing the script.

errors
ParseError[]

Returns errors, if any, discovered while parsing the script.

Returns

The ScriptBlockAst that represents the input script file.

Applies to