Shards¶
This section contains a reference for all the shards distributed with Shards.
How to read¶
Let's look at the description for String.Join as an example:
| Name | - | Description | Default | Type |
|---|---|---|---|---|
<input> |
A sequence of string values that will be joined together. | [ String ] |
||
<output> |
A string consisting of all the elements of the sequence delimited by the separator. | String |
||
Separator |
The string to use as a separator. | "" |
String |
The first thing you will see on every shard page is this table.
The first two entries in the table describe what inputs a shard will accept and what kind of values it will output.
<input>¶
In this case, the String.Join shard accepts a sequence of Strings as an input - written as [String]. A sequence is identified by its enclosing square brackets.
<output>¶
The output will be a single String.
Parameters¶
After the input and output of the shard, the parameters are listed. The String.Join shard requires a Separator parameter that is a String. When the parameter is not specified, the default value will be "".
Optional parameters¶
| Name | - | Description | Default | Type |
|---|---|---|---|---|
Window |
None or a window variable we wish to use as a relative origin. | None |
Object |
Occasionally you will see a icon next to a parameter. This means that the parameter is optional and its value can be left unset.
When a variable is not optional and its default value is not None, you should set the parameter on the shard.
Type descriptions¶
The type column shows the expected types for input, output, or parameter:
| Name | Type |
|---|---|
Values |
String Float |
Sequence |
[ String Float ] |
Table |
{ String Float } |
Variables |
&String &Float |
SequenceVariable |
&[ Float4 ] |
Multiple different types in a row indicate that any of the types listed are accepted.
When placed within [ square brackets ], this means that a Sequence of those types is accepted.
When placed within { curly brackets }, this means that a Table of those types as values is accepted.
When a value is prefixed with an &ersand, this means that a variable / ContextVar of that type is accepted.
Further reading¶
See the Types page for more information about types.
When placed within { curly brackets }, this means that a Table of those types as values is accepted.
When a value is prefixed with an &ersand, this means that a variable / ContextVar of that type is accepted.