Object/Trait

io.scalajs.nodejs.os

OS

Related Docs: trait OS | package os

Permalink

object OS extends Object with OS

Operating System Singleton

Annotations
@native() @JSImport( "os" , JSImport.Namespace )
Linear Supertypes
OS, Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. OS
  2. OS
  3. Object
  4. Any
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. def EOL: String

    Permalink

    A constant defining the appropriate End-of-line marker for the operating system.

    A constant defining the appropriate End-of-line marker for the operating system.

    • \n on POSIX
    • \r\n on Windows
    Definition Classes
    OS
    Example:
    1. os.EOL

  5. def arch(): String

    Permalink

    Returns the operating system CPU architecture.

    Returns the operating system CPU architecture. Possible values are 'x64', 'arm' and 'ia32'. Returns the value of process.arch.

    Definition Classes
    OS
    Example:
    1. os.arch()

  6. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  7. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  8. def constants: Dictionary[Any]

    Permalink

    Returns an object containing commonly used operating system specific constants for error codes, process signals, and so on.

    Returns an object containing commonly used operating system specific constants for error codes, process signals, and so on. The specific constants currently defined are described in OS Constants.

    Definition Classes
    OS
    See also

    https://nodejs.org/api/os.html#os_os_constants_1

  9. def cpus(): Array[Any]

    Permalink

    Returns an array of objects containing information about each CPU/core installed: model, speed (in MHz), and times (an object containing the number of milliseconds the CPU/core spent in: user, nice, sys, idle, and irq).

    Returns an array of objects containing information about each CPU/core installed: model, speed (in MHz), and times (an object containing the number of milliseconds the CPU/core spent in: user, nice, sys, idle, and irq).

    Definition Classes
    OS
    Example:
    1. os.cpus()

  10. def endianness(): String

    Permalink

    Returns the endianness of the CPU.

    Returns the endianness of the CPU. Possible values are 'BE' for big endian or 'LE' for little endian.

    Definition Classes
    OS
    Example:
    1. os.endianness()

  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  13. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. def freemem(): Double

    Permalink

    Returns the amount of free system memory in bytes.

    Returns the amount of free system memory in bytes.

    Definition Classes
    OS
    Example:
    1. os.freemem()

  15. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  16. def hasOwnProperty(v: String): Boolean

    Permalink
    Definition Classes
    Object
  17. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  18. def homedir(): String

    Permalink

    Returns the home directory of the current user.

    Returns the home directory of the current user.

    Definition Classes
    OS
    Example:
    1. os.homedir()

  19. def hostname(): String

    Permalink

    Returns the hostname of the operating system.

    Returns the hostname of the operating system.

    Definition Classes
    OS
    Example:
    1. os.hostname()

  20. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  21. def isPrototypeOf(v: Object): Boolean

    Permalink
    Definition Classes
    Object
  22. def loadavg(): Array[Int]

    Permalink

    Returns an array containing the 1, 5, and 15 minute load averages.

    Returns an array containing the 1, 5, and 15 minute load averages.

    The load average is a measure of system activity, calculated by the operating system and expressed as a fractional number. As a rule of thumb, the load average should ideally be less than the number of logical CPUs in the system.

    The load average is a very UNIX-y concept; there is no real equivalent on Windows platforms. That is why this function always returns [0, 0, 0] on Windows.

    Definition Classes
    OS
    Example:
    1. os.loadavg()

  23. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  24. def networkInterfaces(): Dictionary[NetworkInterface]

    Permalink

    Get a list of network interfaces

    Get a list of network interfaces

    Definition Classes
    OS
    Example:
    1. os.networkInterfaces()

  25. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  26. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  27. def platform(): String

    Permalink

    Returns the operating system platform.

    Returns the operating system platform. Possible values are 'darwin', 'freebsd', 'linux', 'sunos' or 'win32'. Returns the value of process.platform.

    Definition Classes
    OS
    Example:
    1. os.platform()

  28. def propertyIsEnumerable(v: String): Boolean

    Permalink
    Definition Classes
    Object
  29. def release(): String

    Permalink

    Returns the operating system release.

    Returns the operating system release.

    Definition Classes
    OS
    Example:
    1. os.release()

  30. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  31. def tmpdir(): String

    Permalink

    Returns the operating system's default directory for temporary files.

    Returns the operating system's default directory for temporary files.

    Definition Classes
    OS
    Example:
    1. os.tmpdir()

  32. def toLocaleString(): String

    Permalink
    Definition Classes
    Object
  33. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  34. def totalmem(): Double

    Permalink

    Returns the total amount of system memory in bytes.

    Returns the total amount of system memory in bytes.

    Definition Classes
    OS
    Example:
    1. os.totalmem()

  35. def type(): String

    Permalink

    Returns the operating system name.

    Returns the operating system name. For example 'Linux' on Linux, 'Darwin' on OS X and 'Windows_NT' on Windows.

    Definition Classes
    OS
    Example:
    1. os.type()

  36. def uptime(): Double

    Permalink

    Returns the system uptime in seconds.

    Returns the system uptime in seconds.

    Definition Classes
    OS
    Example:
    1. os.uptime()

  37. def userInfo(options: UserInfoOptions = js.native): UserInfoObject

    Permalink

    The os.userInfo() method returns information about the currently effective user -- on POSIX platforms, this is typically a subset of the password file.

    The os.userInfo() method returns information about the currently effective user -- on POSIX platforms, this is typically a subset of the password file. The returned object includes the username, uid, gid, shell, and homedir. On Windows, the uid and gid fields are -1, and shell is null.

    The value of homedir returned by os.userInfo() is provided by the operating system. This differs from the result of os.homedir(), which queries several environment variables for the home directory before falling back to the operating system response.

    returns

    a user information object

    Definition Classes
    OS
  38. def valueOf(): Any

    Permalink
    Definition Classes
    Object
  39. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  41. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from OS

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped