Search in sources :

Example 1 with IProjectValidator

use of org.bndtools.api.IProjectValidator in project bndtools by bndtools.

the class MarkerSupport method validate.

void validate(Project model) throws Exception {
    List<IValidator> validators = loadValidators();
    if (validators != null) {
        for (IValidator v : validators) {
            try {
                if (v instanceof IProjectValidator) {
                    ((IProjectValidator) v).validateProject(model);
                } else {
                    for (Builder builder : model.getSubBuilders()) {
                        IStatus status = v.validate(builder);
                        report(builder, status);
                        model.getInfo(builder);
                    }
                }
            } catch (Exception e) {
                logger.logError("Validator error", e);
            }
        }
    }
}
Also used : IProjectValidator(org.bndtools.api.IProjectValidator) IStatus(org.eclipse.core.runtime.IStatus) IValidator(org.bndtools.api.IValidator) Builder(aQute.bnd.osgi.Builder) CoreException(org.eclipse.core.runtime.CoreException)

Aggregations

Builder (aQute.bnd.osgi.Builder)1 IProjectValidator (org.bndtools.api.IProjectValidator)1 IValidator (org.bndtools.api.IValidator)1 CoreException (org.eclipse.core.runtime.CoreException)1 IStatus (org.eclipse.core.runtime.IStatus)1