Package org.teiid.file.ftp
Class FtpFileConnection
- java.lang.Object
-
- org.teiid.file.ftp.FtpFileConnection
-
- All Implemented Interfaces:
VirtualFileConnection
,Connection
- Direct Known Subclasses:
FtpFileConnectionImpl
public class FtpFileConnection extends Object implements VirtualFileConnection
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.teiid.file.VirtualFileConnection
VirtualFileConnection.FileMetadata, VirtualFileConnection.Util
-
-
Field Summary
Fields Modifier and Type Field Description static BundleUtil
UTIL
-
Constructor Summary
Constructors Constructor Description FtpFileConnection(FtpConfiguration config)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(InputStream in, String path)
Add a fileboolean
areFilesUsableAfterClose()
void
close()
org.jboss.vfs.VirtualFile
getFile(String path)
VirtualFile[]
getFiles(String pattern)
Return a list of files by a given file patternboolean
remove(String path)
Remove a file-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.teiid.file.VirtualFileConnection
add
-
-
-
-
Field Detail
-
UTIL
public static final BundleUtil UTIL
-
-
Constructor Detail
-
FtpFileConnection
public FtpFileConnection(FtpConfiguration config) throws TranslatorException
- Throws:
TranslatorException
-
-
Method Detail
-
close
public void close() throws Exception
- Specified by:
close
in interfaceConnection
- Throws:
Exception
-
getFiles
public VirtualFile[] getFiles(String pattern)
Description copied from interface:VirtualFileConnection
Return a list of files by a given file pattern- Specified by:
getFiles
in interfaceVirtualFileConnection
- Parameters:
pattern
- - the syntax and pattern. The wildcard character * is supported in the filename only.- Returns:
-
getFile
public org.jboss.vfs.VirtualFile getFile(String path)
-
add
public void add(InputStream in, String path) throws TranslatorException
Description copied from interface:VirtualFileConnection
Add a file- Specified by:
add
in interfaceVirtualFileConnection
- Throws:
TranslatorException
-
remove
public boolean remove(String path)
Description copied from interface:VirtualFileConnection
Remove a file- Specified by:
remove
in interfaceVirtualFileConnection
- Returns:
-
areFilesUsableAfterClose
public boolean areFilesUsableAfterClose()
- Specified by:
areFilesUsableAfterClose
in interfaceVirtualFileConnection
-
-