You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by sc...@apache.org on 2005/02/20 16:01:20 UTC
svn commit: r154513 -
jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/input/CountingInputStream.java
Author: scolebourne
Date: Sun Feb 20 07:01:19 2005
New Revision: 154513
URL: http://svn.apache.org/viewcvs?view=rev&rev=154513
Log:
Formatting and Javadoc
Modified:
jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/input/CountingInputStream.java
Modified: jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/input/CountingInputStream.java
URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/input/CountingInputStream.java?view=diff&r1=154512&r2=154513
==============================================================================
--- jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/input/CountingInputStream.java (original)
+++ jakarta/commons/proper/io/trunk/src/java/org/apache/commons/io/input/CountingInputStream.java Sun Feb 20 07:01:19 2005
@@ -1,5 +1,5 @@
/*
- * Copyright 2001-2004 The Apache Software Foundation.
+ * Copyright 2001-2005 The Apache Software Foundation.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -19,21 +19,22 @@
import java.io.InputStream;
/**
- * Used in debugging, it counts the number of bytes that pass
- * through it.
+ * A decorating input stream that counts the number of bytes that
+ * have passed through so far.
*
- * @author <a href="mailto:bayard@apache.org">Henri Yandell</a>
- * @version $Id: CountingInputStream.java,v 1.9 2004/06/13 05:35:44 bayard Exp $
+ * @author Henri Yandell
+ * @version $Id$
*/
public class CountingInputStream extends ProxyInputStream {
+ /** The count of bytes that have passed. */
private int count;
/**
* Constructs a new CountingInputStream.
* @param in InputStream to delegate to
*/
- public CountingInputStream( InputStream in ) {
+ public CountingInputStream(InputStream in) {
super(in);
}
@@ -79,10 +80,10 @@
}
/**
- * Set the count back to 0.
- *
- * @return the count previous to resetting.
- */
+ * Set the count back to 0.
+ *
+ * @return the count previous to resetting.
+ */
public synchronized int resetCount() {
int tmp = this.count;
this.count = 0;
---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org