Class Directory
java.lang.Object
org.fedoraproject.xmvn.tools.install.File
org.fedoraproject.xmvn.tools.install.Directory
A directory installed as part of a package.
While package doesn't have to own all directories it creates, directories represented by instances of this class are assumed to be owned by the package they belong to.
- Author:
- Mikolaj Izdebski
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringGet additional file attributes to be added to file descriptor.protected voidinstallContents(Path targetAbsolutePath) Install the file into specified location.Methods inherited from class File
equals, getAccessMode, getDescriptor, getTargetPath, hashCode, install
-
Constructor Details
-
Directory
Create a directory with specified path and default permissions (0755).- Parameters:
targetPath- directory path, relative to installation root
-
Directory
Create a directory with specified path and permissions.- Parameters:
targetPath- directory path, relative to installation rootaccessMode- Unix access mode of the file (must be an integer in range from 0 to 0777)
-
-
Method Details
-
installContents
Description copied from class:FileInstall the file into specified location.Implementations of this method can assume that all parent directory of target file already exists. Access mode of target file doesn't have to be set as it will be manipulated with other means.
- Specified by:
installContentsin classFile- Parameters:
targetAbsolutePath- absolute path to the target file- Throws:
IOException
-
getDescriptorExtra
Description copied from class:FileGet additional file attributes to be added to file descriptor.By default there are no extra attributes, but subclasses can override this method and specify it.
- Overrides:
getDescriptorExtrain classFile- Returns:
- extra descriptor data (can be
null)
-