Visara Master Console Center Scripting Guide Manuel d'utilisateur

Naviguer en ligne ou télécharger Manuel d'utilisateur pour Accessoires pour ordinateurs Visara Master Console Center Scripting Guide. Visara Master Console Center Scripting Guide User Manual Manuel d'utilisatio

  • Télécharger
  • Ajouter à mon manuel
  • Imprimer
  • Page
    / 262
  • Table des matières
  • MARQUE LIVRES
  • Noté. / 5. Basé sur avis des utilisateurs

Résumé du contenu

Page 1 - Scripting Guide

VisaraMaster Console CenterScripting GuideP/N 707131-001

Page 2 - Notices

About This Guide Scripting Guide 10 The MCC Documentation Set In addition to this manual, you may need to refer to other manuals in the MCC docume

Page 3 - Contents

Chapter 5 Script Commands Scripting Guide 100 Manifest Constant Value Associated String/Reason ICLErr_Mvs_InvMsgCnt 4020 Invalid message count

Page 4 - Scripting Guide 4

Chapter 5 Script Commands Scripting Guide 101 EXEC Syntax: EXEC( $ScriptName[, Parm1, ...]) ==> ReturnValue Description: Executes a script who

Page 5 - Scripting Guide 5

Chapter 5 Script Commands Scripting Guide 102 $ScriptName := “script1” ELSE $ScriptName := “script2” ENDIF %ReturnValue := EXEC( $ScriptName,

Page 6 - Scripting Guide 6

Chapter 5 Script Commands Scripting Guide 103 FCLOSE Syntax: FCLOSE( %FileNum) Description: Closes an open file. Action: Closes a file opened wit

Page 7 - Scripting Guide 7

Chapter 5 Script Commands Scripting Guide 104 FDELETE Syntax: FDELETE( $FileName) ==> %Success Description: Permanently deletes a file. Action

Page 8

Chapter 5 Script Commands Scripting Guide 105 FEXISTS Syntax: FEXISTS( $FileName) ==> %Success Description: Determines if a file exists. Actio

Page 9 - About This Guide

Chapter 5 Script Commands Scripting Guide 106 FILENO Syntax FILENO(%FileHandle) ==> %FileDescriptor Description: Obtains the system integer fil

Page 10 - The MCC Documentation Set

Chapter 5 Script Commands Scripting Guide 107 FINDSTR Syntax: FINDSTR( $String, $Substring) ==> $FoundText Description: Searches a string for

Page 11 - Chapter 1 Script Overview

Chapter 5 Script Commands Scripting Guide 108 FMODTIME Syntax: FMODTIME( File) ==> %EpochSeconds Description: Returns the time value of a last

Page 12 - Script Concepts

Chapter 5 Script Commands Scripting Guide 109 FOPEN Syntax: FOPEN( $FileName[, %Mode]) ==> %FileHandle Description: Opens a file for I/O acces

Page 13 - Script Source Structure

Scripting Guide 11 Chapter 1 Script Overview This chapter describes:  Script concepts  Script structures  Master scripts  Reserved scripts 

Page 14 - Master Scripts

Chapter 5 Script Commands Scripting Guide 110 Example: %Handle := FOPEN( “SYS5”, OVERWRITE) $FileName := “SYS5” %Mode := APPEND %Handle := FOPEN(

Page 15 - Reserved Scripts

Chapter 5 Script Commands Scripting Guide 111 FORMATSTR Syntax: FORMATSTR( $String [, expr1, [expr2, ..., [exprn]..]]) ==> $Formatted Descript

Page 16 - #logswap.scr

Chapter 5 Script Commands Scripting Guide 112 $Return := FORMATSTR( "The value is: %10d.", %Value2 ) LOG( LOG_EXEC, $Return, 12 ) OU

Page 17 - #shutdn.scr

Chapter 5 Script Commands Scripting Guide 113 Conversion Specifications Syntax Each conversion specification in the String parameter has the follo

Page 18 - Executing Scripts

Chapter 5 Script Commands Scripting Guide 114 A field width can be indicated by an * (asterisk) instead of a digit string. In this case, an integ

Page 19 - Scripting Guide 19

Chapter 5 Script Commands Scripting Guide 115 x, X Accepts an integer value and converts it to unsigned hexadecimal notation. The letters abcdef

Page 20

Chapter 5 Script Commands Scripting Guide 116 FPOS Syntax: FPOS( %FileNum) ==> %Position Description: Returns an open file’s current record po

Page 21 - Chapter 2 Advanced Topics

Chapter 5 Script Commands Scripting Guide 117 FREAD Syntax: FREAD( %FileNum, var1[, var2, ..., [varn]...]) ==> %QtyRead Description: Reads val

Page 22 - Script Writing Guidelines

Chapter 5 Script Commands Scripting Guide 118 FRENAME Syntax: FRENAME( $CurrentName, $NewName) ==> %Success Description: Renames a file. Actio

Page 23 - Scripting Guide 23

Chapter 5 Script Commands Scripting Guide 119 FREWIND Syntax: FREWIND( %FileNum) Description: Moves an open file’s current record pointer to the

Page 24 - MCC Concepts

Chapter 1 Script Overview Scripting Guide 12 Overview The Master Console Center Global Control Language (MCC GCL) is a powerful high-level program

Page 25 - Object Key

Chapter 5 Script Commands Scripting Guide 120 FSEEK Syntax: FSEEK( %FileNum, %Position) ==> %Success Description: Moves an open file’s current

Page 26 - Object Field

Chapter 5 Script Commands Scripting Guide 121 FWRITE Syntax: FWRITE( %FileNum, expr [, %NEWLINE] ) ==> %Success Description: Writes the expres

Page 27 - Object Action

Chapter 5 Script Commands Scripting Guide 122 GETENV Syntax: GETENV($Variable) ==> $Value Description: Obtains the current value of the given e

Page 28

Chapter 5 Script Commands Scripting Guide 123 GETPID Syntax: GETPID() ==> %ProcessId Description: Obtains the system process identifier for thi

Page 29 - Icon Class/Icon Name

Chapter 5 Script Commands Scripting Guide 124 GOSUB Syntax: GOSUB *Label Description: Immediately transfers script execution to the specified lab

Page 30 - Scripting Guide 30

Chapter 5 Script Commands Scripting Guide 125 GOTO Syntax: GOTO *Label Description: Immediately transfers script execution to the specified label

Page 31 - MIB OID

Chapter 5 Script Commands Scripting Guide 126 HEXSTR Syntax: HEXSTR( %Number) ==> $Hex Description: Converts an integer to a hex string. Actio

Page 32

Chapter 5 Script Commands Scripting Guide 127 HMCEXEC Syntax: HMCEXEC(%ObjID, $Action [, parm1, ...]) => %RetVal Description: Send a command t

Page 33 - Chapter 3 Script Syntax

Chapter 5 Script Commands Scripting Guide 128 Possible HMC actions and parameters CPC and Image Commands Action Description Optional Parameter(s

Page 34 - Structuring a Script

Chapter 5 Script Commands Scripting Guide 129 HUMID Syntax: HUMID( %Port) ==> %Humidity Description: Reads the current humidity from a sensor

Page 35 - − “scr” for script source

Chapter 1 Script Overview Scripting Guide 13 A script source file format is a standard ASCII file—it can be written anywhere and copied to the MCC

Page 36 - Variables

Chapter 5 Script Commands Scripting Guide 130 ICON Syntax: ICON( %Status[, $Message [, %Class [, $Name]]]) Description: Changes icon characterist

Page 37 - Numeric Variables

Chapter 5 Script Commands Scripting Guide 131 Notes: 1. Refer to Manifest Constants on page 42 for the constants reference list. 2. The defaul

Page 38 - Using and Naming Arrays

Chapter 5 Script Commands Scripting Guide 132 ICONMSG Syntax: ICONMSG( [%Class [, $Name]]) ==> $Message Description: Returns an icon’s current

Page 39 - Associative Arrays

Chapter 5 Script Commands Scripting Guide 133 ICONNAME Syntax: ICONNAME( [%Class [, %Port]]) ==> $Name Description: Returns an icon’s name. Ac

Page 40 - Date/Time

Chapter 5 Script Commands Scripting Guide 134 ICONSTATUS Syntax: ICONSTATUS( [%Class [, $Name]]) ==> %Status Description: Returns an icon’s cu

Page 41 - Expressions

Chapter 5 Script Commands Scripting Guide 135 IF Syntax: IF...[ELSE...]ENDIF IF Expression Group 1 command [More group 1 commands] [ELSE]

Page 42

Chapter 5 Script Commands Scripting Guide 136 INC Syntax: INC %Variable Description: Adds one to a numeric variable’s value. Action: The value in

Page 43 - Manifest Error Constants

Chapter 5 Script Commands Scripting Guide 137 JOIN Syntax: JOIN( $Array, $Delimiter) ==> $String Description: Combines the elements of an arra

Page 44

Chapter 5 Script Commands Scripting Guide 138 KEY Syntax: KEY( %Port, $Keys [,%Timeout]) ==> %RetCode Description: Enters a character string t

Page 45

Chapter 5 Script Commands Scripting Guide 139 a command being processed, and a console that has failed or hung. 5. The KEY command processing als

Page 46

Chapter 1 Script Overview Scripting Guide 14 Naming Scripts Each script must be given a unique name before it is saved and compiled. Note: The sc

Page 47 - Other Manifest Constants

Chapter 5 Script Commands Scripting Guide 140 KEY Command Return Values Manifest Constant Value Description Err_None 0 No error Err_Key_Timelock

Page 48

Chapter 5 Script Commands Scripting Guide 141 KEY Command Specifics Note: The KEY command is not case sensitive. Characters within brackets ([ o

Page 49

Chapter 5 Script Commands Scripting Guide 142 Keyboard Key Key Command INS (^a) or INSERT [INS] or [INSERT] IRPT [IPT] or [IRPT] ISTEP EOF [IS

Page 50 - Operators

Chapter 5 Script Commands Scripting Guide 143 LEFTSTR Syntax: LEFTSTR( $String, %Count) ==> $SubStr Description: Returns the leftmost specifie

Page 51 - Comment Statements

Chapter 5 Script Commands Scripting Guide 144 LEN Syntax: LEN( $StringExpr) ==> %Count Description: Returns the number of characters in a stri

Page 52 - Label Statements

Chapter 5 Script Commands Scripting Guide 145 LOG Syntax: LOG( %LogType, $Message[, %Status]) Description: Enters a message in a log. Action: The

Page 53 - Scripting Guide 53

Chapter 5 Script Commands Scripting Guide 146 LOWER Syntax: LOWER( $String) ==> $Lowercase Description: Converts uppercase characters to lower

Page 54 - Regular Expressions

Chapter 5 Script Commands Scripting Guide 147 MKDTEMP Syntax: MKDTEMP($Pattern) ==> $DirectoryName Description: Creates a unique temporary dire

Page 55 - Subexpressions

Chapter 5 Script Commands Scripting Guide 148 MKSTEMP Syntax: MKSTEMP($Pattern) ==> %FileHandle Description: Opens a unique temporary file for

Page 56 - Scripting Guide 56

Chapter 5 Script Commands Scripting Guide 149 MKTEMP Syntax: MKTEMP($Pattern) ==> $FileName Description: Returns a unique file name. Action: Cr

Page 57 - Bracket Expressions

Chapter 1 Script Overview Scripting Guide 15 Reserved Scripts Every MCC system includes a set of reserved scripts. Reserved scripts automatically

Page 58

Chapter 5 Script Commands Scripting Guide 150 MONIKER Syntax: MONIKER() ==> $Name Description: Obtains the product name. Action: Returns the pr

Page 59

Chapter 5 Script Commands Scripting Guide 151 OBJEXEC Syntax: OBJEXEC( %ObjID, $Action[, Parms...]) ==> %ReturnValue Description: Executes an

Page 60 - Description

Chapter 5 Script Commands Scripting Guide 152 OBJGET Syntax: OBJGET( %ObjID, $ObjFieldName) ==> $CurrentValue Description: Returns the current

Page 61 - Scripting Guide 61

Chapter 5 Script Commands Scripting Guide 153 OBJGETARRAY Syntax: OBJGETARRAY( %ObjID, $AssocArray) ==> %ErrCode Description: Populates an ass

Page 62 - Alternation

Chapter 5 Script Commands Scripting Guide 154 OBJID Syntax: OBJID( %Class, $ObjKeyExpr) ==> %ObjectID Description: Returns the ID (unique only

Page 63 - Order Type Symbols

Chapter 5 Script Commands Scripting Guide 155 //This example builds an array of ObjIDs, for use // with the QOPEN command. $Lpar1 := “9672-1:BETA

Page 64 - Character Description

Chapter 5 Script Commands Scripting Guide 156 OBJIDARRAY Syntax: OBJIDARRAY( %Class, %ObjIDParent, %AssocArray) ==> %Children Description: Pop

Page 65 - Collating Elements

Chapter 5 Script Commands Scripting Guide 157 LOG(LOG_EXEC, $aKidIDs[%Count] + “Object ID is: “ + / %aaKidIDs[$aKidIDs[%Count]], 1) INC %Count

Page 66

Chapter 5 Script Commands Scripting Guide 158 OBJSET Syntax: OBJSET( %ObjID, $ObjFieldName, $NewValue) ==> %ErrCode Description: Sets the curr

Page 67 - Chapter 5 Script Commands

Chapter 5 Script Commands Scripting Guide 159 OBJSETARRAY Syntax: OBJSETARRAY( %ObjID, $AssocArray) ==> %Success Description: Sets the field va

Page 68 - Script Command Types

Chapter 1 Script Overview Scripting Guide 16 Status Change Reserved Script Name Executed in Response MCC is started (this event is not a login)

Page 69 - AICONNAMES

Chapter 5 Script Commands Scripting Guide 160 RETURN OUTPUT: Current Status is: UNKNOWN Desired Status is: UNKNOWN Group Status is: NONE Current

Page 70

Chapter 5 Script Commands Scripting Guide 161 PARMS Syntax: PARMS var1[, var2 [, var3, ..., [varn]...]]] Description: Receives parameters into th

Page 71 - ALERTCREATE

Chapter 5 Script Commands Scripting Guide 162 PORT Syntax: PORT( %Class[, $IconName]) ==> %Port Description: Returns the port number for a con

Page 72 - ALERTDEL

Chapter 5 Script Commands Scripting Guide 163 QCLOSE Syntax: QCLOSE( %QueueID) Description: Closes a message queue. Action: Closes the specified

Page 73 - ALERTGETACTIVE

Chapter 5 Script Commands Scripting Guide 164 QOPEN Syntax: QOPEN( [%ObjIdArray]) ==> %QueueID Description: Opens a new queue of OS printer co

Page 74

Chapter 5 Script Commands Scripting Guide 165 commands does not function with an OS that uses an RS232 or Telnet connection with the no_printer fl

Page 75

Chapter 5 Script Commands Scripting Guide 166 QPREVIEW Syntax: QPREVIEW( %QueueID, $ResultArray) ==> %RetCode Description: For non-mainframe p

Page 76 - ALERTMOD

Chapter 5 Script Commands Scripting Guide 167 console, you may wish to key “exit” before issuing your QPREVIEW().) Example: // Get the Object IDs

Page 77

Chapter 5 Script Commands Scripting Guide 168 QREAD Syntax: QREAD( %QueueID, $MsgArray, %Wait[, $Filter]) ==> $MsgLine Description: Reads the

Page 78

Chapter 5 Script Commands Scripting Guide 169 the printer message queue. It is placed in the printer message queue after the user presses <ENT

Page 79

Chapter 1 Script Overview Scripting Guide 17  Parm 3. The name of the backup log. (A string.) The default #LOGSWAP.SCR script shipped with the

Page 80

Chapter 5 Script Commands Scripting Guide 170 QSKIP Syntax: QSKIP( %QueueID, %Skip) Description: Moves a current message pointer for a queue. Act

Page 81 - ASSOCKEYS

Chapter 5 Script Commands Scripting Guide 171 REPEAT Syntax: REPEAT...UNTIL REPEAT Commands UNTIL Expression Description: Repeats a sequence

Page 82

Chapter 5 Script Commands Scripting Guide 172 REPSTR Syntax: REPSTR( $String, %Count) ==> $RepeatedString Description: Returns a string repeat

Page 83 - BASEDIRECTORY

Chapter 5 Script Commands Scripting Guide 173 RETURN Syntax: RETURN [Expression] Description: Returns execution to the calling routine, passing a

Page 84 - BLOCKSCAN

Chapter 5 Script Commands Scripting Guide 174 RIGHTSTR Syntax: RIGHTSTR( $String, %Count) ==> $SubStr Description: Returns the right-most spec

Page 85

Chapter 5 Script Commands Scripting Guide 175 SCANB Syntax: SCANB( %Port, $Text, *Found) Description: Searches an OS console for a specified char

Page 86

Chapter 5 Script Commands Scripting Guide 176 SCANP Syntax: SCANP( %Port, $Text, %Wait, *Found[, $Array]) Description: Searches an OS console for

Page 87 - CLASSNAME

Chapter 5 Script Commands Scripting Guide 177 SCRIPTCANCEL Syntax: SCRIPTCANCEL($ScriptName,$Class,$Name) Description: Obtains the system integer

Page 88 - CLASSNUM

Chapter 5 Script Commands Scripting Guide 178 SCRIPTGETACTIVE Syntax: SCRIPTGETACTIVE($AssocArray) ==> %ErrCode Description: Retrieves informat

Page 89 - CPUPOWER

Chapter 5 Script Commands Scripting Guide 179 current WAIT command $ScriptInfo[6] 0 Number of seconds which remain for the current WAIT comman

Page 90

Chapter 1 Script Overview Scripting Guide 18 Executing Scripts There are four ways to execute a script:  Manually. A user selects a script for

Page 91

Chapter 5 Script Commands Scripting Guide 180 Examples: Simple Script to log all of the script information to the filtered message log: %rc := SC

Page 92

Chapter 5 Script Commands Scripting Guide 181 SCRNTEXT Syntax: SCRNTEXT( %Port, %Start, %Length) ==> $Text Description: A full or partial scr

Page 93

Chapter 5 Script Commands Scripting Guide 182 SECONDS Syntax: SECONDS() ==> %EpochSeconds Description: Returns the time value for the current

Page 94

Chapter 5 Script Commands Scripting Guide 183 SET Syntax: SET Variable := Expression Description: Make the contents of a variable equal to the sp

Page 95

Chapter 5 Script Commands Scripting Guide 184 SNMP_GET Syntax: SNMP_GET( $Alias, $MIBOID) ==> $Value Description: Retrieves the value of a spe

Page 96

Chapter 5 Script Commands Scripting Guide 185 SNMP_GETNEXT Syntax: SNMP_GETNEXT( $Alias, $MIBOID, $NextMIBOID) ==> $Value Description: Retriev

Page 97 - ERRORMSG

Chapter 5 Script Commands Scripting Guide 186 SNMP_GETTABLE Syntax: SNMP_GETTABLE( $Alias, $MIBOID, $TableArray[, $Delimiter]) ==> %ReturnCode

Page 98 - ERRORNUM

Chapter 5 Script Commands Scripting Guide 187 Example: // gets the table at “interfaces” from the named host // alias $Alias := “Galileo” $MIBOI

Page 99

Chapter 5 Script Commands Scripting Guide 188 SNMP_SET Syntax: SNMP_SET( $Alias, $MIBOID, $Value) ==> %ReturnCode Description: Sets the value

Page 100

Chapter 5 Script Commands Scripting Guide 189 SNMP_TRAPSEND Syntax: SNMP_TRAPSEND( $Alias, %TrapNum[, %EntNum [, $MIBOID ] [, $VARBINDS]]) ==>

Page 101

Chapter 1 Script Overview Scripting Guide 19 Using the EXEC Command A script may be executed from within another script with the EXEC command. Th

Page 102 - See Also:

Chapter 5 Script Commands Scripting Guide 190 Example: ************************************** Example 1 ************************************** $A

Page 103

Chapter 5 Script Commands Scripting Guide 191 SPLIT Syntax: SPLIT( $Array, $String, $Delimiter) Description: Populates an array with the fields o

Page 104 - FDELETE

Chapter 5 Script Commands Scripting Guide 192 START Syntax: START( ScriptName( Parms)[, %Class[, $Name]]) Description: Initiates execution of ano

Page 105 - FEXISTS

Chapter 5 Script Commands Scripting Guide 193 STOP Syntax: STOP( ScriptName[, %Class [, $Name]]) Description: Halts execution of a script. Action

Page 106

Chapter 5 Script Commands Scripting Guide 194 STR Syntax: STR( %Number) ==> $String Description: Converts a numeric expression to a string. Ac

Page 107 - FINDSTR

Chapter 5 Script Commands Scripting Guide 195 SUBSTR Syntax: SUBSTR( $String, %Start[, %Count]) ==> $SubStr Description: Extract a substring f

Page 108 - FMODTIME

Chapter 5 Script Commands Scripting Guide 196 SWITCH Syntax: SWITCH...CASE...[DEFAULT...]ENDSWITCH SWITCH Expression CASE SimpleExpr: [comm

Page 109

Chapter 5 Script Commands Scripting Guide 197 Example: SWITCH $Msg[ 3] CASE “IOS000I”: //call the IOS000 script to handle IOS000( $Msg[

Page 110

Chapter 5 Script Commands Scripting Guide 198 SYSEXEC Syntax: SYSEXEC( $String) ==> %Return Description: Executes a Unix command on the MCC ho

Page 111 - FORMATSTR

Chapter 5 Script Commands Scripting Guide 199 TEMP Syntax: TEMP( %Port) ==> %Temp Description: Reads the current temperature from a sensor uni

Page 112

Technical Support Contacting the Visara Intellicenter For US domestic customers, Visara provides technical support through its Intellicenter, 8:30 - 5

Page 114 - Scripting Guide 114

Chapter 5 Script Commands Scripting Guide 200 TIME Syntax: TIME( [$TimeString]) ==> %MidnightSeconds Description: Converts a time string to a

Page 115 - Scripting Guide 115

Chapter 5 Script Commands Scripting Guide 201 TIMESTR Syntax: TIMESTR( %EpochSeconds, $Format) ==> $Formatted Description: Formats epoch secon

Page 116

Chapter 5 Script Commands Scripting Guide 202 Date Related Codes for TIMESTR() Code Description Notes/Examples a Weekday short name Mon, Wed A

Page 117

Chapter 5 Script Commands Scripting Guide 203 Time Related Codes Code Description Notes/Examples H Hour number for a 24-hour clock with a leadi

Page 118 - FRENAME

Chapter 5 Script Commands Scripting Guide 204 TRIMSTR Syntax: TRIMSTR( $String[, %Where]) ==> $Trimmed Description: Removes leading and traili

Page 119 - FREWIND

Chapter 5 Script Commands Scripting Guide 205 UPPER Syntax: UPPER( $String) ==> $UpperString Description: Converts lowercase characters to up

Page 120 - Action:

Chapter 5 Script Commands Scripting Guide 206 VAL Syntax: VAL( $String) ==> %Number Description: Converts a string expression to a number. Act

Page 121

Chapter 5 Script Commands Scripting Guide 207 VERSION Syntax: VERSION() ==> $VersionStr Description: Returns a string giving the product and s

Page 122

Chapter 5 Script Commands Scripting Guide 208 WAITFOR Syntax: WAITFOR( %Seconds) Description: Pauses script execution for the specified number of

Page 123

Chapter 5 Script Commands Scripting Guide 209 WAITUNTIL Syntax: WAITUNTIL( %MidnightSeconds) Description: Pauses current script execution until t

Page 124

Scripting Guide 21 Chapter 2 Advanced Topics This chapter contains:  Script Writing Guidelines  Descriptions of key MCC features, such as ports,

Page 125

Chapter 5 Script Commands Scripting Guide 210 WHILE Syntax: WHILE...ENDWHILE WHILE Expression Commands ENDWHILE Description: Repeats a seque

Page 126

Scripting Guide 211 Chapter 6 Obsolete Material This chapter:  Lists discontinued intrinsic manifest constants and their replacements.  Describes

Page 127 - HMCEXEC

Chapter 6 Obsolete Material Scripting Guide 212 Overview As the Master Console Center has evolved, some constants and commands have been supersede

Page 128 - Image-only Commands

Chapter 6 Obsolete Material Scripting Guide 213 Manifest Constants The following table lists discontinued intrinsic manifest constants and their r

Page 129

Chapter 6 Obsolete Material Scripting Guide 214 Commands KEY Command (Date and Time Formats) The time and date KEY command formats have been depre

Page 130

Chapter 6 Obsolete Material Scripting Guide 215 EVENTCLOSE Syntax: EVENTCLOSE( %QueueID ) ==> %Status Description: Close an event queue. Actio

Page 131 - Notes:

Chapter 6 Obsolete Material Scripting Guide 216 EVENTOPEN Syntax: EVENTOPEN( %Source [, $OsNameArray] ) ==> %QueueID Description: Opens a conn

Page 132 - ICONMSG

Chapter 6 Obsolete Material Scripting Guide 217 Notes: 1. Currently, the only Event Source supported is “PATROL_EVENTS”. 2. More than one queu

Page 133 - ICONNAME

Chapter 6 Obsolete Material Scripting Guide 218 EVENTREAD Syntax: EVENTREAD(%QueueIdArray,$EventArray[,%Wait])==>%Status Description: Returns

Page 134 - ICONSTATUS

Chapter 6 Obsolete Material Scripting Guide 219 Returns: Numeric value for %Status, as follows: Value Meaning 0 or event read Success -1

Page 135

Chapter 2 Advanced Topics Scripting Guide 22 Script Writing Guidelines The following coding guidelines and style suggestions increase code readabi

Page 136

Chapter 6 Obsolete Material Scripting Guide 220 // Close the previously opened queues. *done: %i := 1 WHILE( %i <= ALEN( %queueId ) ) %statu

Page 137

Chapter 6 Obsolete Material Scripting Guide 221 MVSCOMMAND Syntax: MVSCOMMAND( %ObjID, $CmdArray, $Output Array, %ErrArray $ErrorTextArray[, %Por

Page 138

Chapter 6 Obsolete Material Scripting Guide 222 generated output from each independently submitted command. Use the QREAD() command to process th

Page 139

Chapter 6 Obsolete Material Scripting Guide 223 14.23.53 P390 STC00019 GWLU62MC08 D T BY WATCHSNA USERID P390 <======= **

Page 140 - KEY Command Return Values

Chapter 6 Obsolete Material Scripting Guide 224 Manifest Constant Value Associated String ICLErr_MvsRsp_0019 10019 Add operator rejected; admin

Page 141 - KEY Command Specifics

Chapter 6 Obsolete Material Scripting Guide 225 QUEUE Syntax: QUEUE( Operation[, Port]) Description: Starts (stops and resets) a queue of OS print

Page 142 - Keyboard Key Key Command

Chapter 6 Obsolete Material Scripting Guide 226 QUEUE command operation parameter options Operation Constant Description ON Creates a message qu

Page 143 - LEFTSTR

Chapter 6 Obsolete Material Scripting Guide 227 READMSG Syntax: READMSG( $Msg, Wait, *Timeout[, Port [, Filter]]) Description: Reads the next mes

Page 144

Chapter 6 Obsolete Material Scripting Guide 228 Example: //======================================================= // Example 1 //===============

Page 145

Chapter 6 Obsolete Material Scripting Guide 229 TSOEREXX Syntax: TSOEREXX( %ObjID, $CmdArray, %ErrorArray, $ErrorTextArray) ==> %ReturnValue D

Page 146

Chapter 2 Advanced Topics Scripting Guide 23  To improve readability, put one blank line before and one after each control structure, such as IF

Page 147 - MKDTEMP

Chapter 6 Obsolete Material Scripting Guide 230 Example: // Sample TSOEREXX() call ARESET( $Cmds) ARESET( %Err) ARESET( $ErrMsg) %OsID := OBJID

Page 148 - MKSTEMP

Scripting Guide 231 Appendix A ASCII Character Values (including ISO-8859-1 ANSI “Latin 1” values) hex dec Char hex dec Char hex dec Char hex dec

Page 149

Scripting Guide 232 (continued from previous page) 80 128 PAD A0 160 NS C0192À E0224à HOP High Octet Preset 81 129 HOP A1 161 ¡ C1193Á E1

Page 150 - MONIKER

Scripting Guide 233 Appendix B Command Syntax Appendix B contains two tables:  The first table lists information by command types.  The second ta

Page 151 - OBJEXEC

Appendix B Command Syntax Scripting Guide 234 Command Syntax—By Command Type Command Command Type Description Syntax ALARM Alerting Gene

Page 152

Appendix B Command Syntax Scripting Guide 235 Command Command Type Description Syntax KEY Console Message Enters a character string to t

Page 153 - OBJGETARRAY

Appendix B Command Syntax Scripting Guide 236 EVENTCLOSE Event Closes a specified event queue. Events are no longer available from the

Page 154

Appendix B Command Syntax Scripting Guide 237 FPOS File Returns an open file’s current record pointer position. FPOS(%FileNum)==>%Po

Page 155

Appendix B Command Syntax Scripting Guide 238 GOSUB Flow Control Immediately transfers script execution to the specified label and waits

Page 156 - OBJIDARRAY

Appendix B Command Syntax Scripting Guide 239 WHILE (ENDWHILE) Flow Control Repeats a sequence of commands while an expression evaluates

Page 157

Chapter 2 Advanced Topics Scripting Guide 24 MCC Concepts Ports Each MCC console interface has a unique number that is assigned when the system is

Page 158

Appendix B Command Syntax Scripting Guide 240 OBJSET Object Manager Populates an associative numeric array with object IDs from the chi

Page 159 - OBJSETARRAY

Appendix B Command Syntax Scripting Guide 241 SCRIPTGETACTIVE Scripting Retrieves information on all active scripts into an associative

Page 160

Appendix B Command Syntax Scripting Guide 242 WAITUNTIL Time Pauses current script execution until the specified time is reached. WAITU

Page 161

Appendix B Command Syntax Scripting Guide 243 FINDSTR Variable Searches a string for a regular expression pattern. FINDSTR($String,$Subs

Page 162

Appendix B Command Syntax Scripting Guide 244 LOWER Variable Converts uppercase characters to lowercase. LOWER($String)==>$Lowercase

Page 163

Appendix B Command Syntax Scripting Guide 245 VERSION Variable Returns a string giving the product and script language version levels.

Page 164

Appendix B Command Syntax Scripting Guide 246 Command Syntax—By Command Command Command Type Description Syntax AICONNAMES Variable Fill

Page 165

Appendix B Command Syntax Scripting Guide 247 Command Command Type Description Syntax BASEDIRECTORY Variable Obtains the base directory

Page 166 - QPREVIEW

Appendix B Command Syntax Scripting Guide 248 Command Command Type Description Syntax ERRORNUM Misc. Returns the error number for the mo

Page 167

Appendix B Command Syntax Scripting Guide 249 Command Command Type Description Syntax FREAD File Reads values from an open file into var

Page 168

Chapter 2 Advanced Topics Scripting Guide 25 Object Name The object name is, obviously enough, the name of an object. In object-oriented terms, t

Page 169

Appendix B Command Syntax Scripting Guide 250 Command Command Type Description Syntax ICONNAME Alerting Returns an icon’s name. ICONNAM

Page 170

Appendix B Command Syntax Scripting Guide 251 MVSCOMMAND Event Enters commands to MVS using the GW-MVS agent (optional software). MVSCO

Page 171

Appendix B Command Syntax Scripting Guide 252 QOPEN Console Message Opens a new queue of OS printer console messages. QOPEN([%ObjIDArray]

Page 172

Appendix B Command Syntax Scripting Guide 253 SET Variable Make the contents of a variable equal to the specified expression. SETVariabl

Page 173

Appendix B Command Syntax Scripting Guide 254 TEMP Physical Interface Control Reads the current temperature from a sensor unit. TEMP(%Po

Page 174 - RIGHTSTR

Scripting Guide 255 IndexAICONNAMES Syntax— AICONNAMES( $AssocArray, %Class, $ParentIcon)...71 ALAR

Page 175

Index Scripting Guide 256 numeric...43 string...

Page 176

Index Scripting Guide 257 Object Manager ...26 icon class ...

Page 177 - SCRIPTCANCEL

Index Scripting Guide 258 Syntax—SCRNTEXT( %Port, %Start, %Length) ==> $Text...183 SECONDS S

Page 178 - SCRIPTGETACTIVE

Index Scripting Guide 259 ICONSTATUS( [%Class [, $Name]]) ==> %Status...136

Page 179

Chapter 2 Advanced Topics Scripting Guide 26 Object ID The Object ID is an integer value generated by the GCL scripting language to refer to an ob

Page 180 - Examples:

Index Scripting Guide 260 Syntax—WHILE...ENDWHILE ...212

Page 183

Chapter 2 Advanced Topics Scripting Guide 27 Object Action The status of objects can change with time. You can use object actions to wait for tho

Page 184 - SNMP_GET

Chapter 2 Advanced Topics Scripting Guide 28 Object Action Type Description Parameters Return Value takes two seconds to perform some processing,

Page 185 - SNMP_GETNEXT

Chapter 2 Advanced Topics Scripting Guide 29 Icon Class/Icon Name A script executes on an object in a class. Objects are represented by an icon d

Page 186 - SNMP_GETTABLE

Scripting Guide 3 Contents Technical Support ... 2 Contacting the

Page 187

Chapter 2 Advanced Topics Scripting Guide 30 The default class and name for a script are determined when the script begins executing:  A script

Page 188 - SNMP_SET

Chapter 2 Advanced Topics Scripting Guide 31 SNMP A full discussion of SNMP (Simple Network Management Protocol) is beyond the scope of this guide

Page 190

Scripting Guide 33 Chapter 3 Script Syntax This chapter contains:  General Scripting Syntax  Basic Overviews of: − Variables − Date/Time − Exp

Page 191

Chapter 3 Script Syntax Scripting Guide 34 General Script Syntax Information General Syntax of a Script The general structure of a script file is

Page 192

Chapter 3 Script Syntax Scripting Guide 35  A script file name comprises up to eight characters followed by a period “.” and a fixed three chara

Page 193

Chapter 3 Script Syntax Scripting Guide 36 Variables Using and Naming Variables  Variables may be character strings, numerics, or arrays; array

Page 194

Chapter 3 Script Syntax Scripting Guide 37 Numeric Variables  Numeric variable names are prefixed with a percent sign “%”.  The maximum value

Page 195

Chapter 3 Script Syntax Scripting Guide 38 Arrays Using and Naming Arrays  There are two types of arrays, integer arrays and string arrays. Int

Page 196

Chapter 3 Script Syntax Scripting Guide 39 Normal Arrays Normal arrays are indexed by any expression that evaluates to a positive integer value. T

Page 197

Contents Scripting Guide 4 Chapter 3 Script Syntax... 33 General S

Page 198 - SYSEXEC

Chapter 3 Script Syntax Scripting Guide 40 Date/Time The date and time type functions allow great flexibility in manipulating and formatting of ti

Page 199

Chapter 3 Script Syntax Scripting Guide 41 Expressions There are two types of expressions, String and Numeric. String Expressions String expressio

Page 200

Chapter 3 Script Syntax Scripting Guide 42 Manifest Constants Intrinsic manifest constants have been defined to make scripts easier to read, write

Page 201 - TIMESTR

Chapter 3 Script Syntax Scripting Guide 43 List of Intrinsic Manifest Constants Manifest Error Constants Manifest Error Constants Value Associat

Page 202

Chapter 3 Script Syntax Scripting Guide 44 Manifest Error Constants Value Associated String not run. Err_Mvs1 4012 General MVS error. Err_Mvs_

Page 203 - Miscellaneous Codes

Chapter 3 Script Syntax Scripting Guide 45 Manifest Error Constants Value Associated String Err_Key_CantReadStatus 5109 Err_Key_ConsoleNotLock

Page 204 - TRIMSTR

Chapter 3 Script Syntax Scripting Guide 46 Manifest Error Constants Value Associated String ICLErr_MvsRsp_0022 10022 Cannot delete last admini

Page 205

Chapter 3 Script Syntax Scripting Guide 47 Other Manifest Constants Other Manifest Constants Value Assoc. String On 1 True 1 Asc 1 Left 1

Page 206

Chapter 3 Script Syntax Scripting Guide 48 Other Manifest Constants Value Assoc. String SkipEnd 2 SkipNext 1 Status_Error 1 Status_Warnin

Page 207 - VERSION

Chapter 3 Script Syntax Scripting Guide 49 Other Manifest Constants Value Assoc. String Hmc_SnaAddr HMC_SnaAddr Hmc_MachModel HMC_MachModel

Page 208 - WAITFOR

Contents Scripting Guide 5 AICONNAMES... 69 ALARM...

Page 209 - WAITUNTIL

Chapter 3 Script Syntax Scripting Guide 50 Operators Mathematical The following mathematical operators may be used in numeric expressions: Charac

Page 210

Chapter 3 Script Syntax Scripting Guide 51 The following Boolean syntax may be used: Syntax Means == Equals < Less than > Greater than <=

Page 211 - Chapter 6 Obsolete Material

Chapter 3 Script Syntax Scripting Guide 52 Label Statements Label statements are used as a reference point within a script to which processing can

Page 212

Scripting Guide 53 Chapter 4 Regular Expressions This chapter discusses regular expressions including:  Bracket expressions  Special characters 

Page 213 - Manifest Constants

Chapter 4 Regular Expressions Scripting Guide 54 Regular Expressions Regular expressions (REs) or patterns are textual statements including specia

Page 214 - Commands

Chapter 4 Regular Expressions Scripting Guide 55 [^.] Match anything EXCEPT a dot. [^A-Z] Match anything EXCEPT an upper case letter. Subexpres

Page 215 - EVENTCLOSE

Chapter 4 Regular Expressions Scripting Guide 56 Rules for Building Regular Expressions When using the rules to build regular expressions (REs), f

Page 216 - EVENTOPEN

Chapter 4 Regular Expressions Scripting Guide 57 An RE ordinary character or an RE special character preceded by a backslash or a period matches a

Page 217

Chapter 4 Regular Expressions Scripting Guide 58 Inside bracket expressions, the following are true:  The special characters ‘.’ , ‘*’, ‘[‘, an

Page 218 - EVENTREAD

Chapter 4 Regular Expressions Scripting Guide 59 The rules in Table 9. Bracket Expression Rules. apply to:  Creating and using matching and non

Page 219 - Returns:

Contents Scripting Guide 6 HEXSTR... 126 HMCEXE

Page 220

Chapter 4 Regular Expressions Scripting Guide 60 Bracket Expression Rule Description Equivalence Class Expression Specifies a set of collating el

Page 221 - MVSCOMMAND

Chapter 4 Regular Expressions Scripting Guide 61 Matching Multiple Characters in Bracket Expressions The following rules are used to build multipl

Page 222

Chapter 4 Regular Expressions Scripting Guide 62 Alternation If ’x’ and ‘y’ are REs, then ‘x|y’ is an RE matching any string that is matched by ei

Page 223 - Possible Error Codes

Chapter 4 Regular Expressions Scripting Guide 63 Precedence of Special Characters The order of precedence, from high to low, is shown below: Order

Page 224

Chapter 4 Regular Expressions Scripting Guide 64 Special Characters in Regular Expressions Table 12. Regular Expressions, Special Characters desc

Page 225

Chapter 4 Regular Expressions Scripting Guide 65 Character Description the quantity. | OR. "A|B" matches either "A" or "

Page 227 - READMSG

Scripting Guide 67 Chapter 5 Script Commands This chapter:  Discusses the types of script commands  Gives information about script syntax  Lis

Page 228

Chapter 5 Script Commands Scripting Guide 68 Conventions in this Chapter When writing scripts, text placed in brackets “[]” is an optional paramet

Page 229 - TSOEREXX

Chapter 5 Script Commands Scripting Guide 69 AICONNAMES Syntax: AICONNAMES( $AssocArray, %Class, $ParentIcon) Description: Fill an array with all

Page 230

Contents Scripting Guide 7 SNMP_GETTABLE... 186 SNMP_SET...

Page 231

Chapter 5 Script Commands Scripting Guide 70 ALARM Syntax: ALARM( %Operation) Description: Generates a repetitive alarm tone (beep) at the MCC te

Page 232

Chapter 5 Script Commands Scripting Guide 71 ALERTCREATE Syntax: ALERTCREATE( %Status, %State, $Source, $MsgText, $UserNote) ==> %AlertID Desc

Page 233 - Appendix B Command Syntax

Chapter 5 Script Commands Scripting Guide 72 ALERTDEL Syntax: ALERTDEL( %AlertID) ==> %ErrCode Description: Deletes an existing Alert. Action:

Page 234 - Description Syntax

Chapter 5 Script Commands Scripting Guide 73 ALERTGETACTIVE Syntax: ALERTGETACTIVE($AssocArray) ==>%ErrCode Description: Retrieves information

Page 235

Chapter 5 Script Commands Scripting Guide 74 $AlertInfo[14] 'Quilt' source computer/OS $AlertInfo[15] message $AlertInfo[16] &a

Page 236

Chapter 5 Script Commands Scripting Guide 75 See Also: ALERTMOD, ALERTCREATE, ALERTDEL

Page 237

Chapter 5 Script Commands Scripting Guide 76 ALERTMOD Syntax: ALERTMOD( %AlertID, %AlertField, NewValue) ==> %ErrCode Description: Modifies th

Page 238 - (ENDIF) Flow

Chapter 5 Script Commands Scripting Guide 77 ARESET Syntax: ARESET( Array) Description: Reset the contents of an array to “empty”. Action: All el

Page 239 - (ENDWHILE) Flow

Chapter 5 Script Commands Scripting Guide 78 ASCII Syntax: ASCII( $String) ==> %Value Description: Given a string $String, returns the integer

Page 240

Chapter 5 Script Commands Scripting Guide 79 ASCRN Syntax: ASCRN( $Array, %Port) Description: Fill an array with the full text of a console scree

Page 241

Contents Scripting Guide 8 List of Tables Table 1. List of MCC Reserved Scripts executed in response to status changes...

Page 242

Chapter 5 Script Commands Scripting Guide 80 ASORT Syntax: ASORT( NormArray, %Direction) Description: Sort a normal array. Action: The data eleme

Page 243

Chapter 5 Script Commands Scripting Guide 81 ASSOCKEYS Syntax: ASSOCKEYS( AssocArray, $NormArray) ==> %RetVal Description: Populate a normal s

Page 244

Chapter 5 Script Commands Scripting Guide 82 ATSTR Syntax: ATSTR( $String, $Substring) ==> %StartPos Description: Returns the starting positio

Page 245

Chapter 5 Script Commands Scripting Guide 83 BASEDIRECTORY Syntax: BASEDIRECTORY() ==> $DirectoryString Description: Obtains the base directory

Page 246 - Command Syntax—By Command

Chapter 5 Script Commands Scripting Guide 84 BLOCKSCAN Syntax: BLOCKSCAN( %Wait, *Timeout [, $Array]) ...ENDBLOCK Description: Enables up to 256

Page 247

Chapter 5 Script Commands Scripting Guide 85 See Also: SCANB, SCANP

Page 248

Chapter 5 Script Commands Scripting Guide 86 CHR Syntax: CHR( %Number) ==> $String Description: Given an integer in the range 0 to 255, return

Page 249

Chapter 5 Script Commands Scripting Guide 87 CLASSNAME Syntax: CLASSNAME( [%Class]) ==> $ClassName Description: Returns the class name for a c

Page 250

Chapter 5 Script Commands Scripting Guide 88 CLASSNUM Syntax: CLASSNUM( [$ClassName]) ==> %Class Description: Returns the class number for a c

Page 251

Chapter 5 Script Commands Scripting Guide 89 CPUPOWER Syntax: CPUPOWER( %Port, %Operation) Description: Switches a CPU’s power ON or OFF. Action:

Page 252

Scripting Guide 9 About This Guide Purpose of This Guide This guide illustrates the Master Console Center Global Control Language (MCC GCL). It assu

Page 253

Chapter 5 Script Commands Scripting Guide 90 DATE Syntax: DATE( [$DateString]) ==> %EpochSeconds Description: Converts a date string to a date

Page 254

Chapter 5 Script Commands Scripting Guide 91 DEC Syntax: DEC %Variable Description: Subtracts one from a numeric variable’s value. Action: The va

Page 255 - Scripting Guide 255

Chapter 5 Script Commands Scripting Guide 92 DECODE Syntax: DECODE ($String[, $Key]) ==> $Result Description: Decodes a GCL string, for exampl

Page 256 - Scripting Guide 256

Chapter 5 Script Commands Scripting Guide 93 DIUNIT Syntax: DIUNIT( %Port) ==> %Status Description: Check the status of a device connected to

Page 257 - Scripting Guide 257

Chapter 5 Script Commands Scripting Guide 94 DOUNIT Syntax: DOUNIT( %Port[, %Operation]) ==> %DOSwitch Description: Controls the device connec

Page 258 - Scripting Guide 258

Chapter 5 Script Commands Scripting Guide 95 ENCODE Syntax: ENCODE ($String[,$Key]) ==> $Result Description: Encodes a GCL string, for example

Page 259 - Scripting Guide 259

Chapter 5 Script Commands Scripting Guide 96 END Syntax: END Description: Ends the execution of the script thread. Action: The execution of the c

Page 260 - Scripting Guide 260

Chapter 5 Script Commands Scripting Guide 97 ERRORMSG Syntax: ERRORMSG( %ErrNum)==> $ErrMsg Description: Returns the error message associated

Page 261

Chapter 5 Script Commands Scripting Guide 98 ERRORNUM Syntax: ERRORNUM() ==> %ErrNum Description: Returns the error number for the most recent

Page 262 - 707131-001

Chapter 5 Script Commands Scripting Guide 99 Manifest Constant Value Associated String/Reason Support. Err_Mvs_NoComm 4001 Unable to communicate

Commentaires sur ces manuels

Pas de commentaire