|
Modified: ofbiz/branches/20120329_portletWidget/framework/minilang/dtd/simple-methods-v2.xsd
URL: http://svn.apache.org/viewvc/ofbiz/branches/20120329_portletWidget/framework/minilang/dtd/simple-methods-v2.xsd?rev=1369382&r1=1369381&r2=1369382&view=diff ============================================================================== --- ofbiz/branches/20120329_portletWidget/framework/minilang/dtd/simple-methods-v2.xsd (original) +++ ofbiz/branches/20120329_portletWidget/framework/minilang/dtd/simple-methods-v2.xsd Sat Aug 4 18:11:00 2012 @@ -25,7 +25,8 @@ under the License. (see further down for the Simple Map Processor Section) --> - <!-- Reusable artifacts (abstract elements, groups, attributeGroups --> + <!-- Abstract elements and element groups --> + <xs:element name="CallOperations" abstract="true"/> <xs:element name="EventOperations" abstract="true"/> <xs:element name="ServiceOperations" abstract="true"/> @@ -39,7 +40,8 @@ under the License. <xs:element name="IfBasicOperations" abstract="true"/> <xs:element name="IfOtherOperations" abstract="true"/> <xs:element name="OtherOperations" abstract="true"/> - <xs:group name="AllOperations"> <!-- Any simple-method operation can be nested under an if-* tag. --> + + <xs:group name="AllOperations"> <xs:choice> <xs:element ref="CallOperations"/> <xs:element ref="EventOperations"/> @@ -57,6 +59,17 @@ under the License. </xs:choice> </xs:group> + <xs:group name="IfConditions"> + <xs:choice> + <xs:element ref="IfCombineConditions"/> + <xs:element ref="IfBasicOperations"/> + </xs:choice> + </xs:group> + + <xs:element name="IfCombineConditions" abstract="true"/> + + <!-- Reusable types --> + <xs:simpleType name="booleanConst"> <xs:restriction base="xs:token"> <xs:enumeration value="true" /> @@ -65,11 +78,19 @@ under the License. </xs:simpleType> <xs:simpleType name="booleanExpr"> + <xs:restriction base="xs:string"> + <xs:pattern value="\$\{.+\}|true|false" /> + </xs:restriction> + </xs:simpleType> + + <xs:simpleType name="javaClassName"> <xs:restriction base="xs:token"> - <xs:pattern value="\$\{[a-zA-Z_]{1}[a-zA-Z0-9_\-.]+\}|true|false" /> + <xs:pattern value="[a-zA-Z_]{1}[a-zA-Z0-9_$.]+" /> </xs:restriction> </xs:simpleType> + <!-- Reusable attributes and attribute groups --> + <xs:attribute name="field"> <xs:annotation> <xs:documentation> @@ -85,54 +106,26 @@ under the License. </xs:simpleType> </xs:attribute> - <xs:attribute type="xs:string" name="error-list-name"> + <xs:attribute name="error-list-name" type="xs:string"> <xs:annotation> <xs:documentation> The name of the error message list. It will be created if it does not exist. Defaults to "error_list". <br/><br/> - Optional. Attribute type: constant + Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attributeGroup name="attlist.propertyInfoOptional"> - <xs:attribute type="xs:string" name="resource"/> - <xs:attribute type="xs:string" name="property"/> - </xs:attributeGroup> - - <xs:attributeGroup name="attlist.optionalJavaType"> - <xs:attribute type="xs:string" name="type"> - <xs:annotation> - <xs:documentation> - The Java data type. The source object will be converted to this type. - <br/><br/> - Optional. Attribute type: constant. Attribute must contain a valid Java class name. - </xs:documentation> - </xs:annotation> - </xs:attribute> - </xs:attributeGroup> - - <xs:attributeGroup name="attlist.typeDefaultString"> - <xs:attribute name="type" default="String"> - <xs:simpleType> - <xs:restriction base="xs:token"> - <xs:enumeration value="PlainString"/> - <xs:enumeration value="String"/> - <xs:enumeration value="BigDecimal"/> - <xs:enumeration value="Double"/> - <xs:enumeration value="Float"/> - <xs:enumeration value="Long"/> - <xs:enumeration value="Integer"/> - <xs:enumeration value="Date"/> - <xs:enumeration value="Time"/> - <xs:enumeration value="Timestamp"/> - <xs:enumeration value="Boolean"/> - <xs:enumeration value="Object"/> - </xs:restriction> - </xs:simpleType> - </xs:attribute> - </xs:attributeGroup> + <xs:attribute name="type" type="javaClassName"> + <xs:annotation> + <xs:documentation> + The Java data type. + <br/><br/> + Optional. Attribute type: constant. Attribute must contain a valid Java class name. + </xs:documentation> + </xs:annotation> + </xs:attribute> <xs:attributeGroup name="attlist.operatorRequired"> <xs:attribute name="operator" use="required"> @@ -194,159 +187,48 @@ under the License. </xs:attribute> </xs:attributeGroup> - <xs:attribute name="level"> - <xs:annotation> - <xs:documentation> - The logging/debug level to use. - Must be one of the following: verbose | timing | info | important | warning | error | fatal | always. - Defaults to "info". - <br/><br/> - Required. Attribute type: constant. - </xs:documentation> - </xs:annotation> - <xs:simpleType> - <xs:restriction base="xs:token"> - <xs:enumeration value="info" /> - <xs:enumeration value="verbose" /> - <xs:enumeration value="timing" /> - <xs:enumeration value="important" /> - <xs:enumeration value="warning" /> - <xs:enumeration value="error" /> - <xs:enumeration value="fatal" /> - <xs:enumeration value="always" /> - </xs:restriction> - </xs:simpleType> - </xs:attribute> - - <xs:attributeGroup name="attlist.entityFindOperations"> - <xs:attribute name="entity-name" type="xs:string" use="required"> - <xs:annotation> - <xs:documentation> - Name of the entity to search in. - <br/><br/> - Required. Attribute type: constant, ${expression}. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute name="list" type="xs:string" use="required"> - <xs:annotation> - <xs:documentation> - Name of the list where to put results. - <br/><br/> - Required. Attribute type: expression. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute name="filter-by-date" default="false"> - <xs:annotation> - <xs:documentation> - Look for from-date and through-date fields in the list of results coming back - and filters by the current date and time if set to true. - Defaults to "false". - <br/><br/> - Optional. Attribute type: constant, ${expression}. - </xs:documentation> - </xs:annotation> - <xs:simpleType> - <xs:restriction base="xs:token"> - <xs:enumeration value="true" /> - <xs:enumeration value="false" /> - <xs:enumeration value="by-name" /> - </xs:restriction> - </xs:simpleType> - </xs:attribute> - <xs:attribute name="distinct" default="false"> - <xs:annotation> - <xs:documentation> - Filter the results making sure that all of them are unique. - Defaults to "false". - <br/><br/> - Optional. Attribute type: constant, ${expression}. - </xs:documentation> - </xs:annotation> - <xs:simpleType> - <xs:restriction base="xs:token"> - <xs:enumeration value="true"/> - <xs:enumeration value="false"/> - </xs:restriction> - </xs:simpleType> - </xs:attribute> - <xs:attribute name="use-cache" type="xs:string" default="false"> + <xs:attributeGroup name="attlist.check-permission"> + <xs:attribute name="permission" type="xs:string" use="required"> <xs:annotation> <xs:documentation> - Specifies whether or not the delegator's cache should be searched before going to the database. - This results in much faster retrieval times, but can return stale data that is not the most current in the database. - Must be "true" or "false", defaults to "false". + The name of the permission. + The user must belong to a security group that includes this permission. <br/><br/> - Optional. Attribute type: constant, ${expression}. + Required. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute name="delegator-name" type="xs:string"> + <xs:attribute name="action" type="xs:string"> <xs:annotation> <xs:documentation> - Overrides the delegator by specifying a delegator name. + If an action is specified the user can have one of two permissions: the permission + "_ADMIN" or permission + action. + Examples of actions include "_CREATE", "_VIEW", etc. <br/><br/> - Optional. Attribute type: constant, ${expression}. + Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> </xs:attributeGroup> - <!-- ELEMENTS start here --> - <xs:element name="field"> - <xs:annotation> - <xs:documentation> - Specifies an environment field to be passed as an argument to a method call. - </xs:documentation> - </xs:annotation> - <xs:complexType> - <xs:attribute type="xs:string" name="field" use="required"> - <xs:annotation> - <xs:documentation> - The name of the environment field to use. - <br/><br/> - Required. Attribute type: expression. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="type"> - <xs:annotation> - <xs:documentation> - The Java class of the argument. Defaults to java.lang.String. - If this is a method call or object creation and the type in the method signature being called is for a parent class or interface, - then it should be the type in that parent class or interface and not the type of the object being - passed in. - <br/><br/> - Optional. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - </xs:complexType> - </xs:element> - <xs:element name="string"> - <xs:annotation> - <xs:documentation> - Specifies a java.lang.String to be passed as an argument to a method call. - The String can be contained in the value attribute or in the element body. - </xs:documentation> - </xs:annotation> - <xs:complexType> - <xs:attribute type="xs:string" name="value" /> - </xs:complexType> - </xs:element> +<!-- + ============================= + ===== The Root Elements ===== + ============================= +--> + <xs:element name="simple-methods"> <xs:annotation> <xs:documentation> - Opening tag of simple-method files. + The document-level element of Mini-language files. </xs:documentation> </xs:annotation> <xs:complexType> <xs:sequence> - <xs:element maxOccurs="unbounded" ref="simple-method"/> + <xs:element ref="simple-method" minOccurs="0" maxOccurs="unbounded"/> </xs:sequence> </xs:complexType> </xs:element> + <xs:element name="simple-method"> <xs:annotation> <xs:documentation> @@ -359,8 +241,8 @@ under the License. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:group minOccurs="0" maxOccurs="unbounded" ref="AllOperations" /> - <xs:attribute name="method-name" use="required"> + <xs:group ref="AllOperations" minOccurs="0" maxOccurs="unbounded" /> + <xs:attribute name="method-name" type="javaClassName" use="required"> <xs:annotation> <xs:documentation> A name (preferably a legal Java identifier) for this method. @@ -369,13 +251,8 @@ under the License. Required. Attribute type: constant. </xs:documentation> </xs:annotation> - <xs:simpleType> - <xs:restriction base="xs:token"> - <xs:pattern value="[a-zA-Z_]{1}[a-zA-Z0-9_\-.]+" /> - </xs:restriction> - </xs:simpleType> </xs:attribute> - <xs:attribute type="xs:string" name="short-description"> + <xs:attribute name="short-description" type="xs:string"> <xs:annotation> <xs:documentation> A short description of the method - used for documentation. @@ -402,7 +279,7 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="default-error-code"> + <xs:attribute name="default-error-code" type="xs:string"> <xs:annotation> <xs:documentation> The default error return code. Defaults to "error". @@ -411,7 +288,7 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="default-success-code"> + <xs:attribute name="default-success-code" type="xs:string"> <xs:annotation> <xs:documentation> The default success return code. Defaults to "success". @@ -420,7 +297,7 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="event-request-object-name"> + <xs:attribute name="event-request-object-name" type="xs:string"> <xs:annotation> <xs:documentation> The name of the field containing the javax.servlet.ServletRequest object. Defaults to "request". @@ -431,7 +308,7 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="event-response-object-name"> + <xs:attribute name="event-response-object-name" type="xs:string"> <xs:annotation> <xs:documentation> The name of the field containing the javax.servlet.ServletResponse object. Defaults to "response". @@ -442,10 +319,10 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="event-response-code-name"> + <xs:attribute name="event-session-object-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the event response code. Defaults to "_response_code_". + The name of the field containing the javax.servlet.http.HttpSession object. Defaults to "session". <br/><br/> Used when the simple method is invoked as an event, it is ignored otherwise. <br/><br/> @@ -453,10 +330,10 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="event-error-message-name"> + <xs:attribute name="event-response-code-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the event error message. Defaults to "_error_message_". + The name of the field containing the event response code. Defaults to "_response_code_". <br/><br/> Used when the simple method is invoked as an event, it is ignored otherwise. <br/><br/> @@ -464,10 +341,10 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="event-event-message-name"> + <xs:attribute name="event-error-message-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the event message. Defaults to "_event_message_". + The name of the field containing the event error message. Defaults to "_error_message_". <br/><br/> Used when the simple method is invoked as an event, it is ignored otherwise. <br/><br/> @@ -475,43 +352,43 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="service-response-message-name"> + <xs:attribute name="event-error-message-list-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the service response message. Defaults to "responseMessage". + The name of the field containing the event error message list. Defaults to "_error_message_list_". <br/><br/> - Used when the simple method is invoked as a service, it is ignored otherwise. + Used when the simple method is invoked as an event, it is ignored otherwise. <br/><br/> Optional. Attribute type: constant. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="service-error-message-name"> + <xs:attribute name="event-event-message-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the service error message. Defaults to "errorMessage". + The name of the field containing the event message. Defaults to "_event_message_". <br/><br/> - Used when the simple method is invoked as a service, it is ignored otherwise. + Used when the simple method is invoked as an event, it is ignored otherwise. <br/><br/> Optional. Attribute type: constant. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="service-error-message-list-name"> + <xs:attribute name="event-event-message-list-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the service error message list. Defaults to "errorMessageList". + The name of the field containing the event message list. Defaults to "_event_message_list_". <br/><br/> - Used when the simple method is invoked as a service, it is ignored otherwise. + Used when the simple method is invoked as an event, it is ignored otherwise. <br/><br/> Optional. Attribute type: constant. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="service-error-message-map-name"> + <xs:attribute name="service-response-message-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the service error message map. Defaults to "errorMessageMap". + The name of the field containing the service response message. Defaults to "responseMessage". <br/><br/> Used when the simple method is invoked as a service, it is ignored otherwise. <br/><br/> @@ -519,10 +396,10 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="service-success-message-name"> + <xs:attribute name="service-error-message-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the service success message. Defaults to "successMessage". + The name of the field containing the service error message. Defaults to "errorMessage". <br/><br/> Used when the simple method is invoked as a service, it is ignored otherwise. <br/><br/> @@ -530,10 +407,10 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="service-success-message-list-name"> + <xs:attribute name="service-error-message-list-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the field containing the service success message list. Defaults to "successMessageList". + The name of the field containing the service error message list. Defaults to "errorMessageList". <br/><br/> Used when the simple method is invoked as a service, it is ignored otherwise. <br/><br/> @@ -541,768 +418,642 @@ under the License. </xs:documentation> </xs:annotation> </xs:attribute> - </xs:complexType> - </xs:element> - <xs:element name="call-map-processor" substitutionGroup="CallOperations"> - <xs:annotation> - <xs:documentation> - The call-map-processor tag invokes a simple map processor from an existing map, creating a new map or adding to an existing one - if the named out-map already exists. Resulting messages are added to the named list, and a new list is created if a list with - the given name does not yet exist. All lists and maps exist in the same context and must have unique names. - <br/><br/> - An inline simple-map-processor can be used by putting a simple-map-processor tag under the call-map-processor tag. - If both an external and an inline map-processor are specified, the external - one will be called first, allowing the inline one to override its behavior. - </xs:documentation> - </xs:annotation> - <xs:complexType> - <xs:sequence> - <xs:element minOccurs="0" ref="simple-map-processor" /> - </xs:sequence> - <xs:attribute type="xs:string" name="processor-name"> + <xs:attribute name="service-error-message-map-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of the external map processor to execute in the specified xml-resource. - This is only required if an external map processor is desired. + The name of the field containing the service error message map. Defaults to "errorMessageMap". + <br/><br/> + Used when the simple method is invoked as a service, it is ignored otherwise. <br/><br/> Optional. Attribute type: constant. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="xml-resource"> + <xs:attribute name="service-success-message-name" type="xs:string"> <xs:annotation> <xs:documentation> - The full path and filename on the classpath of the XML file which contains an external map processor to execute. - This is only required if an external map processor is desired. + The name of the field containing the service success message. Defaults to "successMessage". + <br/><br/> + Used when the simple method is invoked as a service, it is ignored otherwise. <br/><br/> Optional. Attribute type: constant. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="in-map-name" use="required"> + <xs:attribute name="service-success-message-list-name" type="xs:string"> <xs:annotation> <xs:documentation> - The name of a map in the method environment to use as the input map. + The name of the field containing the service success message list. Defaults to "successMessageList". <br/><br/> - Required. Attribute type: expression. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="out-map-name" use="required"> - <xs:annotation> - <xs:documentation> - The name of a map in the method environment to use as the output map. - Will be created if it does not exist already. - If already exists will be added to in place. + Used when the simple method is invoked as a service, it is ignored otherwise. <br/><br/> - Required. Attribute type: expression. + Optional. Attribute type: constant. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute ref="error-list-name" /> </xs:complexType> </xs:element> - <xs:element name="set-service-fields" substitutionGroup="CallOperations"> + +<!-- + ================================= + ===== Assignment Operations ===== + ================================= +--> + + <xs:element name="add-error" substitutionGroup="ControlOperations"> <xs:annotation> <xs:documentation> - Copies elements from a source map that match a service's IN attributes to a target map. - If the target map does not exist, one will be created. + Adds an error message to an error message list. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="service-name" use="required"> + <xs:choice> + <xs:element ref="fail-message" /> + <xs:element ref="fail-property" /> + </xs:choice> + <xs:attribute ref="error-list-name"/> + </xs:complexType> + </xs:element> + + <xs:element name="assert" substitutionGroup="EnvOperations"> + <xs:annotation> + <xs:documentation> + Adds an error message to the error message list for each condition that evaluates to false. + </xs:documentation> + </xs:annotation> + <xs:complexType> + <xs:group maxOccurs="unbounded" ref="IfConditions" /> + <xs:attribute type="xs:string" name="title"> <xs:annotation> <xs:documentation> - The name of the service to get the IN attributes from. + The title of the assert operation. The title is used in test reports. <br/><br/> - Required. Attribute type: constant+expr. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="map" use="required"> - <xs:annotation> - <xs:documentation> - The map to copy the matching IN attributes from. - <br/><br/> - Required. Attribute type: expression. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="to-map" use="required"> - <xs:annotation> - <xs:documentation> - The map to copy the matching IN attributes to. - If the map does not exist, one will be created. - <br/><br/> - Required. Attribute type: expression. + Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> + <xs:attribute ref="error-list-name"/> </xs:complexType> </xs:element> - <xs:element name="call-service" substitutionGroup="CallOperations"> + + <xs:element name="check-id" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Invokes a service through the Service Engine. + Evaluates the specified field, and adds an error message to the error message list if the field's value is not a valid database ID value. + <br/><br/> + <![CDATA[Valid IDs can be any sequence of characters or digits but must not contain the following characters: + space [ ], double quote ["], single quote ['], ampersand [&], question mark [?], + less-than sign [<], greater-than sign [>], forward-slash [/], back-slash [\].]]> </xs:documentation> </xs:annotation> <xs:complexType> - <xs:sequence> - <xs:element minOccurs="0" ref="error-prefix" /> - <xs:element minOccurs="0" ref="error-suffix" /> - <xs:element minOccurs="0" ref="success-prefix" /> - <xs:element minOccurs="0" ref="success-suffix" /> - <xs:element minOccurs="0" ref="message-prefix" /> - <xs:element minOccurs="0" ref="message-suffix" /> - <xs:element minOccurs="0" ref="default-message" /> - <xs:choice minOccurs="0" maxOccurs="unbounded"> - <xs:element ref="results-to-map" /> - <xs:element ref="result-to-field" /> - <xs:element ref="result-to-request" /> - <xs:element ref="result-to-session" /> - <xs:element ref="result-to-result" /> - </xs:choice> - </xs:sequence> - <xs:attribute type="xs:string" name="service-name" use="required"> - <xs:annotation> - <xs:documentation> - Name of the service to call. - <br/><br/> - Required. Attribute type: constant, ${expression}. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="in-map-name"> - <xs:annotation> - <xs:documentation> - A map in the method environment to use as the input map. - If you're not going to pass any parameters to the service than you can just - omit the in-map attribute, although typically in a service element you will see - the in-map-name attribute included. - <br/><br/> - Optional. Attribute type: expression. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute name="include-user-login" type="booleanConst"> - <xs:annotation> - <xs:documentation> - Include the current UserLogin GenericValue in the called service IN attributes. - Defaults to "true". - <br/><br/> - Optional. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute name="break-on-error" type="booleanConst"> - <xs:annotation> - <xs:documentation> - Halt script execution if the called service returns an error. - Defaults to "true". - <br/><br/> - Optional. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="error-code"> - <xs:annotation> - <xs:documentation> - The error code returned by the called service. The error code is copied to the script result. - Defaults to the enclosing simple-method "default-error-code" attribute value. - <br/><br/> - Optional. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="success-code"> - <xs:annotation> - <xs:documentation> - The success code returned by the called service. The success code is copied to the script result. - Defaults to the enclosing simple-method "default-success-code" attribute value. - <br/><br/> - Optional. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute name="require-new-transaction" type="booleanConst"> - <xs:annotation> - <xs:documentation> - Require a new transaction for the called service. - Defaults to "false". - <br/><br/> - Optional. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="transaction-timeout"> + <xs:choice minOccurs="0"> + <xs:element ref="fail-message" /> + <xs:element ref="fail-property" /> + </xs:choice> + <xs:attribute type="xs:string" name="field" use="required"> <xs:annotation> <xs:documentation> - The timeout for the new transaction, in seconds. - Defaults to the value set in the service definition. + The name of the field that contains the ID value to check. <br/><br/> - Optional. Attribute type: constant. + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> + <xs:attribute ref="error-list-name" /> </xs:complexType> </xs:element> - <xs:element name="error-prefix"> - <xs:annotation> - <xs:documentation> - Specify a resource and a property to prepend to the error message. - </xs:documentation> - </xs:annotation> - <xs:complexType mixed="true"> - <xs:attributeGroup ref="attlist.propertyInfoOptional"/> - </xs:complexType> - </xs:element> - <xs:element name="error-suffix"> - <xs:annotation> - <xs:documentation> - Specify a resource and a property to append to the error message. - </xs:documentation> - </xs:annotation> - <xs:complexType mixed="true"> - <xs:attributeGroup ref="attlist.propertyInfoOptional"/> - </xs:complexType> - </xs:element> - <xs:element name="success-prefix"> - <xs:annotation> - <xs:documentation> - Specify a resource and a property to prepend to the success message. - </xs:documentation> - </xs:annotation> - <xs:complexType mixed="true"> - <xs:attributeGroup ref="attlist.propertyInfoOptional"/> - </xs:complexType> - </xs:element> - <xs:element name="success-suffix"> - <xs:annotation> - <xs:documentation> - Specify a resource and a property to append to the success message. - </xs:documentation> - </xs:annotation> - <xs:complexType mixed="true"> - <xs:attributeGroup ref="attlist.propertyInfoOptional"/> - </xs:complexType> - </xs:element> - <xs:element name="message-prefix"> + + <xs:element name="check-permission" substitutionGroup="IfOtherOperations"> <xs:annotation> <xs:documentation> - Specify a resource and a property to prepend to any kind of message. + Checks to see if the current user has the specified permission. + If the user does not have the specified permission or if there is no user associated with the context + then the failure message from fail-message or fail-property will be added to the + specified error list. + <br/><br/> + Note that this element must be followed by the check-errors element for it to do anything meaningful. </xs:documentation> </xs:annotation> - <xs:complexType mixed="true"> - <xs:attributeGroup ref="attlist.propertyInfoOptional"/> + <xs:complexType> + <xs:sequence> + <xs:element name="alt-permission" minOccurs="0" maxOccurs="unbounded"> + <xs:annotation> + <xs:documentation> + Declares an alternate permission. Alternate permissions are checked when the primary permission check fails. + </xs:documentation> + </xs:annotation> + <xs:complexType> + <xs:attributeGroup ref="attlist.check-permission" /> + </xs:complexType> + </xs:element> + <xs:choice> + <xs:element ref="fail-message" /> + <xs:element ref="fail-property" /> + </xs:choice> + </xs:sequence> + <xs:attributeGroup ref="attlist.check-permission" /> + <xs:attribute ref="error-list-name" /> </xs:complexType> </xs:element> - <xs:element name="message-suffix"> + + <xs:element name="clear-field" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Specify a resource and a property to append to any kind of message. + Sets the value of the specified field to null. </xs:documentation> </xs:annotation> - <xs:complexType mixed="true"> - <xs:attributeGroup ref="attlist.propertyInfoOptional"/> + <xs:complexType> + <xs:attribute ref="field" /> </xs:complexType> </xs:element> - <xs:element name="default-message"> + + <xs:element name="create-object" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Message that you can specify for the case where the service does not return a message. - You can just specify a default-message to use as if the service had returned that default-message. + Creates an instance of the specified class. + The string and field sub-elements are passed to the constructor method as arguments in the order they are specified. + A runtime exception will be thrown if the sub-elements do not match the constructor method arguments. + <br/><br/> + Deprecated - use the script element. </xs:documentation> </xs:annotation> - <xs:complexType mixed="true"> - <xs:attributeGroup ref="attlist.propertyInfoOptional"/> + <xs:complexType> + <xs:choice minOccurs="0" maxOccurs="unbounded"> + <xs:element ref="field" /> + <xs:element ref="string" /> + </xs:choice> + <xs:attribute ref="field" /> + <xs:attribute name="class-name" type="javaClassName" use="required"> + <xs:annotation> + <xs:documentation> + The name of the class to construct an instance of. + <br/><br/> + Required. Attribute type: constant. + </xs:documentation> + </xs:annotation> + </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="results-to-map"> + + <xs:element name="fail-message"> <xs:annotation> <xs:documentation> - Copies the called service result Map to the specified field. + Declares an error message. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="map-name" use="required"> + <xs:attribute type="xs:string" name="message" use="required"> <xs:annotation> <xs:documentation> - Name of the target field. + The error message text. <br/><br/> - Required. Attribute type: expression. + Required. Attribute type: constant+expr </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="result-to-field"> + + <xs:element name="fail-property"> <xs:annotation> <xs:documentation> - Copies the called service OUT attribute to the specified field. + Declares an error message found in a properties file. + Typically used for internationalized messages. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="result-name" use="required"> + <xs:attribute type="xs:string" name="resource" use="required"> <xs:annotation> <xs:documentation> - Name of the called service OUT attribute. + The name of a properties file on the classpath. <br/><br/> - Required. Attribute type: expression. + Required. Attribute type: constant </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="field"> + <xs:attribute type="xs:string" name="property" use="required"> <xs:annotation> <xs:documentation> - Name of target field. Defaults to the "result-name" attribute value. + The property key. <br/><br/> - Optional. Attribute type: expression. + Required. Attribute type: constant </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="result-to-request"> + + <xs:element name="field"> <xs:annotation> <xs:documentation> - Copies the called service OUT attribute to the specified request attribute. - Valid only when the script is run in an event. + Declares an environment field to be passed as an argument to an object method call. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="result-name" use="required"> + <xs:attribute type="xs:string" name="field" use="required"> <xs:annotation> <xs:documentation> - Name of the called service OUT attribute. + The name of the environment field to use. <br/><br/> Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="request-name"> + <xs:attribute ref="type"> <xs:annotation> <xs:documentation> - Name of the target request attribute. Defaults to the "result-name" attribute value. + The Java class of the argument. Defaults to "java.lang.String". + It should be the type specified in the method signature, not the type of the object being + passed in. <br/><br/> - Optional. Attribute type: expression. + Optional. Attribute type: constant. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="result-to-session"> + + <xs:element name="field-to-list" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Copies the called service OUT attribute to the specified session attribute. - Valid only when the script is run in an event. + Appends an object to the specified list. + <br/><br/> + Deprecated - use the set element. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="result-name" use="required"> + <xs:attribute type="xs:string" name="field" use="required"> <xs:annotation> <xs:documentation> - Name of the called service OUT attribute. + The field name of the object to append. The operation does nothing if the field does not exist. <br/><br/> Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="session-name"> + <xs:attribute type="xs:string" name="list" use="required"> <xs:annotation> <xs:documentation> - Name of the target session attribute. Defaults to the "result-name" attribute value. + The field name of the list that the object will be appended to. + If the list does not exist, one will be created. <br/><br/> - Optional. Attribute type: expression. + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="result-to-result"> + + <xs:element name="field-to-request" substitutionGroup="EventOperations"> <xs:annotation> <xs:documentation> - Copies service OUT attributes from a called service to the calling service's OUT attributes. - This element can also be used to copy the called service OUT attributes to the return result of - a simple-method called as a function. - <br/><br/> - Note that the attribute names are somewhat confusing: - "result-name" is the name of the OUT attribute of the called service, and - "service-result-name" is the name of the OUT attribute of the calling service. - In other words, copy the OUT attribute FROM "result-name" TO "service-result-name". + Copies a field to a servlet request attribute. + Valid only when the simple-method is called as an event, it is ignored otherwise. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="result-name" use="required"> + <xs:attribute type="xs:string" name="field" use="required"> <xs:annotation> <xs:documentation> - Name of the called service OUT attribute. + The name of the field to copy from. The source of the assignment. + The operation does nothing if the field does not exist. <br/><br/> Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="service-result-name"> + <xs:attribute type="xs:string" name="request-name"> <xs:annotation> <xs:documentation> - Name of the calling service OUT attribute (or function return result). - Defaults to the "result-name" attribute value. + The servlet request attribute name. The target of the assignment. + Defaults to the value of the field attribute. <br/><br/> - Optional. Attribute type: expression. + Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="call-service-asynch" substitutionGroup="CallOperations"> + + <xs:element name="field-to-result" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Calls a service asynchronously and ignores the result, so no return messages - are used; that doesn't mean no errors will result, but they would just be - system errors like database failures, etc. which all have system error messages. + Copies a field to a service OUT attribute. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="service-name" use="required"> + <xs:attribute type="xs:string" name="field" use="required"> <xs:annotation> <xs:documentation> - Name of the service to call. + The name of the field to copy from. The source of the assignment. + The operation does nothing if the field does not exist. <br/><br/> - Required. Attribute type: constant, ${expression}. + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="in-map-name"> + <xs:attribute type="xs:string" name="result-name"> <xs:annotation> <xs:documentation> - A map in the method environment to use as the input map. - If you're not going to pass any parameters to the service than you can just - omit the in-map attribute, although typically in a call-service-asynch element - you will see the in-map-name attribute included. + The name of the result field to set. The target of the assignment. + Defaults to the value of the field attribute. <br/><br/> Optional. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute name="include-user-login" type="booleanConst"> - <xs:annotation> - <xs:documentation> - Include the current UserLogin GenericValue in the called service IN attributes. - Defaults to "true". - <br/><br/> - Optional. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="script" substitutionGroup="CallOperations"> + + <xs:element name="field-to-session" substitutionGroup="EventOperations"> <xs:annotation> <xs:documentation> - Runs an external script or a short inline script (scriptlet). The scriptlet can be - included in the script attribute or in the element body. + Copies a field to a servlet session attribute. + Valid only when the simple-method is called as an event, it is ignored otherwise. </xs:documentation> </xs:annotation> - <xs:complexType mixed="true"> - <xs:attribute type="xs:string" name="location"> + <xs:complexType> + <xs:attribute type="xs:string" name="field" use="required"> <xs:annotation> <xs:documentation> - The script location. The location attribute accepts the component:// file location - protocol. Script functions/methods can be invoked by appending a hash (#) and the - function/method name. + The name of the field to copy from. The source of the assignment. + The operation does nothing if the field does not exist. <br/><br/> - Required if the script attribute is empty. Attribute type: constant. + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="script"> + <xs:attribute type="xs:string" name="session-name"> <xs:annotation> <xs:documentation> - A short script (scriptlet). Can be used instead of a file. - The script must be prefixed with the script language followed by a colon (":"). + The servlet session attribute name. The target of the assignment. + Defaults to the value of the field attribute. <br/><br/> - Required if the location attribute is empty. Attribute type: script. + Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="call-bsh" substitutionGroup="CallOperations"> + + <xs:element name="first-from-list" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Executes a BSH script. Deprecated - replace with script. + Assigns the first (lowest order) entry in a list to a field. + If the list does not exist or is empty, assigns null to a field. <br/><br/> - The script can be contained in a Java resource, or a short - script can be included in the element body. + Deprecated - use the set element. </xs:documentation> </xs:annotation> - <xs:complexType mixed="true"> - <xs:attribute type="xs:string" name="resource"> + <xs:complexType> + <xs:attribute type="xs:string" name="entry" use="required"> <xs:annotation> <xs:documentation> - A Java resource that contains the script. + The name of the field to set. The target of the assignment. <br/><br/> - Required if the element body is empty. Attribute type: constant. + Required. Attribute type: expression. + </xs:documentation> + </xs:annotation> + </xs:attribute> + <xs:attribute type="xs:string" name="list" use="required"> + <xs:annotation> + <xs:documentation> + The name of the list that contains the object to copy. + <br/><br/> + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="call-simple-method" substitutionGroup="CallOperations"> + + <xs:element name="list-to-list" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Calls another simple-method in the same context as the current one. - The called simple-method will have the same environment as the calling simple-method, - including all environment fields, and either the event or service objects - that the calling simple-method was called with. + Copy a list to another list. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:sequence> - <xs:element ref="result-to-field" minOccurs="0" maxOccurs="unbounded"> - <xs:annotation> - <xs:documentation> - Used when scope="function". Copies the called method fields - to the calling method fields. - </xs:documentation> - </xs:annotation> - </xs:element> - </xs:sequence> - <xs:attribute type="xs:string" name="method-name" use="required"> - <xs:annotation> - <xs:documentation> - The name of the simple-method to execute in the specified xml-resource, - or in the current XML file if no xml-resource is specified. - <br/><br/> - Required. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="xml-resource"> + <xs:attribute type="xs:string" name="list" use="required"> <xs:annotation> <xs:documentation> - The full path and filename on the classpath of the XML file which contains an external simple-method to execute. - This is only required if a simple-method in a different file is desired. + Name of the list to copy from. The operation does nothing if the list does not exist. <br/><br/> - Optional. Attribute type: constant. + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute name="scope"> + <xs:attribute type="xs:string" name="to-list" use="required"> <xs:annotation> <xs:documentation> - The memory scope to use. In an "inline" memory scope, fields declared or modified in the called method - will be reflected back to the calling method - as if the called method was inline. In a "function" memory - scope, fields declared or modified in the called method are local to the called method - they are not - reflected back to the calling method. + Name of the list to copy to. If the list does not exist, one will be created. <br/><br/> - Optional. Attribute type: constant. + Required. Attribute type: expression. </xs:documentation> </xs:annotation> - <xs:simpleType> - <xs:restriction base="xs:token"> - <xs:enumeration value="inline" /> - <xs:enumeration value="function" /> - </xs:restriction> - </xs:simpleType> </xs:attribute> </xs:complexType> </xs:element> - <!-- Operations to call Java methods and create Java objects --> - <xs:element name="call-object-method" substitutionGroup="CallOperations"> + + <xs:element name="map-to-map" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Calls a method on an existing Java object. Deprecated - replace with script. - <br/><br/> - The string and field sub-elements are passed to the method as arguments in the order they are specified. - If the method returns a value, the value will be put in the named field. + Copies a map to another map. + If a target map is not specified, the source map is copied to the current + environment (memory space). </xs:documentation> </xs:annotation> <xs:complexType> - <xs:choice minOccurs="0" maxOccurs="unbounded"> - <xs:element ref="string" /> - <xs:element ref="field" /> - </xs:choice> - <xs:attribute type="xs:string" name="obj-field" use="required"> - <xs:annotation> - <xs:documentation> - The name of the field the object is in that has the method to be called. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="method-name" use="required"> + <xs:attribute type="xs:string" name="map" use="required"> <xs:annotation> <xs:documentation> - The name of the method to call on the given object. + The name of the map to copy from. The operation does nothing if the map does not exist. + <br/><br/> + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="ret-field"> + <xs:attribute type="xs:string" name="to-map"> <xs:annotation> <xs:documentation> - The name of the field to put the result in. - If not specified any return value will be ignored. + The name of the map to copy to. If the target map does not exist, one will be created. + If this attribute is empty, the source map will be copied to the current environment. + <br/><br/> + Optional. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="call-class-method" substitutionGroup="CallOperations"> + + <xs:element name="now" substitutionGroup="OtherOperations"> <xs:annotation> <xs:documentation> - Calls a static method on a Java class. Deprecated - replace with script. - <br/><br/> - The string and field sub-elements are passed to the method as arguments in the order they are specified. - If the method returns a value, the value will be put in the named field. + Sets a field to the current system time. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:choice minOccurs="0" maxOccurs="unbounded"> - <xs:element ref="string"/> - <xs:element ref="field"/> - </xs:choice> - <xs:attribute type="xs:string" name="class-name" use="required"> - <xs:annotation> - <xs:documentation> - The name of the class to call the static method on. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="method-name" use="required"> - <xs:annotation> - <xs:documentation> - The name of the static method to call on the given class. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="ret-field"> + <xs:attribute ref="field" use="required" /> + <xs:attribute name="type"> <xs:annotation> <xs:documentation> - The name of the field to put the result in. If not specified any return value will be ignored. + The field data type. Defaults to "java.sql.Timestamp". + <br/><br/> + Optional. Attribute type: constant. </xs:documentation> </xs:annotation> + <xs:simpleType> + <xs:restriction base="xs:token"> + <xs:enumeration value="java.sql.Timestamp"/> + <xs:enumeration value="java.sql.Date" /> + <xs:enumeration value="java.sql.Time" /> + <xs:enumeration value="java.util.Date" /> + <xs:enumeration value="java.lang.Long" /> + </xs:restriction> + </xs:simpleType> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="create-object" substitutionGroup="EnvOperations"> + + <xs:element name="now-date-to-env" substitutionGroup="OtherOperations"> <xs:annotation> <xs:documentation> - Creates an object of the specified class. - The string and field sub-elements are passed to the constructor method as arguments in the order they are specified. - If the sub-elements do not match the constructor method arguments an error will be returned. - <br/><br/> - Deprecated - use the script element. + Sets a field to a java.sql.Date object initialized to the current system time. + Deprecated - use now. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:choice minOccurs="0" maxOccurs="unbounded"> - <xs:element ref="field" /> - <xs:element ref="string" /> - </xs:choice> - <xs:attribute type="xs:token" name="class-name" use="required"> - <xs:annotation> - <xs:documentation> - The name of the class to construct an instance of. - <br/><br/> - Required. Attribute type: constant. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute ref="field" /> + <xs:attribute ref="field" use="required" /> </xs:complexType> </xs:element> - <!-- Operations to copy map fields in the current env to context specific containers --> - <!-- Event specific operations --> - <xs:element name="field-to-request" substitutionGroup="EventOperations"> + + <xs:element name="now-timestamp" substitutionGroup="OtherOperations"> <xs:annotation> <xs:documentation> - Copies a field to the specified servlet request attribute. - Does nothing if the specified field does not exist. - Valid only when the simple-method is called as an event, it is ignored otherwise. + Sets a field to a java.sql.Timestamp object initialized to the current system time. + Deprecated - use now. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="field" use="required"> + <xs:attribute ref="field" use="required" /> + </xs:complexType> + </xs:element> + + <xs:element name="order-by"> + <xs:annotation> + <xs:documentation> + Declares a field or map key to sort on. + </xs:documentation> + </xs:annotation> + <xs:complexType> + <xs:attribute name="field-name" type="xs:string" use="required"> <xs:annotation> <xs:documentation> - The name of the field to copy. + The name of the field or map key to sort on. <br/><br/> Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="request-name"> + </xs:complexType> + </xs:element> + + <xs:element name="order-map-list" substitutionGroup="EnvOperations"> + <xs:annotation> + <xs:documentation> + Sorts a list of maps. Maps are sorted by the keys specified in the order-by sub-elements. + </xs:documentation> + </xs:annotation> + <xs:complexType> + <xs:sequence> + <xs:element maxOccurs="unbounded" ref="order-by" /> + </xs:sequence> + <xs:attribute type="xs:string" name="list" use="required"> <xs:annotation> <xs:documentation> - The servlet request attribute name. Defaults to the value of field attribute. + The name of the field containing the list to be sorted. The operation does nothing if the list is not found. <br/><br/> - Optional. Attribute types: constant, ${expression}. + Required. Attribute type: expression. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="field-to-session" substitutionGroup="EventOperations"> + + <xs:element name="property-to-field" substitutionGroup="OtherOperations"> <xs:annotation> <xs:documentation> - Copies a field to the specified servlet session attribute. - Does nothing if the specified field does not exist. - Valid only when the simple-method is called as an event, it is ignored otherwise. + Assigns a resource property value to a field. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute type="xs:string" name="field" use="required"> + <xs:attribute ref="field" /> + <xs:attribute type="xs:string" name="resource" use="required"> <xs:annotation> <xs:documentation> - The name of the field to copy. + The name of a properties resource. Can be a file on the classpath or + a resource defined in the SystemProperty entity. <br/><br/> - Required. Attribute type: expression. + Required. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="session-name"> + <xs:attribute type="xs:string" name="property" use="required"> <xs:annotation> <xs:documentation> - The servlet session attribute name. Defaults to the value of field attribute. + The property key. <br/><br/> - Optional. Attribute types: constant, ${expression}. + Required. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> - </xs:complexType> - </xs:element> - <xs:element name="request-to-field" substitutionGroup="EventOperations"> - <xs:annotation> - <xs:documentation> - Copies a servlet request attribute to a field. - Valid only when the simple-method is called as an event, it is ignored otherwise. - </xs:documentation> - </xs:annotation> - <xs:complexType> - <xs:attribute ref="field" /> - <xs:attribute type="xs:string" name="request-name"> + <xs:attribute type="xs:string" name="default"> <xs:annotation> <xs:documentation> - The servlet request attribute name. Defaults to the value of field attribute. + The default value to use if the specified property value is null or empty. <br/><br/> Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> - <xs:attribute type="xs:string" name="default"> + <xs:attribute type="booleanConst" name="no-locale"> <xs:annotation> <xs:documentation> - A default value to use if the request attribute does not exist. + Suppress property value localization. The user's/system locale will be ignored + when retriving the property value. + Defaults to "false". <br/><br/> - Optional. Attribute types: constant, ${expression}. + Optional. Attribute type: constant. + </xs:documentation> + </xs:annotation> + </xs:attribute> + <xs:attribute type="xs:string" name="arg-list"> + <xs:annotation> + <xs:documentation> + The name of an argument list to be used with a formatting string. + The argument list is applied to the property value. + The attribute does nothing if the argument list is not found. + See the java.text.MessageFormat class for more information. + <br/><br/> + Optional. Attribute type: expression. + </xs:documentation> + </xs:annotation> + </xs:attribute> + <xs:attribute type="xs:string" name="arg-list-name"> + <xs:annotation> + <xs:documentation> + Deprecated - use the arg-list attribute. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> + <xs:element name="request-parameters-to-list" substitutionGroup="EventOperations"> <xs:annotation> <xs:documentation> - Appends a servlet request parameter list to a list. If the target list does not exist, one will be created. + Appends a servlet request parameter list to a list. Valid only when the simple-method is called as an event, it is ignored otherwise. </xs:documentation> </xs:annotation> @@ -1310,7 +1061,7 @@ under the License. <xs:attribute type="xs:string" name="request-name" use="required"> <xs:annotation> <xs:documentation> - The servlet request parameter name. + The servlet request parameter name. All matching parameter values will be added to the list. <br/><br/> Required. Attribute types: constant, ${expression}. </xs:documentation> @@ -1319,7 +1070,8 @@ under the License. <xs:attribute type="xs:string" name="list"> <xs:annotation> <xs:documentation> - The name of the field containing the list. Defaults to the request-name attribute value. + The name of the field containing the list. If the list does not exist, one will be created. + Defaults to the request-name attribute value. <br/><br/> Optional. Attribute type: expression. </xs:documentation> @@ -1334,7 +1086,8 @@ under the License. </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="session-to-field" substitutionGroup="EventOperations"> + + <xs:element name="request-to-field" substitutionGroup="EventOperations"> <xs:annotation> <xs:documentation> Copies a servlet request attribute to a field. @@ -1343,10 +1096,10 @@ under the License. </xs:annotation> <xs:complexType> <xs:attribute ref="field" /> - <xs:attribute type="xs:string" name="session-name"> + <xs:attribute type="xs:string" name="request-name"> <xs:annotation> <xs:documentation> - The servlet session attribute name. Defaults to the value of field attribute. + The servlet request attribute name. Defaults to the value of field attribute. <br/><br/> Optional. Attribute types: constant, ${expression}. </xs:documentation> @@ -1363,208 +1116,139 @@ under the License. </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="webapp-property-to-field" substitutionGroup="EventOperations"> + + <xs:element name="session-to-field" substitutionGroup="EventOperations"> <xs:annotation> <xs:documentation> - The webapp-property-to-field tag copies a property value from a properties file in a ServletContext resource to a field. - Valid only when the simple-method is called as an event, it is ignored otherwise. + Copies a servlet session attribute to a field. + Valid only when the simple-method is called as an HTTP event, it is ignored otherwise. </xs:documentation> </xs:annotation> <xs:complexType> <xs:attribute ref="field" /> - <xs:attribute type="xs:string" name="resource" use="required"> - <xs:annotation> - <xs:documentation> - 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". - <br/><br/> - Required. Attribute types: constant, ${expression}. - </xs:documentation> - </xs:annotation> - </xs:attribute> - <xs:attribute type="xs:string" name="property" use="required"> + <xs:attribute type="xs:string" name="session-name"> <xs:annotation> <xs:documentation> - The property whose value will be put in the field. + The servlet session attribute name. Defaults to the value of the field attribute. <br/><br/> - Required. Attribute types: constant, ${expression}. + Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> <xs:attribute type="xs:string" name="default"> <xs:annotation> <xs:documentation> - A default value to use if the property value is null or empty. + A default value to use if the request attribute does not exist. <br/><br/> - Required. Attribute types: constant, ${expression}. + Optional. Attribute types: constant, ${expression}. </xs:documentation> </xs:annotation> </xs:attribute> </xs:complexType> </xs:element> - <xs:element name="field-to-result" substitutionGroup="EnvOperations"> + + <xs:element name="set" substitutionGroup="EnvOperations"> <xs:annotation> <xs:documentation> - Copies a field to a service OUT attribute. + Assigns a field from an expression or script, or from a constant value. Also supports a default value and type conversion. </xs:documentation> </xs:annotation> <xs:complexType> - <xs:attribute name="field" use="required"> + <xs:attribute ref="field" use="required" /> + <xs:attribute type="xs:string" name="from"> <xs:annotation> <xs:documentation> - The name of the field to copy from. The source of the assignment. + An expression or script that returns an object or null. The source of the assignment. <br/><br/> - Required. Attribute type: expression. + A script must be prefixed with the script language followed by a colon (":"). + <br/><br/> + Required if the value attribute is empty. Attribute types: expression, script. </xs:documentation> </xs:annotation> - <xs:simpleType> - <xs:restriction base="xs:string"> - <xs:minLength value="1" /> - </xs:restriction> - </xs:simpleType> </xs:attribute> - <xs:attribute name="result-name"> + <xs:attribute type="xs:string" name="from-field"> <xs:annotation> <xs:documentation> - The name of the result field to set. The target of the assignment. - <br/><br/> - Optional. Attribute type: expression. + Deprecated - use the from attribute. </xs:documentation> </xs:annotation> - <xs:simpleType> - <xs:restriction base="xs:string"> - <xs:minLength value="1" /> - </xs:restriction> - </xs:simpleType> [... 5541 lines stripped ...] |
| Free forum by Nabble | Edit this page |
