@webda/kubernetes • Readme | API
Function: CronReplace()
CronReplace(
template
,cron
,app
,replacements
):any
Replaces placeholders in a given template string with values from a CronDefinition object and other replacements.
Cron Arguments are rendered in 3 different ways:
- argsLine: The arguments are rendered as a single string, with each argument wrapped in double quotes and separated by a space.
- argsLineSingleQuote: The arguments are rendered as a single string, with each argument wrapped in single quotes and separated by a space.
- argsArray: The arguments are rendered as a single string, with each argument wrapped in double quotes and separated by a comma.
Parameters
• template: any
The template string to replace placeholders in.
• cron: CronDefinition
The CronDefinition object containing values to replace placeholders with.
• app: Application
The Application object.
• replacements: any
= {}
Optional additional replacements to use in the template string.
Returns
any
The template string with all placeholders replaced with their corresponding values.