Table of Contents
Table of Contents |
---|
Introduction
he Mini-Language concept in Open For Business is similar to the Gang of Four Interpreter pattern, or the Mark Grand Little Language pattern. This is also the central theme of the Building Parsers with Java book by Steven John Metsker which the OFBiz Rule Engine is based on. The idea is to create simple languages that simplify complex or frequently performed tasks.
...
Attribute Name | Required? | Description |
---|---|---|
map-name | N | The name of the map in the method environment. If not specified the field-name will be used to set the field in the method environment. |
field-name | Y | The name (key) of the map field to use. |
default | N | A default value to use if the session attribute is null or is a String and is empty. This will also be used when NOT running as an event. |
session-name | N | The name of the session attribute to use. Defaults to the field-name. |
webapp-property-to-field
The webapp-property-to-field tag copies a property value from a properties file in a ServletContext resource to a field.
The tag is only used when the simple-method is called as an event, it is ignored otherwise (except the default value, if specified).
Attribute Name | Required? | Description |
---|---|---|
resource | Y | The resource location of the properties file inside the webapp, and relative to the root of the webapp (can be inside a war file). An example of this is "/WEB-INF/myprops.properties". |
property | Y | The property whose value will be put in the field. |
default | N | A default value to use if the property value is null or empty. This will also be used when NOT running as an event. |
map-name | N | The name of the map in the method environment. If not specified the field-name will be used to set the field in the method environment. |
field-name | Y | The name (key) of the map field to use. |
Service Specific Operations
field-to-result
The field-to-result tag copies a field from a map to the specified service result field.
The tag is only used when the simple-method is called as a service, it is ignored otherwise.
Attribute Name | Required? | Description |
---|---|---|
map-name | N | The name of the map in the method environment. If not specified the field-name will be used to get the field from the method environment. |
field-name | Y | The name (key) of the map field to use. |
result-name | N | The name of the request attribute to use. Defaults to the field-name. |
Method Environment Operations
map-to-map
The map-to-map tag copies all fields from one map to another map