Re: Execute actions VS external functions

Hi Noldus,

You wrote on Thu, 24 May 2012 19:12:42 +0200 [1]:
>
> I was wondering how (taken from RIF-PRD specification)
> Do(Execute( act:print(func:concat("New customer: " _c1)) ))
> differs from ('Do(Execute' changed in 'External')
> External( act:print(func:concat("New customer: " _c1)) )
> To me it seems they both execute the function. Could
> someone please explain me the difference between the two?

The RIF-PRD specification does not allow External as an action => the 
proposed alternative conclusion, using External, is not a well-formed 
action block in RIF-PRD, and its semantics are not defined.

This being said, you are right that Execute is, essentially, the RHS 
counter-part of Externa. The different syntax emphasizes the different 
roles in the semantics of PRD: with External, a, externally defined 
function is executed to check whether a substitution is matching or not; 
with Execute, it is executed for its side effects only, and whatever is 
maps to is discarded.

Cheers,

Christian

IBM
9 rue de Verdun
94253 - Gentilly cedex - FRANCE
Tel./Fax: +33 1 49 08 29 81


Sauf indication contraire ci-dessus:/ Unless stated otherwise above:
Compagnie IBM France
Siège Social : 17 avenue de l'Europe, 92275 Bois-Colombes Cedex
RCS Nanterre 552 118 465
Forme Sociale : S.A.S.
Capital Social : 639.291.962.10 ?
SIREN/SIRET : 552 118 465 03644 - Code NAF 6202A 

Received on Tuesday, 19 June 2012 13:22:59 UTC