Package com.dooapp.fxform.validation

Examples of com.dooapp.fxform.validation.PropertyElementValidator


    private final NodeController constraintController;

    public PropertyElementController(final FXForm fxForm, PropertyElement element) {
        super(fxForm, element);
        PropertyElementValidator validator = ((PropertyEditorController) editorController).getPropertyElementValidator();
        validator.constraintViolationsProperty().addListener(new ListChangeListener<ConstraintViolation>() {
            @Override
            public void onChanged(Change<? extends ConstraintViolation> change) {
                while (change.next()) {
                    fxForm.getConstraintViolations().addAll(change.getAddedSubList());
                    fxForm.getConstraintViolations().removeAll(change.getRemoved());
                }
            }
        });
        constraintController = new ConstraintController(fxForm, element, validator.constraintViolationsProperty());
        updateSkin((FXFormSkin) fxForm.getSkin());
        validator.invalidProperty().addListener(new ChangeListener<Boolean>() {
            @Override
            public void changed(ObservableValue<? extends Boolean> observableValue, Boolean aBoolean, Boolean aBoolean2) {
                if (aBoolean2) {
                    addStyle(FXForm.INVALID_STYLE);
                } else {
                    removeStyle(FXForm.INVALID_STYLE);
                }
            }
        });
        validator.warningProperty().addListener(new ChangeListener<Boolean>() {
            @Override
            public void changed(ObservableValue<? extends Boolean> observableValue, Boolean aBoolean, Boolean aBoolean2) {
                if (aBoolean2) {
                    addStyle(FXForm.WARNING_STYLE);
                } else {
View Full Code Here


    private final AnnotationAdapterProvider annotationAdapterProvider = new AnnotationAdapterProvider();

    public PropertyEditorController(FXForm fxForm, Element element) {
        super(fxForm, element);
        propertyElementValidator = new PropertyElementValidator((PropertyElement) element);
        propertyElementValidator.validatorProperty().bind(fxForm.fxFormValidatorProperty());

    }
View Full Code Here

    private final NodeController constraintController;

    public PropertyElementController(final AbstractFXForm fxForm, PropertyElement element) {
        super(fxForm, element);
        PropertyElementValidator validator = ((PropertyEditorController) editorController).getPropertyElementValidator();
        validator.constraintViolationsProperty().addListener(new ListChangeListener<ConstraintViolation>() {
            @Override
            public void onChanged(Change<? extends ConstraintViolation> change) {
                while (change.next()) {
                    fxForm.getConstraintViolations().addAll(change.getAddedSubList());
                    fxForm.getConstraintViolations().removeAll(change.getRemoved());
                }
            }
        });
        constraintController = new ConstraintController(fxForm, element, validator.constraintViolationsProperty());
        updateSkin((FXFormSkin) fxForm.getSkin());
        validator.invalidProperty().addListener(new ChangeListener<Boolean>() {
            @Override
            public void changed(ObservableValue<? extends Boolean> observableValue, Boolean aBoolean, Boolean aBoolean2) {
                if (aBoolean2) {
                    addStyle(FXForm.INVALID_STYLE);
                } else {
                    removeStyle(FXForm.INVALID_STYLE);
                }
            }
        });
        validator.warningProperty().addListener(new ChangeListener<Boolean>() {
            @Override
            public void changed(ObservableValue<? extends Boolean> observableValue, Boolean aBoolean, Boolean aBoolean2) {
                if (aBoolean2) {
                    addStyle(FXForm.WARNING_STYLE);
                } else {
View Full Code Here

    private final AnnotationAdapterProvider annotationAdapterProvider = new AnnotationAdapterProvider();

    public PropertyEditorController(AbstractFXForm fxForm, Element element) {
        super(fxForm, element);
        propertyElementValidator = new PropertyElementValidator((PropertyElement) element);
        propertyElementValidator.validatorProperty().bind(fxForm.fxFormValidatorProperty());

    }
View Full Code Here

    private final NodeController constraintController;

    public PropertyElementController(final AbstractFXForm fxForm, PropertyElement element) {
        super(fxForm, element);
        PropertyElementValidator validator = ((PropertyEditorController) editorController).getPropertyElementValidator();
        validator.constraintViolationsProperty().addListener(new ListChangeListener<ConstraintViolation>() {
            @Override
            public void onChanged(Change<? extends ConstraintViolation> change) {
                while (change.next()) {
                    fxForm.getConstraintViolations().addAll(change.getAddedSubList());
                    fxForm.getConstraintViolations().removeAll(change.getRemoved());
                }
            }
        });
        constraintController = new ConstraintController(fxForm, element, validator.constraintViolationsProperty());
        updateSkin((FXFormSkin) fxForm.getSkin());
        validator.invalidProperty().addListener(new ChangeListener<Boolean>() {
            @Override
            public void changed(ObservableValue<? extends Boolean> observableValue, Boolean aBoolean, Boolean aBoolean2) {
                if (aBoolean2) {
                    addStyle(FXForm.INVALID_STYLE);
                } else {
                    removeStyle(FXForm.INVALID_STYLE);
                }
            }
        });
        validator.warningProperty().addListener(new ChangeListener<Boolean>() {
            @Override
            public void changed(ObservableValue<? extends Boolean> observableValue, Boolean aBoolean, Boolean aBoolean2) {
                if (aBoolean2) {
                    addStyle(FXForm.WARNING_STYLE);
                } else {
View Full Code Here

TOP

Related Classes of com.dooapp.fxform.validation.PropertyElementValidator

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.