Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Titan » TTCN-3 record with a field of type "port"(TTCN-3)
TTCN-3 record with a field of type "port" [message #1848441] Thu, 02 December 2021 08:43 Go to next message
Yann Garcia is currently offline Yann GarciaFriend
Messages: 153
Registered: June 2016
Senior Member
Hello All,

I have the following TTCN-3 data structure
	type port MyPort  message {
		in 
			MsgIn;
		out 
			MsgOut;
	};
	type record Interface {
		MyPort myPort,
		charstring myHost,
		charstring myProtocolBinding,
		charstring mySerialization
	}


While compiling the code, I got the following error:
Port type `@OneM2M_Ports.OneM2MPort' cannot be embedded into another type


But, according to the TTCN-3 Core Language standard, this kind of data structure is authorized.

Is it a limitation of TITAN? Is there a work-around to address it?

Many thanks for your support,

BR\Yann
Re: TTCN-3 record with a field of type "port" [message #1848475 is a reply to message #1848441] Fri, 03 December 2021 11:57 Go to previous messageGo to next message
Lenard Nagy is currently offline Lenard NagyFriend
Messages: 54
Registered: September 2016
Member
Hi Yann,

Though the standard states that "The fields of a record type may be of any TTCN-3 type" the BNF of the Type (which is the definition of field type for records) does not allow port type as a field of a record:

404.Type ::= PredefinedType | ReferencedType
405.PredefinedType ::= BitStringKeyword |
BooleanKeyword |
CharStringKeyword |
UniversalCharString |
IntegerKeyword |
OctetStringKeyword |
HexStringKeyword |
VerdictTypeKeyword |
FloatKeyword |
AddressKeyword |
DefaultKeyword |
AnyTypeKeyword |
TimerKeyword

I have the following questions:
1: Is there something in the standard that we might have missed and port should be allowed here?
2: Could You please explain why You would need a port to be inserted in a record? We might suggest an alternative solution.

Lenard
Re: TTCN-3 record with a field of type "port" [message #1848576 is a reply to message #1848475] Wed, 08 December 2021 12:47 Go to previous message
Yann Garcia is currently offline Yann GarciaFriend
Messages: 153
Registered: June 2016
Senior Member
Hello Lenard,

Thanks a lot for your feedback.

This is about oneM2M Conformance test suite.
We have several network interface (mcc, mca...). To prevent a lot of test in send/receive functions, a component variable was created (with the type record), containing the port, the binding, the serialization and so on.
Initially, this test suite was develop with TTworkbench and I'm trying to compile it with TITAN.

Regarding the TTCN-3 type, you're right, so I have to find another way to go.

Many thanks again for your help,

BR\Yann
Previous Topic:Eclipse Titan 8.1.0 Release announcement
Next Topic:Compiler core dump on Linux and Windows
Goto Forum:
  


Current Time: Sat Nov 02 05:22:03 GMT 2024

Powered by FUDForum. Page generated in 0.04125 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top