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
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
|
<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE erlref SYSTEM "erlref.dtd">
<erlref>
<header>
<copyright>
<year>2004</year><year>2013</year>
<holder>Ericsson AB. All Rights Reserved.</holder>
</copyright>
<legalnotice>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
</legalnotice>
<title>snmpa_network_interface</title>
<prepared></prepared>
<responsible></responsible>
<docno></docno>
<approved></approved>
<checked></checked>
<date></date>
<rev></rev>
<file>snmpa_network_interface.xml</file>
</header>
<module>snmpa_network_interface</module>
<modulesummary>Behaviour module for the SNMP agent network interface.</modulesummary>
<description>
<p>This module defines the behaviour of the agent network
interface. A <c>snmpa_network_interface</c> compliant module
must export the following functions: </p>
<list type="bulleted">
<item>
<p><seealso marker="#start_link">start_link/4</seealso></p>
</item>
<item>
<p><seealso marker="#info">info/1</seealso></p>
</item>
<item>
<p><seealso marker="#get_log_type">get_log_type/1</seealso></p>
</item>
<item>
<p><seealso marker="#set_log_type">set_log_type/2</seealso></p>
</item>
<item>
<p><seealso marker="#verbosity">verbosity/2</seealso></p>
</item>
</list>
<p>The semantics of them and their exact signatures are explained
below. </p>
<p>But this is not enough. There is also a set of <em>mandatory</em>
messages which the network interface entity must be able to
receive and be able to send. This is described in chapter
<seealso marker="snmp_agent_netif">snmp_agent_netif</seealso>.
</p>
<marker id="start_link"></marker>
</description>
<funcs>
<func>
<name>start_link(Prio, NoteStore, MasterAgent, Opts) -> {ok, Pid} | {error, Reason}</name>
<fsummary>Start-link the network interface process</fsummary>
<type>
<v>Prio = priority()</v>
<v>NoteStore = pid()</v>
<v>MasterAgent = pid()</v>
<v>Opts = [opt()]</v>
<v>opt() = {verbosity, verbosity()} | {versions, versions()} | term()</v>
<v>versions() = [version()]</v>
<v>version() = v1 | v2 | v3</v>
</type>
<desc>
<p>Start-link the network interface process.</p>
<p><c>NoteStore</c> is the pid of the note-store process and
<c>MasterAgent</c> is the pid of the master-agent process.</p>
<p><c>Opts</c> is an (basically) implementation dependent list of
options to the network interface process. There are however
a number of options which <em>must</em> be handled:
<c>versions</c> and <c>verbosity</c>.</p>
<marker id="info"></marker>
</desc>
</func>
<func>
<name>info(Pid) -> [{Key, Value}]</name>
<fsummary>Return information about the running network interface process</fsummary>
<type>
<v>Pid = pid()</v>
</type>
<desc>
<p>The info returned is basically up to the implementer to decide.
This implementation provided by the application provides info about
memory allocation and various socket information.</p>
<p>The info returned by this function is returned together with other
info collected by the agent when the
<seealso marker="snmpa#info">info</seealso> function is called
(tagged with with the key <c>net_if</c>).</p>
<marker id="verbosity"></marker>
</desc>
</func>
<func>
<name>verbosity(Pid, Verbosity) -> void()</name>
<fsummary>Change the verbosity of a running network interface process</fsummary>
<type>
<v>Pid = pid()</v>
<v>Verbosity = verbosity()</v>
</type>
<desc>
<p>Change the verbosity of a running network interface process.</p>
<marker id="get_log_type"></marker>
</desc>
</func>
<func>
<name>get_log_type(Pid) -> {ok, LogType} | {error, Reason}</name>
<fsummary>Get the Audit Trail Log type</fsummary>
<type>
<v>Pid = pid()</v>
<v>LogType = atl_type()</v>
<v>Reason = term()</v>
</type>
<desc>
<p>The Audit Trail Log is managed by the network interface process.
So, it is this process that has to retrieve the actual log-type. </p>
<!--
<p>See
<seealso marker="snmpa#get_log_type">get_log_type</seealso>
for more info. </p>
-->
<marker id="set_log_type"></marker>
</desc>
</func>
<func>
<name>set_log_type(Pid, NewType) -> {ok, OldType} | {error, Reason}</name>
<fsummary>Change the Audit Trail Log type</fsummary>
<type>
<v>Pid = pid()</v>
<v>NewType = OldType = atl_type()</v>
<v>Reason = term()</v>
</type>
<desc>
<p>The Audit Trail Log is managed by the network interface process.
So, it is this process that has to do the actual changing of the
type. </p>
<p>See
<seealso marker="snmpa#set_log_type">set_log_type</seealso>
for more info. </p>
</desc>
</func>
</funcs>
</erlref>
|