Examples of findValue()


Examples of com.fasterxml.jackson.databind.JsonNode.findValue()

            try {
                ObjectMapper mapper = new ObjectMapper();
                JsonParser jp = mapper.getFactory().createParser(getBuiltQuery());
                JsonNode rootNode = mapper.readTree(jp);
                JsonNode timestampNode = rootNode.findValue("range").findValue("timestamp");
                String from = Tools.elasticSearchTimeFormatToISO8601(timestampNode.findValue("from").asText());
                String to = Tools.elasticSearchTimeFormatToISO8601(timestampNode.findValue("to").asText());
                boundaries = new AbsoluteRange(from, to);
            } catch (Exception ignored) {}
        }
View Full Code Here

Examples of com.fasterxml.jackson.databind.JsonNode.findValue()

                ObjectMapper mapper = new ObjectMapper();
                JsonParser jp = mapper.getFactory().createParser(getBuiltQuery());
                JsonNode rootNode = mapper.readTree(jp);
                JsonNode timestampNode = rootNode.findValue("range").findValue("timestamp");
                String from = Tools.elasticSearchTimeFormatToISO8601(timestampNode.findValue("from").asText());
                String to = Tools.elasticSearchTimeFormatToISO8601(timestampNode.findValue("to").asText());
                boundaries = new AbsoluteRange(from, to);
            } catch (Exception ignored) {}
        }

        return boundaries;
View Full Code Here

Examples of com.opensymphony.xwork.util.OgnlValueStack.findValue()

    {
        actualName = findString( nameAttr );
        String msg = null;
        OgnlValueStack stack = getStack();
        //find the name on the valueStack, and cast it to a date
        Object dateObj = stack.findValue( actualName );

        if ( dateObj != null )
        {
            if ( dateObj instanceof Date )
            {
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.findValue()

        proxy.execute();
        proxy.getAction();

        //then
        assertEquals("This is blah", ((SimpleAction) proxy.getAction()).getBlah());
        Object allowMethodAccess = stack.findValue("\u0023_memberAccess['allowStaticMethodAccess']");
        assertNotNull(allowMethodAccess);
        assertEquals(Boolean.FALSE, allowMethodAccess);
    }

    public void testParameters() throws Exception {
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.findValue()

        if (expr == null) {
            return null;
        }

        ValueStack stack = context.getStack();
        return stack.findValue(ComponentUtils.stripExpressionIfAltSyntax(stack, expr));
    }

    private Object findValue(String expr, Class toType) {
        ValueStack stack = context.getStack();
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.findValue()

        ValueStack stack = context.getStack();

        if (altSyntax && toType == String.class) {
            return TextParseUtil.translateVariables('%', expr, stack);
        } else {
            return stack.findValue(ComponentUtils.stripExpressionIfAltSyntax(stack, expr), toType);
        }
    }
}
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.findValue()

        final ValueStack stack = ActionContext.getContext().getValueStack();

        if (application != null)
            for (int i = 0; i < application.length; i++) {
                String string = application[i];
                Object value = stack.findValue(string);
                if (LOG.isDebugEnabled()) {
                    LOG.debug("application scoped variable saved " + string + " = " + String.valueOf(value));
                }

                //if( value != null)
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.findValue()

                for (int i = 0; i < session.length; i++) {
                    String string = session[i];
                    if (ends) {
                        ses.remove(key + string);
                    } else {
                        Object value = stack.findValue(string);

                        if (LOG.isDebugEnabled()) {
                            LOG.debug("session scoped variable saved " + string + " = " + String.valueOf(value));
                        }
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.findValue()

    }

    public void testValueStackWithTypeParameter() {
        ValueStack stack = ActionContext.getContext().getValueStack();
        stack.push(new Foo1());
        Bar1 bar = (Bar1) stack.findValue("bar", Bar1.class);
        assertNotNull(bar);
    }

    public void testGenericProperties() {
        GenericsBean gb = new GenericsBean();
View Full Code Here

Examples of com.opensymphony.xwork2.util.ValueStack.findValue()

        stack.setValue("genericMap[123.12]", "66");
        stack.setValue("genericMap[456.12]", "42");

        assertEquals(2, gb.getGenericMap().size());
        assertEquals(Integer.class, stack.findValue("genericMap.get(123.12).class"));
        assertEquals(Integer.class, stack.findValue("genericMap.get(456.12).class"));
        assertEquals(66, stack.findValue("genericMap.get(123.12)"));
        assertEquals(42, stack.findValue("genericMap.get(456.12)"));
        assertEquals(true, stack.findValue("genericMap.containsValue(66)"));
        assertEquals(true, stack.findValue("genericMap.containsValue(42)"));
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.