summaryrefslogtreecommitdiffhomepage
path: root/libs/nixio/docsrc/nixio.lua
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2011-08-12 10:26:33 +0000
committerJo-Philipp Wich <jow@openwrt.org>2011-08-12 10:26:33 +0000
commit2b33717dc402bdd8f1ab9e3f89ecc09d52b2df60 (patch)
treece03d146d2d558f6049ceb36060363bef375f7ef /libs/nixio/docsrc/nixio.lua
parent4e78f77d631309608d9e31733c67650804f068de (diff)
libs/nixio: implement getproto(), getprotobyname() and getprotobynumber()
Diffstat (limited to 'libs/nixio/docsrc/nixio.lua')
-rw-r--r--libs/nixio/docsrc/nixio.lua35
1 files changed, 34 insertions, 1 deletions
diff --git a/libs/nixio/docsrc/nixio.lua b/libs/nixio/docsrc/nixio.lua
index 90331cf23..1b434d76d 100644
--- a/libs/nixio/docsrc/nixio.lua
+++ b/libs/nixio/docsrc/nixio.lua
@@ -37,6 +37,39 @@ module "nixio"
-- <li>ifindex = Interface Index (Linux, "packet"-family)</li>
-- </ul>
+--- Get protocol entry by name.
+-- @usage This function returns nil if the given protocol is unknown.
+-- @class function
+-- @name nixio.getprotobyname
+-- @param name protocol name to lookup
+-- @return Table containing the following fields: <ul>
+-- <li>name = Protocol Name</li>
+-- <li>proto = Protocol Number</li>
+-- <li>aliases = Table of alias names</li>
+-- </ul>
+
+--- Get protocol entry by number.
+-- @usage This function returns nil if the given protocol is unknown.
+-- @class function
+-- @name nixio.getprotobynumber
+-- @param proto protocol number to lookup
+-- @return Table containing the following fields: <ul>
+-- <li>name = Protocol Name</li>
+-- <li>proto = Protocol Number</li>
+-- <li>aliases = Table of alias names</li>
+-- </ul>
+
+--- Get all or a specifc proto entry.
+-- @class function
+-- @name nixio.getproto
+-- @param proto protocol number or name to lookup (optional)
+-- @return Table (or if no parameter is given, a table of tables)
+-- containing the following fields: <ul>
+-- <li>name = Protocol Name</li>
+-- <li>proto = Protocol Number</li>
+-- <li>aliases = Table of alias names</li>
+-- </ul>
+
--- Create a new socket and bind it to a network address.
-- This function is a shortcut for calling nixio.socket and then bind()
-- on the socket object.
@@ -431,4 +464,4 @@ module "nixio"
-- @class function
-- @name nixio.tls
-- @param mode TLS-Mode ["client", "server"]
--- @return TLSContext Object \ No newline at end of file
+-- @return TLSContext Object