This sample demonstrates how you can programmatically obtain the list of system objects that are currently defined. Through a system object, you can obtain basic properties such as the name, the IP address, and the connection status of the system.
To retrieve information about z/OS® systems, select the API Samples > Systems Information. action.
For each system that is defined, the name, IP address, and connection status is displayed in the standard output associated with the workbench. This can be found in the DOS window from which the workbench was started, or in the Console view of the hosting workbench in the case of the runtime workbench.

The following code snippet from the ListSystemsAction class contains the core of the sample.
Object [] systemReferences = PhysicalSystemRegistryFactory.
getSingleton().getSystems(IPopulatorConstants.MVSFiles);
for (int i = 0; i < systemReferences.length; i++) {
if (systemReferences[i] instanceof IOSImage) {
IOSImage system = (IOSImage) systemReferences[i];
System.out.println("----------");
System.out.println("System " + i + ": " +
system.getName());
System.out.println("IP address = " +
system.getIpAddress());
if (system.isConnected()) {
System.out.println("System is currently connected.");
} else {
System.out.println(
"System is not currently connected.");
}
}
}
It starts by using the PhysicalSystemRegistry class, obtained using the getSingleton method of the PhysicalSystemRegistryFactory class, to retrieve the IOSImage objects representing the MVS™ subsystem of the systems defined in the workspace. Then it iterates through each of the (sub)systems, and prints out the following information:
<extension
id="com.ibm.ftt.api.samples.actionSets"
name="%apiSample.actionSets"
point="org.eclipse.ui.actionSets">
<actionSet label="com.ibm.ftt.api.samples.actionSet1"
description="Action set for the API samples"
visible="true"
id="com.ibm.ftt.api.samples.actionSet1">
<menu label="%apiMenu.title"
id="com.ibm.ftt.api.samples.apiMenu">
<separator name="com.ibm.ftt.api.samples.apiMenu.resourcesAPI"/>
</menu>
<action label="%apiMenu.samples.listSystems"
class="com.ibm.ftt.api.samples.resources.ListSystemsAction"
style="push" menubarPath=
"com.ibm.ftt.api.samples.apiMenu/com.ibm.ftt.api.samples.apiMenu.resourcesAPI"
id="com.ibm.ftt.api.samples.listSystemsAction"/>
......
</actionSet>
</extension>