p4.setName( "StringResult" );
pwd.addResult( p4 );
m.addRhsItem( awi );
ActionSetField asf = new ActionSetField();
asf.setVariable( "$r" );
ActionWorkItemFieldValue fv1 = new ActionWorkItemFieldValue( "ResultsBooleanResult",
DataType.TYPE_BOOLEAN,
"WorkItem",
"BooleanResult",
Boolean.class.getName() );
asf.addFieldValue( fv1 );
ActionWorkItemFieldValue fv2 = new ActionWorkItemFieldValue( "ResultsFloatResult",
DataType.TYPE_NUMERIC_FLOAT,
"WorkItem",
"FloatResult",
Float.class.getName() );
asf.addFieldValue( fv2 );
ActionWorkItemFieldValue fv3 = new ActionWorkItemFieldValue( "ResultsIntegerResult",
DataType.TYPE_NUMERIC_INTEGER,
"WorkItem",
"IntegerResult",
Integer.class.getName() );
asf.addFieldValue( fv3 );
ActionWorkItemFieldValue fv4 = new ActionWorkItemFieldValue( "ResultsStringResult",
DataType.TYPE_STRING,
"WorkItem",
"StringResult",
String.class.getName() );
asf.addFieldValue( fv4 );
m.addRhsItem( asf );
String result = RuleModelDRLPersistenceImpl.getInstance().marshal( m );