Package org.hdiv.state

Examples of org.hdiv.state.IState


    dataComposer.beginRequest("POST", "test.do");
    String result = dataComposer.compose("test.do", "parameter1", "2", false);
    assertEquals("0", result);
    String stateId = dataComposer.endRequest();

    IState state = this.stateUtil.restoreState(stateId);
    assertNotNull(state);
    assertEquals("test.do", state.getAction());

    dataComposer.endPage();
  }
View Full Code Here


    String stateId = dataComposer.endRequest();
    dataComposer.endPage();

    assertNotNull(stateId);

    IState state = this.stateUtil.restoreState(stateId);

    assertEquals("test test.do", state.getAction());

    // Encoded action url
    dataComposer = this.dataComposerFactory.newInstance(request);
    HDIVUtil.setDataComposer(dataComposer, request);

    dataComposer.startPage();
    dataComposer.beginRequest("POST", "test%20test.do");
    stateId = dataComposer.endRequest();
    dataComposer.endPage();

    assertNotNull(stateId);

    state = this.stateUtil.restoreState(stateId);

    // State action value is decoded because we store decoded values only
    assertEquals("test test.do", state.getAction());
  }
View Full Code Here

    assertEquals("value1", val);

    dataComposer.endPage();

    // Restore state
    IState state = stateUtil.restoreState(stateValue);
    assertNotNull(state);

    IParameter param = state.getParameter("param");
    List<String> values = param.getValues();
    assertTrue(values.size() == 1);

    String value = values.get(0);
    assertEquals("value", value);
View Full Code Here

TOP

Related Classes of org.hdiv.state.IState

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.