Skip to content
LibIpv6_ExternalFunctions.ttcn 2.07 KiB
Newer Older
alex's avatar
alex committed
/*
 *	@author 	STF 276
 *  @version 	$Id$
 *	@desc		This module collects external functions available
 *              to any function implementation in the IPv6 lirbary or
 *              ATS. Notice that the test case execution is only possible
 *              if a Platform Adapter with their implementation is used
 *              by the test system.
 */
 module LibIpv6_ExternalFunctions {
	
	//LibCommon
	import from LibCommon_BasicTypesAndValues all;
	import from LibCommon_DataStrings all;
	//LibIpv6
	import from LibIpv6_MultiRfcs_TypesAndValues { type all };
	import from LibIpv6_Interface { type Ipv6Packet };
seb's avatar
seb committed
	import from LibIpv6_Rfc2460Root_TypesAndValues {type all};
alex's avatar
alex committed


	/* @desc    This external function calculates the payload length
	 *			of a IPv6 packet
	 * @param   p_msg Ipv6 packet
	 * @return  payload length in bytes
alex's avatar
alex committed
	*/
seb's avatar
seb committed
	external function fx_payloadLength( in template Ipv6Packet p_msg ) 
alex's avatar
alex committed
	return UInt16;

	/* @desc   This external function calculates the checksum for any
	 *         IPv6 packet which contains an ICMP message as its payload.
	 * @param  p_packet ICMPv6 packet 
	 * @return checksum value 
alex's avatar
alex committed
	*/
seb's avatar
seb committed
	external function fx_icmpv6Checksum( in template Ipv6Packet p_packet) 
alex's avatar
alex committed
	return Oct2;
validator's avatar
""  
validator committed
	
seb's avatar
seb committed
	external function fx_encodeMessage (in template Ipv6Packet p_msg)
validator's avatar
""  
validator committed
	return octetstring;
alex's avatar
alex committed

seb's avatar
seb committed
	/* @desc   This external function calculates the checksum for MIPv6 Header.
	 * @param  p_mipHeader MipHeader
	 * @return MIPv6 Header checksum
	*/
	external function fx_mipHeaderChecksum( in  MipHeader p_mipHeader) 
	return Oct2;

	/* @desc   This external function calculates the length of MIPv6 Header.
	 * @param  p_mipHeader MipHeader
	 * @return MIPv6 Header length
	*/
	external function fx_mipHeaderLength( in  MipHeader p_mipHeader) 
	return UInt8;

	/* @desc   This external function calculates the length of DstOptHeader .
	 * @param  p_extHdr Extension header
	 * @return DstOpt Header length
	*/
//	external function fx_dstOptHdrLength( in  ExtensionHeader p_extHdr) 
//	return UInt8;

alex's avatar
alex committed
	
}// end module LibIpv6_ExternalFunctions