Package software.amazon.awssdk.crt.io
Class DirectoryEntry
- java.lang.Object
-
- software.amazon.awssdk.crt.io.DirectoryEntry
-
public class DirectoryEntry extends Object
Supplied during calls to DirectoryTraversal.traverse() as each entry is encountered.
-
-
Constructor Summary
Constructors Constructor Description DirectoryEntry()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description long
getFileSize()
String
getPath()
String
getRelativePath()
boolean
isDirectory()
boolean
isFile()
boolean
isSymLink()
DirectoryEntry
withFileSize(long fileSize)
Sets the file size corresponding to this entryDirectoryEntry
withIsDirectory(boolean isDirectory)
Sets the isDirectory flag, meaning this entry corresponds to a directoryDirectoryEntry
withIsFile(boolean isFile)
Sets the isFile flag, meaning this entry corresponds to a fileDirectoryEntry
withIsSymLink(boolean isSymLink)
Sets the isSymLink flag, meaning this entry corresponds to a symbolic linkDirectoryEntry
withPath(String path)
Sets the absolute path of this entryDirectoryEntry
withRelativePath(String relativePath)
Sets the path relative to the current working directory
-
-
-
Method Detail
-
withPath
public DirectoryEntry withPath(String path)
Sets the absolute path of this entry- Parameters:
path
- path- Returns:
- this entry object
-
getPath
public String getPath()
- Returns:
- the absolute path of this entry
-
withRelativePath
public DirectoryEntry withRelativePath(String relativePath)
Sets the path relative to the current working directory- Parameters:
relativePath
- relative path- Returns:
- this entry object
-
getRelativePath
public String getRelativePath()
- Returns:
- the path relative to the current working directory
-
withIsDirectory
public DirectoryEntry withIsDirectory(boolean isDirectory)
Sets the isDirectory flag, meaning this entry corresponds to a directory- Parameters:
isDirectory
- isDirectory- Returns:
- this entry object
-
isDirectory
public boolean isDirectory()
- Returns:
- true if this entry corresponds to a directory
-
withIsSymLink
public DirectoryEntry withIsSymLink(boolean isSymLink)
Sets the isSymLink flag, meaning this entry corresponds to a symbolic link- Parameters:
isSymLink
- isSymLink- Returns:
- this entry object
-
isSymLink
public boolean isSymLink()
- Returns:
- true if this entry corresponds to a symbolic link.
-
withIsFile
public DirectoryEntry withIsFile(boolean isFile)
Sets the isFile flag, meaning this entry corresponds to a file- Parameters:
isFile
- isFile- Returns:
- this entry object
-
isFile
public boolean isFile()
- Returns:
- true if this entry corresponds to a file
-
withFileSize
public DirectoryEntry withFileSize(long fileSize)
Sets the file size corresponding to this entry- Parameters:
fileSize
- file size in bytes- Returns:
- this entry object
-
getFileSize
public long getFileSize()
- Returns:
- the size of the file
-
-