@HashCodeAndEqualsPlugin.Enhance public static class Plugin.Engine.Target.ForFolder.Dispatcher.ForJava7CapableVm extends java.lang.Object implements Plugin.Engine.Target.ForFolder.Dispatcher
Plugin.Engine.Target.ForFolder.Dispatcher.CreationAction, Plugin.Engine.Target.ForFolder.Dispatcher.ForJava7CapableVm, Plugin.Engine.Target.ForFolder.Dispatcher.ForLegacyVm
Modifier and Type | Field and Description |
---|---|
private java.lang.reflect.Method |
copy
The
java.nio.Files#copy(Path,Path,CopyOption[]) method. |
private java.lang.Object[] |
copyOptions
The copy options to apply.
|
private java.lang.reflect.Method |
toPath
The
java.io.File#toPath() method. |
Modifier | Constructor and Description |
---|---|
protected |
ForJava7CapableVm(java.lang.reflect.Method toPath,
java.lang.reflect.Method copy,
java.lang.Object[] copyOptions)
Creates a new NIO2 capable dispatcher.
|
Modifier and Type | Method and Description |
---|---|
void |
copy(java.io.File source,
java.io.File target)
Copies the source file to the target location.
|
boolean |
isAlive()
Returns
true if this dispatcher is alive. |
private final java.lang.reflect.Method toPath
java.io.File#toPath()
method.private final java.lang.reflect.Method copy
java.nio.Files#copy(Path,Path,CopyOption[])
method.private final java.lang.Object[] copyOptions
protected ForJava7CapableVm(java.lang.reflect.Method toPath, java.lang.reflect.Method copy, java.lang.Object[] copyOptions)
toPath
- The java.io.File#toPath()
method.copy
- The java.nio.Files#copy(Path,Path,CopyOption[])
method.copyOptions
- The copy options to apply.public boolean isAlive()
true
if this dispatcher is alive.isAlive
in interface Plugin.Engine.Target.ForFolder.Dispatcher
true
if this dispatcher is alive.public void copy(java.io.File source, java.io.File target) throws java.io.IOException
copy
in interface Plugin.Engine.Target.ForFolder.Dispatcher
source
- The source file.target
- The target file.java.io.IOException
- If an I/O error occurs.