Package tripleplay.ui

Examples of tripleplay.ui.Field$Validator


    @Test
    public void value_type_check_skipped_for_null_values() throws Exception
    {
        Field field = mockField();
        MessageFormatter formatter = mockMessageFormatter();
        Validator validator = mockValidator();

        train_isRequired(validator, true);

        validator.validate(field, null, formatter, null);

        replay();

        FieldValidator fv = new FieldValidatorImpl(field, null, formatter, validator, null);
View Full Code Here


    public FieldValidator createValidator(Field field, String validatorType, String constraintValue, String overrideId,
                                          Messages overrideMessages, Locale locale)
    {
        notBlank(validatorType, "validatorType");

        Validator validator = validators.get(validatorType);

        if (validator == null)
            throw new IllegalArgumentException(
                    ServicesMessages.unknownValidatorType(validatorType, InternalUtils.sortedKeys(validators)));
View Full Code Here

        return "UI: History Group";
    }

    @Override
    protected Group createIface () {
        final Field prefix = new Field("Love Potion Number ");
        Button add10 = new Button("+10");
        Button add100 = new Button("+100");
        HistoryGroup.Labels history = new HistoryGroup.Labels();
        final SizableGroup historyBox = new SizableGroup(new BorderLayout());
        historyBox.add(history.setConstraint(BorderLayout.CENTER));
        Slider width = new Slider(150, 25, 1024);
        Group top = new Group(AxisLayout.horizontal()).add(
            prefix.setConstraint(AxisLayout.stretched()), add10, add100, width);
        width.value.connectNotify(new Slot<Float>() {
            @Override public void onEmit (Float val) {
                historyBox.preferredSize.updateWidth(val);
            }
        });
View Full Code Here

TOP

Related Classes of tripleplay.ui.Field$Validator

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.