About Functions
Introduction
FlowOn Logic built-in functions, are a comprehensive toolkit of available utilities. They are designed to simplify and automate your daily tasks regardless the complexity of the business scenarios. With this conditions you can define conditions, perform calculations like averaging, text manipulation such as capitalization, numerical analysis like counting odds, totaling values, determining minimum or maximum values, date formatting, text concatenation, and much more.
These functions are remarkably versatile, catering to various data types, including booleans, dates and times, decimals, integers, strings, floats, and monetary values. The beauty of these functions lies in their ability to perform tasks without any hidden, unanticipated changes to your data or system, ensuring that your operations remain predictable and controlled.
Functions Categories
FlowOn functions offer a wide array of functionality to cater to various needs:
Boolean Functions
Boolean functions are built-in utilities that take one or more inputs, which may not necessarily be Boolean, and produce a Boolean result. These functions evaluate conditions, comparisons, or logical operations and return either 'true' or 'false' based on the defined criteria.
These Boolean functions fall under different categories, including Binary Logical Functions, Control Functions, and Unary Logical Functions, each serving specific purposes within the broader realm of Boolean logic.
Binary Logical Functions
| Function Name | Task |
|---|---|
| Contains SubString | Return true if a string contains the specified substring; otherwise, it returns false. |
| Contains Item | Return true if the list contains the specified item; otherwise, it returns false. |
| Does Not Contain Substring | Return true if a string does not contain the specified substring; otherwise, it returns false. |
| Does Not Contain Item | Return true if the list does not contains the specified item; otherwise, it returns false. |
| Does Not End With | Return true only if the provided text does not end with the characters you specify. |
| Does Not Start With | Return true only if the provided text does not start with the characters you specify. |
| Ends With | Return true if the provided text ends with the characters you specify. |
| Is Equal To | Return true if both operands are equal; otherwise, it returns false |
| Is Greater Than | Returns true if the first operand is greater than, but not equal to, the second operand; otherwise, it returns false |
| Is Greater Than Or Equal To | Returns true if the first operand is greater than,or equal to the second operand; otherwise, it returns false |
| Is Less Than | Returns true if the first operand is less than, but not equal to, the second operand; otherwise, it returns false |
| Is Less Than Or Equal To | Returns true if the first operand is less than, or equal to, the second operand; otherwise, it returns false |
| Is Not Equal To | Returns true if both operands are not equal; otherwise, it returns false |
| Starts With | Returns true if the provided text start withs the characters you specify; otherwise, it returns false |
Control Functions
| Function Name | Task |
|---|---|
| AND | The AND operator specifies that all statements must be true for the expression to evaluate as true. |
| OR | The OR operator specifies that any of the OR statements can be correct for the expression to evaluate as true. |
| If Condition | The If Condition function returns a designated value if the condition evaluates as true, and a different value if it evaluates as false. |
Unary Logical Functions
| Function Name | Task |
|---|---|
| Has Any Value | Return true if the provided list contains at least one non-null value. |
| Is False | Return true if the operand evaluates to false, otherwise, it returns false |
| Is True | Return true if the operand evaluates to true, otherwise, it returns false |
| Not Null | Return true if an operand is NOT null, otherwise, it returns false |
| Not Null Or Empty String | Return true only if a text operand is NEITHER null nor empty, otherwise, it returns false |
| Null | Return true if an operand is null, otherwise, it returns false |
| Null Or Empty String | Return true if a text operand is null or empty,otherwise, it returns false |
For a detailed explanation of the specific Boolean functions and their use cases, please visit their dedicated page, where you can find comprehensive information and practical examples for all functionalities.
Date & Time Functions
Date and Time Functions allow you to manipulate and work with date and time values. These functions enable you to perform various operations, such as formatting dates, calculating time differences, and extracting specific date components. With Date and Time Functions, you can efficiently manage and analyze date and time-related data within your functions.
| Function Name | Task |
|---|---|
| Add Days | This function allow you to add days to a specific valid timestamp. |
| Add Hours | This function allow you to add hours to a specific valid timestamp. |
| Add Minutes | This function allow you to add minutes to a specific valid timestamp. |
| Add Month | This function allow you to add months to a specific valid timestamp. |
| Add Seconds | This function allow you to add seconds to a specific valid timestamp. |
| Add Years | This function allow you to add years to a specific valid timestamp. |
| UTC To Time Zone | This function allow you to converts a timestamp from UTC to the target time zone. |
| Convert Time Zone | This function allow you to converts a timestamp from the source time zone to the target time zone. |
| Time Zone To UTC | This function allow you to converts a timestamp from the target time zone to UTC |
| Parse Timestamp From String | This function allow you to extract a timestamp from the provided string |
| Start Of Day | This function return the start of the day for a timestamp. |
| Start Of Hour | This function return the start of the hour for a timestamp. |
| Start Of Month | This function return the start of the month for a timestamp. |
| Get Current UTC Timestamp | This function allow you to get the current timestamp in UTC format. |
| Get Day from Timestamp | This function allow you to get the day component as a number from a timestamp |
| Get Day Difference | This function allow you to get the difference in days as a number between two timestamps |
| Get Day Of Week | This function allow you to get the number of the day from the week |
| Get Month | This function allow you to get the month component as number from a timestamp |
| Get Month Difference | This function allow you to get the difference in months as a number from two timestamps |
| Get Ticks From Timestamp | This function allow you to get the tick property value from a timestamp |
| Get Year | This function allow you to get the year component as a number from a timestamp |
| Get Year Difference | This function allow you to get the difference between in years as a number between two timestamps |
For a detailed explanation of the specific Date & Time Functions and their use cases, please visit their dedicated page, where you can find comprehensive information and practical examples for all functionalities.
Math Functions
Math Functions provide a range of mathematical operations and calculations. These functions empower you to perform various mathematical tasks, including basic arithmetic operations (addition, subtraction, multiplication, division, count, max, min, etc ), rounding, absolute value calculations, and more. With Math Functions, you can efficiently manipulate numeric data, make complex calculations, and create formulas to address various mathematical requirements within your functions.
| Function Name | Task |
|---|---|
| Add | Returns the result of adding two numbers. |
| Divide | Returns the result of dividing two numbers. |
| Max Value | Returns the maximum value in an array of specified numbers. |
| Min Value | Returns the minimum value in an array of specified numbers. |
| Modulo | Returns the remainder after dividing two numbers (modulo). |
| Multiply | Returns the result of multiplying two numbers. |
| Random | Generates a random number between two values that you specify. |
| Subtract | Returns the result of subtracting two numbers. |
| Raise To Power | Returns the result of raising a number to a power you specify. |
For a detailed explanation of the specific Math Functions and their use cases, please visit their dedicated page, where you can find comprehensive information and practical examples for all functionalities.
Collection Functions
Collection Functions in FlowOn Logic are built-in utilities that operate on lists or collections. They handle tasks ranging from transformation to evaluation of elements based on specified criteria. These functions streamline the processing of data within collections, making tasks like filtering, aggregation, and projection more efficient and intuitive.
| Function Name | Task |
|---|---|
| Collection Average | Returns the average of all the elements in a numbers collection. |
| Collection Count | Counts the number of items in a list. |
| Collection Maximum | Returns the item with the highest value from an object that has multiple values. |
| Collection Minimum | Returns the item with the lowest value from an object that has multiple values. |
| Collection Sum | Returns the sum of all the elements in a numbers collection. |
For a detailed explanation of the specific Collection Functions and their use cases, please visit their dedicated page, where you can find comprehensive information and practical examples for all functionalities.
Text Functions
Text Functions offer a set of tools to manipulate and transform text data. These functions enable you to perform operations such as concatenating strings, changing letter case (capitalization), counting characters, and extracting substrings. Text Functions are valuable for managing and enhancing text-based information within your functions, making it easier to work with and analyze textual data.
| Function Name | Task |
|---|---|
| Concatenate | Join multiple text strings together. |
| Replace | Replace one string with another in the original string. |
| Substring | Return a substring from a starting index to the end of the original string. |
| To Lower Case | Convert a text string to lowercase. |
| To Upper Case | Convert a text string to uppercase. |
| Trim | Remove whitespaces from the start and end of the string. |
| Index Of Substring | Return the starting position of a substring. |
| Last Index Of Substring | Return the starting position for the last occurrence of a substring. |
| Get String Length | Return the length of a specific string. |
For a detailed explanation of the specific text functions and their use cases, please visit their dedicated page, where you can find comprehensive information and practical examples for all functionalities.
Logic Block As a Function
FlowOn Logic Blocks serve as a versatile and powerful function within the FlowOn system, enabling users to create customized functionalities beyond what built-in functions offer. These blocks are adept at handling a variety of data types and are designed to operate without side effects, focusing solely on producing specific outcomes based on their logic. Their integration as expressions in the FlowOn system allows for flexible application in various workflow contexts, significantly enhancing decision-making processes and operational efficiency.
This diverse range of functions empowers you to efficiently address a wide spectrum of requirements within your business processes.
What's Next
Having covered a comprehensive overview of various FlowOn functions, it's now time to delve deeper into the realm of boolean FlowOn functions.