2 // This software is now distributed according to
\r
3 // the Lesser Gnu Public License. Please see
\r
4 // http://www.gnu.org/copyleft/lesser.txt for
\r
6 // -- Happy Computing!
\r
8 package com.stevesoft.pat.wrap;
\r
12 import com.stevesoft.pat.*;
\r
15 * Allows the outcome of a replaceAll() or replaceFirst() to be directed to a
\r
16 * Writer rather than a String.
\r
18 * The method toStringLike() cannot work, however. This means that the return
\r
19 * value of replaceAll() will be null if this Object is used as the
\r
22 public class WriterWrap implements BasicStringBufferLike
\r
26 public WriterWrap(Writer w)
\r
31 public void appendChar(char c)
\r
36 } catch (IOException ioe)
\r
41 public void appendStr(String s)
\r
46 } catch (IOException ioe)
\r
51 /** This operation can't really be done. */
\r
52 public StringLike toStringLike()
\r
57 public Object unwrap()
\r