This is the interface for actions for OData version 4 (V4). This interface provides methods to maintain an action during creation of a service model in a model provider class. Functions and actions as well are also called operations.
Actions are operations that allow side effects, such as data modification, and cannot be further composed in order to avoid non-deterministic behavior. Actions may return data.
This interface includes interface /iwbep/if_v4_med_element.
Visibility and Level |
Alias |
Component |
---|---|---|
public |
get_edm_name | //IWBEP/IF_V4_MED_ELEMENT~GET_EDM_NAME |
public |
get_internal_name |
/IWBEP/IF_V4_MED_ELEMENT~GET_INTERNAL_NAME |
This method creates the action import of an action.
Action imports enable unbound actions to be called from the service root.
create_action_import IMPORTING iv_action_import_name TYPE /iwbep/if_v4_med_element=>ty_e_med_internal_name RETURNING VALUE(ro_action_import) TYPE REF TO /iwbep/if_v4_med_action_imp RAISING /iwbep/cx_v4_med .
Parameter |
Description |
---|---|
iv_action_import_name |
Internal action import name. |
ro_action_import |
Action import. |
Exceptions
The metadata exception is iwbep/cx_v4_med.
This method creates a parameter on an action.
Actions can operate on parameter values. In order to be able to pass parameter values to an action, parameters must be defined for actions.
create_parameter IMPORTING iv_parameter_name TYPE /iwbep/if_v4_med_element=>ty_e_med_internal_name RETURNING VALUE(ro_parameter) TYPE REF TO /iwbep/if_v4_med_act_param RAISING /iwbep/cx_v4_med .
Parameter |
Description |
---|---|
iv_parameter_name |
Internal parameter name. |
ro_parameter |
Action parameter. |
Exceptions
The metadata exception is iwbep/cx_v4_med.
This method creates a return for an action.
Actions may return data which represents the result of the action. Use this method to create a return type for the action, for example a primitive type or an entity type.
create_return RETURNING VALUE(ro_return) TYPE REF TO /iwbep/if_v4_med_act_return RAISING /iwbep/cx_v4_med .
Parameter |
Description |
---|---|
ro_return |
Operation return. |
Exceptions
The metadata exception is iwbep/cx_v4_med.
This method gets the parameter of an action.
After retrieving the parameter, the characteristics of the parameter can be enhanced or changed.
get_parameter IMPORTING iv_parameter_name TYPE /iwbep/if_v4_med_element=>ty_e_med_internal_name RETURNING VALUE(ro_parameter) TYPE REF TO /iwbep/if_v4_med_act_param RAISING /iwbep/cx_v4_med .
Parameter |
Description |
---|---|
iv_parameter_name |
Internal parameter name. |
ro_parameter |
Action parameter. |
Exceptions
The metadata exception is iwbep/cx_v4_med.
This method gets all parameters of an action.
After retrieving the parameters, the characteristics of the parameters can be enhanced or changed.
get_parameters EXPORTING et_parameter TYPE /iwbep/if_v4_med_element=>ty_t_action_parameter RAISING /iwbep/cx_v4_med .
Parameter |
Description |
---|---|
et_parameter |
Action parameter. |
Exceptions
The metadata exception is iwbep/cx_v4_med.
This method gets the return of an action.
After retrieving the return, the characteristics of the return can be enhanced or changed.
get_return RETURNING VALUE(ro_return) TYPE REF TO /iwbep/if_v4_med_act_return RAISING /iwbep/cx_v4_med
Parameter |
Description |
---|---|
ro_return |
Operation return. |
Exceptions
The metadata exception is iwbep/cx_v4_med.
This method sets the EDM name of an action.
The EDM name must be unique within the model.
set_edm_name IMPORTING iv_edm_name TYPE /iwbep/if_v4_med_element=>ty_e_med_edm_name RAISING /iwbep/cx_v4_med .
Parameter |
Description |
---|---|
iv_edm_name |
EDM name. |
Exceptions
The metadata exception is iwbep/cx_v4_med.