public class FileInfoMock extends Object implements net.sourceforge.javadpkg.plugin.impl.FileInfo
A mock implementation of the FileInfo.
| Constructor and Description |
|---|
FileInfoMock(String absolutePath,
long length)
Creates a mock information about a reagular file.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
exists() |
String |
getAbsolutePath() |
File |
getFile() |
long |
getLength() |
boolean |
isDirectory() |
boolean |
isFile() |
public FileInfoMock(String absolutePath, long length)
Creates a mock information about a reagular file.
absolutePath - The absolute path.length - The length.IllegalArgumentException - If the absolute path is null or the length is
less than 0.public File getFile()
getFile in interface net.sourceforge.javadpkg.plugin.impl.FileInfopublic String getAbsolutePath()
getAbsolutePath in interface net.sourceforge.javadpkg.plugin.impl.FileInfopublic boolean exists()
exists in interface net.sourceforge.javadpkg.plugin.impl.FileInfopublic boolean isFile()
isFile in interface net.sourceforge.javadpkg.plugin.impl.FileInfopublic boolean isDirectory()
isDirectory in interface net.sourceforge.javadpkg.plugin.impl.FileInfopublic long getLength()
getLength in interface net.sourceforge.javadpkg.plugin.impl.FileInfoCopyright © 2015–2018. All rights reserved.