File: megaco_encoder.html

package info (click to toggle)
erlang-doc-html 1%3A11.b.2-1
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 23,284 kB
  • ctags: 10,724
  • sloc: erlang: 505; ansic: 323; makefile: 62; perl: 61; sh: 45
file content (129 lines) | stat: -rw-r--r-- 3,753 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
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<!-- This document was generated using DocBuilder 3.3.3 -->
<HTML>
<HEAD>
  <TITLE>megaco_encoder</TITLE>
  <SCRIPT type="text/javascript" src="../../../../doc/erlresolvelinks.js">
</SCRIPT>
  <STYLE TYPE="text/css">
<!--
    .REFBODY     { margin-left: 13mm }
    .REFTYPES    { margin-left: 8mm }
-->
  </STYLE>
</HEAD>
<BODY BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#FF00FF"
      ALINK="#FF0000">
<!-- refpage -->
<CENTER>
<A HREF="http://www.erlang.se">
  <IMG BORDER=0 ALT="[Ericsson AB]" SRC="min_head.gif">
</A>
<H1>megaco_encoder</H1>
</CENTER>

<H3>MODULE</H3>
<DIV CLASS=REFBODY>
megaco_encoder
</DIV>

<H3>MODULE SUMMARY</H3>
<DIV CLASS=REFBODY>
Megaco encoder begaviour.
</DIV>

<H3>DESCRIPTION</H3>
<DIV CLASS=REFBODY>

<P> The following functions should be exported from a 
<CODE>megaco_encoder</CODE> callback module:
</DIV>

<H3>EXPORTS</H3>

<P><A NAME="Module:encode_message/3"><STRONG><CODE>Module:encode_message(EncodingConfig, Version, Message) -&#62; {ok, Bin} | Error</CODE></STRONG></A><BR>

<DIV CLASS=REFBODY><P>Types:
  <DIV CLASS=REFTYPES>
<P>
<STRONG><CODE>EncodingConfig = list()</CODE></STRONG><BR>
<STRONG><CODE>Version = integer()</CODE></STRONG><BR>
<STRONG><CODE>Message = megaco_message()</CODE></STRONG><BR>
<STRONG><CODE>Bin = binary()</CODE></STRONG><BR>
<STRONG><CODE>Error = term()</CODE></STRONG><BR>

  </DIV>
</DIV>

<DIV CLASS=REFBODY>

<P>Encode a megaco message.
</DIV>

<P><A NAME="Module:decode_message/3"><STRONG><CODE>Module:decode_message(EncodingConfig, Version, Bin) -&#62; {ok, Message} | Error</CODE></STRONG></A><BR>

<DIV CLASS=REFBODY><P>Types:
  <DIV CLASS=REFTYPES>
<P>
<STRONG><CODE>EncodingConfig = list()</CODE></STRONG><BR>
<STRONG><CODE>Version = integer() | dynamic</CODE></STRONG><BR>
<STRONG><CODE>Message = megaco_message()</CODE></STRONG><BR>
<STRONG><CODE>Bin = binary()</CODE></STRONG><BR>
<STRONG><CODE>Error = term()</CODE></STRONG><BR>

  </DIV>
</DIV>

<DIV CLASS=REFBODY>

<P>Decode a megaco message. 
<P>Note that if the Version argument is <CODE>dynamic</CODE>, the
         decoder should try to figure out the actual version from the
         message itself and then use the proper decoder, e.g. version 1.
         <BR>
If on the other hand the Version argument is an integer, 
         it means that this is the expected version of the message and 
         the decoder for that version should be used.
</DIV>

<P><A NAME="Module:decode_mini_message/3"><STRONG><CODE>Module:decode_mini_message(EncodingConfig, Version, Bin) -&#62; {ok, Message} | Error</CODE></STRONG></A><BR>

<DIV CLASS=REFBODY><P>Types:
  <DIV CLASS=REFTYPES>
<P>
<STRONG><CODE>EncodingConfig = list()</CODE></STRONG><BR>
<STRONG><CODE>Version = integer() | dynamic</CODE></STRONG><BR>
<STRONG><CODE>Message = megaco_message()</CODE></STRONG><BR>
<STRONG><CODE>Bin = binary()</CODE></STRONG><BR>
<STRONG><CODE>Error = term()</CODE></STRONG><BR>

  </DIV>
</DIV>

<DIV CLASS=REFBODY>

<P>Perform a minimal decode of a megaco message. 
<P>The purpose of this function is to do a minimal decode of
Megaco message. A successfull result is a <CODE>'MegacoMessage'</CODE> 
in which only version and mid has been initiated. This function 
is used by the megaco_messeger module when the 
<CODE>decode_message/3</CODE> function failes to figure out the mid 
(the actual sender) of the message.
<P>Note again that a successfull decode only returns a
partially initiated message.
</DIV>

<H3>AUTHORS</H3>
<DIV CLASS=REFBODY>
Micael Karlberg - support@erlang.ericsson.se<BR>

</DIV>
<CENTER>
<HR>
<SMALL>megaco 3.5<BR>
Copyright &copy; 1991-2006
<A HREF="http://www.erlang.se">Ericsson AB</A><BR>
</SMALL>
</CENTER>
</BODY>
</HTML>