|
Groovy Documentation | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | METHOD | DETAIL: FIELD | METHOD |
public interface FileTreeElement
Information about a file in a FileTree.
Method Summary | |
---|---|
void
|
copyTo(OutputStream outstr)
Copies the content of this file to an output stream. |
boolean
|
copyTo(File target)
Copies this file to the given target file. |
File
|
getFile()
Returns the file being visited. |
long
|
getLastModified()
Returns the last modified time of this file. |
int
|
getMode()
Returns the Unix permissions of this file, e.g. |
String
|
getName()
Returns the base name of this file. |
String
|
getPath()
Returns the path of this file, relative to the root of the containing file tree. |
RelativePath
|
getRelativePath()
Returns the path of this file, relative to the root of the containing file tree. |
long
|
getSize()
Returns the size of this file. |
boolean
|
isDirectory()
Returns true if this element is a directory, or false if this element is a regular file. |
InputStream
|
open()
Opens this file as an input stream. |
Method Detail |
---|
public void copyTo(OutputStream outstr)
outstr
- The output stream to write to. The caller is responsible for closing this stream.
public boolean copyTo(File target)
target
- the target file.
public File getFile()
public long getLastModified()
public int getMode()
public String getName()
public String getPath()
getRelativePath().getPathString()
.
public RelativePath getRelativePath()
public long getSize()
public boolean isDirectory()
public InputStream open()
Gradle API 1.12