public class FTPFileRef
extends org.apache.commons.net.ftp.FTPFile
Constructor and Description |
---|
FTPFileRef(String name)
Create a new file reference, strips the folder of the filename when present
|
FTPFileRef(String name,
String folder) |
Modifier and Type | Method and Description |
---|---|
static FTPFileRef |
fromFTPFile(org.apache.commons.net.ftp.FTPFile ftpFile)
Creates a deep-copy of FTPFile
|
static FTPFileRef |
fromFTPFile(org.apache.commons.net.ftp.FTPFile ftpFile,
String folder)
Creates a deep-copy of FTPFile, relative to the provided folder
|
String |
getFileName()
Returns the filename, not the full (relative) path
|
String |
getName()
Returns the canonical name inclusive file path when present
|
void |
setName(String name)
Strip folder prefix of filename if present.
|
String |
toString() |
void |
updateFTPFile(org.apache.commons.net.ftp.FTPFile ftpFile)
Update the FTPFile attributes
|
getGroup, getHardLinkCount, getLink, getRawListing, getSize, getTimestamp, getTimestampInstant, getType, getUser, hasPermission, isDirectory, isFile, isSymbolicLink, isUnknown, isValid, setGroup, setHardLinkCount, setLink, setPermission, setRawListing, setSize, setTimestamp, setType, setUser, toFormattedString, toFormattedString
public FTPFileRef(String name)
public String getFileName()
public void setName(String name)
setName
in class org.apache.commons.net.ftp.FTPFile
public String getName()
getName
in class org.apache.commons.net.ftp.FTPFile
public String toString()
toString
in class org.apache.commons.net.ftp.FTPFile
public void updateFTPFile(org.apache.commons.net.ftp.FTPFile ftpFile)
public static FTPFileRef fromFTPFile(org.apache.commons.net.ftp.FTPFile ftpFile)
public static FTPFileRef fromFTPFile(org.apache.commons.net.ftp.FTPFile ftpFile, String folder)
Copyright © 2023 Frank!Framework. All rights reserved.