## 4.2.15.20  API for Consumption of Business Rules
The purpose of the CL\_FDT\_FUNCTION\_PROCESS\_API is to enable consumption of BRF+ (Business Rule Framework plus) rules within the ABAP Cloud development environment. It acts as a bridge between your application and BRF+ functions(rules).
The following table shows methods in CL\_FDT\_FUNCTION\_PROCESS\_API class:
| Method                                                                                                     | Parameter                      | Description                                                                                                                                                                                          |
|------------------------------------------------------------------------------------------------------------|--------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| Get_Content_List                                                                                           | Importing: IV_FUNCTION_ID      | ID of the function to be processed.                                                                                                                                                                  |
| This method is used to get the list of context elements for BRFplus function.                              | Importing: V_TIMESTAMP :       | The timestamp parameter specifies the data retrieval or function evaluation time. Without a timestamp, the function returns the context list at the current date and time.                           |
| This method is used to get the list of context elements for BRFplus function.                              | Importing: IV_TRACE_GENERATION | This Boolean indicates that the trace should be generated with a lean trace or not.                                                                                                                  |
| This method is used to get the list of context elements for BRFplus function.                              | Exporting: ET_CONTEXT_LIST     | The exporting parameter is a table con- taining the function's context list, which includes the id, name, and data object type of each context.                                                      |
| GET_CONTEXT_VALUE                                                                                          | Importing: IV_FUNCTION_ID      | ID of the function to be processed.                                                                                                                                                                  |
| This method is used to get the value of the context object of a BRFplus func- tion in a referenced object. | Importing: IV_DATA_OBJECT      | A character-like parameter that speci- fies the name or ID of the data object involved in the function call.                                                                                         |
| This method is used to get the value of the context object of a BRFplus func- tion in a referenced object. | Importing: IV_TIMESTAMP        | The timestamp parameter specifies the point in time for data retrieval or func- tion evaluation. If no timestamp is pro- vided, the function returns the context value at the current date and time. |
| This method is used to get the value of the context object of a BRFplus func- tion in a referenced object. | Importing: IV_TRACE_GENERATION | This Boolean indicates that the trace should be generated with a lean trace or not.                                                                                                                  |
| This method is used to get the value of the context object of a BRFplus func- tion in a referenced object. | Exporting: EV_DATA             | This parameter exports the data ob- ject's actual value after function execu- tion. Its type "ANY" indicates flexibility to handle any data type, expanding the function's return possibilities.     |
| This method is used to get the value of the context object of a BRFplus func- tion in a referenced object. | Exporting: ER_DATA             | This exporting parameter references the data object, enabling its manipula- tion or examination beyond the function call.                                                                            |
| GET_DATA_OBJECT_REFERENCE                                                                                  | Importing: IV_FUNCTION_ID      | ID of the function to be processed.                                                                                                                                                                  |
| This method is used to get the data ref- erence of a context object in BRFplus function.                   | Importing: IV_DATA_OBJECT :    | Importing: IV_DATA_OBJECT: A charac- ter-like parameter that specifies the name or ID of the data object involved in the function call.                                                              |
| This method is used to get the data ref- erence of a context object in BRFplus function.                   | Importing: IV_DATA_OBJECT      | A character-like parameter that speci- fies the name or ID of the data object involved in the function call.                                                                                         |
| Method                                                                                                        | Parameter                      | Description                                                                                                                                                                                                                                               |
|---------------------------------------------------------------------------------------------------------------|--------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|                                                                                                               | Importing: IV_TIMESTAMP        | Importing: IV_TIMESTAMP: The time- stamp parameter specifies a specific point in time for data retrieval or func- tion evaluation. If no timestamp is pro- vided, all function context in a refer- enced object at the current date and time is returned. |
|                                                                                                               | Importing: IV_TRACE_GENERATION | Importing: IV_TRACE_GENERATION: This Boolean indicates that the trace should be generated with a lean trace or not.                                                                                                                                       |
|                                                                                                               | Exporting: EV_DATA_OBJECT_NAME | This parameter exports the technical name of the data object involved in the operation, providing metadata such as its name or identifier.                                                                                                                |
|                                                                                                               | Exporting ER_DATA              | This exporting parameter provides a reference to the data object. It does not contain an actual value but rather a pointer to the data object.                                                                                                            |
| MOVE_DATA_TO_DATA_OBJECT This method is used to pass data from external source to BRFplus function's context. | Importing: IR_DATA             | This is a reference to any ABAP data object. It allows the method to directly interact with ABAP data objects pro- vided by the calling program, offering a flexible interface for data processing.                                                       |
| MOVE_DATA_TO_DATA_OBJECT This method is used to pass data from external source to BRFplus function's context. | Importing: IV_FUNCTION_ID      | ID of the function to be processed.                                                                                                                                                                                                                       |
| MOVE_DATA_TO_DATA_OBJECT This method is used to pass data from external source to BRFplus function's context. | Importing: IV_DATA_OBJECT :    | A character-like parameter that speci- fies the name or ID of the data object involved in the function call.                                                                                                                                              |
| MOVE_DATA_TO_DATA_OBJECT This method is used to pass data from external source to BRFplus function's context. | Importing: IV_TIMESTAMP        | The timestamp parameter is used to define a specific point in time for the data retrieval or function evaluation. If no time stamp is provided, then it takes current date and time.                                                                      |
| MOVE_DATA_TO_DATA_OBJECT This method is used to pass data from external source to BRFplus function's context. | Importing: IV_TRACE_GENERATION | This Boolean indicates that the trace should be generated with a lean trace or not.                                                                                                                                                                       |
| MOVE_DATA_TO_DATA_OBJECT This method is used to pass data from external source to BRFplus function's context. | Importing: IV_HAS_DDIC_BINDING | Indicates whether the data passed to the method confirms to a DDIC (Data Dictionary) structure as defined in BRF+.                                                                                                                                        |
| MOVE_DATA_TO_DATA_OBJECT This method is used to pass data from external source to BRFplus function's context. | Exporting: ER_DATA             | This exporting parameter exports a ref- erence to a BRFplus data object. This allows the method to return a data ob- ject that can be further manipulated or evaluated outside the method.                                                                |
| PROCESS                                                                                                       | Importing: IV_FUNCTION_ID      | ID of the function to be processed.                                                                                                                                                                                                                       |
| Method                                                                                                                                                                                                                              | Parameter                  | Description                                                                                                                                                                                                                                                                                |
|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|----------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| With this method, a BRFplus function can be processed. You can specify a timestamp for the function to be proc- essed so you can simulate the system behavior as it would have been at that point. Also, you can decide whether the | Importing: IV_TIMESTAMP    | The timestamp parameter is used to define a specific point in time for the data retrieval or function evaluation. If no time stamp is provided, the result of the function at the current date and time is returned.                                                                       |
| trace for the function execution shall be                                                                                                                                                                                           | Importing: IV_TRACE_MODE   | Indicates the modes of trace. By de- fault, mode is 'L' (Lean Trace).                                                                                                                                                                                                                      |
| saved in database for later reference or not.                                                                                                                                                                                       | Importing: : IV_SAVE_TRACE | Indicates whether the trace generated for current processing of the Function should be saved in database.                                                                                                                                                                                  |
|                                                                                                                                                                                                                                     | Importing: IT_ID_VALUE     | Table of ID/value pairs (ID/reference to value for each context element). From a performance perspective, this is the most efficient way of triggering the processing of BRFplus. Also, using this parameter requires that you know the IDs of the context elements that you want to pass. |
|                                                                                                                                                                                                                                     | Exporting: EA_RESULT       | Exporting: EA_RESULT: A variable of a type that is compatible with the result data object of the BRFplus function. You can get an ABAP data object of this type (a reference) by calling method CL_FDT_FUNCTION_PROCESS_AP I ->IF_FDT_FUNCTION_PROCESS_ API~GET_DATA_OBJECT_REFERE NCE .   |