maestro
latest
false
- はじめに
- 基本情報
- BPMN を使用したプロセス モデリング
- ケース管理を使用したプロセス モデリング
- Process modeling with Flow
- 基本情報
- 中心となる概念
- Node reference
- Build guides
- ベスト プラクティス
- 参照
- プロセスの実装
- プロセスの操作
- プロセスの監視
- プロセスの最適化
- 参考情報
重要 :
このコンテンツの一部は機械翻訳によって処理されており、完全な翻訳を保証するものではありません。
新しいコンテンツの翻訳は、およそ 1 ~ 2 週間で公開されます。
Maestro ユーザー ガイド
機能
Routes a process to one of multiple paths based on ordered conditions. Takes the first match.
When to use this vs Decision
| Use Switch when... | Use Decision when... |
|---|---|
| You have three or more outcomes | You have exactly two outcomes |
| You're routing by multiple distinct conditions | The condition is a simple yes/no |
| You need a default/fallback branch |
Configuration reference
| フィールド | Required | 既定 (Default) | 説明 |
|---|---|---|---|
| ケース | はい | 2 empty cases | Ordered branch list. Each case has a handle label and a JavaScript expression; the first truthy expression is taken. |
| Include default | いいえ | true | Whether to add a Default branch that is taken when no case expression matches. |
Writing case expressions
Each case expression uses the same JavaScript environment as the Script and Decision nodes:
// Case 1 — high priority
$vars.ticket1.output.priority === "high"
// Case 2 — medium priority
$vars.ticket1.output.priority === "medium"
// Case 3 — low priority (or use Default to catch everything else)
$vars.ticket1.output.priority === "low"
// Case 1 — high priority
$vars.ticket1.output.priority === "high"
// Case 2 — medium priority
$vars.ticket1.output.priority === "medium"
// Case 3 — low priority (or use Default to catch everything else)
$vars.ticket1.output.priority === "low"
More specific conditions should appear first. A broader condition higher in the list will match before a more specific one below it.
例
Example 1 — Route by HTTP status code
| ケース (Case) | 式 | ブランチ |
|---|---|---|
| 成功 | $vars.httpRequest1.output.statusCode === 200 | → process response |
| Not Found | $vars.httpRequest1.output.statusCode === 404 | → handle missing resource |
| 既定 (Default) | (fallback) | → handle unexpected error |
Example 2 — Route by string value
| ケース (Case) | 式 | ブランチ |
|---|---|---|
| 承認済み | $vars.form1.output.status === "approved" | → continue process |
| 却下済み | $vars.form1.output.status === "rejected" | → notify rejection |
| 保留中 | $vars.form1.output.status === "pending" | → wait for review |
| 既定 (Default) | (fallback) | → handle unknown status |
関連ページ
- Decision node — for exactly two branches
- Variables and data flow —
$varssyntax and expression patterns - Error handling — handling failures vs conditional branching