Package org.zkoss.zul

Examples of org.zkoss.zul.Constraint


                    _("Invaldid End Date. New End Date must be after current End Date "));
        }
    }

    public Constraint validateStartDate() {
        return new Constraint() {
            @Override
            public void validate(Component comp, Object value)
                    throws WrongValueException {
                validateStartDate(comp, value);
            }
View Full Code Here


            row.appendChild(removeButton);
        }


    public Constraint checkConstraintFormatPrefix() {
        return new Constraint() {
            @Override
            public void validate(Component comp, Object value)
                    throws WrongValueException {

                Row row = (Row) comp.getParent();
View Full Code Here

        }
        return null;
    }

    public Constraint checkConstraintNumberOfDigits() {
        return new Constraint() {

            @Override
            public void validate(Component comp, Object value)
                    throws WrongValueException {
                Row row = (Row) comp.getParent();
View Full Code Here

            }

            public Constraint checkPropertyValue(
                    final ConnectorProperty property) {
                final String key = property.getKey();
                return new Constraint() {
                    @Override
                    public void validate(Component comp, Object value) {
                        if (key.equals(PredefinedConnectorProperties.ACTIVATED)) {
                            if (!((String) value).equalsIgnoreCase("Y")
                                    && !((String) value).equalsIgnoreCase("N")) {
View Full Code Here

                }
            }
        }

        private Constraint getBudgetConstraintFor(final T line) {
            return new Constraint() {
                @Override
                public void validate(Component comp, Object value)
                        throws WrongValueException {
                    if (value == null) {
                        throw new WrongValueException(comp,
View Full Code Here

            }
            return (Treeitem) cmp;
        }

        private Constraint getHoursConstraintFor(final T line) {
            return new Constraint() {
                @Override
                public void validate(Component comp, Object value)
                        throws WrongValueException {
                    if (!getHoursGroupHandler().isTotalHoursValid(line, ((Integer) value))) {
                        throw new WrongValueException(
View Full Code Here

    public void updateLoadRatios() {
        searchResources("", getSelectedCriterions());
    }

    public Constraint  checkConstraintFilteringDate() {
        return new Constraint() {
            @Override
            public void validate(Component comp, Object value) throws WrongValueException {
                if (value == null) {
                    if (comp.getId().equals("startDateLoadRatiosDatebox")) {
                        throw new WrongValueException(comp,
View Full Code Here

    /**
     * Operations to filter the machines by multiple filters
     */

    public Constraint checkConstraintFinishDate() {
        return new Constraint() {
            @Override
            public void validate(Component comp, Object value)
                    throws WrongValueException {
                Date finishDate = (Date) value;
                if ((finishDate != null)
View Full Code Here

            }
        };
    }

    public Constraint checkConstraintStartDate() {
        return new Constraint() {
            @Override
            public void validate(Component comp, Object value)
                    throws WrongValueException {
                Date startDate = (Date) value;
                if ((startDate != null)
View Full Code Here

    }

    /* Operations to the data validations */

    public Constraint validateWorkReportTypeName() {
        return new Constraint() {
            @Override
            public void validate(Component comp, Object value)
                    throws WrongValueException {
                try {
                    workReportTypeModel
View Full Code Here

TOP

Related Classes of org.zkoss.zul.Constraint

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.