FITECH Laboratories spacer
graphic Company graphic Products graphic Support graphic Customers graphic Partners
The Power of Choice
spacer » Buy graphic » Try graphic » Map graphic » Contact graphic
spacer
spacer
xTier™
Overview
xTier Services
Business Case
Documentation
F.A.Q.
Buy xTier™
Try xTier™
Professional Services
graphic
spacer xTier
spacer
os
Product: xTier™/LWC 2.3
Whitepaper: n/a
spacer
 support@fitechlabs.com
 Download
 Buy
 Depends: n/a
 Related: n/a
xTier™ Navigator:
cache cluster config email i18n
ioc info jmx jndi security
log marshal objpool os fs
tx uidgen workflow jobs
db startup jms grid

Description
The 'os' is a simple service that provides series of convinience methods to obtain basic information about underlying operating system (OS) such as OS name and type, CPU architecture and number of CPUs. This service allows:

  • Get OS family, name and type.
  • Get JDK name, vendor and version information.
  • Get number of CPUs.

 Top

Configuration
The 'os' service, unlike most of the xTier™ services, does not require configuration through XML and thus it does not have an associated XML configuration file.

 Top

Examples
The os service is simple to use and follows the standard way for accessing services in xTier™. The following code snippet illustrates the basic usage pattern for the 'os' service:

1// Get the instance of xTier kernel.
2XtierKernel xtier = XtierKernel.getInstance();
3 
4// Get the instance of 'os' service.
5OsService os = xtier.os();
6 
7// Use 'os' service.
8System.out.println("Full environment description: " + 
9    os.getFullEnvDesc());
10System.out.println("Number of CPUs: " + 
11    os.getNumberOfCpus());
12System.out.println("Linux? " + 
13    os.isLinux());
14System.out.println("Mac OS? " + 
15    os.isMacOs());
16System.out.println("Netware? " + 
17    os.isNetWare());
18System.out.println("Solaris? " + 
19    os.isSolaris());
20System.out.println("Solaris x86? " + 
21    os.isSolarisX86());
22System.out.println("Unix? " + 
23    os.isUnix());
24System.out.println("Windows? " + 
25    os.isWindows());
26System.out.println("Windows 2K? " + 
27    os.isWindows2k());
28System.out.println("Windows 95? " + 
29    os.isWindows95());
30System.out.println("Windows 98? " + 
31    os.isWindows98());
32System.out.println("Windows NT? " + 
33    os.isWindowsNT());
34System.out.println("Windows XP? " + 
35    os.isWindowsXP());
36System.out.println("Windows Server 2003? " + 
37    os.isWindows2003());
38System.out.println("JDK name: " + 
39    os.getJdkName());
40System.out.println("JDK vendor: " + 
41    os.getJdkVendor());
42System.out.println("JDK version: " + 
43    os.getJdkVersion());
44System.out.println("OS name: " + 
45    os.getOsName());
46System.out.println("OS version: " + 
47    os.getOsVersion());
48System.out.println("OS architecture: " + 
49    os.getOsArch()); 

 Download xTier™ for full examples and documentation.

 Top

spacer