Skip to content

Commit 7e392dd

Browse files
StartAutomatingStartAutomating
authored andcommitted
Invoke-PipeScript: Trimming whitespace
1 parent 3e87166 commit 7e392dd

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

docs/New-PipeScript.md

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ HTTP Accept indicates what content types the web request will accept as a respon
3333
Defines one or more parameters for a ScriptBlock.
3434
Parameters can be defined in a few ways:
3535
* As a ```[Collections.Dictionary]``` of Parameters
36-
* As the ```[string]``` name of an untyped parameter.
36+
* As the ```[string]``` name of an untyped parameter.
3737
* As a ```[ScriptBlock]``` containing only parameters.
3838

3939

@@ -124,9 +124,23 @@ If provided, will add inline help to parameters.
124124
|-------------------|--------|-------|-------------|
125125
|```[IDictionary]```|false |8 |false |
126126
---
127+
#### **WeaklyTyped**
128+
129+
If set, will weakly type parameters generated by reflection.
130+
1. Any parameter type implements IList should be made a [PSObject[]]
131+
2. Any parameter that implements IDictionary should be made an [Collections.IDictionary]
132+
3. Booleans should be made into [switch]es
133+
4. All other parameter types should be [PSObject]
134+
135+
136+
137+
|Type |Requried|Postion|PipelineInput|
138+
|--------------|--------|-------|-------------|
139+
|```[Switch]```|false |named |false |
140+
---
127141
### Syntax
128142
```PowerShell
129-
New-PipeScript [[-Parameter] <Object>] [[-DynamicParameter] <ScriptBlock>] [[-Begin] <ScriptBlock>] [[-Process] <ScriptBlock>] [[-End] <ScriptBlock>] [[-Header] <String>] [-AutoParameter] [[-AutoParameterType] <Type>] [[-ParameterHelp] <IDictionary>] [<CommonParameters>]
143+
New-PipeScript [[-Parameter] <Object>] [[-DynamicParameter] <ScriptBlock>] [[-Begin] <ScriptBlock>] [[-Process] <ScriptBlock>] [[-End] <ScriptBlock>] [[-Header] <String>] [-AutoParameter] [[-AutoParameterType] <Type>] [[-ParameterHelp] <IDictionary>] [-WeaklyTyped] [<CommonParameters>]
130144
```
131145
---
132146

0 commit comments

Comments
 (0)