/[classpath]/classpath/java/io/PrintStream.java
ViewVC logotype

Diff of /classpath/java/io/PrintStream.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.19 by bryce, Sun Aug 10 03:04:38 2003 UTC revision 1.19.2.1 by tromey, Sun Jan 2 22:43:45 2005 UTC
# Line 1  Line 1 
1  /* PrintStream.java -- OutputStream for printing output  /* PrintStream.java -- OutputStream for printing output
2     Copyright (C) 1998, 1999, 2001, 2003 Free Software Foundation, Inc.     Copyright (C) 1998, 1999, 2001, 2003, 2005 Free Software Foundation, Inc.
3    
4  This file is part of GNU Classpath.  This file is part of GNU Classpath.
5    
# Line 56  package java.io; Line 56  package java.io;
56   * @author Aaron M. Renn <arenn@urbanophile.com>   * @author Aaron M. Renn <arenn@urbanophile.com>
57   * @author Tom Tromey <tromey@cygnus.com>   * @author Tom Tromey <tromey@cygnus.com>
58   */   */
59  public class PrintStream extends FilterOutputStream  public class PrintStream extends FilterOutputStream implements Appendable
60  {  {
61    /**    /**
62     * This boolean indicates whether or not an error has ever occurred     * This boolean indicates whether or not an error has ever occurred
# Line 136  public class PrintStream extends FilterO Line 136  public class PrintStream extends FilterO
136      this.auto_flush = auto_flush;      this.auto_flush = auto_flush;
137    }    }
138    
139      /** @since 1.5 */
140      public PrintStream (String filename) throws FileNotFoundException
141      {
142        super (new FileOutputStream (filename));
143        pw = new PrintWriter (new OutputStreamWriter (out), false);
144        auto_flush = false;
145      }
146    
147      /** @since 1.5 */
148      public PrintStream (String filename, String encoding)
149        throws FileNotFoundException
150      {
151        super (new FileOutputStream (filename));
152        pw = new PrintWriter (new OutputStreamWriter (out, encoding), false);
153        auto_flush = false;
154      }
155    
156      /** @since 1.5 */
157      public PrintStream (File file) throws FileNotFoundException
158      {
159        super (new FileOutputStream (file));
160        pw = new PrintWriter (new OutputStreamWriter (out), false);
161        auto_flush = false;
162      }
163    
164      /** @since 1.5 */
165      public PrintStream (File file, String encoding)
166        throws FileNotFoundException
167      {
168        super (new FileOutputStream (file));
169        pw = new PrintWriter (new OutputStreamWriter (out, encoding), false);
170        auto_flush = false;
171      }
172    
173    /**    /**
174     * This method checks to see if an error has occurred on this stream.  Note     * This method checks to see if an error has occurred on this stream.  Note
175     * that once an error has occurred, this method will continue to report     * that once an error has occurred, this method will continue to report
# Line 467  public class PrintStream extends FilterO Line 501  public class PrintStream extends FilterO
501          setError ();          setError ();
502        }        }
503    }    }
504    
505      /** @since 1.5 */
506      public PrintStream append(char c) throws IOException
507      {
508        print(c);
509        return this;
510      }
511    
512      /** @since 1.5 */
513      public PrintStream append(CharSequence cs) throws IOException
514      {
515        print(cs == null ? "null" : cs.toString());
516        return this;
517      }
518    
519      /** @since 1.5 */
520      public PrintStream append(CharSequence cs, int start, int end)
521        throws IOException
522      {
523        print(cs == null ? "null" : cs.subSequence(start, end).toString());
524        return this;
525      }
526  } // class PrintStream  } // class PrintStream
527    

Legend:
Removed from v.1.19  
changed lines
  Added in v.1.19.2.1

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26