Examples of StringMatcher


Examples of org.jtester.hamcrest.matcher.string.StringMatcher

    matcher.setStringModes(StringMode.SameAsSpace);
    return (IStringAssert) this.assertThat(matcher);
  }

  public IStringAssert eqIgnoreSpace(String string) {
    StringMatcher matcher = new StringEqualMatcher(string);
    matcher.setStringModes(StringMode.IgnoreSpace);
    return this.assertThat("expect equal when ignore all space.", matcher);
  }
View Full Code Here

Examples of org.rabinfingerprint.scanner.StringFinder.StringMatcher

    final StringFinder scanner = new StringFinder(targetString);
   
    // find
    for (final File file : files) {
      final String str = IOUtils.readEntireFile(file);
      final StringMatcher sm = scanner.matcher(str);
      LineNumberIndex index = null;
     
      // find matching strings
      while (sm.find()) {
        if (index == null) index = new LineNumberIndex(str);
        final int off = sm.getStart();
        final int lineOffset = index.getLineNumber(off);
        final String line = index.getLine(off);
        final StringMatch match = new StringMatch(file, line, lineOffset, off);
        visitor.found(match);
      }
View Full Code Here

Examples of org.rabinfingerprint.scanner.StringFinder.StringMatcher

    for (final File file : files) {
      executor.submit(new Runnable() {
        public void run() {
          try {
            final String str = IOUtils.readEntireFile(file);
            final StringMatcher sm = scanner.matcher(str);
            LineNumberIndex index = null;

            // find matching strings
            while (sm.find()) {
              if (index == null) index = new LineNumberIndex(str);
              final int off = sm.getStart();
              final int lineOffset = index.getLineNumber(off);
              final String line = index.getLine(off);
              final StringMatch match = new StringMatch(file, line, lineOffset, off);
              visitor.found(match);
            }
View Full Code Here

Examples of org.rssowl.core.util.StringMatcher

   */
  public void setPattern(String patternString) {
    if (patternString == null || patternString.equals("")) //$NON-NLS-1$
      fMatcher = null;
    else
      fMatcher = new StringMatcher(patternString + "*", true, false); //$NON-NLS-1$
  }
View Full Code Here

Examples of org.rssowl.ui.internal.util.StringMatcher

   */
  public void setPattern(String patternString) {
    if (patternString == null || patternString.equals("")) //$NON-NLS-1$
      fMatcher = null;
    else
      fMatcher = new StringMatcher(patternString + "*", true, false); //$NON-NLS-1$
  }
View Full Code Here

Examples of org.rssowl.ui.internal.util.StringMatcher

   */
  public void setPattern(String patternString) {
    if (patternString == null || patternString.equals("")) //$NON-NLS-1$
      fMatcher = null;
    else
      fMatcher = new StringMatcher(patternString + "*", true, false); //$NON-NLS-1$
  }
View Full Code Here

Examples of org.rssowl.ui.internal.util.StringMatcher

   */
  public void setPattern(String patternString) {
    if (patternString == null || patternString.equals("")) //$NON-NLS-1$
      fMatcher = null;
    else
      fMatcher = new StringMatcher(patternString + "*", true, false); //$NON-NLS-1$
  }
View Full Code Here

Examples of org.rssowl.ui.internal.util.StringMatcher

   */
  public void setPattern(String patternString) {
    if (patternString == null || patternString.equals("")) //$NON-NLS-1$
      fMatcher = null;
    else
      fMatcher = new StringMatcher(patternString + "*", true, false); //$NON-NLS-1$
  }
View Full Code Here

Examples of proguard.util.StringMatcher

        // Print out a note about the dynamic invocation.
        if (notePrinter != null &&
            notePrinter.accepts(clazz.getName()))
        {
            // Is the class member name in the list of exceptions?
            StringMatcher noteExceptionMatcher = isField ?
                noteFieldExceptionMatcher :
                noteMethodExceptionMatcher;

            int memberNameIndex = noteSequenceMatcher.matchedConstantIndex(MEMBER_NAME_INDEX);
            String memberName = memberNameIndex <= 0 ? defaultName :
                clazz.getStringString(memberNameIndex);

            if (noteExceptionMatcher == null ||
                !noteExceptionMatcher.matches(memberName))
            {
                // Compose the external member name and partial descriptor.
                String externalMemberDescription = memberName;

                if (!isField)
View Full Code Here

Examples of proguard.util.StringMatcher

        // Print out a note about the dynamic invocation.
        if (notePrinter != null &&
            notePrinter.accepts(clazz.getName()))
        {
            // Is the class member name in the list of exceptions?
            StringMatcher noteExceptionMatcher = isField ?
                noteFieldExceptionMatcher :
                noteMethodExceptionMatcher;

            int memberNameIndex = noteSequenceMatcher.matchedConstantIndex(MEMBER_NAME_INDEX);
            String memberName = memberNameIndex <= 0 ? defaultName :
                clazz.getStringString(memberNameIndex);

            if (noteExceptionMatcher == null ||
                !noteExceptionMatcher.matches(memberName))
            {
                // Compose the external member name and partial descriptor.
                String externalMemberDescription = memberName;

                if (!isField)
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.