Skip to content

Commit 570c796

Browse files
committed
Javadoc
1 parent a040bc6 commit 570c796

6 files changed

Lines changed: 38 additions & 38 deletions

File tree

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

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ private static int checkBufferSize(final int initialBufferSize) {
192192
*
193193
* @param threshold The number of bytes at which to trigger an event.
194194
* @param outputFile The file to which data is saved beyond the threshold.
195-
* @deprecated Use {@link #builder()}
195+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
196196
*/
197197
@Deprecated
198198
public DeferredFileOutputStream(final int threshold, final File outputFile) {
@@ -227,7 +227,7 @@ private DeferredFileOutputStream(final int threshold, final File outputFile, fin
227227
* @param initialBufferSize The initial size of the in memory buffer.
228228
* @param outputFile The file to which data is saved beyond the threshold.
229229
* @since 2.5
230-
* @deprecated Use {@link #builder()}
230+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
231231
*/
232232
@Deprecated
233233
public DeferredFileOutputStream(final int threshold, final int initialBufferSize, final File outputFile) {
@@ -243,7 +243,7 @@ public DeferredFileOutputStream(final int threshold, final int initialBufferSize
243243
* @param suffix Suffix to use for the temporary file.
244244
* @param directory Temporary file directory.
245245
* @since 2.5
246-
* @deprecated Use {@link #builder()}
246+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
247247
*/
248248
@Deprecated
249249
public DeferredFileOutputStream(final int threshold, final int initialBufferSize, final String prefix, final String suffix, final File directory) {
@@ -259,7 +259,7 @@ public DeferredFileOutputStream(final int threshold, final int initialBufferSize
259259
* @param suffix Suffix to use for the temporary file.
260260
* @param directory Temporary file directory.
261261
* @since 1.4
262-
* @deprecated Use {@link #builder()}
262+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
263263
*/
264264
@Deprecated
265265
public DeferredFileOutputStream(final int threshold, final String prefix, final String suffix, final File directory) {

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

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ private static OutputStreamWriter initWriter(final File file, final Object encod
171171
* @param charset the encoding to use, not null
172172
* @throws NullPointerException if the file or encoding is null
173173
* @throws IOException in case of an I/O error
174-
* @deprecated Use {@link #builder()}
174+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
175175
*/
176176
@Deprecated
177177
public FileWriterWithEncoding(final File file, final Charset charset) throws IOException {
@@ -186,7 +186,7 @@ public FileWriterWithEncoding(final File file, final Charset charset) throws IOE
186186
* @param append true if content should be appended, false to overwrite.
187187
* @throws NullPointerException if the file is null.
188188
* @throws IOException in case of an I/O error.
189-
* @deprecated Use {@link #builder()}
189+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
190190
*/
191191
@Deprecated
192192
@SuppressWarnings("resource") // Call site is responsible for closing a new instance.
@@ -201,7 +201,7 @@ public FileWriterWithEncoding(final File file, final Charset encoding, final boo
201201
* @param charsetEncoder the encoding to use, not null
202202
* @throws NullPointerException if the file or encoding is null
203203
* @throws IOException in case of an I/O error
204-
* @deprecated Use {@link #builder()}
204+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
205205
*/
206206
@Deprecated
207207
public FileWriterWithEncoding(final File file, final CharsetEncoder charsetEncoder) throws IOException {
@@ -216,7 +216,7 @@ public FileWriterWithEncoding(final File file, final CharsetEncoder charsetEncod
216216
* @param append true if content should be appended, false to overwrite.
217217
* @throws NullPointerException if the file is null.
218218
* @throws IOException in case of an I/O error.
219-
* @deprecated Use {@link #builder()}
219+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
220220
*/
221221
@Deprecated
222222
@SuppressWarnings("resource") // Call site is responsible for closing a new instance.
@@ -231,7 +231,7 @@ public FileWriterWithEncoding(final File file, final CharsetEncoder charsetEncod
231231
* @param charsetName the name of the requested charset, not null
232232
* @throws NullPointerException if the file or encoding is null
233233
* @throws IOException in case of an I/O error
234-
* @deprecated Use {@link #builder()}
234+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
235235
*/
236236
@Deprecated
237237
public FileWriterWithEncoding(final File file, final String charsetName) throws IOException {
@@ -246,7 +246,7 @@ public FileWriterWithEncoding(final File file, final String charsetName) throws
246246
* @param append true if content should be appended, false to overwrite.
247247
* @throws NullPointerException if the file is null.
248248
* @throws IOException in case of an I/O error.
249-
* @deprecated Use {@link #builder()}
249+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
250250
*/
251251
@Deprecated
252252
@SuppressWarnings("resource") // Call site is responsible for closing a new instance.
@@ -265,7 +265,7 @@ private FileWriterWithEncoding(final OutputStreamWriter outputStreamWriter) {
265265
* @param charset the charset to use, not null
266266
* @throws NullPointerException if the file name or encoding is null
267267
* @throws IOException in case of an I/O error
268-
* @deprecated Use {@link #builder()}
268+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
269269
*/
270270
@Deprecated
271271
public FileWriterWithEncoding(final String fileName, final Charset charset) throws IOException {
@@ -280,7 +280,7 @@ public FileWriterWithEncoding(final String fileName, final Charset charset) thro
280280
* @param append true if content should be appended, false to overwrite
281281
* @throws NullPointerException if the file name or encoding is null
282282
* @throws IOException in case of an I/O error
283-
* @deprecated Use {@link #builder()}
283+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
284284
*/
285285
@Deprecated
286286
public FileWriterWithEncoding(final String fileName, final Charset charset, final boolean append) throws IOException {
@@ -294,7 +294,7 @@ public FileWriterWithEncoding(final String fileName, final Charset charset, fina
294294
* @param encoding the encoding to use, not null
295295
* @throws NullPointerException if the file name or encoding is null
296296
* @throws IOException in case of an I/O error
297-
* @deprecated Use {@link #builder()}
297+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
298298
*/
299299
@Deprecated
300300
public FileWriterWithEncoding(final String fileName, final CharsetEncoder encoding) throws IOException {
@@ -309,7 +309,7 @@ public FileWriterWithEncoding(final String fileName, final CharsetEncoder encodi
309309
* @param append true if content should be appended, false to overwrite
310310
* @throws NullPointerException if the file name or encoding is null
311311
* @throws IOException in case of an I/O error
312-
* @deprecated Use {@link #builder()}
312+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
313313
*/
314314
@Deprecated
315315
public FileWriterWithEncoding(final String fileName, final CharsetEncoder charsetEncoder, final boolean append) throws IOException {
@@ -323,7 +323,7 @@ public FileWriterWithEncoding(final String fileName, final CharsetEncoder charse
323323
* @param charsetName the name of the requested charset, not null
324324
* @throws NullPointerException if the file name or encoding is null
325325
* @throws IOException in case of an I/O error
326-
* @deprecated Use {@link #builder()}
326+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
327327
*/
328328
@Deprecated
329329
public FileWriterWithEncoding(final String fileName, final String charsetName) throws IOException {
@@ -338,7 +338,7 @@ public FileWriterWithEncoding(final String fileName, final String charsetName) t
338338
* @param append true if content should be appended, false to overwrite
339339
* @throws NullPointerException if the file name or encoding is null
340340
* @throws IOException in case of an I/O error
341-
* @deprecated Use {@link #builder()}
341+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
342342
*/
343343
@Deprecated
344344
public FileWriterWithEncoding(final String fileName, final String charsetName, final boolean append) throws IOException {

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

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ public static Builder builder() {
148148
* @param file the file to write to, not null
149149
* @throws NullPointerException if the file is null
150150
* @throws IOException in case of an I/O error
151-
* @deprecated Use {@link #builder()}
151+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
152152
*/
153153
@Deprecated
154154
public LockableFileWriter(final File file) throws IOException {
@@ -162,7 +162,7 @@ public LockableFileWriter(final File file) throws IOException {
162162
* @param append true if content should be appended, false to overwrite
163163
* @throws NullPointerException if the file is null
164164
* @throws IOException in case of an I/O error
165-
* @deprecated Use {@link #builder()}
165+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
166166
*/
167167
@Deprecated
168168
public LockableFileWriter(final File file, final boolean append) throws IOException {
@@ -192,7 +192,7 @@ public LockableFileWriter(final File file, final boolean append, final String lo
192192
* @throws NullPointerException if the file is null
193193
* @throws IOException in case of an I/O error
194194
* @since 2.3
195-
* @deprecated Use {@link #builder()}
195+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
196196
*/
197197
@Deprecated
198198
public LockableFileWriter(final File file, final Charset charset) throws IOException {
@@ -209,7 +209,7 @@ public LockableFileWriter(final File file, final Charset charset) throws IOExcep
209209
* @throws NullPointerException if the file is null
210210
* @throws IOException in case of an I/O error
211211
* @since 2.3
212-
* @deprecated Use {@link #builder()}
212+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
213213
*/
214214
@Deprecated
215215
public LockableFileWriter(final File file, final Charset charset, final boolean append, final String lockDir) throws IOException {
@@ -244,7 +244,7 @@ public LockableFileWriter(final File file, final Charset charset, final boolean
244244
* @throws IOException in case of an I/O error
245245
* @throws java.nio.charset.UnsupportedCharsetException thrown instead of {@link java.io.UnsupportedEncodingException} in version 2.2 if the encoding is not
246246
* supported.
247-
* @deprecated Use {@link #builder()}
247+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
248248
*/
249249
@Deprecated
250250
public LockableFileWriter(final File file, final String charsetName) throws IOException {
@@ -262,7 +262,7 @@ public LockableFileWriter(final File file, final String charsetName) throws IOEx
262262
* @throws IOException in case of an I/O error
263263
* @throws java.nio.charset.UnsupportedCharsetException thrown instead of {@link java.io.UnsupportedEncodingException} in version 2.2 if the encoding is not
264264
* supported.
265-
* @deprecated Use {@link #builder()}
265+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
266266
*/
267267
@Deprecated
268268
public LockableFileWriter(final File file, final String charsetName, final boolean append, final String lockDir) throws IOException {
@@ -275,7 +275,7 @@ public LockableFileWriter(final File file, final String charsetName, final boole
275275
* @param fileName the file to write to, not null
276276
* @throws NullPointerException if the file is null
277277
* @throws IOException in case of an I/O error
278-
* @deprecated Use {@link #builder()}
278+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
279279
*/
280280
@Deprecated
281281
public LockableFileWriter(final String fileName) throws IOException {
@@ -289,7 +289,7 @@ public LockableFileWriter(final String fileName) throws IOException {
289289
* @param append true if content should be appended, false to overwrite
290290
* @throws NullPointerException if the file is null
291291
* @throws IOException in case of an I/O error
292-
* @deprecated Use {@link #builder()}
292+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
293293
*/
294294
@Deprecated
295295
public LockableFileWriter(final String fileName, final boolean append) throws IOException {
@@ -304,7 +304,7 @@ public LockableFileWriter(final String fileName, final boolean append) throws IO
304304
* @param lockDir the directory in which the lock file should be held
305305
* @throws NullPointerException if the file is null
306306
* @throws IOException in case of an I/O error
307-
* @deprecated Use {@link #builder()}
307+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
308308
*/
309309
@Deprecated
310310
public LockableFileWriter(final String fileName, final boolean append, final String lockDir) throws IOException {

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ public static InputStream toBufferedInputStream(final InputStream input, final i
129129
* Creates a new byte array output stream. The buffer capacity is initially
130130
*
131131
* {@value AbstractByteArrayOutputStream#DEFAULT_SIZE} bytes, though its size increases if necessary.
132-
* @deprecated Use {@link #builder()}.
132+
* @deprecated Use {@link #builder()} and {@link Builder#get()}.
133133
*/
134134
@Deprecated
135135
public UnsynchronizedByteArrayOutputStream() {
@@ -141,7 +141,7 @@ public UnsynchronizedByteArrayOutputStream() {
141141
*
142142
* @param size the initial size
143143
* @throws IllegalArgumentException if size is negative
144-
* @deprecated Use {@link #builder()}.
144+
* @deprecated Use {@link #builder()} and {@link Builder#get()}.
145145
*/
146146
@Deprecated
147147
public UnsynchronizedByteArrayOutputStream(final int size) {

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

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,7 @@ private static void checkIbmJdkWithBrokenUTF16(final Charset charset) {
221221
* characters. The output buffer will only be flushed when it overflows or when {@link #flush()} or {@link #close()} is called.
222222
*
223223
* @param writer the target {@link Writer}
224-
* @deprecated Use {@link #builder()} instead
224+
* @deprecated Use {@link #builder()} and {@link Builder#get()} instead
225225
*/
226226
@Deprecated
227227
public WriterOutputStream(final Writer writer) {
@@ -234,7 +234,7 @@ public WriterOutputStream(final Writer writer) {
234234
*
235235
* @param writer the target {@link Writer}
236236
* @param charset the charset encoding
237-
* @deprecated Use {@link #builder()} instead
237+
* @deprecated Use {@link #builder()} and {@link Builder#get()} instead
238238
*/
239239
@Deprecated
240240
public WriterOutputStream(final Writer writer, final Charset charset) {
@@ -250,7 +250,7 @@ public WriterOutputStream(final Writer writer, final Charset charset) {
250250
* @param writeImmediately If {@code true} the output buffer will be flushed after each write operation, i.e. all available data will be written to the
251251
* underlying {@link Writer} immediately. If {@code false}, the output buffer will only be flushed when it overflows or when
252252
* {@link #flush()} or {@link #close()} is called.
253-
* @deprecated Use {@link #builder()} instead
253+
* @deprecated Use {@link #builder()} and {@link Builder#get()} instead
254254
*/
255255
@Deprecated
256256
public WriterOutputStream(final Writer writer, final Charset charset, final int bufferSize, final boolean writeImmediately) {
@@ -272,7 +272,7 @@ public WriterOutputStream(final Writer writer, final Charset charset, final int
272272
* @param writer the target {@link Writer}
273273
* @param decoder the charset decoder
274274
* @since 2.1
275-
* @deprecated Use {@link #builder()} instead
275+
* @deprecated Use {@link #builder()} and {@link Builder#get()} instead
276276
*/
277277
@Deprecated
278278
public WriterOutputStream(final Writer writer, final CharsetDecoder decoder) {
@@ -289,7 +289,7 @@ public WriterOutputStream(final Writer writer, final CharsetDecoder decoder) {
289289
* underlying {@link Writer} immediately. If {@code false}, the output buffer will only be flushed when it overflows or when
290290
* {@link #flush()} or {@link #close()} is called.
291291
* @since 2.1
292-
* @deprecated Use {@link #builder()} instead
292+
* @deprecated Use {@link #builder()} and {@link Builder#get()} instead
293293
*/
294294
@Deprecated
295295
public WriterOutputStream(final Writer writer, final CharsetDecoder decoder, final int bufferSize, final boolean writeImmediately) {
@@ -306,7 +306,7 @@ public WriterOutputStream(final Writer writer, final CharsetDecoder decoder, fin
306306
*
307307
* @param writer the target {@link Writer}
308308
* @param charsetName the name of the charset encoding
309-
* @deprecated Use {@link #builder()} instead
309+
* @deprecated Use {@link #builder()} and {@link Builder#get()} instead
310310
*/
311311
@Deprecated
312312
public WriterOutputStream(final Writer writer, final String charsetName) {
@@ -322,7 +322,7 @@ public WriterOutputStream(final Writer writer, final String charsetName) {
322322
* @param writeImmediately If {@code true} the output buffer will be flushed after each write operation, i.e. all available data will be written to the
323323
* underlying {@link Writer} immediately. If {@code false}, the output buffer will only be flushed when it overflows or when
324324
* {@link #flush()} or {@link #close()} is called.
325-
* @deprecated Use {@link #builder()} instead
325+
* @deprecated Use {@link #builder()} and {@link Builder#get()} instead
326326
*/
327327
@Deprecated
328328
public WriterOutputStream(final Writer writer, final String charsetName, final int bufferSize, final boolean writeImmediately) {

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

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ public static Builder builder() {
109109
* @param file The file to write to
110110
* @throws FileNotFoundException if there is an error creating or
111111
* opening the file
112-
* @deprecated Use {@link #builder()}
112+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
113113
*/
114114
@Deprecated
115115
public XmlStreamWriter(final File file) throws FileNotFoundException {
@@ -124,7 +124,7 @@ public XmlStreamWriter(final File file) throws FileNotFoundException {
124124
* @param defaultEncoding The default encoding if not encoding could be detected
125125
* @throws FileNotFoundException if there is an error creating or
126126
* opening the file
127-
* @deprecated Use {@link #builder()}
127+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
128128
*/
129129
@Deprecated
130130
@SuppressWarnings("resource")
@@ -137,7 +137,7 @@ public XmlStreamWriter(final File file, final String defaultEncoding) throws Fil
137137
* with a default encoding of UTF-8.
138138
*
139139
* @param out The output stream
140-
* @deprecated Use {@link #builder()}
140+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
141141
*/
142142
@Deprecated
143143
public XmlStreamWriter(final OutputStream out) {
@@ -162,7 +162,7 @@ private XmlStreamWriter(final OutputStream out, final Charset defaultEncoding) {
162162
*
163163
* @param out The output stream
164164
* @param defaultEncoding The default encoding if not encoding could be detected
165-
* @deprecated Use {@link #builder()}
165+
* @deprecated Use {@link #builder()} and {@link Builder#get()}
166166
*/
167167
@Deprecated
168168
public XmlStreamWriter(final OutputStream out, final String defaultEncoding) {

0 commit comments

Comments
 (0)