Examples of OgnlValueStack


Examples of com.opensymphony.xwork2.ognl.OgnlValueStack

            WRAPPING_TEMPLATE_MODEL_CONTAINED_OBJECT);
    }

    public void testGetWriter() throws Exception {

        OgnlValueStack stack = (OgnlValueStack)ActionContext.getContext().getValueStack();
       
        final InternalBean bean = new InternalBean(stack);

        MockHttpServletRequest request = new MockHttpServletRequest();
        MockHttpServletResponse response = new MockHttpServletResponse();
View Full Code Here

Examples of com.opensymphony.xwork2.ognl.OgnlValueStack

        container.inject(factory);
        return factory;
    }

    private ValueStack createStubValueStack(final Map<String, Object> actual) {
        ValueStack stack = new OgnlValueStack(
                container.getInstance(XWorkConverter.class),
                (CompoundRootAccessor)container.getInstance(PropertyAccessor.class, CompoundRoot.class.getName()),
                container.getInstance(TextProvider.class, "system"), true) {
            @Override
            public void setValue(String expr, Object value) {
View Full Code Here

Examples of com.opensymphony.xwork2.ognl.OgnlValueStack

        container.inject(factory);
        return factory;
    }

    private ValueStack createStubValueStack(final Map<String, Object> actual) {
        ValueStack stack = new OgnlValueStack(
                container.getInstance(XWorkConverter.class),
                (CompoundRootAccessor)container.getInstance(PropertyAccessor.class, CompoundRoot.class.getName()),
                container.getInstance(TextProvider.class, "system"), true) {
            @Override
            public void setValue(String expr, Object value) {
View Full Code Here

Examples of com.opensymphony.xwork2.ognl.OgnlValueStack

        container.inject(factory);
        return factory;
    }

    private ValueStack createStubValueStack(final Map<String, Object> actual) {
        ValueStack stack = new OgnlValueStack(
                container.getInstance(XWorkConverter.class),
                (CompoundRootAccessor) container.getInstance(PropertyAccessor.class, CompoundRoot.class.getName()),
                container.getInstance(TextProvider.class, "system"), true) {
            @Override
            public void setValue(String expr, Object value) {
View Full Code Here

Examples of com.opensymphony.xwork2.ognl.OgnlValueStack

public class ValidatorSupportTest extends XWorkTestCase {

  public void testConditionalParseExpression()  throws Exception {
    ValueStack oldStack = ActionContext.getContext().getValueStack();
    try {
      OgnlValueStack stack = (OgnlValueStack) container.getInstance(ValueStackFactory.class).createValueStack();
      stack.getContext().put(ActionContext.CONTAINER, container);
      stack.getContext().put("something", "somevalue");
      ActionContext.getContext().setValueStack(stack);
      ValidatorSupport validator = new ValidatorSupport() {
        public void validate(Object object) throws ValidationException {
        }
      };
View Full Code Here

Examples of com.opensymphony.xwork2.util.OgnlValueStack

        ServletContext servletContext = filterConfig.getServletContext();
        ActionContext ctx = ServletActionContext.getActionContext(req);
        if (ctx == null) {
            // ok, one isn't associated with the request, so let's get a ThreadLocal one (which will create one if needed)
            OgnlValueStack vs = new OgnlValueStack();
            vs.getContext().putAll(Dispatcher.getInstance().createContextMap(req, res, null, servletContext));
            ctx = new ActionContext(vs.getContext());
            if (ctx.getActionInvocation() == null) {
                // put in a dummy ActionSupport so basic functionality still works
                ActionSupport action = new ActionSupport();
                vs.push(action);
                ctx.setActionInvocation(new DummyActionInvocation(action));
            }
        }

        // delegate to the actual page decorator
View Full Code Here

Examples of com.opensymphony.xwork2.util.OgnlValueStack

    public void testUnwrapMap() throws Exception {

        MockHttpServletRequest request = new MockHttpServletRequest();
        MockHttpServletResponse response = new MockHttpServletResponse();
        OgnlValueStack stack = new OgnlValueStack();

        Map params = new LinkedHashMap();

        // Try to test out the commons Freemarker's Template Model
View Full Code Here

Examples of com.opensymphony.xwork2.util.OgnlValueStack

            WRAPPING_TEMPLATE_MODEL_CONTAINED_OBJECT);
    }

    public void testGetWriter() throws Exception {

        OgnlValueStack stack = new OgnlValueStack();

        final InternalBean bean = new InternalBean(stack);

        MockHttpServletRequest request = new MockHttpServletRequest();
        MockHttpServletResponse response = new MockHttpServletResponse();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.