Konfigurations-VariablenAllgemeinTyp | Methode | Beschreibung | void | config.resetConfigToDefault() | Revert all changes to the default configurationRücksetzen aller Änderungen auf die Standard-Konfiguration. | void | config.addScriptLine(line: string) | Adds the line to the script that is executed on the device.Fügt eine Zeile zum Skript hinzu, das auf dem Gerät ausgeführt wird.
| void | config.infoLog(msg: string) | Prints the message into the device log within the LMC with log level info Gibt die Meldung im Geräte-Log der LMC mit dem Level info aus. | void | config.infoLog(key: string, msg: string) | Prints the message into the devicelog with the log key within the LMC with log level info Gibt die Meldung im Geräte-Log der LMC mit dem Protokoll-Schlüsse mit dem Level info aus.
| void | config.warnLog(msg: string) | Prints the message into the device log within the LMC with log level warn Gibt die Meldung im Geräte-Log der LMC mit dem Level warn aus. | void | config.abort(msg: string) | Aborts config building, and log the message into the device log within the LMC with log level Bricht das Erstellen der Konfiguration ab und protokolliert die Meldung im Geräte-Log der LMC mit dem Level error . | OutputStream | config.createOutputStream() | Creates a new standard output stream for strings. (Only supported for OneTimeScripts)Erstellt eine neue Standard-Ausgabe für Strings (nur von One-Time Skript unterstützt). | OutputStream | config.createOutputStream(key: string) | Creates a new output stream for strings. (Only supported for OneTimeScripts)Erstellt eine neue Ausgabe für Strings (nur von One-Time Skript unterstützt). | void | OutputStream.addLine(key: string) | Adds a string to the output streamFügt einen String zu einer Ausgabe hinzu. |
ScalarSkalar TypeMethodDescriptionBeschreibung |
---|
string | config.getScalarByOid(oid) | Returns the value of the given scalar via oidLiest den Wert eines Skalars per oid aus. | string | config.getScalarByAlias(alias) | Returns the value of the given scalar via aliasLiest den Wert eines Skalars per Alias aus. | string | config.setScalarByOid(oid, value) | Sets scalar value (returns old value)Setzt den Wert eines Skalars per oid (liest den alten Wert aus). | string | config.setScalarByAlias(alias, value) | Sets scalar value (returns old value)Setzt den Wert eines Skalars per Alias (liest den alten Wert aus). | string | config.resetScalarToDefaultByOid(oid); | Reset the given scalar via oid to the default configuration valueSetzt ein Skalar per oid auf den Standard-Wert zurück. | string | config.resetScalarToDefaultByAlias(alias); |
Reset the given scalar via alias to the default configuration value. | TableSetzt ein Skalar per Alias auf den Standard-Wert zurück. |
Tabelle TypeDescriptionBeschreibung |
---|
Table | config.getTableByOid(oid: string); | Get the Table object via oidLiest eine Tabelle per oid aus. | Table | config.getTableByAlias(alias: string); | Get the Table object via aliasLiest eine Tabelle per Alias aus. | List<Row> | table.getRows(); | Get all rows of the Table objectLiest alle Zeilen einer Tabelle aus. | Row | table.getRowBySingleIndex(indexValue: string); | Get a row index, if it has only one index.Liest den Zeilen-Index aus, sofern nur ein Index vorhanden ist | List<Row> | table.getRowsByOid(oid: string, value: string); | Get rows matching the value value in the column oidLiest alle Zeilen aus, die dem Wert entsprechen (per oid). | List<Row> | table.getRowsByAlias(alias:string, value:string); | Get rows matching the value valuein the column aliasLiest alle Zeilen aus, die dem Wert entsprechen (per Alias). | List<Row> | table.getRowsByOids(Map<oid, value>); | Get all rows matching all search criteriaLiest alle Zeilen aus, die den Such-Kriterien entsprechen (per oid). | List<Row> | table.getRowsByAliases(Map<alias, value>); | Get all rows matching all search criteria, using aliasesLiest alle Zeilen aus, die den Such-Kriterien entsprechen (per Alias). | Row | table.getFirstRowByOid(oid, value); | Return first matching row via oidGibt die erste passende Zeile aus, die dem Wert entspricht (per oid). | Row | table | .getFirstRowByAlias(alias, value);Return first matching row via alias.getFirstRowByAlias(alias, value); | Gibt die erste passende Zeile aus, die dem Wert entspricht (per Alias). | Row | table.getFirstRowByOids(Map<oid, value>); | Get first matching row matching via oidGibt die erste passende Zeile aus, die den Werten entsprechen (per oid). | Row | table.getFirstRowByAliases(Map<alias, value>); | Get first matching row matchign via aliasesGibt die erste passende Zeile aus, die den Werten entsprechen (per Alias). | Row | table.createNewRow(); | Create a new empty rowErstellt eine neue leere Zeile. | Row | table.addOrMerge(row) | If the index matches a row the row is updated, otherwise the row is added.Aktualisiert die Zeile, wenn die Zeile dem Index entspricht. Ansonsten wir die Zeile hinzugefügt. | boolean | table.resetToDefault(); |
Reset the table to the default configuration. | RowSetzt die Tabelle auf die Standard-Konfiguration zurück. |
Reihe Type | Method | Description |
---|
string | row.getByOid(oid); | Get value via oid. | string | row.getByAlias(alias); | Get value via alias. | string | row.setByOid(oid, value); | Set value via oid. | string | row.setByAlias(oid, value); | Set value via alias. | void | row.setByOids(Map<oid, value>); | Set multiple values via oid. | void | row.setByAliases(Map<alias, value>); | Set multiple values via aliases. | Row | row.addByOid(oid, value); | Like setByOid but returns the row for fluent API usage. | Row | row.addByAlias(alias, value); | Like setByAlias but returns the row for fluent API usage. | boolean | row.delete(); | Delete the row from the table. |
Exclude/IncludeTypeMethodDescriptionBeschreibung |
---|
void | config.excludeByOid(oid: string) | Do not write element(s) that match oid filter to the device, e.g. config.excludeByOid("1.2.9.13"); | void | config.excludeByOids(oids: List<string>) | Do not write element(s) that match oid filter to the device, e.g. config.excludeByOids(["1.2.9.17", "1.2.9.18", "1.2.11.*"]); | void | config.includeByOid(oid: string) | Only write the element(s) matching the oid filter to the device | void | config.includeByOids(oids: List<string>) | Only write the element(s) matching the oid filter to the device (Note: the include calls do not stack!) |
Context Variables
Kontext-VariablenKontext-Variablen sind schreibgeschütztContext variables are read only. DSCTypeMethodDescriptionBeschreibung |
---|
boolean | context.dsc.existsScalarByOid(oid) | Checks whether the given scalar exists by oid. | boolean | context.dsc.existsScalarByAlias(alias) | Checks whether the given scalar exists by alias. | boolean | context.dsc.existsTableByOid(oid) | Checks whether the given Table exists via oid. | boolean | context.dsc.existsTableByAlias(alias) | Checks whether the given Table exists via alias. |
Network
NetzwerkTypeMethodDescriptionBeschreibung |
---|
<SsidObj>[] | context.network.ssids | Map of SSID objects indexed by its name (usage see next lines). | string[] | context.network.ssids[<SSID>].ifcNumber | List with interface numbers for SSID. | string[] | context.network.ssids[<SSID>].ifcName | List with interface names for SSID. | string | context.network.ssids[<SSID>].radiusName | Radius name for SSID. | string | context.network.ssids[<SSID>].name | The SSID (always same as ) | string | context.network.name | Network name | string | context.network.configName | Network configuration name | string | context.network.configNameLong | Long network configuration name | string | context.network.ifcNumber | Network interface number | string | context.network.tag | Network Vlan Id | string | context.network.vpnGateway | Central Site Gateway address | string[] | context.network.vpnConnections | List of peer ident names for vpn connetions | <Variables> | context.network.vpnSiteVars[<SubnetGroupConfigName> or <PeerIdent>] | User variablen for vpn location | string | context.network.vpnCredentials[<SubnetGroupConfigName> or <PeerIdent>].remote.identity | VPN remote identity for site | string | context.network.vpnCredentials[<SubnetGroupConfigName> or <PeerIdent>].remote.psk | VPN remote psk for site | string | context.network.vpnCredentials[<SubnetGroupConfigName> or <PeerIdent>].local.identity | VPN local identity for site | string | context.network.vpnCredentials[<SubnetGroupConfigName> or <PeerIdent>].local.psk | VPN local psk for site | string | context.network.vpnRemoteData[peerName].subnetMask |
| string | context.network.vpnRemoteData[peerName].subnetId |
| boolean | context.network.isCentralGateway | true if vpn & gateway & central-site | boolean | context.network.isBranchGateway | true if vpn & gateway & not central-site | number | context.network.gatewayNumber | gateway number | <DevRolObj> | context.network.deviceRoles | return device roles object (usage see next 2 lines) | boolean | context.network.deviceRoles.contains(role string) | Check if device has role gateway with GW, access point with AP or switch with SW | string[] | context.network.deviceRoles.list() | Get list of device roles, e.g. {"GW", "AP", "SW"} |
Device
GerätTypeMethodDescriptionBeschreibung |
---|
boolean | context.device.isGateway | true if device is gateway | boolean | context.device.isAccesspoint | true if device is accesspoint | boolean | context.device.isSwitch | true if device is switch | number | context.device.firmwareVersion | Firmware version without build number as double value | number | context.device.firmwareVersionWithBuild | Firmware version with build number as double value | string | context.device.firmwareVersionString | Firmware version as string | Object | context.device.firmwareVersionObject | Firmware version as object: { major: number, minor: number, patch: number } | string | context.device.type | Device type string | <Features> | context.device.features | Feature object (usage see next line) | boolean | context.device.features.supports(int) | Checks whether a feature with given ID is supported, e.g. 43 for feature LAN bridge | string | context.device.macAddress | MAC Address for LAN interface. (Added April 2022. Requires device reboot before use.) | string | context.device.serialNumber | Serial number of the device (Added April 2022. Requires device reboot before use.) |
Location
StandortTypeMethodDescriptionBeschreibung |
---|
string | context.location.configName | Location configuration nameName des Standorts | string | context.location.subnetId | Network ID at location, for example 192.168.1.0 | string | context.location.subnetMask | Subnet maskSubnetz-Maske | string | context.location.gatewayIp | Routing IP address to Central Site, if device Role is Gateway, else null | string[] | context.location.gatewayIps | Returns IP addresses of all location gateways. |
|