[ Reference Manual | Alphabetic Index ]

Operating System

Built-ins to access operating-system services

Predicates

alarm(+Clock)
The operating system will send the signal 14 to the ECLiPSe system Clock seconds after the command was entered.
argc(-Number)
Succeeds if Number is the number of arguments given on the command line to invoke ECLiPSe .
argv(+N, -Argument)
Succeeds if the Nth argument given on the command line when invoking ECLiPSe is the string Argument.
canonical_path_name(+Path, -CanonicalPath)
Expand a path name into the full `canonical' form.
cd(+Directory)
Directory is made the current working directory. Equivalent to set_flag(cwd, Directory).
cputime(-Time)
Succeeds if Time is the elapsed user cpu time in seconds.
date(-Date)
Date is bound to the string giving the date and time.
delete(+File)
The file File (with absolute or relative pathname) is deleted.
errno_id(-Message)
Message is bound to the message string that corresponds to most recent operating system error that occurred during the execution.
exec(++Command, ++Streams)
A child process Command is forked, its standard streams are connected to Streams and the ECLiPSe process waits until it terminates.
exec(++Command, ++Streams, -Pid)
A child process Command is forked, its standard streams are connected to Streams and its process ID is Pid.
exec_group(++Command, ++Streams, -Pid)
A child process Command is forked in a new process group, its standard streams are connected to Streams and its process ID is Pid.
existing_file(++Base, ++Completions, ++Permissions, -MatchedFile)
Finds any existing file subject to the specified conditions.
exists(+File)
Succeeds if the file File (with absolute or relative pathname) exists. File can be a directory.
exit(+Status)
The Prolog session is ended and the specified status returned to the operating system.
get_file_info(+File, ?Attr, -Value)
Succeeds if the file File (with absolute or relative pathname) exists and the value of its attribute Attr unfies with Value.
getcwd(-Cwd)
Unifies the current working directory with Cwd.
getenv(+Name, -Value)
Succeeds if Name is the name of an environment variable or registry entry, and returns the corresponding value.
halt
The Prolog session is ended (the same as Control-D at the top-level loop).
kill(+Pid, +Signal)
Send the signal Signal to the process number Pid
local_time(?Year, ?Month, ?Day, ?Hour, ?Minute, ?Second, ?DST, ?UnixTime)
Conversion between local time and universal time
local_time_string(+UnixTime, +Format, -TimeString)
Create a string representation of the local time
mkdir(+Path)
Create a directory/folder with the given name.
os_file_name(?InternalName, ?ExternalName)
Conversion between internal ECLiPSe file name and Operating System file name syntax.
pathname(+FilePath, -Path, -Name)
If FilePath is a pathname of a file, succeed if Path is the pathname of its parent directory and Name is the local file name.
pathname(+FilePath, -Path, -BaseName, -Suffix)
Decomposes a filename into its directory path, base name and suffix
pause
The ECLiPSe session is suspended (the same as Control-Z at the top-level loop).
read_directory(+Directory, +Pattern, -SubdirList, -FileList)
Unifies SubdirList with a list of subdirectories and FileList with a list of matching files in the specified directory.
rename(+OldName, +NewName)
Renames the file OldName to NewName.
setenv(+Name, +Value)
Sets the environment variable Name to the given value
sh(+ShellCommand)
The string or atom ShellCommand is passed as a command to the operating system, and the command is executed there (it is a synonym for system/1).
sleep(+Seconds)
The execution of ECLiPSe is suspended for Seconds number of seconds.
system(+ShellCommand)
The string or atom ShellCommand is passed as a command to the operating system, and the command is executed there (it is a synonym for sh/1).
wait(?Pid, -Status)
Wait for a child process to terminate and report its process ID and status.

Generated from opsys.eci on 2017-07-09 15:37