Examples of validate()


Examples of com.sun.xml.ws.security.opt.impl.incoming.SignatureConfirmation.validate()

                        return dkt;
                       
                    }
                    case SIGNATURE_CONFIRMATION_ELEMENT:{
                        SignatureConfirmation signConfirm = new SignatureConfirmation(message,creator,(HashMap) currentParentNS, staxIF);
                        signConfirm.validate(context);
                        context.getSecurityContext().getProcessedSecurityHeaders().add(signConfirm);
                        return signConfirm;
                       
                    }
                    case SECURITY_CONTEXT_TOKEN:{
View Full Code Here

Examples of com.sun.xml.ws.security.opt.impl.incoming.UsernameTokenHeader.validate()

                        context.getSecurityContext().getProcessedSecurityHeaders().add(ed);
                        return ed;
                    }
                    case USERNAMETOKEN_ELEMENT :{
                        UsernameTokenHeader ut = new UsernameTokenHeader(message,creator,(HashMap) currentParentNS, staxIF);
                        ut.validate(context);
                        if(context.isTrustMessage() && !context.isClient()){
                            IssuedTokenContext ctx = null;                           
                            if(context.getTrustContext() == null){
                                ctx = new IssuedTokenContextImpl();
                                if(context.isSecure()){
View Full Code Here

Examples of com.thaiopensource.validate.ValidationDriver.validate()

        ErrorHandlerImpl eh = new ErrorHandlerImpl(new BufferedWriter(new OutputStreamWriter(error)));
        ValidateProperty.ERROR_HANDLER.put(properties, eh);
        SchemaReader schemaReader = new AutoSchemaReader();
        ValidationDriver driver = new ValidationDriver(properties.toPropertyMap(), schemaReader);
        if (driver.loadSchema(in)) {
            if (driver.validate(ValidationDriver.uriOrFileInputSource(xml.getAbsolutePath()))) {
                log.debug("" + error);
                return null;
            } else {
                log.error("" + error);
                return "" + error;
View Full Code Here

Examples of com.turn.ttorrent.client.Piece.validate()

            // length is 0, it means the piece has been entirely
            // downloaded. In this case, we have nothing to save, but
            // we should validate the piece.
            if (piece.getOffset() + piece.getBlock().capacity()
                == p.size()) {
              p.validate();
              this.firePieceCompleted(p);
              this.requestedPiece = null;
              this.firePeerReady();
            } else {
              this.requestNextBlocks();
View Full Code Here

Examples of com.vaadin.data.Validatable.validate()

            @Override
            public void evaluate(Property component, WidgetElement element) throws Exception {
                if (component instanceof Validatable) {
                    Validatable validatable = (Validatable) component;
                    try {
                        validatable.validate();
                    } catch (InvalidValueException e) {
                        errors.add(e.getMessage());
                    }
                }
                if (!component.isReadOnly()) {
View Full Code Here

Examples of com.vaadin.data.validator.BeanValidator.validate()

public class TestBeanValidation {
    @Test(expected = InvalidValueException.class)
    public void testBeanValidationNull() {
        BeanValidator validator = new BeanValidator(BeanToValidate.class,
                "firstname");
        validator.validate(null);
    }

    @Test(expected = InvalidValueException.class)
    public void testBeanValidationStringTooShort() {
        BeanValidator validator = new BeanValidator(BeanToValidate.class,
View Full Code Here

Examples of com.vaadin.data.validator.RegexpValidator.validate()

public class TestSerialization extends TestCase {

    public void testValidators() throws Exception {
        RegexpValidator validator = new RegexpValidator(".*", "Error");
        validator.validate("aaa");
        RegexpValidator validator2 = serializeAndDeserialize(validator);
        validator2.validate("aaa");
    }

    public void testForm() throws Exception {
View Full Code Here

Examples of com.vaadin.ui.CheckBox.validate()

                } catch (InvalidValueException e) {
                    checkbox.setComponentError(AbstractErrorMessage
                            .getErrorMessageForException(e));
                }
                try {
                    requiredCheckbox.validate();
                } catch (InvalidValueException e) {
                    requiredCheckbox.setComponentError(AbstractErrorMessage
                            .getErrorMessageForException(e));
                }
                valueLabel.setValue("Checkbox: " + checkbox.getValue()
View Full Code Here

Examples of com.vaadin.ui.Form.validate()

        Button validate = new Button("Validate fields");
        validate.addListener(new ClickListener() {
            @Override
            public void buttonClick(ClickEvent event) {
                try {
                    form.validate();
                } catch (InvalidValueException e) {
                }
            }
        });
        part.addComponent(validate);
View Full Code Here

Examples of com.vaadin.ui.TextField.validate()

    @Test
    public void testIntegerValidation() {
        TextField field = new TextField();
        field.addValidator(new IntegerValidator("Enter a Valid Number"));
        field.setValue(String.valueOf(10));
        field.validate();
    }
}
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.