aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorAnders Svensson <[email protected]>2012-10-11 02:17:56 +0200
committerAnders Svensson <[email protected]>2012-11-18 19:45:08 +0100
commit8317fec82dc677f299e3772d3d644639f936857a (patch)
tree515385ce504a7c9fadc08328b136cfce5cc6b532 /lib
parent41d6a59fb11c65da9edcf97551b19cbdbf00646f (diff)
downloadotp-8317fec82dc677f299e3772d3d644639f936857a.tar.gz
otp-8317fec82dc677f299e3772d3d644639f936857a.tar.bz2
otp-8317fec82dc677f299e3772d3d644639f936857a.zip
<code> -> <pre> in documentation
The former doesn't allow seealso content, which erl_docgen doesn't enforce, resulting in mangled PDF.
Diffstat (limited to 'lib')
-rw-r--r--lib/diameter/doc/src/diameter.xml76
-rw-r--r--lib/diameter/doc/src/diameter_app.xml8
-rw-r--r--lib/diameter/doc/src/diameter_dict.xml88
3 files changed, 86 insertions, 86 deletions
diff --git a/lib/diameter/doc/src/diameter.xml b/lib/diameter/doc/src/diameter.xml
index c93a7b2c67..ea540562af 100644
--- a/lib/diameter/doc/src/diameter.xml
+++ b/lib/diameter/doc/src/diameter.xml
@@ -110,10 +110,10 @@ defined by the application.</p>
| [Mod | ExtraArgs]
| #diameter_callback{}</c></tag>
<item>
-<code>
+<pre>
Mod = atom()
ExtraArgs = list()
-</code>
+</pre>
<p>
A module implementing the callback interface defined in <seealso
@@ -357,7 +357,7 @@ It is an error to specify duplicate tuples.</p>
An expression that can be evaluated as a function in the following
sense.</p>
-<code>
+<pre>
eval([{M,F,A} | T]) ->
apply(M, F, T ++ A);
eval([[F|A] | T]) ->
@@ -366,7 +366,7 @@ eval([F|A]) ->
apply(F, A);
eval(F) ->
eval([F]).
-</code>
+</pre>
<p>
Applying an <c><seealso marker="#evaluable">evaluable()</seealso></c>
@@ -527,12 +527,12 @@ implies the termination of all transport processes.</p>
<tag><c>{up, Ref, Peer, Config}</c></tag>
<tag><c>{down, Ref, Peer, Config}</c></tag>
<item>
-<code>
+<pre>
Ref = <seealso marker="#transport_ref">transport_ref()</seealso>
Peer = <seealso marker="diameter_app#peer">diameter_app:peer()</seealso>
Config = {connect|listen, [<seealso marker="#transport_opt">transport_opt()</seealso>]}
Pkt = #diameter_packet{}
-</code>
+</pre>
<p>
The RFC 3539 watchdog state machine has
@@ -556,10 +556,10 @@ respect to individual Diameter applications.</p>
<tag><c>{reconnect, Ref, Opts}</c></tag>
<item>
-<code>
+<pre>
Ref = <seealso marker="#transport_ref">transport_ref()</seealso>
Opts = [<seealso marker="#transport_opt">transport_opt()</seealso>]
-</code>
+</pre>
<p>
A connecting transport is attempting to establish/reestablish a
@@ -571,10 +571,10 @@ expiry.</p>
<tag><c>{closed, Ref, Reason, Config}</c></tag>
<item>
-<code>
+<pre>
Ref = <seealso marker="#transport_ref">transport_ref()</seealso>
Config = {connect|listen, [<seealso marker="#transport_opt">transport_opt()</seealso>]}
-</code>
+</pre>
<p>
Capabilities exchange has failed.
@@ -584,13 +584,13 @@ Capabilities exchange has failed.
<tag><c>{'CER', Result, Caps, Pkt}</c></tag>
<item>
-<code>
+<pre>
Result = ResultCode | {capabilities_cb, CB, ResultCode|discard}
Caps = #diameter_caps{}
Pkt = #diameter_packet{}
ResultCode = integer()
CB = <seealso marker="#evaluable">evaluable()</seealso>
-</code>
+</pre>
<p>
An incoming CER has been answered with the indicated result code or
@@ -604,11 +604,11 @@ contains the rejecting callback.</p>
<tag><c>{'CER', Caps, {ResultCode, Pkt}}</c></tag>
<item>
-<code>
+<pre>
ResultCode = integer()
Caps = #diameter_caps{}
Pkt = #diameter_packet{}
-</code>
+</pre>
<p>
An incoming CER contained errors and has been answered with the
@@ -627,12 +627,12 @@ connection establishment.</p>
<tag><c>{'CEA', Result, Caps, Pkt}</c></tag>
<item>
-<code>
+<pre>
Result = integer() | atom() | {capabilities_cb, CB, ResultCode|discard}
Caps = #diameter_caps{}
Pkt = #diameter_packet{}
ResultCode = integer()
-</code>
+</pre>
<p>
An incoming CEA has been rejected for the indicated reason.
@@ -647,10 +647,10 @@ contains the rejecting callback.</p>
<tag><c>{'CEA', Caps, Pkt}</c></tag>
<item>
-<code>
+<pre>
Caps = #diameter_caps{}
Pkt = #diameter_packet{}
-</code>
+</pre>
<p>
An incoming CEA contained errors and has been rejected.
@@ -671,12 +671,12 @@ of connection establishment.</p>
<tag><c>{watchdog, Ref, PeerRef, {From, To}, Config}</c></tag>
<item>
-<code>
+<pre>
Ref = <seealso marker="#transport_ref">transport_ref()</seealso>
PeerRef = <seealso marker="diameter_app#peer_ref">diameter_app:peer_ref()</seealso>
From, To = initial | okay | suspect | down | reopen
Config = {connect|listen, [transport_opt()]}
-</code>
+</pre>
<p>
An RFC 3539 watchdog state machine has changed state.</p>
@@ -772,9 +772,9 @@ to be evaluated at <seealso
marker="#start_service">start_service/2</seealso>.
In particular, an identifier <c>Id</c> is mapped to a new identifier
as follows.</p>
-<code>
+<pre>
(H bsl N) bor (Id band ((1 bsl N) - 1))
-</code>
+</pre>
<p>
Note that RFC 3588 requires that End-to-End identifiers remain unique
for a period of at least 4 minutes and that this and the call rate
@@ -980,9 +980,9 @@ Defaults to a single callback returning <c>dpr</c>.</p>
<marker id="reconnect_timer"/>
<tag><c>{reconnect_timer, Tc}</c></tag>
<item>
-<code>
+<pre>
Tc = <seealso marker="diameter_dict#DATA_TYPES">Unsigned32()</seealso>
-</code>
+</pre>
<p>
For a connecting transport, the RFC 3588 Tc timer, in milliseconds.
@@ -1029,12 +1029,12 @@ For example, the following options on a connecting transport
request a connection with one peer over SCTP or another
(typically the same) over TCP.</p>
-<code>
+<pre>
{transport_module, diameter_sctp}
{transport_config, SctpOpts, 5000}
{transport_module, diameter_tcp}
{transport_config, TcpOpts}
-</code>
+</pre>
<p>
To listen on both SCTP and TCP, define one transport for each.</p>
@@ -1065,10 +1065,10 @@ corresponding timeout (see below) or all fail.</p>
<marker id="watchdog_timer"/>
<tag><c>{watchdog_timer, TwInit}</c></tag>
<item>
-<code>
+<pre>
TwInit = <seealso marker="diameter_dict#DATA_TYPES">Unsigned32()</seealso>
| {M,F,A}
-</code>
+</pre>
<p>
The RFC 3539 watchdog timer.
@@ -1334,7 +1334,7 @@ marker="#add_transport">add_transport/2</seealso> and <c>Ref</c> is
as returned by it.
The remaining forms are equivalent to an arity-3 fun as follows.</p>
-<code>
+<pre>
Pred = fun(transport_ref(), list()): fun(Ref, _, Opts) -> Pred(Ref, Opts) end
Pred = fun(list()): fun(_, _, Opts) -> Pred(Opts) end
Pred = transport_ref(): fun(Ref, _, _) -> Pred == Ref end
@@ -1342,7 +1342,7 @@ Pred = list(): fun(_, _, Opts) -> [] == Pred -- Opts end
Pred = true: fun(_, _, _) -> true end
Pred = false: fun(_, _, _) -> false end
Pred = {M,F,A}: fun(Ref, Type, Opts) -> apply(M, F, [Ref, Type, Opts | A]) end
-</code>
+</pre>
<p>
Removing a transport causes the corresponding transport processes to
@@ -1425,7 +1425,7 @@ An example return value with for a client service with Origin-Host
"client.example.com" configured with a single transport connected to
"server.example.com" might look as follows.</p>
-<code>
+<pre>
[[{ref,#Ref&lt;0.0.0.93>},
{type,connect},
{options,[{transport_module,diameter_tcp},
@@ -1470,7 +1470,7 @@ An example return value with for a client service with Origin-Host
{{{0,258,0},recv,{'Result-Code',2001}},3},
{{{0,280,1},recv},2},
{{{0,280,0},send},2}]}]]
-</code>
+</pre>
<p>
Here <c>ref</c> is a <c><seealso
@@ -1510,7 +1510,7 @@ marker="#transport_ref">transport_ref()</seealso></c>.
The <c>transport</c> info returned by a server with a single client
connection might look as follows.</p>
-<code>
+<pre>
[[{ref,#Ref&lt;0.0.0.61>},
{type,listen},
{options,[{transport_module,diameter_tcp},
@@ -1557,7 +1557,7 @@ connection might look as follows.</p>
{{{0,280,0},send},5},
{{{0,257,1},recv},1},
{{{0,257,0},send},1}]}]]
-</code>
+</pre>
<p>
The information presented here is as in the <c>connect</c> case except
@@ -1576,7 +1576,7 @@ connections and for which Diameter-level statistics are accumulated
only for the lifetime of the transport connection.
A return value for the server above might look as follows.</p>
-<code>
+<pre>
[[{ref,#Ref&lt;0.0.0.61>},
{type,accept},
{options,[{transport_module,diameter_tcp},
@@ -1622,7 +1622,7 @@ A return value for the server above might look as follows.</p>
{{{0,280,0},send},66},
{{{0,257,1},recv},1},
{{{0,257,0},send},1}]}]]
-</code>
+</pre>
<p>
Note that there may be multiple entries with the same <c>ref</c>, in
@@ -1655,14 +1655,14 @@ Otherwise it contains the <c>ref</c>, <c>type</c> and <c>options</c>
tuples as in <c>transport</c> and <c>connections</c> info above.
For example:</p>
-<code>
+<pre>
[{ref,#Ref&lt;0.0.0.61>},
{type,accept},
{options,[{transport_module,diameter_tcp},
{transport_config,[{reuseaddr,true},
{ip,{127,0,0,1}},
{port,3868}]}]}]
-</code>
+</pre>
</item>
</taglist>
diff --git a/lib/diameter/doc/src/diameter_app.xml b/lib/diameter/doc/src/diameter_app.xml
index b6870f7c28..290b8a3984 100644
--- a/lib/diameter/doc/src/diameter_app.xml
+++ b/lib/diameter/doc/src/diameter_app.xml
@@ -559,14 +559,14 @@ application.</p>
<p>
The argument <seealso marker="#packet">packet()</seealso> has the following signature.</p>
-<code>
+<pre>
#diameter_packet{header = #diameter_header{},
avps = [#diameter_avp{}],
msg = record() | undefined,
errors = [<seealso marker="diameter_dict#DATA_TYPES">Unsigned32()</seealso> | {<seealso marker="diameter_dict#DATA_TYPES">Unsigned32()</seealso>, #diameter_avp{}}],
bin = binary(),
transport_data = term()}
-</code>
+</pre>
<p>
The <c>msg</c> field will be <c>undefined</c> in case the request has
@@ -619,9 +619,9 @@ being set by diameter.</p>
Send an answer message to the peer containing the specified
protocol error.
Equivalent to</p>
-<code>
+<pre>
{reply, ['answer-message' | Avps]
-</code>
+</pre>
<p>
where <c>Avps</c> sets the Origin-Host, Origin-Realm, the specified
Result-Code and (if the request sent one) Session-Id AVP's.</p>
diff --git a/lib/diameter/doc/src/diameter_dict.xml b/lib/diameter/doc/src/diameter_dict.xml
index 98adebf145..9d6a6a8f38 100644
--- a/lib/diameter/doc/src/diameter_dict.xml
+++ b/lib/diameter/doc/src/diameter_dict.xml
@@ -125,9 +125,9 @@ is used to identify the relevant dictionary module.</p>
<p>
Example:</p>
-<code>
+<pre>
@id 16777231
-</code>
+</pre>
</item>
@@ -146,9 +146,9 @@ with existing modules in the system.</p>
<p>
Example:</p>
-<code>
+<pre>
@name etsi_e2
-</code>
+</pre>
</item>
@@ -169,9 +169,9 @@ different Diameter applications.</p>
<p>
Example:</p>
-<code>
+<pre>
@prefix etsi_e2
-</code>
+</pre>
</item>
@@ -189,9 +189,9 @@ The section has empty content.</p>
<p>
Example:</p>
-<code>
+<pre>
@vendor 13019 ETSI
-</code>
+</pre>
</item>
@@ -205,13 +205,13 @@ The section content consists of AVP names.</p>
<p>
Example:</p>
-<code>
+<pre>
@avp_vendor_id 2937
WWW-Auth
Domain-Index
Region-Set
-</code>
+</pre>
</item>
@@ -244,9 +244,9 @@ All dictionaries should typically inherit RFC3588 AVPs from
<p>
Example:</p>
-<code>
+<pre>
@inherits diameter_gen_base_rfc3588
-</code>
+</pre>
</item>
@@ -268,12 +268,12 @@ none are to be set.</p>
<p>
Example:</p>
-<code>
+<pre>
@avp_types
Location-Information 350 Grouped MV
Requested-Information 353 Enumerated V
-</code>
+</pre>
<warning>
<p>
@@ -298,11 +298,11 @@ encode/decode.</p>
<p>
Example:</p>
-<code>
+<pre>
@custom_types rfc4005_avps
Framed-IP-Address
-</code>
+</pre>
</item>
<tag><c>@codecs Mod</c></tag>
@@ -315,11 +315,11 @@ Like <c>@custom_types</c> but requires the specified module to export
<p>
Example:</p>
-<code>
+<pre>
@codecs rfc4005_avps
Framed-IP-Address
-</code>
+</pre>
</item>
<tag><c>@messages</c></tag>
@@ -330,7 +330,7 @@ The section content consists of definitions of the form specified in
section 3.2 of RFC 3588, "Command Code ABNF specification".</p>
<!-- RFC 4740 RTR/RTA -->
-<code>
+<pre>
@messages
RTR ::= &lt; Diameter Header: 287, REQ, PXY >
@@ -363,7 +363,7 @@ RTA ::= &lt; Diameter Header: 287, PXY >
* [ Proxy-Info ]
* [ Route-Record ]
* [ AVP ]
-</code>
+</pre>
</item>
@@ -378,14 +378,14 @@ section 4.4 of RFC 3588, "Grouped AVP Values".</p>
<p>
Example:</p>
-<code>
+<pre>
@grouped
SIP-Deregistration-Reason ::= &lt; AVP Header: 383 >
{ SIP-Reason-Code }
[ SIP-Reason-Info ]
* [ AVP ]
-</code>
+</pre>
<p>
Specifying a Vendor-Id in the definition of a grouped AVP is
@@ -408,14 +408,14 @@ otherwise defined in another dictionary.</p>
<p>
Example:</p>
-<code>
+<pre>
@enum SIP-Reason-Code
PERMANENT_TERMINATION 0
NEW_SIP_SERVER_ASSIGNED 1
SIP_SERVER_CHANGE 2
REMOVE_SIP_SERVER 3
-</code>
+</pre>
</item>
<tag><c>@end</c></tag>
@@ -450,22 +450,22 @@ contained in the message or grouped AVP in the order specified in the
definition in question.
For example, the grouped AVP</p>
-<code>
+<pre>
SIP-Deregistration-Reason ::= &lt; AVP Header: 383 >
{ SIP-Reason-Code }
[ SIP-Reason-Info ]
* [ AVP ]
-</code>
+</pre>
<p>
will result in the following record definition given an empty
prefix.</p>
-<code>
+<pre>
-record('SIP-Deregistration-Reason' {'SIP-Reason-Code',
'SIP-Reason-Info',
'AVP'}).
-</code>
+</pre>
<p>
The values encoded in the fields of generated records depends on the
@@ -507,7 +507,7 @@ callback upon reception of an incoming request.</p>
<marker id="Float64"/>
<marker id="Grouped"/>
-<code>
+<pre>
OctetString() = [0..255]
Integer32() = -2147483647..2147483647
Integer64() = -9223372036854775807..9223372036854775807
@@ -516,7 +516,7 @@ Unsigned64() = 0..18446744073709551615
Float32() = '-infinity' | float() | infinity
Float64() = '-infinity' | float() | infinity
Grouped() = record()
-</code>
+</pre>
<p>
On encode, an OctetString() can be specified as an iolist(),
@@ -530,10 +530,10 @@ section.</p>
<em>Derived AVP Data Formats</em></p>
<marker id="Address"/>
-<code>
+<pre>
Address() = OctetString()
| tuple()
-</code>
+</pre>
<p>
On encode, an OctetString() IPv4 address is parsed in the usual
@@ -545,7 +545,7 @@ An IPv6 tuple() has length 8 and contains values of type 0..65535.
The tuple representation is used on decode.</p>
<marker id="Time"/>
-<code>
+<pre>
Time() = {date(), time()}
where
@@ -559,7 +559,7 @@ where
Hour = 0..23
Minute = 0..59
Second = 0..59
-</code>
+</pre>
<p>
Additionally, values that can be encoded are
@@ -569,9 +569,9 @@ In particular, only values between <c>{{1968,1,20},{3,14,8}}</c>
and <c>{{2104,2,26},{9,42,23}}</c> (both inclusive) can be encoded.</p>
<marker id="UTF8String"/>
-<code>
+<pre>
UTF8String() = [integer()]
-</code>
+</pre>
<p>
List elements are the UTF-8 encodings of the individual characters
@@ -579,15 +579,15 @@ in the string.
Invalid codepoints will result in encode/decode failure.</p>
<marker id="DiameterIdentity"/>
-<code>
+<pre>
DiameterIdentity() = OctetString()
-</code>
+</pre>
<p>
A value must have length at least 1.</p>
<marker id="DiameterURI"/>
-<code>
+<pre>
DiameterURI() = OctetString()
| #diameter_URI{type = Type,
fqdn = FQDN,
@@ -602,7 +602,7 @@ where
Port = integer()
Transport = sctp | tcp
Protocol = diameter | radius | 'tacacs+'
-</code>
+</pre>
<p>
On encode, fields port, transport and protocol default to 3868, sctp
@@ -612,9 +612,9 @@ section 4.3 of RFC 3588.
The record representation is used on decode.</p>
<marker id="Enumerated"/>
-<code>
+<pre>
Enumerated() = Integer32()
-</code>
+</pre>
<p>
On encode, values can be specified using the macros defined in a
@@ -622,10 +622,10 @@ dictionary's hrl file.</p>
<marker id="IPFilterRule"/>
<marker id="QoSFilterRule"/>
-<code>
+<pre>
IPFilterRule() = OctetString()
QoSFilterRule() = OctetString()
-</code>
+</pre>
<p>
Values of these types are not currently parsed by diameter.</p>