Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ private static class MboxListener implements IMAPChunkListener {
volatile long lastSeq = -1;
private final String lineSeparator;
private final SimpleDateFormat DATE_FORMAT // for mbox From_ lines
= new SimpleDateFormat("EEE MMM dd HH:mm:ss YYYY");
= new SimpleDateFormat("EEE MMM dd HH:mm:ss yyyy");

// e.g. INTERNALDATE "27-Oct-2013 07:43:24 +0000"
// for parsing INTERNALDATE
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ private static void writeFile(final POP3Client pop3, final OutputStreamWriter fw

private static void writeMbox(final POP3Client pop3, final OutputStreamWriter fw, final int i) throws IOException {
final SimpleDateFormat DATE_FORMAT // for mbox From_ lines
= new SimpleDateFormat("EEE MMM dd HH:mm:ss YYYY");
= new SimpleDateFormat("EEE MMM dd HH:mm:ss yyyy");
final String replyTo = "MAILER-DAEMON"; // default
final Date received = new Date();
try (final BufferedReader r = (BufferedReader) pop3.retrieveMessage(i)) {
Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/apache/commons/net/ftp/FTP.java
Original file line number Diff line number Diff line change
Expand Up @@ -993,7 +993,7 @@ public int mdtm(final String file) throws IOException
* receive the reply, and return the reply code.
*
* @param pathname The pathname for which mtime is to be changed
* @param timeval Timestamp in <code>YYYYMMDDhhmmss</code> format
* @param timeval Timestamp in <code>yyyyMMDDhhmmss</code> format
* @return The reply code received from the server.
* @throws FTPConnectionClosedException
* If the FTP server prematurely closes the connection as a result
Expand Down
14 changes: 7 additions & 7 deletions src/main/java/org/apache/commons/net/ftp/FTPClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -1891,11 +1891,11 @@ public boolean getListHiddenFiles() {
/**
* Issue the FTP MDTM command (not supported by all servers) to retrieve the last
* modification time of a file. The modification string should be in the
* ISO 3077 form "YYYYMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* ISO 3077 form "yyyyMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* GMT, but not all FTP servers honor this.
*
* @param pathname The file path to query.
* @return A string representing the last file modification time in <code>YYYYMMDDhhmmss</code> format.
* @return A string representing the last file modification time in <code>yyyyMMDDhhmmss</code> format.
* @throws IOException if an I/O error occurs.
* @since 2.0
*/
Expand Down Expand Up @@ -2943,7 +2943,7 @@ public boolean makeDirectory(final String pathname) throws IOException
/**
* Issue the FTP MDTM command (not supported by all servers) to retrieve the last
* modification time of a file. The modification string should be in the
* ISO 3077 form "YYYYMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* ISO 3077 form "yyyyMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* GMT, but not all FTP servers honor this.
*
* @param pathname The file path to query.
Expand All @@ -2963,7 +2963,7 @@ public Calendar mdtmCalendar(final String pathname) throws IOException {
/**
* Issue the FTP MDTM command (not supported by all servers) to retrieve the last
* modification time of a file. The modification string should be in the
* ISO 3077 form "YYYYMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* ISO 3077 form "yyyyMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* GMT, but not all FTP servers honor this.
*
* @param pathname The file path to query.
Expand All @@ -2987,7 +2987,7 @@ public FTPFile mdtmFile(final String pathname) throws IOException {
/**
* Issue the FTP MDTM command (not supported by all servers) to retrieve the last
* modification time of a file. The modification string should be in the
* ISO 3077 form "YYYYMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* ISO 3077 form "yyyyMMDDhhmmss(.xxx)?". The timestamp represented should also be in
* GMT, but not all FTP servers honor this.
*
* @param pathname The file path to query.
Expand Down Expand Up @@ -3746,14 +3746,14 @@ public void setListHiddenFiles(final boolean listHiddenFiles) {
* Issue the FTP MFMT command (not supported by all servers) which sets the last
* modified time of a file.
*
* The timestamp should be in the form <code>YYYYMMDDhhmmss</code>. It should also
* The timestamp should be in the form <code>yyyyMMDDhhmmss</code>. It should also
* be in GMT, but not all servers honor this.
*
* An FTP server would indicate its support of this feature by including "MFMT"
* in its response to the FEAT command, which may be retrieved by FTPClient.features()
*
* @param pathname The file path for which last modified time is to be changed.
* @param timeval The timestamp to set to, in <code>YYYYMMDDhhmmss</code> format.
* @param timeval The timestamp to set to, in <code>yyyyMMDDhhmmss</code> format.
* @return true if successfully set, false if not
* @throws IOException if an I/O error occurs.
* @since 2.2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ public static FTPFile parseEntry(final String entry) {
}

/**
* Parse a GMT time stamp of the form YYYYMMDDHHMMSS[.sss]
* Parse a GMT time stamp of the form yyyyMMDDHHMMSS[.sss]
*
* @param timestamp the date-time to parse
* @return a Calendar entry, may be {@code null}
Expand Down Expand Up @@ -131,7 +131,7 @@ public static Calendar parseGMTdateTime(final String timestamp) {
}

/**
* Parse a GMT time stamp of the form YYYYMMDDHHMMSS[.sss]
* Parse a GMT time stamp of the form yyyyMMDDHHMMSS[.sss]
*
* @param timestamp the date-time to parse
* @return a Calendar entry, may be {@code null}
Expand Down