« Back to Product

Documentation

IPS_GetInstance

 array IPS_GetInstance (int $InstanceID) 

Parameters

InstanceID

InstanceID to be returned

Returns

The following information is available as key => value pairs:

Index Type Description
InstanceID integer InstanceID
ConnectionID integer ID of the connected instance
InstanceStatus integer see table "Status of Instance"
InstanceSupportsSearching boolean Does the instance support the search mode
InstanceIsSearching boolean Instance is in search mode
InstanceChange integer Unix Timestamp of the last application of configuration
ModuleInfo array see table "Module Information"

Table: Status of Instance

Code Status
101 Instance will be created
102 Instance is activ
103 Instance will be deleted
104 Instance is inactiv
105 Instance was not created
>=200 Instance is marked als faulty

Table: Module Information

Index Type Description
ModuleID string ModuleID of Instance
ModuleName string ModuleName of Instance
ModuleType integer ModuleType of Instance (0: Core, 1: I/O, 2: Splitter, 3: Device, 4: Configurator, 5: Discovery, 6: Visualization)

Description

The command returns an array containing information about the instance with the ID InstanceID. If the instance does not exist, an alert is generated.

Example

print_r(IPS_GetInstance(19668));

/* returns e.g.:
Array
(
    [InstanceID] => 18235
    [InstanceStatus] => 102
    [LastChange] => 0
    [ModuleInfo] => Array
    (
        [ModuleID] => {48FCFDC1-11A5-4309-BB0B-A0DB8042A969}
        [ModuleName] => FS20
        [ModuleType] => 3
    )
    [ConnectionID] => 29416
)
*/
Any questions?