Introduction
Blocks serve as specialized tools tailored to help you create custom functions. These functions offer the flexibility to accept optional inputs and consistently generate desired outputs. Remarkably, Logic Blocks are designed to ensure smooth operations without causing any unintended changes or "side effects" to your system's overall state.
These diverse blocks encompass a range of types, including formulas, validations, validation sets, decision tables, and decision trees. This assortment empowers you to develop reusable functions that can seamlessly enhance your project's capabilities. By incorporating Logic Blocks, you can effectively bridge gaps and optimize workflows, all without the need for manual coding efforts.
Types of Logic Blocks
In FlowOn, logic blocks come in various types, each designed for specific purposes. Let's delve into these types of logic blocks to better understand their individual functionalities and applications.
| Type | Description |
|---|---|
| Formula | Formulas facilitate calculations across data types, handling numbers, dates, text, and boolean conditions. |
| Validation | Designed to assess conditions yielding binary outcomes. Ensures accurate data validation and decision-making. |
| Validation Set | Groups multiple validations for comprehensive input validation. Enhances accuracy by optionally halting at the first error. |
| Decision Table | Navigates complex decision-making with multiple conditions. Automates decision-making for consistent results. |
| Decision Tree | Offers a visual representation of decision-making pathways. Helps navigate decisions based on conditions. |
For a more in-depth understanding of each type, please refer to their respective pages. Your journey to mastering flowOn logic blocks starts there.
Common Properties of Blocks
All the logic block types explained above share certain common properties. These properties include the block's name, description, associated project, input parameters, data parameters, and a designation indicating whether the block is marked as is action. Let's delve into each of these properties in greater detail.
| Property | Required | Description |
|---|---|---|
| Name | Yes | The name of the new block. |
| Type | Yes | The type of the block (formula, validation, validation set, decision table/tree). |
| Project | Yes | The project to which the block belongs. |
| Description | No | The optional description of the block. |
| Is Action | No | Indicates whether the block is marked as an action. |
| Input | No | The input parameters to be used in the block. |
| Data | No | Data that can be added from an entity or queried from a table. |
Special Properties For Decision Tables and Decision Trees:
Decision tables and decision trees share the same properties as other logic block types, and they also have the two specific properties mentioned below.
| Property | Required | Description |
|---|---|---|
| Decisions | Yes | The decisions you create using expressions to add them. At least one decision is required. |
| Outcome | Yes | The outcome you add corresponding to each decision in the decision table/tree. |
What's Next
Now that we've covered the various types of FlowOn logic blocks, their common properties, it's time to delve deeper into the first type: the Formula Block. In the upcoming section, we will explore the ins and outs of using formula blocks to perform calculations, handle different data types, and create efficient functions.