Package schrodinger :: Package test :: Package stu :: Module sysinfo :: Class _SysInfo
[hide private]
[frames] | no frames]

Class _SysInfo

object --+
         |
        _SysInfo

Determines and saves the system information.


To Do: Does not support remote hosts from windows

Instance Methods [hide private]
 
__init__(self, host='localhost')
x.__init__(...) initializes x; see help(type(x)) for signature
 
get_host(self)
 
set_host(self, new_host)
None
update(self, new_host='localhost')
Fills in the information based on the host name.
 
get_platform(self)
Finds the platform based on the execute host.
str
get_os_version(self)
Returns a string of os version information.
str
_runcmd(self, cmd)
Returns: String output of the cmd or schrodinger.utils.UKNOWN (str)
str
get_processor(self)
Returns a string of processor information.
 
toDict(self)
Dump sysinfo object as a dict
str
__str__(self)
Allows direct printing of the _SysInfo object.

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __subclasshook__

Instance Variables [hide private]
  _host_entry_name
'Title from schrodinger.hosts
  _ssh_host_name
'Host' from schrodinger.hosts
Properties [hide private]
  host
  name
bool isLinux
Is this a Linux platform?
bool isWindows
Is this a Windows platform?
bool isDarwin
Is this a Darwin/Mac platform?

Inherited from object: __class__

Method Details [hide private]

__init__(self, host='localhost')
(Constructor)

 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

get_os_version(self)

 

Returns a string of os version information.

Uses python's platform.linux_distribution, platform.mac_ver, or platform.win32_ver for Linux, Mac and Windows, respectively.

Returns: str
OS version information.

_runcmd(self, cmd)

 
Parameters:
  • cmd (str) - command specified as a string. This function will prepend $SCHRODINGER/run and run appropriately local or remote.
Returns: str
String output of the cmd or schrodinger.utils.UKNOWN (str)

get_processor(self)

 

Returns a string of processor information.

Returns: str
Processor information (manufacturor, speed, etc.)

__str__(self)
(Informal representation operator)

 

Allows direct printing of the _SysInfo object.

Returns: str
Overrides: object.__str__

Property Details [hide private]

host

Get Method:
get_host(self)
Set Method:
set_host(self, new_host)

name

Get Method:
unreachable.name(self)

isLinux

Is this a Linux platform?

Get Method:
unreachable.isLinux(self) - Is this a Linux platform?
Type:
bool

isWindows

Is this a Windows platform?

Get Method:
unreachable.isWindows(self) - Is this a Windows platform?
Type:
bool

isDarwin

Is this a Darwin/Mac platform?

Get Method:
unreachable.isDarwin(self) - Is this a Darwin/Mac platform?
Type:
bool