Skip to content

Commit 84484f2

Browse files
author
Gary Gregory
committed
Javadoc: Use the same names for arguments as the JDK, less confusing.
1 parent 785fa1a commit 84484f2

1 file changed

Lines changed: 10 additions & 11 deletions

File tree

src/main/java/org/apache/commons/io/output/ProxyWriter.java

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
* to increase reusability, because FilterWriter changes the
2828
* methods being called, such as write(char[]) to write(char[], int, int)
2929
* and write(String) to write(String, int, int).
30-
*
3130
*/
3231
public class ProxyWriter extends FilterWriter {
3332

@@ -107,14 +106,14 @@ public Writer append(final CharSequence csq) throws IOException {
107106

108107
/**
109108
* Invokes the delegate's <code>write(int)</code> method.
110-
* @param idx the character to write
109+
* @param c the character to write
111110
* @throws IOException if an I/O error occurs
112111
*/
113112
@Override
114-
public void write(final int idx) throws IOException {
113+
public void write(final int c) throws IOException {
115114
try {
116115
beforeWrite(1);
117-
out.write(idx);
116+
out.write(c);
118117
afterWrite(1);
119118
} catch (final IOException e) {
120119
handleIOException(e);
@@ -144,16 +143,16 @@ public void write(final char[] chr) throws IOException {
144143

145144
/**
146145
* Invokes the delegate's <code>write(char[], int, int)</code> method.
147-
* @param chr the characters to write
148-
* @param st The start offset
146+
* @param cbuf the characters to write
147+
* @param off The start offset
149148
* @param len The number of characters to write
150149
* @throws IOException if an I/O error occurs
151150
*/
152151
@Override
153-
public void write(final char[] chr, final int st, final int len) throws IOException {
152+
public void write(final char[] cbuf, final int off, final int len) throws IOException {
154153
try {
155154
beforeWrite(len);
156-
out.write(chr, st, len);
155+
out.write(cbuf, off, len);
157156
afterWrite(len);
158157
} catch (final IOException e) {
159158
handleIOException(e);
@@ -184,15 +183,15 @@ public void write(final String str) throws IOException {
184183
/**
185184
* Invokes the delegate's <code>write(String)</code> method.
186185
* @param str the string to write
187-
* @param st The start offset
186+
* @param off The start offset
188187
* @param len The number of characters to write
189188
* @throws IOException if an I/O error occurs
190189
*/
191190
@Override
192-
public void write(final String str, final int st, final int len) throws IOException {
191+
public void write(final String str, final int off, final int len) throws IOException {
193192
try {
194193
beforeWrite(len);
195-
out.write(str, st, len);
194+
out.write(str, off, len);
196195
afterWrite(len);
197196
} catch (final IOException e) {
198197
handleIOException(e);

0 commit comments

Comments
 (0)