INFO() Function - Get System Information

For this topic's original documentation, see the INFO() Function - Get System Information.

BBj-Specific Information

Many INFO() function arguments have not been implemented and others return different values than they do in PRO/5. The following identifies each of the INFO() function arguments and lists the differences between the BBj information returned and the PRO/5 information returned.

Argument

BBj Information Returned

PRO/5 Information Returned

0,0

Operating system, as reported by the JDK (Java Development Kit)

Note:

In all progressions of PRO/5, the values that would be returned by INFO(0,0) and INFO(0,1) were determined when the interpreter executable was compiled. BBj is not compiled on individual operating systems like PRO/5; another paradigm is used. In BBj, INFO(0,0) and INFO(0,1) return operating system information as reported by the JVM in use. Since different JVMs report these values in different formats, applications should not depend on these functions returning the same values as in PRO/5, nor should applications depend on these functions reporting the exact same values among different BBj installations.

Operating system name for which PRO/5 is compiled.

0,1

Operating system version, as reported by the JDK (Java Development Kit). See the Note for Argument (0,0).

Operating system version for which PRO/5 is compiled.

0,2

(Unchanged)

BASIS "port ID."

0,4

Build date and time in the format:
"Build: 00/00/0000 00:00"

PRO/5 build date and time in the format:
"Build: Xxx 00 0000 00:00:00."

1,0

Always returns "Java".

CPU ID (or CPU family) for which PRO/5 is compiled.

1,1

JVM release level.

Not supported in PRO/5.

1,2

Server character set.

Not available in PRO/5.

1,3

Client character set.

Not available in PRO/5.

1,4

BBj 9.0 and higher: client look and feel ID. Returns the value reported by the Java LookAndFeel.getID() method on the client. Common values are "Windows", "Aqua", "Motif", "GTK", and "Metal".

BBj 10.0 and higher: browser name if running in BUI.

Not available in PRO/5.

1,5

BBj 10.0 and higher: a unique identifier for the server JVM.  This identifier will be unique across multiple machines.

Not available in PRO/5.

1,6

BBj 10.0 and higher: a unique identifier for the client JVM.  This identifier will be unique across multiple machines.

Not available in PRO/5.

1,7

BBj 17.0 and higher: the start up date/time of BBjServices is reported.

Not available in PRO/5.

2,0

Total number of user licenses (4-byte binary string).

Total number of user licenses (4-byte binary string). For versions prior to 2.1, this argument returns the total number of foreground user slots (binary string).

2,1

Total number of available licenses (4-byte binary string)

Total number of available licenses, those not in use (4-byte binary string). For versions prior to 2.1, this argument returns the number of free foreground user slots (binary string).

2,2

(Unchanged)

UNIX: 32

Windows: 0 (Zero)

For versions prior to 2.1, this argument returns the total number of background user slots (binary string).

2,3

(Unchanged)

UNIX: 32

Windows: 0 (Zero)

For versions prior to 2.1, this argument returns the number of free background user slots (binary string).

2,4

Current user slot number (binary string).

Current user slot number (binary string).

2,5

(Not implemented)

Last background process number started (binary string).

2,6

In PRO/5, VPRO/5 4.10, and BBj 3.01 and higher, this function returns the license expiration date in Julian date format (binary string). 2147483647 ($7fffffff$) indicates a permanent license or that BBj or PRO/5 is running without a license.

Example 1:

10 LET A=DEC(INFO(2,6))-JUL(0,0,0)
20 IF A<30 THEN PRINT "This license will expire in",A," days"

Example 2:

10 LET A=DEC(INFO(2,6))
20 IF A=2147483647 THEN PRINT "This license will not expire"
20:ELSE PRINT "This license will expire on ",DATE(A)

In PRO/5, the expiration date applies to the license checked out when starting PRO/5. If the license was updated after PRO/5 was started, then PRO/5 must be restarted to return the updated expiration date.

2,7

In BBj 9.0 and higher, license version.

Not available in PRO/5.

2,8

In BBj 15.0 and higher, whether the SAM license feature is available.

Not available in PRO/5.

2,9

In BBj 22.0 and higher, this function returns the expiration date for the SoftwareAssetManagement (SAM) license in Julian date format (binary string).

Example:

LET A=DEC(INFO(2,9))-JUL(0,0,0)
IF A<30 THEN PRINT "The SAM license will expire in",A," days"

Not available in PRO/5.

3,0

Unique task ID (4-byte binary string).

Four-byte process ID.

3,1

Unique task ID (8-byte binary string).

Eight-byte string, where the first four bytes are identical to INFO(3,0). The last four bytes are set to the local IP address if network access is enabled using SETOPTS byte 4, bit $20$. If network access is not enabled, the last four bytes of INFO(3,1) return $00000000$.

3,2

User name.

User login ID. This value is set to the credentials used at login when user authentication is enabled for BBjServices. BBj initializes this value with the USERID environment variable or the -u option at invocation when user authentication is not enabled in BBjServices. This value can be changed at runtime to change the user for the BBj session by changing the !DSUDDB STBL value:
      void$=STBL("!DSUDDB","user=theuser,passwd=mypassword").

See also BBj User Authentication.

3,3

On Unix, user description (as found in the password file gecos (comment) field.

On Windows, returns the value of the USERDESC environment variable.

User description.

3,4

(Unchanged)

Current host name.

3,5

(Not implemented)

Features of licensed product.

3,6
 

Value Meaning BBj Version
0
Running with -FC, IO, or in TermConsole mode in BBj 4.0 and lower.
Running with IO or in TermConsole mode in BBj 5.0 and higher.
4.00
1 Running with -TC (1) 4.00
2 Running with Applet capabilities 4.00
3

Running with Webstart capabilities (2)

4.00
4

Running in the JavaBBjBridge

4.00
5

Running in BUI

10.00
6

Running in DWC

21.10
7 Running in a desktop app 22.11

Notes:

  • (1) BBj's default behavior is to run as if -TC is set.

  • (2) Web start may detect BBjServices running on the client machine. If it determines that it should reuse the JVM used by BBjServices, INFO(3,6) instead returns "1" because the client has the capabilities of a normal thin client session.

Not supported in PRO/5.

3,7

If running in thin client, returns the host name of the client, otherwise returns the empty string.

Not supported in PRO/5.

3,8

BUI logoDWC logoIf running in BUI (BBj 11.0 and higher) or DWC (BBj 22.0 and higher), returns the navigator.userAgent string from the browser, otherwise returns the empty string.

Not supported in PRO/5.

3,9

BBj 16.0 and higher: returns the group identifier for the session group as a 4-byte binary string, equivalent to BBjSessionInfo::getGroupID.

Not supported in PRO/5.

3,100

(Not implemented)

Novell NetWare: Name of the server PRO/5 was invoked from, or the empty string, if none.

3,101

(Not implemented)

Novell NetWare: Volume or drive PRO/5 was invoked from, minus the final colon.

3,102

(Not implemented)

Novell NetWare: Full path of the PRO/5 executable, minus any server or volume information.

4,*

Returns operating system environment variables.

Values of any environment variable set. int ranges from zero to the maximum number of environment strings, minus one. In BBj 4.0 and higher, if SETOPTS bit 8, $08$ is set, then the function returns client side environment variables. Otherwise, server side variables will be returned.

6,0

Name of the GUI system, if applicable. This will be one of the following values:

Value Description
"SWING" Java GUI
"GWT" BUI
"WEB" DWC
"" No GUI capabilities

Name of the GUI system, if applicable. This will be "WINDOWS" (Visual PRO/5) or " " (No GUI capabilities).

6,1

Returns a meaningless value. START size is not relevant in BBj.

A binary string containing the maximum possible START size, in 256-byte pages. This value does not indicate the exact amount of memory available, and it may not be possible to use a START size as large as the returned value.

6,2

(Unchanged)

The result is either "<>|", indicating that the operating system supports pipes, or the empty string if the operating system does not support pipes.

6,3

(Unchanged)

Number of significant digits (as a binary string) for Business Math fields.

7,*

BBj 3.01 and higher: returns operating system environment variables from the thin client side of a thin client session.

If running in BUI, returns key=value parameters from the URL query string.

Values of any environment variable set on the thin client side. int ranges from zero to the maximum number of environment strings, minus one.

8,*

In BBj 4.0 and higher, returns operating system environment variables from the server side of a thin client session.

Values of any environment variable set on the server side. int ranges from zero to the maximum number of environment strings, minus one.