Re: Octopus

Re: Octopus

From: Jos Warmer ^lt;>
Date: Tue 31 Jan 2006 - 08:10:38 GMT
Message-ID: <>

Octopus can generate code for checking all invariants and preconditions.
Octopus also generate code for OCL used in init expressions, derivation 
rules and body-expressions for operations.

Preconditions are turned into assert statements, and can be turned on or 
off using standard Java features.

For each invariant an operation is generated that checks the invariant. 
The tiome and place where you want to
call this invariant operation is up to yourself. Since we cannot check 
invariants "always". we have chosen that
the checking strategy has to be chosen y the developer.
To allow testing your invariants the user interface generated by Octopus 
(Eclipse RCP) has buttons to perform
checking invariants for either a single object or for all objects in the 
system. These buttons simply call the
invariant operations.

Init expressions, derivation rules for derived attributes and body 
expressions for query operations are all generated
and always used inside the Java code.

Octopus does not generate test cases, although this might be an 
interesting extension.

Hope this helps to clarify things,


Andrea Baruzzo wrote:
> Dear Jos,
> thank you for your reply. In fact at present I am able only to load
> the model in xmi and the ocl specifications, performing a static
> checking of their syntactical correctness. I am not able to generate
> any code.
> Aside from these issues, I am interested to better understand which
> type of checks Octopus is able to perform. For example, the Octopus
> web site states:
> 1. Octopus is able to statically check OCL expressions. It checks the
> syntax, as well as the expression types, and the correct use of model
> elements like association roles and attributes.
> 2. Octopus is able to transform the UML model, including the OCL
> expressions, into Java code.
> Does Octopus verify the invariants, preconditions and postconditions
> in the model for every possible scenario? If so, this check is static
> (without requiring to generate any test case and test scenario), or it
> is dynamic, based upon a specific test execution?
> Thanks in advice for any further infromation about these concerns.
> Cordially,
> Andrea
> On 1/30/06, Jos Warmer <> wrote:
>> Andrea,
>> The current distribution is for Eclipse 3.0.  Internally we have a new
>> version of Octopus running with
>> Eclipse 3.1, and it will be distributed soon. We are in progress of
>> getting Octopus on sourceforge for this.
>> Regards, Jos Warmer
> --
> __________________________________________________________
> Dr. Andrea Baruzzo
> Laboratorio di Intelligenza Artificiale
> UniversitÓ degli Studi di Udine, Via delle Scienze 206, 33100 Udine
> Memberships: IEEE Computer Society
> homepage:
> Office: +39 0432 558435
> ___________________________________________________________
> To remove yourself from this list please mail
> with a message containing the word "unsubscribe".
Received on Mon Jan 30 20:10:47 2006