Avaya Writing Technician Interface Scripts Manual do Utilizador Página 50

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 116
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 49
Writing Technician Interface Scripts
2-20
308660-14.00 Rev 00
The let command provides the following string functions:
strlen( )
strindex( )
strrindex( )
strpbrk( )
•strmatch( )
<single_character>
The arguments for each function can be a literal character string, a set of
characters enclosed in double quotes (“”), or the name of an environment variable.
When you specify an environment variable, do not precede the name with
$.
If a function returns an offset within a string, an index of 1 refers to the first
character position.
The function
strlen( ) returns the number of characters in the parameter
<string>
.
strlen(
<string>
)
The function strindex( ) finds the first occurrence of a string in another string. The
function
strrindex( ) finds the last occurrence of a string in another string. Both
functions return the offset within
<string>
of
<substring>
s position, or 0 if
<
substring
> is not found.
strindex(
<string>
,
<substring>
)
strrindex(
<string>
,
<substring>
)
The function strpbrk( ) searches
<string>
for the first character that matches any
of the characters given in the character string
<set>
. The function returns the
offset to the first matching character’s position in
<string>
, or 0 if no character of
<set>
appears in
<string>
.
strpbrk(
<string>, <set>
)
The function
strmatch(
<string>
,
<pattern>
) compares
<string>
to
<pattern>
. If
<string>
matches the pattern, the function returns a 1; otherwise it returns a 0. You
may use wildcards (
* or ?) in
<pattern>
. A * matches any character (or no
character), and a
? matches any character in that position in the string. A character
must exist in that position for
? to match.
strmatch(
<string>
,
<pattern>
)
Vista de página 49
1 2 ... 45 46 47 48 49 50 51 52 53 54 55 ... 115 116

Comentários a estes Manuais

Sem comentários