RE: [atl_discussion] UML2 transformation

From: Peter Rosenthal <peter.rosenthal_at_example.com>
Date: Tue Feb 01 2005 - 12:06:09 CET

Hello,

Yes, ->isEmpty() and ->notEmpty() should work if you have a recent ATL
version.
See also
http://www.sciences.univ-nantes.fr/lina/atl/cgi-bin/atlwebservice.sh?query=S
equence+%7B1%2C+2%2C+3%7D-%3EisEmpty%28%29

Yesterday afternoon, I started building an OCL tutorial
(work in progress) which is based on an OCL web test tool by Fred.
http://www.sciences.univ-nantes.fr/lina/atl/cgi-bin/atlwebservice.sh?query=t
rue+or+false
where you can test some OCL expressions that are supported by OCL.

Here is the link to the tutorial:
http://www.sciences.univ-nantes.fr/lina/atl/atldemo/oclturorial/

regards,
Peter

PS.: The version distributed on the GMT site and the version of the
OCL web test tool may not always be the same.
I have not checked if ->isEmpty() and ->notEmpty() is supported by the GMT
distributed version.

-----Message d'origine-----
De : Guillaume Savaton [mailto:guillaume.savaton@eseo.fr]
Envoyé : mardi 1 février 2005 11:48
À : Peter Rosenthal
Cc : atl_discussion@yahoogroups.com
Objet : Re: [atl_discussion] UML2 transformation

Peter Rosenthal a écrit :

> Hello,
>
> The program below works as indicated by Guillaume if the multiplicity is
> 0..1.
>
> However the returnResult has the multiplicity 0..n which means that it is
> represented by a collection. You need to test if the collection is empty,
> and not if the collection is null.
>
> Try to use ->size()=0

Another solution is to use ->isEmpty()

I was wondering if ->notEmpty() is supported ?

-- 
Guillaume Savaton
----------------------------
ESEO
4, rue Merlet de la Boulaye - BP 30926
49009 Angers Cedex 01
France
Tél (ligne directe) : +33(0)2.41.86.67.60
Tél (accueil) : +33(0)2.41.86.67.67
Fax : +33(0)2.41.87.99.27
           
Received on Tue Feb 01 03:09:15 2005

This archive was generated by hypermail 2.1.8 : Thu Jan 18 2007 - 15:04:54 CET