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 longgetFileSize()StringgetPath()StringgetRelativePath()booleanisDirectory()booleanisFile()booleanisSymLink()DirectoryEntrywithFileSize(long fileSize)Sets the file size corresponding to this entryDirectoryEntrywithIsDirectory(boolean isDirectory)Sets the isDirectory flag, meaning this entry corresponds to a directoryDirectoryEntrywithIsFile(boolean isFile)Sets the isFile flag, meaning this entry corresponds to a fileDirectoryEntrywithIsSymLink(boolean isSymLink)Sets the isSymLink flag, meaning this entry corresponds to a symbolic linkDirectoryEntrywithPath(String path)Sets the absolute path of this entryDirectoryEntrywithRelativePath(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
-
-