TokenKind Enum
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The specific kind of token.
public enum class TokenKind
public enum TokenKind
type TokenKind =
Public Enum TokenKind
- Inheritance
-
TokenKind
Fields
Name | Value | Description |
---|---|---|
Unknown | 0 | An unknown token, signifies an error condition. |
Variable | 1 | A variable token, always begins with '$' and followed by the variable name, possibly enclose in curly braces. Tokens with this kind are always instances of VariableToken. |
SplattedVariable | 2 | A splatted variable token, always begins with '@' and followed by the variable name. Tokens with this kind are always instances of VariableToken. |
Parameter | 3 | A parameter to a command, always begins with a dash ('-'), followed by the parameter name. Tokens with this kind are always instances of ParameterToken. |
Number | 4 | Any numerical literal token. Tokens with this kind are always instances of NumberToken. |
Label | 5 | A label token - always begins with ':', followed by the label name. Tokens with this kind are always instances of LabelToken. |
Identifier | 6 | A simple identifier, always begins with a letter or '', and is followed by letters, numbers, or ''. |
Generic | 7 | A token that is only valid as a command name, command argument, function name, or configuration name. It may contain characters not allowed in identifiers. Tokens with this kind are always instances of StringLiteralToken or StringExpandableToken if the token contains variable references or subexpressions. |
NewLine | 8 | A newline (one of '\n', '\r', or '\r\n'). |
LineContinuation | 9 | A line continuation (backtick followed by newline). |
Comment | 10 | A single line comment, or a delimited comment. |
EndOfInput | 11 | Marks the end of the input script or file. |
StringLiteral | 12 | A single quoted string literal. Tokens with this kind are always instances of StringLiteralToken. |
StringExpandable | 13 | A double quoted string literal. Tokens with this kind are always instances of StringExpandableToken even if there are no nested tokens to expand. |
HereStringLiteral | 14 | A single quoted here string literal. Tokens with this kind are always instances of StringLiteralToken. |
HereStringExpandable | 15 | A double quoted here string literal. Tokens with this kind are always instances of StringExpandableToken. even if there are no nested tokens to expand. |
LParen | 16 | The opening parenthesis token '('. |
RParen | 17 | The closing parenthesis token ')'. |
LCurly | 18 | The opening curly brace token '{'. |
RCurly | 19 | The closing curly brace token '}'. |
LBracket | 20 | The opening square brace token '['. |
RBracket | 21 | The closing square brace token ']'. |
AtParen | 22 | The opening token of an array expression '@('. |
AtCurly | 23 | The opening token of a hash expression '@{'. |
DollarParen | 24 | The opening token of a sub-expression '$('. |
Semi | 25 | The statement terminator ';'. |
AndAnd | 26 | The (unimplemented) operator '&&'. |
OrOr | 27 | The (unimplemented) operator '||'. |
Ampersand | 28 | The invocation operator '&'. |
Pipe | 29 | The pipe operator '|'. |
Comma | 30 | The unary or binary array operator ','. |
MinusMinus | 31 | The pre-decrement operator '--'. |
PlusPlus | 32 | The pre-increment operator '++'. |
DotDot | 33 | The range operator '..'. |
ColonColon | 34 | The static member access operator '::'. |
Dot | 35 | The instance member access or dot source invocation operator '.'. |
Exclaim | 36 | The logical not operator '!'. |
Multiply | 37 | The multiplication operator '*'. |
Divide | 38 | The division operator '/'. |
Rem | 39 | The modulo division (remainder) operator '%'. |
Plus | 40 | The addition operator '+'. |
Minus | 41 | The subtraction operator '-'. |
Equals | 42 | The assignment operator '='. |
PlusEquals | 43 | The addition assignment operator '+='. |
MinusEquals | 44 | The subtraction assignment operator '-='. |
MultiplyEquals | 45 | The multiplication assignment operator '*='. |
DivideEquals | 46 | The division assignment operator '/='. |
RemainderEquals | 47 | The modulo division (remainder) assignment operator '%='. |
Redirection | 48 | A redirection operator such as '2>&1' or '>>'. |
RedirectInStd | 49 | The (unimplemented) stdin redirection operator '<'. |
Format | 50 | The string format operator '-f'. |
Not | 51 | The logical not operator '-not'. |
Bnot | 52 | The bitwise not operator '-bnot'. |
And | 53 | The logical and operator '-and'. |
Or | 54 | The logical or operator '-or'. |
Xor | 55 | The logical exclusive or operator '-xor'. |
Band | 56 | The bitwise and operator '-band'. |
Bor | 57 | The bitwise or operator '-bor'. |
Bxor | 58 | The bitwise exclusive or operator '-xor'. |
Join | 59 | The join operator '-join'. |
Ieq | 60 | The case insensitive equal operator '-ieq' or '-eq'. |
Ine | 61 | The case insensitive not equal operator '-ine' or '-ne'. |
Ige | 62 | The case insensitive greater than or equal operator '-ige' or '-ge'. |
Igt | 63 | The case insensitive greater than operator '-igt' or '-gt'. |
Ilt | 64 | The case insensitive less than operator '-ilt' or '-lt'. |
Ile | 65 | The case insensitive less than or equal operator '-ile' or '-le'. |
Ilike | 66 | The case insensitive like operator '-ilike' or '-like'. |
Inotlike | 67 | The case insensitive not like operator '-inotlike' or '-notlike'. |
Imatch | 68 | The case insensitive match operator '-imatch' or '-match'. |
Inotmatch | 69 | The case insensitive not match operator '-inotmatch' or '-notmatch'. |
Ireplace | 70 | The case insensitive replace operator '-ireplace' or '-replace'. |
Icontains | 71 | The case insensitive contains operator '-icontains' or '-contains'. |
Inotcontains | 72 | The case insensitive notcontains operator '-inotcontains' or '-notcontains'. |
Iin | 73 | The case insensitive in operator '-iin' or '-in'. |
Inotin | 74 | The case insensitive notin operator '-inotin' or '-notin' |
Isplit | 75 | The case insensitive split operator '-isplit' or '-split'. |
Ceq | 76 | The case sensitive equal operator '-ceq'. |
Cne | 77 | The case sensitive not equal operator '-cne'. |
Cge | 78 | The case sensitive greater than or equal operator '-cge'. |
Cgt | 79 | The case sensitive greater than operator '-cgt'. |
Clt | 80 | The case sensitive less than operator '-clt'. |
Cle | 81 | The case sensitive less than or equal operator '-cle'. |
Clike | 82 | The case sensitive like operator '-clike'. |
Cnotlike | 83 | The case sensitive notlike operator '-cnotlike'. |
Cmatch | 84 | The case sensitive match operator '-cmatch'. |
Cnotmatch | 85 | The case sensitive not match operator '-cnotmatch'. |
Creplace | 86 | The case sensitive replace operator '-creplace'. |
Ccontains | 87 | The case sensitive contains operator '-ccontains'. |
Cnotcontains | 88 | The case sensitive not contains operator '-cnotcontains'. |
Cin | 89 | The case sensitive in operator '-cin'. |
Cnotin | 90 | The case sensitive not in operator '-notin'. |
Csplit | 91 | The case sensitive split operator '-csplit'. |
Is | 92 | The type test operator '-is'. |
IsNot | 93 | The type test operator '-isnot'. |
As | 94 | The type conversion operator '-as'. |
PostfixPlusPlus | 95 | The post-increment operator '++'. |
PostfixMinusMinus | 96 | The post-decrement operator '--'. |
Shl | 97 | The shift left operator. |
Shr | 98 | The shift right operator. |
Colon | 99 | The PS class base class and implemented interfaces operator ':'. Also used in base class ctor calls. |
QuestionMark | 100 | The ternary operator '?'. |
QuestionQuestionEquals | 101 | The null conditional assignment operator '??='. |
QuestionQuestion | 102 | The null coalesce operator '??'. |
QuestionDot | 103 | The null conditional member access operator '?.'. |
QuestionLBracket | 104 | The null conditional index access operator '?[]'. |
Begin | 119 | The 'begin' keyword. |
Break | 120 | The 'break' keyword. |
Catch | 121 | The 'catch' keyword. |
Class | 122 | The 'class' keyword. |
Continue | 123 | The 'continue' keyword. |
Data | 124 | The 'data' keyword. |
Define | 125 | The (unimplemented) 'define' keyword. |
Do | 126 | The 'do' keyword. |
Dynamicparam | 127 | The 'dynamicparam' keyword. |
Else | 128 | The 'else' keyword. |
ElseIf | 129 | The 'elseif' keyword. |
End | 130 | The 'end' keyword. |
Exit | 131 | The 'exit' keyword. |
Filter | 132 | The 'filter' keyword. |
Finally | 133 | The 'finally' keyword. |
For | 134 | The 'for' keyword. |
Foreach | 135 | The 'foreach' keyword. |
From | 136 | The (unimplemented) 'from' keyword. |
Function | 137 | The 'function' keyword. |
If | 138 | The 'if' keyword. |
In | 139 | The 'in' keyword. |
Param | 140 | The 'param' keyword. |
Process | 141 | The 'process' keyword. |
Return | 142 | The 'return' keyword. |
Switch | 143 | The 'switch' keyword. |
Throw | 144 | The 'throw' keyword. |
Trap | 145 | The 'trap' keyword. |
Try | 146 | The 'try' keyword. |
Until | 147 | The 'until' keyword. |
Using | 148 | The (unimplemented) 'using' keyword. |
Var | 149 | The (unimplemented) 'var' keyword. |
While | 150 | The 'while' keyword. |
Workflow | 151 | The 'workflow' keyword. |
Parallel | 152 | The 'parallel' keyword. |
Sequence | 153 | The 'sequence' keyword. |
InlineScript | 154 | The 'InlineScript' keyword |
Configuration | 155 | The "configuration" keyword |
DynamicKeyword | 156 | The token kind for dynamic keywords |
Public | 157 | The 'public' keyword |
Private | 158 | The 'private' keyword |
Static | 159 | The 'static' keyword |
Interface | 160 | The 'interface' keyword |
Enum | 161 | The 'enum' keyword |
Namespace | 162 | The 'namespace' keyword |
Module | 163 | The 'module' keyword |
Type | 164 | The 'type' keyword |
Assembly | 165 | The 'assembly' keyword |
Command | 166 | The 'command' keyword |
167 | The 'hidden' keyword |
|
Base | 168 | The 'base' keyword |
Default | 169 | The 'default' keyword |
Clean | 170 | The 'clean' keyword. |