Newer
Older
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
/**
* @author ETSI / STF405
* @version $URL: svn+ssh://vcs.etsi.org/TTCN3/ATS/Its/trunk/ttcn/AtsIPv6OverGeoNetworking/ItsIpv6OverGeoNetworking_TestCases.ttcn $
* $Id: ItsIpv6OverGeoNetworking_TestCases.ttcn 169 2010-09-23 08:12:36Z berge $
* @desc IPv6 over GeoNetworking Protocol Templates
*
*/
module LibItsIpv6OverGeoNetworking_Templates {
//LibCommon
import from LibCommon_BasicTypesAndValues all;
import from LibCommon_DataStrings all;
//LibIts
import from LibIts_Interface all;
import from LibItsGeoNetworking_TypesAndValues {type Payload;}
import from LibItsIpv6OverGeoNetworking_TypesAndValues all;
group ipv6OverGeoNwPrimitivesTemplates {
template (value) IPv6OverGeoNetworkingReq m_ipv6OverGeoNwReq(
template (value) charstring p_interface,
template (value) MacAddress p_srcMacAddr,
template (value) MacAddress p_dstMacAddr,
template (value) Ipv6Packet p_ipv6Packet
) := {
interface := p_interface,
macSourceAddress := p_srcMacAddr,
macDestinationAddress := p_dstMacAddr,
ipv6Packet := p_ipv6Packet
}
template IPv6OverGeoNetworkingInd mw_ipv6OverGeoNwInd(
template (value) charstring p_interface,
template (value) MacAddress p_srcMacAddr,
template (value) MacAddress p_dstMacAddr,
template (present) Ipv6Packet p_ipv6Packet
) := {
interface := p_interface,
macSourceAddress := p_srcMacAddr,
macDestinationAddress := p_dstMacAddr,
ipv6Packet := p_ipv6Packet
}
} // ipv6OverGeoNwPrimitivesTemplates
group ipv6 {
template Payload mw_ipv6Payload(in template (present) Ipv6Packet p_ipv6Packet) := {
ipv6Packet := p_ipv6Packet
}
template Ipv6Packet m_ipv6Packet(
in template (value) Ipv6Address p_srcAddr,
in template (value) Ipv6Address p_dstAddr,
in template (value) UInt8 p_nextHdr,
in template (omit) Ipv6Payload p_payload
) := {
ipv6Hdr := m_ipv6Header(p_srcAddr, p_dstAddr, p_nextHdr),
extHdrList := omit,
ipv6Payload := p_payload
}
template Ipv6Header m_ipv6Header(
in template (value) Ipv6Address p_srcAddr,
in template (value) Ipv6Address p_dstAddr,
in template (value) UInt8 p_nextHdr
) := {
version := 6,
trafficClass := 0,
flowLabel := 0,
payloadLength := 0, //indicates that the adaptation will fill the correct value
nextHeader := p_nextHdr,
hopLimit := 255,
sourceAddress := p_srcAddr,
destinationAddress := p_dstAddr
}
template Ipv6Payload m_rtAdv := {
routerAdvMsg := {
icmpType := c_rtAdvMsg,
icmpCode := 0,
checksum := c_2ZeroBytes, //indicates that the adaptation will fill the correct value
curHopLimit := 255,
managedConfigFlag := 0,
otherConfigFlag := 0,
homeAgentFlag := 0,
reserved := 0,
routerLifetime := c_uInt16Max,
reachableTime := 0,
retransTimer := 0,
rtAdvOptions := omit
}
}
} // end group ipv6
} // end LibItsIpv6OverGeoNetworking_TypesAndValues