/*
(non-Javadoc)
@see net.leadware.persistence.tools.validator.IDAOValidator#processValidation(java.lang.Object)
773001
@Override
	public void processValidation(Object entity) {

		// Si la classe cible n'est pas specifiee
		if(annotation.targetClass() == null) {
			
			// On sort
			return;
		}
		
		// Si le champ id n'est pas specifie
		if(annotation.idField() == null || annotation.idField().trim().length() == 0) {
			
			// On sort
			return;
		}
		
		// Champ ID
		String ifField = annotation.idField().trim();
		
		// Buffer de la Requete de test
		StringBuffer requestBuffer = new StringBuffer();
		
		// Construction de la requete
		requestBuffer.append("from ");
		requestBuffer.append(annotation.targetClass().getName());
		requestBuffer.append(" c where ");
		requestBuffer.append("c.".concat(ifField));
		requestBuffer.append(" = ");
		requestBuffer.append("${" + ifField + "}");
		
		// La requete
		final String request = requestBuffer.toString();

		// Instanciation d'une annotation de validation de taille
		Annotation sizeAnnotation = new SizeDAOValidator() {

			@Override
			public DAOValidatorEvaluationTime[] evaluationTime() {
				
				// On positionne la min
				return annotation.evaluationTime();
			}

			@Override
			public String expr() {
				
				// On positionne l'expression
				return request;
			}

			@Override
			public long max() {
				
				// On positionne la max
				return 1;
			}

			@Override
			public String message() {
				
				// On positionne la min
				return annotation.message();
			}

			@Override
			public long min() {
				
				// On positionne la min
				return 1;
			}

			@Override
			public DAOMode[] mode() {
				
				// On positionne le mode
				return annotation.mode();
			}

			@Override
			public ValidatorExpressionType type() {
				
				// On positionne le type
				return annotation.type();
			}

			@Override
			public Class<? extends Annotation> annotationType() {
				
				// On positionne la classe
				return SizeDAOValidator.class;
			}

			@Override
			public String[] parameters() {
				
				// On retourne la liste des expressions de parametres
				return annotation.parameters();
			}
		};

		// Initialisation du validateur de regle
		sizeValidator.initialize(sizeAnnotation, this.entityManager, this.systemDAOMode, this.systemEvaluationTime);
		
		// On valide
		sizeValidator.processValidation(entity);
	}
1184450
public void validate() {
    StringBuilder validationErrorBuilder = new StringBuilder("Process engine configuration is invalid: \n");
    boolean isValid = true;    
    
    if(datasourceJndiName == null || datasourceJndiName.isEmpty()) {
      isValid = false;
      validationErrorBuilder.append(" property 'datasource' cannot be null \n");      
    }
    if(engineName == null || engineName.isEmpty()) {
      isValid = false;
      validationErrorBuilder.append(" property 'engineName' cannot be null \n");
    }

    for (int i = 0; i < pluginConfigurations.size(); i++) {
      ProcessEnginePluginXml pluginConfiguration = pluginConfigurations.get(i);
      if (pluginConfiguration.getPluginClass() == null || pluginConfiguration.getPluginClass().isEmpty()) {
        isValid = false;
        validationErrorBuilder.append(" property 'class' in plugin[" + i + "] cannot be null \n");
      }
    }
    
    if(!isValid) {
      throw new ProcessEngineException(validationErrorBuilder.toString());
    }
  }
974351
private void performSchemaValidation(Message receivedMessage, JsonMessageValidationContext validationContext) {
        log.debug("Starting Json schema validation ...");

        ProcessingReport report = jsonSchemaValidation.validate(receivedMessage,
                                                                schemaRepositories,
                                                                validationContext,
                                                                applicationContext);
        if (!report.isSuccess()) {
            log.error("Failed to validate Json schema for message:\n" + receivedMessage.getPayload(String.class));

            throw new ValidationException(constructErrorMessage(report));
        }

        log.info("Json schema validation successful: All values OK");
    }
1351118
public void observeProcessValidations(@Observes @Before @ProcessValidations PhaseEvent event) {
        log.debug("After Process Validations event");
        performObservation(event, PhaseIdType.PROCESS_VALIDATIONS);
    }
719695
@Override
    public void validate() throws OpsGenieClientValidationException {
        super.validate();
        if (username == null && id == null)
            throw OpsGenieClientValidationException.missingMultipleMandatoryProperty(OpsGenieClientConstants.API.USERNAME, OpsGenieClientConstants.API.ID);
    }
737521
protected void validate(String operationType) throws Exception
	{
		super.validate(operationType);

		MPSString id_validator = new MPSString();
		id_validator.setConstraintIsReq(MPSConstants.DELETE_CONSTRAINT, true);
		id_validator.setConstraintIsReq(MPSConstants.MODIFY_CONSTRAINT, true);
		id_validator.validate(operationType, id, "\"id\"");
		
		MPSString uuid_validator = new MPSString();
		uuid_validator.setConstraintMaxStrLen(MPSConstants.GENERIC_CONSTRAINT, 128);
		uuid_validator.setConstraintMinStrLen(MPSConstants.GENERIC_CONSTRAINT, 1);
		uuid_validator.validate(operationType, uuid, "\"uuid\"");
		
		MPSInt number_validator = new MPSInt();
		number_validator.validate(operationType, number, "\"number\"");
		
		MPSDouble cpu_usage_validator = new MPSDouble();
		cpu_usage_validator.validate(operationType, cpu_usage, "\"cpu_usage\"");
		
		MPSString vendor_validator = new MPSString();
		vendor_validator.setConstraintMaxStrLen(MPSConstants.GENERIC_CONSTRAINT, 128);
		vendor_validator.setConstraintMinStrLen(MPSConstants.GENERIC_CONSTRAINT, 1);
		vendor_validator.validate(operationType, vendor, "\"vendor\"");
		
		MPSInt speed_validator = new MPSInt();
		speed_validator.validate(operationType, speed, "\"speed\"");
		
		MPSString modelname_validator = new MPSString();
		modelname_validator.setConstraintMaxStrLen(MPSConstants.GENERIC_CONSTRAINT, 128);
		modelname_validator.setConstraintMinStrLen(MPSConstants.GENERIC_CONSTRAINT, 1);
		modelname_validator.validate(operationType, modelname, "\"modelname\"");
		
		MPSInt family_validator = new MPSInt();
		family_validator.validate(operationType, family, "\"family\"");
		
		MPSInt model_validator = new MPSInt();
		model_validator.validate(operationType, model, "\"model\"");
		
		MPSString stepping_validator = new MPSString();
		stepping_validator.setConstraintMaxStrLen(MPSConstants.GENERIC_CONSTRAINT, 128);
		stepping_validator.setConstraintMinStrLen(MPSConstants.GENERIC_CONSTRAINT, 1);
		stepping_validator.validate(operationType, stepping, "\"stepping\"");
		
		MPSString flags_validator = new MPSString();
		flags_validator.setConstraintMaxStrLen(MPSConstants.GENERIC_CONSTRAINT, 512);
		flags_validator.setConstraintMinStrLen(MPSConstants.GENERIC_CONSTRAINT, 1);
		flags_validator.validate(operationType, flags, "\"flags\"");
		
		MPSString features_validator = new MPSString();
		features_validator.setConstraintMaxStrLen(MPSConstants.GENERIC_CONSTRAINT, 128);
		features_validator.setConstraintMinStrLen(MPSConstants.GENERIC_CONSTRAINT, 1);
		features_validator.validate(operationType, features, "\"features\"");
		
	}
648872
private void processService(Service service) throws Exception {

        getLog().info("  Service: " + service.getServiceName());

        Document iddDoc = parseIddFile(service.getServiceName());

        // 1. validate
        if (!isOffline()) {
            getLog().debug("Validating XML..");
            new XmlValidator(resolver).validate(iddDoc);
        }

        // 2. generate outputs
        generateJavaCode(service, iddDoc);
    }
1250051
@Override
    public void validate(final FacesContext context) {
        // iterate over submitted values and attempt to convert to the proper
        // data type. For successful values, remove from submitted and add to
        // local values map. for failures, add a conversion message and leave in
        // the submitted state
        final Iterator<Entry<SheetRowColIndex, String>> entries = submittedValues.entrySet().iterator();
        final boolean hadBadUpdates = !getInvalidUpdates().isEmpty();
        getInvalidUpdates().clear();
        while (entries.hasNext()) {
            final Entry<SheetRowColIndex, String> entry = entries.next();
            final SheetColumn column = getColumns().get(entry.getKey().getColIndex());
            final String newValue = entry.getValue();
            final String rowKey = entry.getKey().getRowKey();
            final int col = entry.getKey().getColIndex();
            setRowVar(context, rowKey);

            // attempt to convert new value from string to correct object type
            // based on column converter. Use PF util as helper
            final Converter converter = ComponentUtils.getConverter(context, column);

            // assume string value if converter not found
            Object newValueObj = newValue;
            if (converter != null) {
                try {
                    newValueObj = converter.getAsObject(context, this, newValue);
                }
                catch (final ConverterException e) {
                    // add offending cell to list of bad updates
                    // and to a StringBuilder for error messages (so we have one
                    // message for the component)
                    setValid(false);
                    FacesMessage message = e.getFacesMessage();
                    if (message == null) {
                        message = new FacesMessage(FacesMessage.SEVERITY_ERROR, e.getMessage(), e.getMessage());
                    }
                    context.addMessage(this.getClientId(context), message);

                    final String messageText = message.getDetail();
                    getInvalidUpdates()
                                .add(new SheetInvalidUpdate(getRowKeyValue(context), col, column, newValue, messageText));
                    continue;
                }
            }
            // value is fine, no further validations (again, not to be confused
            // with validators. until we have a "required" or something like
            // that, nothing else to do).
            setLocalValue(rowKey, col, newValueObj);

            // process validators on column
            column.setValue(newValueObj);
            try {
                column.validate(context);
            }
            finally {
                column.resetValue();
            }

            entries.remove();
        }
        setRowVar(context, null);

        final boolean newBadUpdates = !getInvalidUpdates().isEmpty();
        final String errorMessage = getErrorMessage();

        if (hadBadUpdates || newBadUpdates) {
            // update the bad data var if partial request
            if (context.getPartialViewContext().isPartialRequest()) {
                renderBadUpdateScript(context);
            }
        }

        if (newBadUpdates && errorMessage != null) {
            final FacesMessage message = new FacesMessage(FacesMessage.SEVERITY_ERROR, errorMessage, errorMessage);
            context.addMessage(null, message);
        }
    }
1093377
@SuppressWarnings( "unchecked" )
    protected void processParametersOfMethodDeclaration( MethodDeclaration methodDeclaration,
                                                         MethodMetadata methodMetadata ) {
        for (SingleVariableDeclaration singleVariableDeclaration : (List<SingleVariableDeclaration>)methodDeclaration.parameters()) {
            Type type = singleVariableDeclaration.getType();

            if (type.isPrimitiveType()) {
                FieldMetadata primitiveFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(primitiveFieldMetadata);
            }
            if (type.isParameterizedType()) {
                FieldMetadata parameterizedTypeFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(parameterizedTypeFieldMetadata);
            }
            if (type.isQualifiedType()) {
                // TODO
            }
            if (type.isSimpleType()) {
                FieldMetadata simpleTypeFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(simpleTypeFieldMetadata);
            }
            if (type.isArrayType()) {
                FieldMetadata arrayTypeFieldMetadata = processVariableDeclaration(singleVariableDeclaration, type);
                methodMetadata.getParameters().add(arrayTypeFieldMetadata);
            }
            if (type.isWildcardType()) {
                // TODO
            }
        }

    }
401598
private boolean validateProcessInstance(ProcessInstance processInst) {
        Integer status = processInst.getStatusCode();
        if (WorkStatus.STATUS_CANCELLED.equals(status)) {
            logger.info("ProcessInstance has been cancelled. ProcessInstanceId = " + processInst.getId());
            return false;
        } else if (WorkStatus.STATUS_COMPLETED.equals(status)) {
            logger.info("ProcessInstance has been completed. ProcessInstanceId = " + processInst.getId());
            return false;
        } else return true;
    }
66984
protected void initValidator() throws SQLException, IOException
	{

		EmblEntryValidationPlanProperty emblEntryValidationPlanProperty = new EmblEntryValidationPlanProperty();
		emblEntryValidationPlanProperty.validationScope.set(ValidationScope.getScope(fileType));
		emblEntryValidationPlanProperty.isDevMode.set(testMode);
		emblEntryValidationPlanProperty.isFixMode.set(fixMode || fixDiagnoseMode);
		emblEntryValidationPlanProperty.minGapLength.set(min_gap_length);
		emblEntryValidationPlanProperty.isRemote.set(remote);
		emblEntryValidationPlanProperty.fileType.set(fileType);
		emblEntryValidationPlanProperty.enproConnection.set(con);
		emblValidator = new EmblEntryValidationPlan(emblEntryValidationPlanProperty);
		emblValidator.addMessageBundle(ValidationMessageManager.STANDARD_VALIDATION_BUNDLE);
		emblValidator.addMessageBundle(ValidationMessageManager.STANDARD_FIXER_BUNDLE);
		gff3Validator = new GFF3ValidationPlan(emblEntryValidationPlanProperty);
		gff3Validator.addMessageBundle(ValidationMessageManager.GFF3_VALIDATION_BUNDLE);
		gaValidator = new GenomeAssemblyValidationPlan(emblEntryValidationPlanProperty);
		gaValidator.addMessageBundle(ValidationMessageManager.GENOMEASSEMBLY_VALIDATION_BUNDLE);
		gaValidator.addMessageBundle(ValidationMessageManager.GENOMEASSEMBLY_FIXER_BUNDLE);
		initWriters();

	}
1170969
public void validate() throws InvalidPropertyException {

        final String methodName = "validate";
        if (TraceComponent.isAnyTracingEnabled() && TRACE.isEntryEnabled()) {
            SibTr.entry(this, TRACE, methodName);
        }

        final List<String> failedPropsMessages = new ArrayList<String>();
        final List<PropertyDescriptor> invalidProperties = new ArrayList<PropertyDescriptor>();

        try {

            if (isSet(_destinationName))
            {
                // BusName must be set
                if (!isSet(_busName)) {

                    if (TraceComponent.isAnyTracingEnabled() && TRACE.isDebugEnabled()) {
                        SibTr.debug(this, TRACE, "Invalid BusName - BusName was "
                                                 + _busName);
                    }
                    failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_BUSNAME_CWSIV0504"),
                                                                    null, null));
                    invalidProperties.add(new PropertyDescriptor("BusName",
                                    SibRaActivationSpec.class));

                }

                // DestinationType must be valid
                if (!DESTINATION_TYPES.keySet().contains(_destinationType)) {

                    if (TraceComponent.isAnyTracingEnabled() && TRACE.isDebugEnabled()) {
                        SibTr.debug(this, TRACE,
                                    "Invalid Destination Type - We expected a destination type of "
                                                    + DESTINATION_TYPE_QUEUE + " or " + DESTINATION_TYPE_TOPIC_SPACE + " or "
                                                    + DESTINATION_TYPE_PORT + " or " + DESTINATION_TYPE_SERVICE
                                                    + " but we got "
                                                    + _destinationType);
                    }

                    failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_DESTINATION_TYPE_CWSIV0505"),
                                                                    new Object[] { DESTINATION_TYPE_QUEUE,
                                                                                  DESTINATION_TYPE_TOPIC_SPACE,
                                                                                  DESTINATION_TYPE_PORT,
                                                                                  DESTINATION_TYPE_SERVICE,
                                                                                  _destinationType }, null));
                    invalidProperties.add(new PropertyDescriptor(
                                    "DestinationType", SibRaActivationSpec.class));

                }

                // Make sure we are not using a topic space if wildcarded destinations are used.
                if ((Boolean.TRUE.equals(_useDestinationWildcard))
                    && (DESTINATION_TYPE_TOPIC_SPACE.equals(_destinationType)))
                {
                    failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_USEDESTWILDCARD_CWSIV0515"),
                                                                    null, null));
                    invalidProperties.add(new PropertyDescriptor(
                                    "UseDestinationWildcard",
                                    SibRaActivationSpec.class));
                }

                // For durable subscriptions...
                if ((DESTINATION_TYPE_TOPIC_SPACE.equals(_destinationType))
                    && (isSet(_subscriptionName))) {

                    // ShareDurableSubscriptions must be valid
                    if (!SUBSCRIPTION_SHAREABILITY.keySet().contains(
                                                                     _shareDurableSubscriptions)) {

                        if (TraceComponent.isAnyTracingEnabled() && TRACE.isDebugEnabled()) {
                            SibTr.debug(this, TRACE,
                                        "Invalid shareDurableSubscriptions - We expect a value of "
                                                        + SibRaDurableSubscriptionSharing.ALWAYS + ", "
                                                        + SibRaDurableSubscriptionSharing.NEVER + " or "
                                                        + SibRaDurableSubscriptionSharing.CLUSTER_ONLY + " but we got "
                                                        + _shareDurableSubscriptions);
                        }
                        failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_SHARE_DURSUB_CWSIV0506"),
                                                                        new Object[] { SibRaDurableSubscriptionSharing.ALWAYS,
                                                                                      SibRaDurableSubscriptionSharing.NEVER,
                                                                                      SibRaDurableSubscriptionSharing.CLUSTER_ONLY,
                                                                                      _shareDurableSubscriptions },
                                                                        null));

                        invalidProperties.add(new PropertyDescriptor(
                                        "ShareDurableSubscriptions",
                                        SibRaActivationSpec.class));

                    }

                    // DurableSubscriptionHome must be set
                    if (!isSet(_durableSubscriptionHome)) {

                        failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_DURSUBHOME_CWSIV0507"),
                                                                        null, null));
                        invalidProperties.add(new PropertyDescriptor(
                                        "DurableSubscriptionHome",
                                        SibRaActivationSpec.class));

                    }

                }

            } else {

                // DestinationType must be valid and not a topic space
                if (!DESTINATION_TYPES.keySet().contains(_destinationType)
                    || DESTINATION_TYPE_TOPIC_SPACE
                                    .equals(_destinationType)) {

                    if (TraceComponent.isAnyTracingEnabled() && TRACE.isDebugEnabled()) {
                        SibTr.debug(this, TRACE,
                                    "Invalid Destination Type - No destination was specified so we expected a destination type of "
                                                    + DESTINATION_TYPE_QUEUE + " or " + DESTINATION_TYPE_PORT + " or "
                                                    + DESTINATION_TYPE_SERVICE + " but we got "
                                                    + _destinationType);
                    }

                    failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_DESTINATION_TYPE_CWSIV0508"),
                                                                    new Object[] { DESTINATION_TYPE_QUEUE,
                                                                                  DESTINATION_TYPE_PORT,
                                                                                  DESTINATION_TYPE_SERVICE,
                                                                                  _destinationType }, null));
                    invalidProperties.add(new PropertyDescriptor(
                                    "DestinationType", SibRaActivationSpec.class));

                }

            }

            // MaxBatchSize must be an Integer greater than zero
            if ((_maxBatchSize == null) || (_maxBatchSize.intValue() < 1)) {

                failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_MAXBATCH_CWSIV0509"),
                                                                null, null));
                invalidProperties.add(new PropertyDescriptor("MaxBatchSize",
                                SibRaActivationSpec.class));

            }

            // MessageDeletionMode must be valid
            if (!MESSAGE_DELETION_MODES.keySet().contains(_messageDeletionMode)) {

                if (TraceComponent.isAnyTracingEnabled() && TRACE.isDebugEnabled()) {
                    SibTr.debug(this, TRACE,
                                "Invalid Message Deletion Mode we expected a mode of "
                                                + SibRaMessageDeletionMode.SINGLE + " or "
                                                + SibRaMessageDeletionMode.BATCH + " or "
                                                + SibRaMessageDeletionMode.APPLICATION + " but we got "
                                                + _messageDeletionMode);
                }

                failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_DELETION_MODE_CWSIV0510"),
                                                                new Object[] { SibRaMessageDeletionMode.SINGLE,
                                                                              SibRaMessageDeletionMode.BATCH,
                                                                              SibRaMessageDeletionMode.APPLICATION,
                                                                              _messageDeletionMode }, null));
                invalidProperties.add(new PropertyDescriptor(
                                "MessageDeletionMode", SibRaActivationSpec.class));

            }

            // MaxConcurrency must be an Integer greater than zero
            if ((_maxConcurrency == null) || (_maxConcurrency.intValue() < 1)) {

                failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_MAXCONC_CWSIV0511"),
                                                                null, null));
                invalidProperties.add(new PropertyDescriptor("MaxConcurrency",
                                SibRaActivationSpec.class));

            }

            /**
             * For the target set of properties, use the defaults if none specified
             */

            if ("".equals(_targetType)) {

                _targetType = JmsraConstants.DEFAULT_TARGET_TRANSPORT;

            }

            if ("".equals(_target)) {

                _target = JmsraConstants.DEFAULT_TARGET;

            }

            // Target type must be one of the predefined values
            if ((null == _targetType) || ("".equals(_targetType))) {

                _targetType = JmsraConstants.DEFAULT_TARGET_TYPE;

            } else {

                if (!((ApiJmsConstants.TARGET_TYPE_BUSMEMBER.equals(_targetType)) ||
                      (ApiJmsConstants.TARGET_TYPE_ME.equals(_targetType)) || (ApiJmsConstants.TARGET_TYPE_CUSTOM.equals(_targetType)))) {

                    failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_TARGET_TYPE_CWSIV0512"),
                                                                    new Object[] { ApiJmsConstants.TARGET_TYPE_BUSMEMBER,
                                                                                  ApiJmsConstants.TARGET_TYPE_ME,
                                                                                  ApiJmsConstants.TARGET_TYPE_CUSTOM,
                                                                                  _targetType },
                                                                    null));

                    invalidProperties.add(new PropertyDescriptor(
                                    "targetType",
                                    SibRaActivationSpec.class));

                }

            }

            // Target significance must be one of the predefined values
            if ((null == _targetSignificance) || ("".equals(_targetSignificance))) {

                _targetSignificance = JmsraConstants.DEFAULT_TARGET_SIGNIFICANCE;

            } else {

                if (!((ApiJmsConstants.TARGET_SIGNIFICANCE_PREFERRED.equals(_targetSignificance)) || (ApiJmsConstants.TARGET_SIGNIFICANCE_REQUIRED.equals(_targetSignificance)))) {

                    failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_TARGET_SIGNIFICANCE_CWSIV0513"),
                                                                    new Object[] { ApiJmsConstants.TARGET_SIGNIFICANCE_PREFERRED,
                                                                                  ApiJmsConstants.TARGET_SIGNIFICANCE_REQUIRED,
                                                                                  _targetSignificance },
                                                                    null));
                    invalidProperties.add(new PropertyDescriptor(
                                    "targetSignificance",
                                    SibRaActivationSpec.class));

                }

            }

            if ((_useServerSubject.booleanValue()) && (isSet(_providerEndpoints)))
            {
                failedPropsMessages.add(NLS.getFormattedMessage(("INVALID_PROPERTY_PROVIDER_ENDPOINTS_CWSIV0514"),
                                                                new Object[] { _providerEndpoints },
                                                                null));
                invalidProperties.add(new PropertyDescriptor(
                                "providerEndpoints",
                                SibRaActivationSpec.class));
            }

        } catch (final IntrospectionException exception) {

            FFDCFilter.processException(exception, CLASS_NAME + "."
                                                   + methodName, FFDC_PROBE_1, this);
            // Should never happen

        }

        // If we have any invalid properties, throw an
        // InvalidPropertyException
        if (!invalidProperties.isEmpty()) {

            final PropertyDescriptor[] invalidPropertyArray = (PropertyDescriptor[]) invalidProperties
                            .toArray(new PropertyDescriptor[invalidProperties
                                            .size()]);

            if (TraceComponent.isAnyTracingEnabled() && TRACE.isDebugEnabled()) {
                SibTr.debug(this, TRACE, "Invalid properties found:",
                            failedPropsMessages);
            }

            final InvalidPropertyException exc = new InvalidPropertyException(
                            NLS.getFormattedMessage(
                                                    ("INVALID_PROPERTIES_CWSIV0501"),
                                                    new Object[] { this, failedPropsMessages }, null));
            exc.setInvalidPropertyDescriptors(invalidPropertyArray);
            throw exc;
        }

        if (TraceComponent.isAnyTracingEnabled() && TRACE.isEntryEnabled()) {
            SibTr.exit(this, TRACE, methodName);
        }

    }
1249747
private void process() {
    Entity entity = entityClass.getAnnotation(Entity.class);
    ProjectedEntity projectedEntity = entityClass.getAnnotation(ProjectedEntity.class);
    if (entity != null) {
      initEntityMetadata(entity);
    } else if (projectedEntity != null) {
      initEntityMetadata(projectedEntity);
    } else {
      String message = String.format("Class %s must either have %s or %s annotation",
          entityClass.getName(), Entity.class.getName(), ProjectedEntity.class.getName());
      throw new EntityManagerException(message);
    }

    processPropertyOverrides();

    processFields();
    // If we did not find valid Identifier...
    if (entityMetadata.getIdentifierMetadata() == null) {
      throw new EntityManagerException(
          String.format("Class %s requires a field with annotation of %s", entityClass.getName(),
              Identifier.class.getName()));
    }
    entityMetadata.setEntityListenersMetadata(EntityListenersIntrospector.introspect(entityClass));
    entityMetadata.ensureUniqueProperties();
    entityMetadata.cleanup();
  }
1274988
@Override
	public void processValidation(Object entity) {
		
		// Si on ne doit pas evaluer cette annotation
		if(!this.isProcessable()) {
			
			// On sort
			return;
		}
		
		// Le Type
		ValidatorExpressionType type = this.getType();
		
		// Si le type est null
		if(type == null) type = ValidatorExpressionType.JPQL;
		
		// Si le type est HQL|JPQL|EJBQL
		if(type.equals(ValidatorExpressionType.HQL) || type.equals(ValidatorExpressionType.JPQL) || type.equals(ValidatorExpressionType.EJBQL)) {
			
			// On construit la requte
			Query query = this.buildQuery(entity);
			
			// Execution
			List<Object> result = query.getResultList();
			
			// La Taille
			long size = 0;
			
			// Le minimum
			long min = ((SizeDAOValidator) this.annotation).min();
			
			// Le max
			long max = ((SizeDAOValidator) this.annotation).max();
						
			// Si la liste n'est pas vide
			if(result != null && result.size() > 0) size = result.size();
						
			// On compare
			if((min > size) || (max < size)) {
				
				// On lve une exception
				throw new DAOValidationException(getMessage(), getMessageParameters(entity));
			}
		}
	}
906621
private void processFile(String fileName)
      throws ValidationException, ParserConfigurationException, SAXException, IOException,
          SchedulerException, ClassNotFoundException, ParseException, XPathException {

    prepForProcessing();

    logger.info("Parsing XML file: " + fileName);
    InputSource is = new InputSource(getInputStream(fileName));
    // is.setSystemId(systemId);

    process(is);

    maybeThrowValidationException();
  }
212649
protected void storeValidation(Validation v, XMLStreamWriter writer) throws Exception
   {
      writer.writeStartElement(CommonXML.ELEMENT_VALIDATION);

      if (v.isValidateOnMatch() != null)
      {
         writer.writeStartElement(CommonXML.ELEMENT_VALIDATE_ON_MATCH);
         writer.writeCharacters(v.getValue(CommonXML.ELEMENT_VALIDATE_ON_MATCH, v.isValidateOnMatch().toString()));
         writer.writeEndElement();
      }

      if (v.isBackgroundValidation() != null)
      {
         writer.writeStartElement(CommonXML.ELEMENT_BACKGROUND_VALIDATION);
         writer.writeCharacters(v.getValue(CommonXML.ELEMENT_BACKGROUND_VALIDATION,
                                           v.isBackgroundValidation().toString()));
         writer.writeEndElement();
      }

      if (v.getBackgroundValidationMillis() != null)
      {
         writer.writeStartElement(CommonXML.ELEMENT_BACKGROUND_VALIDATION_MILLIS);
         writer.writeCharacters(v.getValue(CommonXML.ELEMENT_BACKGROUND_VALIDATION_MILLIS,
                                           v.getBackgroundValidationMillis().toString()));
         writer.writeEndElement();
      }

      if (v.isUseFastFail() != null)
      {
         writer.writeStartElement(CommonXML.ELEMENT_USE_FAST_FAIL);
         writer.writeCharacters(v.getValue(CommonXML.ELEMENT_USE_FAST_FAIL, v.isUseFastFail().toString()));
         writer.writeEndElement();
      }

      writer.writeEndElement();
   }
349457
@Override
    public void validate() {
        //validate the parameters
        String target = getTargetName();
        if (value() < 1) {
            throw new FaultToleranceDefinitionException(Tr.formatMessage(tc, "bulkhead.parameter.invalid.value.CWMFT5016E", "value ", value(), target));
        }
        //validate the parameters
        if (waitingTaskQueue() < 1) {
            throw new FaultToleranceDefinitionException(Tr.formatMessage(tc, "bulkhead.parameter.invalid.value.CWMFT5016E", "waitingTaskQueue", waitingTaskQueue(),
                                                                         target));
        }

    }