Mercurial > luasocket
comparison doc/dns.html @ 0:4b915342e2a8
LuaSocket 2.0.2 + CMake build description.
author | Eric Wing <ewing . public |-at-| gmail . com> |
---|---|
date | Tue, 26 Aug 2008 18:40:01 -0700 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:4b915342e2a8 |
---|---|
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" | |
2 "http://www.w3.org/TR/html4/strict.dtd"> | |
3 <html> | |
4 | |
5 <head> | |
6 <meta name="description" content="LuaSocket: DNS support"> | |
7 <meta name="keywords" content="Lua, LuaSocket, DNS, Network, Library, Support"> | |
8 <title>LuaSocket: DNS support</title> | |
9 <link rel="stylesheet" href="reference.css" type="text/css"> | |
10 </head> | |
11 | |
12 <body> | |
13 | |
14 <!-- header +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | |
15 | |
16 <div class=header> | |
17 <hr> | |
18 <center> | |
19 <table summary="LuaSocket logo"> | |
20 <tr><td align=center><a href="http://www.lua.org"> | |
21 <img width=128 height=128 border=0 alt="LuaSocket" src="luasocket.png"> | |
22 </a></td></tr> | |
23 <tr><td align=center valign=top>Network support for the Lua language | |
24 </td></tr> | |
25 </table> | |
26 <p class=bar> | |
27 <a href="home.html">home</a> · | |
28 <a href="home.html#download">download</a> · | |
29 <a href="installation.html">installation</a> · | |
30 <a href="introduction.html">introduction</a> · | |
31 <a href="reference.html">reference</a> | |
32 </p> | |
33 </center> | |
34 <hr> | |
35 </div> | |
36 | |
37 <!-- dns ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | |
38 | |
39 <h2 id=dns>DNS</h2> | |
40 | |
41 <p> | |
42 Name resolution functions return <em>all</em> information obtained from the | |
43 resolver in a table of the form: | |
44 </p> | |
45 | |
46 <blockquote><tt> | |
47 resolved = {<br> | |
48 name = <i>canonic-name</i>,<br> | |
49 alias = <i>alias-list</i>,<br> | |
50 ip = <i>ip-address-list</i><br> | |
51 } | |
52 </tt> </blockquote> | |
53 | |
54 <p> | |
55 Note that the <tt>alias</tt> list can be empty. | |
56 </p> | |
57 | |
58 <!-- gethostname ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | |
59 | |
60 <p class=name id=gethostname> | |
61 socket.dns.<b>gethostname()</b> | |
62 </p> | |
63 | |
64 <p class=description> | |
65 Returns the standard host name for the machine as a string. | |
66 </p> | |
67 | |
68 <!-- tohostname +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | |
69 | |
70 <p class=name id=tohostname> | |
71 socket.dns.<b>tohostname(</b>address<b>)</b> | |
72 </p> | |
73 | |
74 <p class=description> | |
75 Converts from IP address to host name. | |
76 </p> | |
77 | |
78 <p class=parameters> | |
79 <tt>Address</tt> can be an IP address or host name. | |
80 </p> | |
81 | |
82 <p class=return> | |
83 The function returns a string with the canonic host name of the given | |
84 <tt>address</tt>, followed by a table with all information returned by | |
85 the resolver. In case of error, the function returns <b><tt>nil</tt></b> | |
86 followed by an error message. | |
87 </p> | |
88 | |
89 <!-- toip +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | |
90 | |
91 <p class=name id=toip> | |
92 socket.dns.<b>toip(</b>address<b>)</b> | |
93 </p> | |
94 | |
95 <p class=description> | |
96 Converts from host name to IP address. | |
97 </p> | |
98 | |
99 <p class=parameters> | |
100 <tt>Address</tt> can be an IP address or host name. | |
101 </p> | |
102 | |
103 <p class=return> | |
104 Returns a string with the first IP address found for <tt>address</tt>, | |
105 followed by a table with all information returned by the resolver. | |
106 In case of error, the function returns <b><tt>nil</tt></b> followed by an error | |
107 message. | |
108 </p> | |
109 | |
110 <!-- footer +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ --> | |
111 | |
112 <div class=footer> | |
113 <hr> | |
114 <center> | |
115 <p class=bar> | |
116 <a href="home.html">home</a> · | |
117 <a href="home.html#down">download</a> · | |
118 <a href="installation.html">installation</a> · | |
119 <a href="introduction.html">introduction</a> · | |
120 <a href="reference.html">reference</a> | |
121 </p> | |
122 <p> | |
123 <small> | |
124 Last modified by Diego Nehab on <br> | |
125 Thu Apr 20 00:25:07 EDT 2006 | |
126 </small> | |
127 </p> | |
128 </center> | |
129 </div> | |
130 | |
131 </body> | |
132 </html> |