The R Project SVN R

Rev

Rev 59039 | Rev 60531 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 59039 Rev 60528
Line 1... Line 1...
1
% File src/library/utils/man/make.socket.Rd
1
% File src/library/utils/man/make.socket.Rd
2
% Part of the R package, http://www.R-project.org
2
% Part of the R package, http://www.R-project.org
3
% Copyright 1995-2007 R Core Team
3
% Copyright 1995-2012 R Core Team
4
% Distributed under GPL 2 or later
4
% Distributed under GPL 2 or later
5
 
5
 
6
\name{make.socket}
6
\name{make.socket}
7
\alias{make.socket}
7
\alias{make.socket}
8
\alias{print.socket}
8
\alias{print.socket}
Line 16... Line 16...
16
  \item{fail}{failure to connect is an error?}
16
  \item{fail}{failure to connect is an error?}
17
  \item{server}{a server socket?}
17
  \item{server}{a server socket?}
18
}
18
}
19
\description{
19
\description{
20
  With \code{server = FALSE} attempts to open a client socket to the
20
  With \code{server = FALSE} attempts to open a client socket to the
21
  specified port and host. With \code{server = TRUE} listens on the
21
  specified port and host.  With \code{server = TRUE} the \R process
22
  specified port for a connection and then returns a server socket. It is
22
  listens on the specified port for a connection and then returns a
23
  a good idea to use \code{\link{on.exit}} to ensure that a socket is
23
  server socket.  It is a good idea to use \code{\link{on.exit}} to
24
  closed, as you only get 64 of them.
24
  ensure that a socket is closed, as you only get 64 of them.
25
}
25
}
26
\value{
26
\value{
27
  An object of class \code{"socket"}.
27
  An object of class \code{"socket"}, a list with components:
28
  \item{socket}{socket number. This is for internal use}
28
  \item{socket}{socket number.  This is for internal use.}
29
  \item{port}{port number of the connection}
29
  \item{port}{port number of the connection.}
30
  \item{host}{name of remote computer}
30
  \item{host}{name of remote computer.}
31
}
31
}
32
\author{Thomas Lumley}
32
\author{Thomas Lumley}
33
\references{
33
\references{
34
  Adapted from Luke Tierney's code for \code{XLISP-Stat}, in turn
34
  Adapted from Luke Tierney's code for \code{XLISP-Stat}, in turn
35
  based on code from Robbins and Robbins "Practical UNIX Programming"
35
  based on code from Robbins and Robbins \dQuote{Practical UNIX Programming}.
36
}
36
}
37
\section{Warning}{
37
\section{Warning}{
38
  I don't know if the connecting host name returned
38
  I don't know if the connecting host name returned
39
  when \code{server = TRUE} can be trusted. I suspect not.
39
  when \code{server = TRUE} can be trusted.  I suspect not.
40
} 
40
} 
41
 
41
 
42
\seealso{
42
\seealso{
43
  \code{\link{close.socket}}, \code{\link{read.socket}}
43
  \code{\link{close.socket}}, \code{\link{read.socket}}
44
}
44
}