Concepts
Template Structure
How templates are structured
Overview
Templates are the container for defining a unique process in Stubber.
Templates are the top-level of the process definition.
Naming Templates correctly is very important.
Templates are broken down into components in a tree structure.
Together the template, branch and context define a unique process in Stubber.
This is called a program.
It is possible to change the program of a stub using the morph stub task.
Example
Here is an example of what a template structure would look like to define a "sales enquiry" process.
There are 2 default branches namely draft and live.
The publish action on the editor will copy the draft branch to the live branch.
Template Context
Basics
The context is the viewpoint or aspect into the template.
Some default contexts are create and manage.
You would define how a new stub is created in the create context.
You could define actions that are used to manage all the stubs in the manage context.
Clarification
This means a stub actually follows the definition contained in the context of the template.
The stub is a unique instance of the template and follows the specific definition of the context that it is created from.
Conceptual Example
Practical Example
For a "sales enquiry" template, we might have many stubs created using the default context, which specify how a sales enquiry works. We also have a context called create that specifies how someone would create a new sales enquiry. This context contains the fields required to create a new sales enquiry. Additionally, we have a context called manage that specifies how someone would manage a sales enquiry. This context contains the actions required to manage a sales enquiry.
Contexts in the Stubber Framework provide different perspectives or viewpoints on how a template can be utilized. For the sales enquiry template, you might have several contexts:
Default Context:
This context specifies the general operation of the sales enquiry process. It outlines how the process should function under ordinary circumstances, including the states and actions involved.
Create Context:
This context is specifically designed for creating a new sales enquiry. It specifies the fields required to gather information necessary for a new enquiry, such as customer name, contact details, and inquiry specifics. Essentially, it defines what data needs to be collected when starting a new inquiry.
Manage Context:
Once a sales enquiry is created, the manage context comes into play. This context outlines the actions required to oversee and handle the sales enquiry throughout its lifecycle. This could include actions like updating inquiry details, following up with the customer, or closing the enquiry once resolved.
Flow
Basics
The flow is where you define the states and actions of the context.
This is most important part of the Stubber Framework and where the most of the defining happens.
Most people when they think of building in Stubber will be working on the flow canvas.
The flow is built and maintained in the Editor application on the Stubber Platform.
States and Actions
The states and actions are the building blocks of the flow.
The states and actions are explained in this conceptual page.