RE: SDL-News: Unions


Subject: RE: SDL-News: Unions
From: SUEL Jean-Francois CNET/DTL/LAN (jeanfrancois.suel#cnet.francetelecom.fr)
Date: Thu Apr 15 1999 - 16:07:33 GMT


The originator of this message is responsible for its content.
-----From SUEL Jean-Francois CNET/DTL/LAN <jeanfrancois.suel#cnet.francetelecom.fr> to sdlnews -----

Using Z.105, you can use ASN.1 CHOICE type, which has an union semantic :
- declaration of the type : MyUnion::=CHOICE { field1 Field1type, field2
Field2type };
- declaration of a variable : dcl myVar MyUnion;
- and you can use its value with all the operators which come with the
CHOICE type :
        myVar!field1:=aField1typeValue;
        then field1Present(myVar) is TRUE and field2Present(myVar) is FALSE
JF.

> ----------
> De : joanna.archer#bt.com[SMTP:joanna.archer#bt.com]
> Répondre à : joanna.archer#bt.com
> Date : jeudi 15 avril 1999 17:38
> A : sdlnews#sdl-forum.org
> Objet : SDL-news: Unions
>
> The originator of this message is responsible for its content.
> -----From joanna.archer#bt.com to sdlnews -----
>
> I realise unions are not supported by SDL but can't they be specified as
> an
> Abstract Data Type and if so does anyone know where this has been done
> that
> I can cut and paste from as I'm not sure I'd like to go through the
> rigmarole of defining operations and axioms etc....
>
> Jo
>
> -----End text from joanna.archer#bt.com to sdlnews -----
> For help, email "majordomo#sdl-forum.org" with the body of your email as:
> help
> or (iff this does not answer your question) email:
> owner-sdlnews#sdl-forum.org
>

-----End text from SUEL Jean-Francois CNET/DTL/LAN <jeanfrancois.suel#cnet.francetelecom.fr> to sdlnews -----
For help, email "majordomo#sdl-forum.org" with the body of your email as:
    help
or (iff this does not answer your question) email: owner-sdlnews#sdl-forum.org



This archive was generated by hypermail 2a23 : Sun Jun 16 2013 - 10:41:40 GMT