Skip to content

Commit

Permalink
Rename ArrayOrString to ParamValues
Browse files Browse the repository at this point in the history
This commit fixes issue tektoncd#4858. With the implementation of Tep75,
ArrayOrString contains object type and it would be confusing if still
use the same name. This commit renames it to ParamValues and type alias
ResultValues to ParamValues. Also use type alias to make sure dependant
libraries can still use ArrayOrString and NewArrayOrString.
  • Loading branch information
Yongxuanzhang committed Aug 12, 2022
1 parent 57aa030 commit e2028cc
Show file tree
Hide file tree
Showing 58 changed files with 2,762 additions and 1,787 deletions.
11 changes: 6 additions & 5 deletions docs/api-spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
- [Status Signalling](#status-signalling)
- [Listing Resources](#listing-resources)
- [Detailed Resource Types - v1beta1](#detailed-resource-types---v1beta1)
* [`ArrayOrString`](#arrayorstring)
* [`ParamValue`](#paramvalue)
* [`ContainerStateRunning`](#containerstaterunning)
* [`ContainerStateWaiting`](#containerstatewaiting)
* [`ContainerStateTerminated`](#containerstateterminated)
Expand Down Expand Up @@ -186,13 +186,14 @@ List responses have the following fields (based on [`meta.v1/ListMeta`](https://

## Detailed Resource Types - v1beta1

### `ArrayOrString`
### `ParamValue`

| Field Name | Field Type | Requirement |
|-------------|------------|-------------|
| `type` | Enum:<br>- `"string"` (default)<br>- `"array"` | REQUIRED |
| `type` | Enum:<br>- `"string"` (default)<br>- `"array"` <br>- `"object"` | REQUIRED |
| `stringVal` | string | REQUIRED |
| `arrayVal` | []string | REQUIRED |
| `objectVal` | map<string,string> | REQUIRED |

### `ContainerStateRunning`

Expand Down Expand Up @@ -235,7 +236,7 @@ List responses have the following fields (based on [`meta.v1/ListMeta`](https://
| Field Name | Field Type | Requirement |
|------------|-----------------|-------------|
| `name` | string | REQUIRED |
| `value` | `ArrayOrString` | REQUIRED |
| `value` | `ParamValue` | REQUIRED |

### `ParamSpec`

Expand All @@ -244,7 +245,7 @@ List responses have the following fields (based on [`meta.v1/ListMeta`](https://
| `name` | string | REQUIRED |
| `description` | string | REQUIRED |
| `type` | Enum: <br>- `"string"` (default) <br>- `"array"` | REQUIRED |
| `default` | `ArrayOrString` | REQUIRED |
| `default` | `ParamValue` | REQUIRED |

### `Step`

Expand Down
Loading

0 comments on commit e2028cc

Please sign in to comment.