java.lang.Object
org.eclipse.jgit.util.FS.Attributes
- Enclosing class:
- FS
File attributes we typically care for.
- Since:
- 3.3
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionAttributes(File path, FS fs) Constructor when there are issues with reading. -
Method Summary
Modifier and TypeMethodDescriptionlongGet the file creation timegetFile()Get the file the attributes apply toGet the time when this object was last modifiedlongGet the length of this filegetName()Get the filenamebooleanWhether this are attributes of a directorybooleanWhether this are attributes of an executable filebooleanWhether this are the attributes of a regular filebooleanWhether this are the attributes of a symbolic link
-
Field Details
-
length
protected long lengthfile length
-
-
Constructor Details
-
Attributes
Constructor when there are issues with reading. All attributes except given will be set to the default values.- Parameters:
path- file pathfs- FS to use
-
-
Method Details
-
isDirectory
public boolean isDirectory()Whether this are attributes of a directory- Returns:
- true if this are the attributes of a directory
-
isExecutable
public boolean isExecutable()Whether this are attributes of an executable file- Returns:
- true if this are the attributes of an executable file
-
isSymbolicLink
public boolean isSymbolicLink()Whether this are the attributes of a symbolic link- Returns:
- true if this are the attributes of a symbolic link
-
isRegularFile
public boolean isRegularFile()Whether this are the attributes of a regular file- Returns:
- true if this are the attributes of a regular file
-
getCreationTime
public long getCreationTime()Get the file creation time- Returns:
- the time when the file was created
-
getLastModifiedInstant
Get the time when this object was last modified- Returns:
- the time when this object was last modified
- Since:
- 5.1.9
-
getLength
public long getLength()Get the length of this file- Returns:
- length of this file object
-
getName
Get the filename- Returns:
- the filename
-
getFile
Get the file the attributes apply to- Returns:
- the file the attributes apply to
-