Skip to content

Commit

Permalink
Javadoc: Use "file name" instead of "filename".
Browse files Browse the repository at this point in the history
  • Loading branch information
Gary Gregory committed May 30, 2019
1 parent 39e6a07 commit 928984e
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public class DefaultFileItem
* <code>null</code> if not specified.
* @param isFormField Whether or not this item is a plain form field, as
* opposed to a file upload.
* @param fileName The original filename in the user's file system, or
* @param fileName The original file name in the user's file system, or
* <code>null</code> if not specified.
* @param sizeThreshold The threshold, in bytes, below which items will be
* retained in memory and above which they will be
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/org/apache/commons/fileupload2/FileItem.java
Original file line number Diff line number Diff line change
Expand Up @@ -69,12 +69,12 @@ public interface FileItem extends FileItemHeadersSupport {
String getContentType();

/**
* Returns the original filename in the client's file system, as provided by
* Returns the original file name in the client's file system, as provided by
* the browser (or other client software). In most cases, this will be the
* base file name, without path information. However, some clients, such as
* the Opera browser, do include path information.
*
* @return The original filename in the client's file system.
* @return The original file name in the client's file system.
* @throws InvalidFileNameException The file name contains a NUL character,
* which might be an indicator of a security attack. If you intend to
* use the file name anyways, catch the exception and use
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,12 @@ public static class ItemSkippedException extends IOException {
String getContentType();

/**
* Returns the original filename in the client's file system, as provided by
* Returns the original file name in the client's file system, as provided by
* the browser (or other client software). In most cases, this will be the
* base file name, without path information. However, some clients, such as
* the Opera browser, do include path information.
*
* @return The original filename in the client's file system.
* @return The original file name in the client's file system.
*/
String getName();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public class DiskFileItem
private boolean isFormField;

/**
* The original filename in the user's file system.
* The original file name in the user's file system.
*/
private final String fileName;

Expand Down Expand Up @@ -168,7 +168,7 @@ public class DiskFileItem
* <code>null</code> if not specified.
* @param isFormField Whether or not this item is a plain form field, as
* opposed to a file upload.
* @param fileName The original filename in the user's file system, or
* @param fileName The original file name in the user's file system, or
* <code>null</code> if not specified.
* @param sizeThreshold The threshold, in bytes, below which items will be
* retained in memory and above which they will be
Expand Down Expand Up @@ -240,9 +240,9 @@ public String getCharSet() {
}

/**
* Returns the original filename in the client's file system.
* Returns the original file name in the client's file system.
*
* @return The original filename in the client's file system.
* @return The original file name in the client's file system.
* @throws org.apache.commons.fileupload2.InvalidFileNameException The file name contains a NUL character,
* which might be an indicator of a security attack. If you intend to
* use the file name anyways, catch the exception and use
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@
* Iterator i = fileItems.iterator();
* String comment = ((FileItem)i.next()).getString();
* FileItem fi = (FileItem)i.next();
* // filename on the client
* // file name on the client
* String fileName = fi.getName();
* // save comment and filename to database
* // save comment and file name to database
* ...
* // write the file
* fi.write(new File("/www/uploads/", fileName));
Expand Down

0 comments on commit 928984e

Please sign in to comment.