File: inets.3

package info (click to toggle)
erlang-manpages 1%3A12.b.3-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 4,188 kB
  • ctags: 2
  • sloc: makefile: 68; perl: 30; sh: 15
file content (144 lines) | stat: -rw-r--r-- 3,189 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
.TH inets 3 "inets  5.0.9" "Ericsson AB" "ERLANG MODULE DEFINITION"
.SH MODULE
inets \- The inets services API
.SH DESCRIPTION
.LP
This module provides the most basic API to the clients and servers, that are part of the Inets application, such as start and stop\&. 

.SH COMMON DATA TYPES 
.LP
Type definitions that are used more than once in this module: 
.LP
\fI service() = ftpc | tfptd | httpc | httpd\fR
.LP
\fI property() = atom() \fR
.SH EXPORTS
.LP
.B
services() -> [{Service, Pid}]
.br
.RS
.TP
Types
Service = service()
.br
Pid = pid()
.br
.RE
.RS
.LP
Returns a list of currently running services\&.
.SS Note:
.LP
Services started as \fIstand_alone\fR will not be listed\&.

.RE
.LP
.B
service_info() -> [{Service, Pid, Info}]
.br
.RS
.TP
Types
Service = service()
.br
Pid = pid()
.br
Info = [{Option, Value}]
.br
Option = property()
.br
Value = term()
.br
.RE
.RS
.LP
Returns a list of currently running services where each service is described by a [{Option, Value}] list\&. The information given in the list is specific for each service and it is probable that each service will have its own info function that gives you even more details about the service\&.
.RE
.LP
.B
service_names() -> [Service] 
.br
.RS
.TP
Types
Service = service()
.br
.RE
.RS
.LP
Returns a list of available service names\&.
.RE
.LP
.B
start() -> 
.br
.B
start(Type) -> ok | {error, Reason}
.br
.RS
.TP
Types
Type = permanent | transient | temporary
.br
.RE
.RS
.LP
Starts the Inets application\&. Default type is temporary\&. See also application(3)
.RE
.LP
.B
stop() -> ok 
.br
.RS
.LP
Stops the inets application\&. See also application(3)
.RE
.LP
.B
start(Service, ServiceConfig) -> 
.br
.B
start(Service, ServiceConfig, How) -> {ok, Pid} | {error, Reason}
.br
.RS
.TP
Types
Service = service()
.br
ServiceConfig = [{Option, Value}]
.br
Option = property()
.br
Value = term()
.br
How = inets | stand_alone - default is inets
.br
.RE
.RS
.LP
Dynamically starts an inets service after the inets application has been started\&. 
.SS Note:
.LP
Dynamically started services will not be handled by application takeover and failover behavior when inets is run as a distributed application\&. Nor will they be automaticly restarted when the inets application is restarted, but as long as the inets application is up and running they will be supervised and may be soft code upgraded\&. Services started as \fIstand_alone\fR, e\&.i\&. the service is not started as part of the inets application, will lose all OTP application benefits such as soft upgrade\&. The "stand_alone-service" will be linked to the process that started it\&. In most cases some of the supervison functionallity will still be in place and in some sense the calling process has now become the top supervisor\&.

.RE
.LP
.B
stop(Service, Reference) -> 
.br
.RS
.TP
Types
Service = service() | stand_alone
.br
Reference = pid() | term() - service specified reference 
.br
.RE
.RS
.LP
Stops a started service of the inets application or takes down a "stand_alone-service" gracefully\&. When the \fIstand_alone\fR option is used in start, only the pid is a valid argument to stop\&.
.RE
.SH SEE ALSO
.LP
ftp(3), http(3), httpd(3), tftp(3)