Class DirectoryHandle
- java.lang.Object
-
- org.apache.sshd.server.subsystem.sftp.Handle
-
- org.apache.sshd.server.subsystem.sftp.DirectoryHandle
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
,java.nio.channels.Channel
,java.util.Iterator<java.nio.file.Path>
,AttributeRepository
,AttributeStore
public class DirectoryHandle extends Handle implements java.util.Iterator<java.nio.file.Path>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.sshd.common.AttributeRepository
AttributeRepository.AttributeKey<T>
-
-
Field Summary
Fields Modifier and Type Field Description private boolean
done
private java.nio.file.DirectoryStream<java.nio.file.Path>
ds
private java.util.Iterator<java.nio.file.Path>
fileList
private boolean
sendDot
private boolean
sendDotDot
-
Constructor Summary
Constructors Constructor Description DirectoryHandle(SftpSubsystem subsystem, java.nio.file.Path dir, java.lang.String handle)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
boolean
hasNext()
boolean
isDone()
boolean
isSendDot()
boolean
isSendDotDot()
void
markDone()
void
markDotDotSent()
void
markDotSent()
java.nio.file.Path
next()
void
remove()
-
Methods inherited from class org.apache.sshd.server.subsystem.sftp.Handle
attributeKeys, clearAttributes, computeAttributeIfAbsent, getAttribute, getAttributesCount, getFile, getFileHandle, getSubsystem, isOpen, removeAttribute, setAttribute, signalHandleOpen, signalHandleOpening, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.apache.sshd.common.AttributeRepository
resolveAttribute
-
-
-
-
Constructor Detail
-
DirectoryHandle
public DirectoryHandle(SftpSubsystem subsystem, java.nio.file.Path dir, java.lang.String handle) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
isDone
public boolean isDone()
-
markDone
public void markDone()
-
isSendDot
public boolean isSendDot()
-
markDotSent
public void markDotSent()
-
isSendDotDot
public boolean isSendDotDot()
-
markDotDotSent
public void markDotDotSent()
-
hasNext
public boolean hasNext()
- Specified by:
hasNext
in interfacejava.util.Iterator<java.nio.file.Path>
-
next
public java.nio.file.Path next()
- Specified by:
next
in interfacejava.util.Iterator<java.nio.file.Path>
-
remove
public void remove()
- Specified by:
remove
in interfacejava.util.Iterator<java.nio.file.Path>
-
-