<br />In general all functions are namend and behave like their POSIX API
counterparts - where applicable - applying the following rules:
<ul>
- <li>Functions should be named like the underlying POSIX API function omitting
+ <li>Functions should be named like the underlying POSIX API function omitting
prefixes or suffixes - especially when placed in an object-context (
lockf -> File:lock, fsync -> File:sync, dup2 -> dup, ...)</li>
<li>If you are unclear about the behaviour of a function you should consult
<li>If the name is significantly different from the POSIX-function, the
underlying function(s) are stated in the documentation.</li>
<li>Parameters should reflect those of the C-API, buffer length arguments and
- by-reference parameters should be omitted for pratical purposes.</li>
+ by-reference parameters should be omitted for practical purposes.</li>
<li>If a C function accepts a bitfield as parameter, it should be translated
into lower case string flags representing the flags if the bitfield is the
- last parameter and also omitting prefixes or suffixes. (e.g. waitpid
+ last parameter and also omitting prefixes or suffixes. (e.g. waitpid
(pid, &s, WNOHANG | WUNTRACED) -> waitpid(pid, "nohang", "untraced"),
getsockopt(fd, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt)) ->
Socket:getopt("socket", "reuseaddr"), etc.) </li>
<li>The blocksize given is only advisory and to be seen as an upper limit,
if an underlying read returns less bytes the chunk is nevertheless returned.
- <li>If the limit parameter is omitted, the iterator returns data
+ <li>If the limit parameter is omitted, the iterator returns data
until an end-of-file, end-of-stream, connection shutdown or similar happens.
<li>The iterator will not buffer so it is safe to mix with calls to read.
<li>This function uses the blocksource function of the source descriptor
and the sink function of the target descriptor.
- <li>If the limit parameter is omitted, data is copied
+ <li>If the limit parameter is omitted, data is copied
until an end-of-file, end-of-stream, connection shutdown or similar happens.
<li>If the descriptor is non-blocking the function may fail with EAGAIN.
blocksource function of the source descriptor and the sink function
of the target descriptor as a fallback mechanism.
- <li>If the limit parameter is omitted, data is copied
+ <li>If the limit parameter is omitted, data is copied
until an end-of-file, end-of-stream, connection shutdown or similar happens.
<li>If the descriptor is non-blocking the function may fail with EAGAIN.
you can pass "true" to the iterator which will flush the buffer
and return the bufferd data.
- <li>If the limit parameter is omitted, this function uses the nixio
+ <li>If the limit parameter is omitted, this function uses the nixio
buffersize (8192B by default).
<li>If the descriptor is non-blocking the iterator may fail with EAGAIN.
<li>This function uses the low-level read function of the descriptor.
- <li>If the length parameter is omitted, this function returns all data
+ <li>If the length parameter is omitted, this function returns all data
that can be read before an end-of-file, end-of-stream, connection shutdown
or similar happens.
-- <br />In general all functions are namend and behave like their POSIX API
-- counterparts - where applicable - applying the following rules:
-- <ul>
--- <li>Functions should be named like the underlying POSIX API function ommiting
+-- <li>Functions should be named like the underlying POSIX API function omitting
-- prefixes or suffixes - especially when placed in an object-context (
-- lockf -> File:lock, fsync -> File:sync, dup2 -> dup, ...)</li>
-- <li>If you are unclear about the behaviour of a function you should consult
-- <li>If the name is significantly different from the POSIX-function, the
-- underlying function(s) are stated in the documentation.</li>
-- <li>Parameters should reflect those of the C-API, buffer length arguments and
--- by-reference parameters should be ommitted for pratical purposes.</li>
+-- by-reference parameters should be omitted for practical purposes.</li>
-- <li>If a C function accepts a bitfield as parameter, it should be translated
-- into lower case string flags representing the flags if the bitfield is the
--- last parameter and also ommiting prefixes or suffixes. (e.g. waitpid
+-- last parameter and also omitting prefixes or suffixes. (e.g. waitpid
-- (pid, &s, WNOHANG | WUNTRACED) -> waitpid(pid, "nohang", "untraced"),
-- getsockopt(fd, SOL_SOCKET, SO_REUSEADDR, &opt, sizeof(opt)) ->
-- Socket:getopt("socket", "reuseaddr"), etc.) </li>
--- Send a message on the socket.
-- This function is identical to sendto except for the missing destination
--- paramters. See the sendto description for a detailed description.
+-- parameters. See the sendto description for a detailed description.
-- @class function
-- @name Socket.send
-- @param buffer Buffer holding the data to be written.
-- "mtu" (IP, IPv6), "hdrincl" (IP), "multicast_ttl" (IP), "multicast_loop"
-- (IP, IPv6), "multicast_if" (IP, IPv6), "v6only" (IPv6), "multicast_hops"
-- (IPv6), "add_membership" (IP, IPv6), "drop_membership" (IP, IPv6)]
--- @return Value
\ No newline at end of file
+-- @return Value
-- @class function
-- @name UnifiedIO.readall
-- @usage This function uses the low-level read function of the descriptor.
--- @usage If the length parameter is ommited, this function returns all data
+-- @usage If the length parameter is omitted, this function returns all data
-- that can be read before an end-of-file, end-of-stream, connection shutdown
-- or similar happens.
-- @usage If the descriptor is non-blocking this function may fail with EAGAIN.
-- @param length Bytes to read (optional)
--- @return data that was successfully read if no error occured
+-- @return data that was successfully read if no error occurred
-- @return - reserved for error code -
-- @return - reserved for error message -
--- @return data that was successfully read even if an error occured
+-- @return data that was successfully read even if an error occurred
--- Write a block of data and wait until all data is written.
-- @class function
-- @usage This function uses the low-level write function of the descriptor.
-- @usage If the descriptor is non-blocking this function may fail with EAGAIN.
-- @param block Bytes to write
--- @return bytes that were successfully written if no error occured
+-- @return bytes that were successfully written if no error occurred
-- @return - reserved for error code -
-- @return - reserved for error message -
--- @return bytes that were successfully written even if an error occured
+-- @return bytes that were successfully written even if an error occurred
--- Create a line-based iterator.
-- Lines may end with either \n or \r\n, these control chars are not included
-- to stop reading line-based and want to use the read(all) functions instead
-- you can pass "true" to the iterator which will flush the buffer
-- and return the bufferd data.
--- @usage If the limit parameter is ommited, this function uses the nixio
+-- @usage If the limit parameter is omitted, this function uses the nixio
-- buffersize (8192B by default).
-- @usage If the descriptor is non-blocking the iterator may fail with EAGAIN.
-- @usage The iterator can be used as an LTN12 source.
-- @usage This function uses the low-level read function of the descriptor.
-- @usage The blocksize given is only advisory and to be seen as an upper limit,
-- if an underlying read returns less bytes the chunk is nevertheless returned.
--- @usage If the limit parameter is ommited, the iterator returns data
+-- @usage If the limit parameter is omitted, the iterator returns data
-- until an end-of-file, end-of-stream, connection shutdown or similar happens.
-- @usage The iterator will not buffer so it is safe to mix with calls to read.
-- @usage If the descriptor is non-blocking the iterator may fail with EAGAIN.
-- @name UnifiedIO.copy
-- @usage This function uses the blocksource function of the source descriptor
-- and the sink function of the target descriptor.
--- @usage If the limit parameter is ommited, data is copied
+-- @usage If the limit parameter is omitted, data is copied
-- until an end-of-file, end-of-stream, connection shutdown or similar happens.
-- @usage If the descriptor is non-blocking the function may fail with EAGAIN.
-- @param fdout Target Descriptor
-- @param size Bytes to copy (optional)
--- @return bytes that were successfully written if no error occured
+-- @return bytes that were successfully written if no error occurred
-- @return - reserved for error code -
-- @return - reserved for error message -
--- @return bytes that were successfully written even if an error occured
+-- @return bytes that were successfully written even if an error occurred
--- Copy data from the current descriptor to another one using kernel-space
-- copying if possible.
-- @usage This function uses the sendfile() syscall to copy the data or the
-- blocksource function of the source descriptor and the sink function
-- of the target descriptor as a fallback mechanism.
--- @usage If the limit parameter is ommited, data is copied
+-- @usage If the limit parameter is omitted, data is copied
-- until an end-of-file, end-of-stream, connection shutdown or similar happens.
-- @usage If the descriptor is non-blocking the function may fail with EAGAIN.
-- @param fdout Target Descriptor
-- @param size Bytes to copy (optional)
--- @return bytes that were successfully written if no error occured
+-- @return bytes that were successfully written if no error occurred
-- @return - reserved for error code -
-- @return - reserved for error message -
--- @return bytes that were successfully written even if an error occured
+-- @return bytes that were successfully written even if an error occurred
--- Close the descriptor.
-- @class function
-- @name UnifiedIO.close
-- @usage If the descriptor is a TLS-socket the underlying descriptor is
-- closed without touching the TLS connection.
--- @return true
\ No newline at end of file
+-- @return true
-- @name nixio.fs.rename
-- @param src Source path
-- @param dest Destination path
--- @usage It is normally not possible to rename files accross filesystems.
+-- @usage It is normally not possible to rename files across filesystems.
-- @return true
--- Remove an empty directory.
-- omit the basename even if source and destination basename are equal.
-- @param src Source path
-- @param dest Destination path
--- @return true
\ No newline at end of file
+-- @return true
-- @param flag1 First Flag ["append", "creat", "excl", "nonblock", "ndelay",
-- "sync", "trunc", "rdonly", "wronly", "rdwr"]
-- @param ... More Flags [-"-]
--- @return flag to be used as second paramter to open
+-- @return flag to be used as second parameter to open
--- Duplicate a file descriptor.
-- @class function
--- Wait for some event on a file descriptor.
-- poll() sets the revents-field of the tables provided by fds to a bitfield
--- indicating the events that occured.
+-- indicating the events that occurred.
-- @class function
-- @usage This function works in-place on the provided table and only
-- writes the revents field, you can use other fields on your demand.
--- Set or unset a environment variable.
-- @class function
-- @name nixio.setenv
--- @usage The environment variable will be unset if value is ommited.
+-- @usage The environment variable will be unset if value is omitted.
-- @param variable Variable
-- @param value Value (optional)
-- @return true