Examples of IValidator


Examples of org.freeplane.core.resources.components.IValidator

    private void addPropertiesToOptionPanel() {
        final URL preferences = this.getClass().getResource("preferences.xml");
        if (preferences == null)
            throw new RuntimeException("cannot open preferences");
        Controller.getCurrentController().addOptionValidator(new IValidator() {
            @Override
            public ValidationResult validate(Properties properties) {
                final ValidationResult result = new ValidationResult();
                final String readAccessString = properties
                    .getProperty(ScriptingPermissions.RESOURCES_EXECUTE_SCRIPTS_WITHOUT_READ_RESTRICTION);
View Full Code Here

Examples of org.springframework.ide.eclipse.core.model.validation.IValidator

  public final boolean isEnabled(IStructuredSelection selection) {
    validatorResources = new LinkedHashMap<ValidatorDefinition, Set<IResource>>();
    if (selection.size() > 0) {
      for (ValidatorDefinition validatorDefinition : ValidatorDefinitionFactory
          .getValidatorDefinitions()) {
        IValidator validator = validatorDefinition.getValidator();
        for (Object object : selection.toList()) {
          Set<IResource> resources = validator.deriveResources(object);
          if (resources != null && resources.size() > 0) {
            Set<IResource> valResources = validatorResources.get(validatorDefinition);
            if (valResources == null) {
              valResources = new LinkedHashSet<IResource>();
              validatorResources.put(validatorDefinition, valResources);
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.