* Get an action. * * @param {String} actionName Name of the action * @param {String} actionId ID of the action * @returns {Object} The requested action if found, else null
(actionName: string, actionId: string)
| 399 | * @returns {Object} The requested action if found, else null |
| 400 | */ |
| 401 | getAction(actionName: string, actionId: string): Action|null { |
| 402 | if (!this.actions.hasOwnProperty(actionName)) { |
| 403 | return null; |
| 404 | } |
| 405 | |
| 406 | for (const action of this.actions[actionName]) { |
| 407 | if (action.getId() === actionId) { |
| 408 | return action; |
| 409 | } |
| 410 | } |
| 411 | |
| 412 | return null; |
| 413 | } |
| 414 | |
| 415 | |
| 416 | /** |
no test coverage detected