Home Corporate Contacts

TETware Java API Overview


Products
Solutions

Information

Datasheet
Documentation
FAQ
Knowledgebase

14. Remote System Information


Introduction

These methods are provided in Distributed TETware to enable a test purpose to retrieve information about remote systems.


tet_remgetlist()

Synopsis


      // public class TestSession
      public int[] tet_remgetlist()

Description

A call to tet_remgetlist() from a process which is part of a distributed test case returns an array containing the system IDs of the other systems. A call to tet_remgetlist() from a process which is not part of a distributed test case returns null.

Portability

In TETware-Lite a call to tet_remgetlist() always returns null.


tet_remgetsys()

Synopsis


      // public class TestSession
      public int tet_remgetsys()

Description

A call to tet_remgetsys() returns the system ID of the system on which the calling process is executing.

Return value

This method returns the value described above.

Portability

In TETware-Lite a call to tet_remgetsys() always returns zero.


tet_getsysbyid()

Synopsis


      // public class TestSession
      public SystemEntry tet_getsysbyid(int sysid) throws TetException

Description

The tet_getsysbyid() method enables a test case to access information contained in the system definition file. If an entry for the system specified by sysid can be found in the file, tet_getsysbyid() returns a SystemEntry object for that system. The SystemEntry class contains the following fields:


      /**
        * The id of the system.
        */
      public int ts_sysid;
      /**
        * The name of the system.
        */
      public String ts_name;

Refer to the section entitled "System definitions" in the TETware Programmers Guide for details of the system definition file.

Return value

A call tet_getsysbyid() returns a SystemEntry object for the system specified by sysid.

Exceptions

tet_getsysbyid() throws a TetException object if the API encounters an error while processing the request.

Portability

In TETware-Lite, this method always throws a TetException object.


tet_remtime()

Synopsis


      // public class TestSession
      public Date tet_remtime(int sysid) throws TetException

Description

A call to tet_remtime() returns the system time on the system specified by sysid. When sysid specifies the system ID of the calling process, the time is obtained by using an appropriate system call. However, when sysid specifies a different system ID, the time is obtained from an instance of TCCD that is running on the specified system.

Return value

This method returns the value described above.

Exceptions

tet_remtime() throws a TetException object if the API encounters an error while processing the request.

Portability

In TETware-Lite, this method always throws a TetException object.

Application notes

The Java version of tet_remtime() returns a Date value (number of milliseconds since the epoch) whereas the C version of tet_remtime() returns a time_t value (number of seconds since the epoch).

Return to Contents



Home Contacts Legal Copyright Corporate News

Copyright © The Open Group 1995-2012, All Rights Reserved