Package org.apache.tapestry5.internal.util

Examples of org.apache.tapestry5.internal.util.IntegerRange


        return propertyName;
    }

    public final IntegerRange range(int from, int to)
    {
        return new IntegerRange(from, to);
    }
View Full Code Here


        PropertyConduit pc = source.create(IntegerHolder.class, "10..value");
        IntegerHolder h = new IntegerHolder();

        h.setValue(5);

        IntegerRange ir = (IntegerRange) pc.get(h);

        assertEquals(ir, new IntegerRange(10, 5));
    }
View Full Code Here

        PropertyConduit pc = source.create(IntegerHolder.class, "value..99");
        IntegerHolder h = new IntegerHolder();

        h.setValue(72);

        IntegerRange ir = (IntegerRange) pc.get(h);

        assertEquals(ir, new IntegerRange(72, 99));
    }
View Full Code Here

        return propertyType;
    }

    public final IntegerRange range(int from, int to)
    {
        return new IntegerRange(from, to);
    }
View Full Code Here

                if (fromNode.getType() != INTEGER || toNode.getType() != INTEGER) break;

                int from = Integer.parseInt(fromNode.getText());
                int to = Integer.parseInt(toNode.getText());

                IntegerRange ir = new IntegerRange(from, to);

                return createLiteralConduit(IntegerRange.class, ir);

            case THIS:
View Full Code Here

                        { " -227", -227l },
                        { " 5.", 5d },
                        { " -100.", -100d },
                        { " -0.0 ", -0d },
                        { "+50", 50l },
                        { "+7..+20", new IntegerRange(7, 20) },
                        { "+5.5", 5.5d },
                        { "1..10", new IntegerRange(1, 10) },
                        { " -20 .. -30 ", new IntegerRange(-20, -30) },
                        { "0.", 0d },
                        { " 227.75", 227.75d },
                        { " -10123.67", -10123.67d },
                        { "'Hello World'", "Hello World" },
                        { " 'Whitespace Ignored' ", "Whitespace Ignored" },
View Full Code Here

        PropertyConduit pc = source.create(IntegerHolder.class, "10..value");
        IntegerHolder h = new IntegerHolder();

        h.setValue(5);

        IntegerRange ir = (IntegerRange) pc.get(h);

        assertEquals(ir, new IntegerRange(10, 5));
    }
View Full Code Here

        PropertyConduit pc = source.create(IntegerHolder.class, "value..99");
        IntegerHolder h = new IntegerHolder();

        h.setValue(72);

        IntegerRange ir = (IntegerRange) pc.get(h);

        assertEquals(ir, new IntegerRange(72, 99));
    }
View Full Code Here

                if (matcher.matches())
                {
                    int start = Integer.parseInt(matcher.group(1));
                    int finish = Integer.parseInt(matcher.group(2));

                    IntegerRange range = new IntegerRange(start, finish);

                    return new LiteralBinding(description, range, location);
                }

                return null;
View Full Code Here

        PropertyConduit pc = source.create(IntegerHolder.class, "10..value");
        IntegerHolder h = new IntegerHolder();

        h.setValue(5);

        IntegerRange ir = (IntegerRange) pc.get(h);

        assertEquals(ir, new IntegerRange(10, 5));
    }
View Full Code Here

TOP

Related Classes of org.apache.tapestry5.internal.util.IntegerRange

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.