Secondary Commands; Table 8-19 Secondary Commands - Lantronix SLC 8000 User Manual

Advanced console manager
Hide thumbs Also See for SLC 8000:
Table of Contents

Advertisement

Secondary Commands

These are commands which provide data or other support to the Primary commands. These
commands are never used by themselves in a script. The preprocessor will require that these
commands always follow a left square bracket ('[') character and be followed on a single line by a
right bracket (']').
Command
string
SLC™ 8000 Advanced Console Manager User Guide

Table 8-19 Secondary Commands

Description
The
command provides a series of string manipulation operations. The
string
command will only be used with the
string
for a variable. There are nine operations provided by the
Syntax (varies by operation):
string compare <str 1> <str 2>
Compare two strings
string match <str 1> <str 2>
Determine if two strings are equal
string first <str needle> <str haystack>
Find and return the index of the first occurrence
of 'str_needle' in 'str_haystack'
string last <str needle> <str haystack>
Find and return the index of the last occurrence of
'str_needle' in 'str_haystack'
string length <str>
Return the length of 'str'
string index <str> <int>
Return the character located at position 'int' in
'str'
string range <str> <int start> <int end>
Return a string consisting of the characters in
'str' between 'int start' and 'int end'
string tolower <str>
Convert <str> to lowercase
string toupper <str>
Convert <str> to uppercase
string trim <str 1> <str 2>
Trim 'str 2' from 'str 1'
string trimleft <str 1> <str 2>
Trim 'str 2' from the beginning of 'str 1'
string trimright <str 1> <str 2>
Trim 'str 2' from the end of 'str 1'
In each of the above operations, each <str *> element can either be a quoted string
or a variable reference. The <int *> elements will be either words or variable
references.
8: Device Ports
to generate a value
set command
command.
string
168

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the SLC 8000 and is the answer not in the manual?

Questions and answers

Table of Contents