Examples of LongTranslator


Examples of org.apache.hivemind.schema.rules.LongTranslator

        assertEquals(new Long(0), t.translate(null, null, null, null));
    }

    public void testLongLow()
    {
        LongTranslator t = new LongTranslator("min=5,max=200");

        try
        {

            t.translate(null, null, "3", null);
            unreachable();
        }
        catch (ApplicationRuntimeException ex)
        {
View Full Code Here

Examples of org.apache.hivemind.schema.rules.LongTranslator

    }

    public void testLongHigh()
    {

        LongTranslator t = new LongTranslator("min=5,max=200");

        try
        {

            t.translate(null, null, "50900", null);
            unreachable();
        }
        catch (ApplicationRuntimeException ex)
        {
View Full Code Here

Examples of org.apache.hivemind.schema.rules.LongTranslator

        }
    }

    public void testLongDefaultValue()
    {
        LongTranslator t = new LongTranslator("default=7");

        assertEquals(new Long(7), t.translate(null, null, null, null));
    }
View Full Code Here

Examples of org.apache.hivemind.schema.rules.LongTranslator

        assertEquals(new Long(7), t.translate(null, null, null, null));
    }

    public void testLongInvalid()
    {
        LongTranslator t = new LongTranslator("default=13");

        try
        {

            t.translate(null, null, "qbert", null);
            unreachable();
        }
        catch (ApplicationRuntimeException ex)
        {
            assertExceptionSubstring(ex, "'qbert' is not a long value.");
View Full Code Here

Examples of org.apache.tapestry.translator.LongTranslator

    public static void contributeTranslatorDefaultSource(
            MappedConfiguration<Class, Translator> configuration)
    {
        configuration.add(Integer.class, new IntegerTranslator());
        configuration.add(String.class, new StringTranslator());
        configuration.add(Long.class, new LongTranslator());
        configuration.add(Double.class, new DoubleTranslator());
    }
View Full Code Here

Examples of org.apache.tapestry.translator.LongTranslator

        // organized (perhaps they should be joined together into a single service, where we
        // identify a name and a match type).

        configuration.add("integer", new IntegerTranslator());
        configuration.add("string", new StringTranslator());
        configuration.add("long", new LongTranslator());
        configuration.add("double", new DoubleTranslator());
    }
View Full Code Here

Examples of org.apache.tapestry.translator.LongTranslator

        // organized (perhaps they should be joined together into a single service, where we
        // identify a name and a match type).

        configuration.add("integer", new IntegerTranslator());
        configuration.add("string", new StringTranslator());
        configuration.add("long", new LongTranslator());
        configuration.add("double", new DoubleTranslator());
    }
View Full Code Here

Examples of org.apache.tapestry.translator.LongTranslator

    public static void contributeTranslatorDefaultSource(
            MappedConfiguration<Class, Translator> configuration)
    {
        configuration.add(Integer.class, new IntegerTranslator());
        configuration.add(String.class, new StringTranslator());
        configuration.add(Long.class, new LongTranslator());
        configuration.add(Double.class, new DoubleTranslator());
    }
View Full Code Here

Examples of org.apache.tapestry.translator.LongTranslator

    public static void contributeTranslatorDefaultSource(
            MappedConfiguration<Class, Translator> configuration)
    {
        configuration.add(Integer.class, new IntegerTranslator());
        configuration.add(String.class, new StringTranslator());
        configuration.add(Long.class, new LongTranslator());
        configuration.add(Double.class, new DoubleTranslator());
    }
View Full Code Here

Examples of org.apache.tapestry.translator.LongTranslator

        // organized (perhaps they should be joined together into a single service, where we
        // identify a name and a match type).

        configuration.add("integer", new IntegerTranslator());
        configuration.add("string", new StringTranslator());
        configuration.add("long", new LongTranslator());
        configuration.add("double", new DoubleTranslator());
    }
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.