Class: AWS::Flow::Templates::TemplateBase

Inherits:
Object
  • Object
show all
Defined in:
aws-flow-ruby/aws-flow/lib/aws/templates/base.rb

Overview

A Template is a precanned workflow definition that can be combined with other templates to construct a workflow body. TemplateBase is a class that must be inherited by all templates. It provides the 'abstract' method #run that needs to be implemented by subclasses.

Direct Known Subclasses

RootTemplate

Instance Method Summary (collapse)

Instance Method Details

- (Object) run(input, context)

This method needs to be implemented by the sub classes.

Parameters:

  • input (Hash)

    This is the input to the template

  • context (AWS::Flow::Workflows)

    A class that extends AWS::Flow::Workflows. The workflow that runs a template passes itself as an argument to provide the template with the right context to execute in.

Raises:

  • (NotImplementedError)


18
19
20
# File 'aws-flow-ruby/aws-flow/lib/aws/templates/base.rb', line 18

def run(input, context)
  raise NotImplementedError, "Please implement the #run method of your template."
end