JumpToPageDDMFormRuleActionSerializer implements SPIDDMFormRuleActionSerializer { @Override public String serialize( SPIDDMFormRuleSerializerContext spiDDMFormRuleSerializerContext) { if (Validator.isNull(_jumpToPageDDMFormRuleAction.getTarget())) { return null; } return String.format( _FUNCTION_CALL_BINARY_EXPRESSION_FORMAT, "jumpPage", _jumpToPageDDMFormRuleAction.getSource(), _jumpToPageDDMFormRuleAction.getTarget()); } JumpToPageDDMFormRuleActionSerializer(
		JumpToPageDDMFormRuleAction jumpToPageDDMFormRuleAction); @Override String serialize(
		SPIDDMFormRuleSerializerContext spiDDMFormRuleSerializerContext);  }
@Test public void testSerialize() { when( _jumpToPageDDMFormRuleAction.getSource() ).thenReturn( "1" ); when( _jumpToPageDDMFormRuleAction.getTarget() ).thenReturn( "3" ); JumpToPageDDMFormRuleActionSerializer jumpToPageDDMFormRuleActionSerializer = new JumpToPageDDMFormRuleActionSerializer( _jumpToPageDDMFormRuleAction); String result = jumpToPageDDMFormRuleActionSerializer.serialize( _spiDDMFormRuleSerializerContext); Assert.assertEquals("jumpPage(1, 3)", result); }