Utility is a special case of model. The utility has the right to operate on a group of entities and their instances. The utility does not have any template code connected to it so it is always only manually written code in an utility. A utility always ends up as a database package with one or more methods. Utilities can be layered, meaning that they can be extended.
A system service is a specialization of a utility. The system service can only exist in the framework. System services can be used by all entities in the system to perform framework activities like security and reference checks. The system services can't have layers.
Utilities are easy to model in Developer Studio and there is nearly no choices to be made when creating a utility.
Follow these steps to model a utility:
- Create the utility model.
In most cases you are then ready with the utility model.
- If you need to change the behavior of the code generation, add code generation properties.
The Codegen properties can only be added on the top level of the model.
- Generate the code.
Now you can start to add the methods and functionality necessary for the utility in the database package.
After code generation, you will get the following:
- One database package, used to create utility specific business rules.
- The views file is used for overtaking, overriding views and for creation of additional views. Normally there is no views for an utility.
- The plsql file is used for overtaking, overriding methods and creation of own written methods.
utilityname DateFormatting; component F1DOC;