@Test public void testExampleFromHomepage_usage() throws Exception { Reader originalReader = new StringReader("edit stream"); Modifier myModifier = new RegexModifier("edit stream", 0, "modify stream"); Reader modifyingReader = new ModifyingReader(originalReader, myModifier); String output = IOUtils.toString(modifyingReader); assertEquals("modify stream", output); }
@Override public String toString() { StringBuilder builder = new StringBuilder(); builder.append("RegexModifier [\nfactory="); builder.append(factory); builder.append(", \nreplacement="); builder.append(matchProcessor); builder.append(", \nmatcher="); builder.append(matcher); builder.append(", \nnewNumberOfChars="); builder.append(newNumberOfChars); builder.append("]"); return builder.toString(); }
RegexModifier implements Modifier { @Override public String toString() { StringBuilder builder = new StringBuilder(); builder.append("RegexModifier [\nfactory="); builder.append(factory); builder.append(", \nreplacement="); builder.append(matchProcessor); builder.append(", \nmatcher="); builder.append(matcher); builder.append(", \nnewNumberOfChars="); builder.append(newNumberOfChars); builder.append("]"); return builder.toString(); } }
RegexModifier implements Modifier { @Override public String toString() { StringBuilder builder = new StringBuilder(); builder.append("RegexModifier [\nfactory="); builder.append(factory); builder.append(", \nreplacement="); builder.append(matchProcessor); builder.append(", \nmatcher="); builder.append(matcher); builder.append(", \nnewNumberOfChars="); builder.append(newNumberOfChars); builder.append("]"); return builder.toString(); } protected  RegexModifier();  RegexModifier(String regex, int flags, String replacement);  RegexModifier(String regex, int flags, String replacement, int minimumLengthOfLookBehind,
            int newNumberOfChars);  RegexModifier(String regex, int flags, MatchProcessor matchProcessor, int minimumLengthOfLookBehind,
            int newNumberOfChars);  RegexModifier(OnStreamMatcher matcher, MatchProcessor matchProcessor, int minimumLengthOfLookBehind,
            int newNumberOfChars); }
RegexModifier implements Modifier { @Override public String toString() { StringBuilder builder = new StringBuilder(); builder.append("RegexModifier [\nfactory="); builder.append(factory); builder.append(", \nreplacement="); builder.append(matchProcessor); builder.append(", \nmatcher="); builder.append(matcher); builder.append(", \nnewNumberOfChars="); builder.append(newNumberOfChars); builder.append("]"); return builder.toString(); } protected  RegexModifier();  RegexModifier(String regex, int flags, String replacement);  RegexModifier(String regex, int flags, String replacement, int minimumLengthOfLookBehind,
            int newNumberOfChars);  RegexModifier(String regex, int flags, MatchProcessor matchProcessor, int minimumLengthOfLookBehind,
            int newNumberOfChars);  RegexModifier(OnStreamMatcher matcher, MatchProcessor matchProcessor, int minimumLengthOfLookBehind,
            int newNumberOfChars); @Override AfterModification modify(StringBuilder characterBuffer, int firstModifiableCharacterInBuffer,
            boolean endOfStreamHit); @Override String toString(); void setMatchProcessor(MatchProcessor matchProcessor); }
RegexModifier implements Modifier { @Override public String toString() { StringBuilder builder = new StringBuilder(); builder.append("RegexModifier [\nfactory="); builder.append(factory); builder.append(", \nreplacement="); builder.append(matchProcessor); builder.append(", \nmatcher="); builder.append(matcher); builder.append(", \nnewNumberOfChars="); builder.append(newNumberOfChars); builder.append("]"); return builder.toString(); } protected  RegexModifier();  RegexModifier(String regex, int flags, String replacement);  RegexModifier(String regex, int flags, String replacement, int minimumLengthOfLookBehind,
            int newNumberOfChars);  RegexModifier(String regex, int flags, MatchProcessor matchProcessor, int minimumLengthOfLookBehind,
            int newNumberOfChars);  RegexModifier(OnStreamMatcher matcher, MatchProcessor matchProcessor, int minimumLengthOfLookBehind,
            int newNumberOfChars); @Override AfterModification modify(StringBuilder characterBuffer, int firstModifiableCharacterInBuffer,
            boolean endOfStreamHit); @Override String toString(); void setMatchProcessor(MatchProcessor matchProcessor);  }