Simple Friendly Enough Expression Language (S-FEEL) is described by DMN. This Section will show you how S-FEEL Expressions get translated to RuleML or Prova. Please choose a language:

FEEL expression can used as assigning or comparison.

 

$$ X := 7 \cdot a / 20 - c $$

        
    

Simple Literal Rule number 33

String Literal Rule number 34

S-FEEL grammar rule:
string literal = '"' , { character – ('"' | vertical space) }, '"' ;
RuleML serialization example:
<Data xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xs="http://www.w3.org/2001/XMLSchema" xsi:type="xs:string">Summer</Data>

Boolean Literal Rule number 35

S-FEEL grammar rule:
Boolean literal = "true" | "false" ;
RuleML serialization example:
<Data xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xs="http://www.w3.org/2001/XMLSchema" xsi:type="xs:boolean">true</Data>

Numeric Literal Rule numbers 36, 37, 38

S-FEEL grammar rule:
numeric literal = [ "-" ] , ( digits , [ ".", digits ] | "." , digits ) ;
digit = [0-9] ;
digits = digit , {digit} ;
RuleML serialization example:
<Data xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xs="http://www.w3.org/2001/XMLSchema" xsi:type="xs:double">3.14</Data>

Date Time Literal Rule number 39

This literal type is currently not supported.

S-FEEL grammar rule:
date time literal = ("date" | "time" | "duration" ) , "(" , string literal , ")" ;

Simple Expressions Rule number 6

S-FEEL grammar rule:
simpleExpressions: (simpleExpression ','?)+ | simpleExpression;

Simple Expression Rule number 5

S-FEEL grammar rule:
simpleExpression: arithmetic | simpleUnaryTests | simpleValue;

Simple Value Rule number 19

S-FEEL grammar rule:
simpleValue: simpleLiteral | qualifiedName;

Qualified Name Rule number 20

S-FEEL grammar rule:
qualifiedName: ( '.'? Name )+;
Name: NameStartChar (NamePartChar+ | AdditionalNameSymbols)*;

Endpoint Rule number 18

S-FEEL grammar rule:
endpoint: simpleValue;

Arithmetic Rule number 4

S-FEEL grammar rule
arithmetic
: <assoc=right> simpleExpression ^ simpleExpression
| simpleExpression / simpleExpression
| simpleExpression * simpleExpression
| simpleExpression + simpleExpression
| simpleExpression - simpleExpression
| - simpleExpression
;
RuleML Translation $ 1 + 3 $ example:

                
            

Simple Unary Tests Rule number 14

S-FEEL grammar rule:
simpleUnaryTests: simplePositiveUnaryTests | NOT '(' simplePositiveUnaryTests ')' | '-';

Simple Positive Unary Tests Rule number 13

S-FEEL grammar rule:
simplePositiveUnaryTests: (simplePositiveUnaryTest ','?)+;

Simple Positive Unary Test Rule number 7

S-FEEL grammar rule:
simplePositiveUnaryTest: (< | <= | > | >=) endpoint | interval;
RuleML Translation $ \geq 12 $ example:

                
            

Interval Rule numbers 8, 9, 10 , 11, 12

S-FEEL grammar rule:
interval: (openIntervalStart | closedIntervalStart ) endpoint '..' endpoint (openIntervalEnd | closedIntervalEnd );
openIntervalStart: '(' | ']';
closedIntervalStart: '[';
openIntervalEnd: ')' | '[';
closedIntervalEnd: ']';
..
RuleML Translation $ [ 5 .. 17 ] $ example: