HP P4518A - Traffic Management Server Sa7150 User Manual page 35

Hp e-commerce/xml server accelerator sa7150 - user guide
Hide thumbs Also See for P4518A - Traffic Management Server Sa7150:
Table of Contents

Advertisement

C H A P T E R 3
Function
starts-with(value,
substring)
contains(value,
substring)
translate(value,
fromString,
toString)
Sample Pattern
//Order[starts-with
(PartNumber, "001")]
//Part[contains
(@PartNumber, '12345')]
//Part[contains(translate
(@Description,'abcdefg
hijklmnopqrstuvwxyz',
'ABCDEFGHIJKLMNOP
QRSTUVWXYZ'),
'ENGINE')]
XML Operations
required arguments. Wrong numbers of arguments or arguments not
of the required type result in errors. The result of the FunctionCall
expression is the result returned by the function.
Description
The starts-with function tests whether the string value of value starts the
specified substring. value can be either an element, attribute, or function
call that returns a string value. substring must be a literal value enclosed
in single or double quotes.
The contains function tests whether value contains the specified
substring. value can be either an element, attribute, or function call that
returns a string value. substring must be a literal value enclosed in single
or double quotes.
The translate function replaces characters in the value string if they
appear in the fromString with the corresponding characters in the
toString. If a character appears in fromString but not in the corresponding
position in toString, the character will be dropped from the value string.
The result string is returned. value can be either an element, attribute, or
function call that returns a string value. Both fromString and toString
have to be a literal value enclosed in single or double quotes.
Function Calls
.
Description
Matches if there is an Order element with a value of a PartNumber
child element starting with "001."
Matches if there is a Part element with the value of a PartNumber
attribute containing "12345."
Matches if there is a Part element with the value of a Description
attribute containing "ENGINE." All characters in the Description
attribute are converted to uppercase before being passed to the
contains function.
Function Call Examples
25

Advertisement

Table of Contents
loading

This manual is also suitable for:

Sa7150

Table of Contents