Package org.wikipediacleaner.api.check

Examples of org.wikipediacleaner.api.check.NullActionProvider


        for (Integer controlFound : controls) {
          ControlCharacter found = getControlCharacter(controlFound.intValue());
          if (found != null) {
            errorResult.addPossibleAction(
                Integer.toHexString(controlFound.intValue()) + " - " + GT._(found.description),
                new NullActionProvider());
          }
        }
        StringBuilder replacementB = new StringBuilder();
        List<String> otherReplacements = new ArrayList<String>();
        boolean unsafeCharacter = false;
View Full Code Here


          CheckErrorResult errorResult = createCheckErrorResult(analysis, isbn, true);
          errorResult.addPossibleAction(
              GT._(
                  "The checksum is {0} instead of {1}",
                  new Object[] { check, computedCheck } ),
              new NullActionProvider());
          addHelpNeededTemplates(analysis, errorResult, isbn);
          addHelpNeededComment(analysis, errorResult, isbn);
          String value = isbn.getISBN();
          addSearchEngines(analysis, errorResult, value);
          value = value.substring(0, value.length() - 1) + computedCheck;
View Full Code Here

      for (Replacement replacement : group.getReplacements()) {

        // Manage comment
        String comment = replacement.getComment();
        if (comment == null) {
          error.addPossibleAction(null, new NullActionProvider());
        } else if (!comment.equals(previousComment)) {
          error.addPossibleAction(comment, new NullActionProvider());
        }
        previousComment = comment;

        error.addReplacement(replacement.getReplacement(), replacement.isAutomatic());
        if (Boolean.TRUE.equals(replacement.isMultiple())) {
View Full Code Here

          CheckErrorResult errorResult = createCheckErrorResult(analysis, isbn, true);
          errorResult.addPossibleAction(
              GT._(
                  "The checksum is {0} instead of {1}",
                  new Object[] { check, computedCheck } ),
              new NullActionProvider());
          addHelpNeededTemplates(analysis, errorResult, isbn);
          addHelpNeededComment(analysis, errorResult, isbn);

          // Use search engines
          String value = number;
View Full Code Here

          CheckErrorResult errorResult = createCheckErrorResult(analysis, isbn, true);
          errorResult.addPossibleAction(
              GT._(
                  "Length of ISBN is {0} instead of 10 or 13",
                  Integer.toString(length) ),
              new NullActionProvider());
          addSuggestions(analysis, errorResult, isbn);
          addHelpNeededTemplates(analysis, errorResult, isbn);
          addHelpNeededComment(analysis, errorResult, isbn);
          String value = isbn.getISBN();
          addSearchEngines(analysis, errorResult, value);
View Full Code Here

    CheckErrorResult result = createCheckErrorResult(
        analysis, isbn.getBeginIndex(), isbn.getEndIndex(), level);
    List<String> infos = ISBNRange.getInformation(isbn.getISBN());
    if (infos != null) {
      for (String info : infos) {
        result.addPossibleAction(info, new NullActionProvider());
      }
    }
    return result;
  }
View Full Code Here

          if (characterReplaced) {
            errorResult.addReplacement(PageElementFunction.createFunction(tag.getFunctionName(), text));
          } else {
            errorResult.addPossibleAction(
                GT._("Unable to replace the characters [{0}]", unknownCharacters),
                new NullActionProvider());
          }
          errors.add(errorResult);
        }
      }
    }
View Full Code Here

                int endIndex = (paramIndex + 1 < template.getParameterCount()) ?
                    template.getParameterPipeIndex(paramIndex + 1) : template.getEndIndex() - 2;
                CheckErrorResult errorResult = createCheckErrorResult(
                    analysis, beginIndex, endIndex);
                for (int i = 2; i < elements.length; i++) {
                  errorResult.addPossibleAction(elements[i], new NullActionProvider());
                }
                errors.add(errorResult);
              }
            }
          }
View Full Code Here

TOP

Related Classes of org.wikipediacleaner.api.check.NullActionProvider

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.