in ftp/src/main/scala/org/apache/pekko/stream/connectors/ftp/javadsl/FtpApi.scala [42:280]
def ls(host: String): Source[FtpFile, NotUsed]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s from a base path.
* By default, `anonymous` credentials will be used.
*
* @param host FTP, FTPs or SFTP host
* @param basePath Base path from which traverse the remote file server
* @return A [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s
*/
def ls(
host: String,
basePath: String): Source[FtpFile, NotUsed]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s from the remote user `root` directory.
*
* @param host FTP, FTPs or SFTP host
* @param username username
* @param password password
* @return A [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s
*/
def ls(
host: String,
username: String,
password: String): Source[FtpFile, NotUsed]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s from a base path.
*
* @param host FTP, FTPs or SFTP host
* @param username username
* @param password password
* @param basePath Base path from which traverse the remote file server
* @return A [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s
*/
def ls(
host: String,
username: String,
password: String,
basePath: String): Source[FtpFile, NotUsed]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s from a base path.
*
* @param basePath Base path from which traverse the remote file server
* @param connectionSettings connection settings
* @return A [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s
*/
def ls(
basePath: String,
connectionSettings: S): Source[FtpFile, NotUsed]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s from a base path.
*
* @param basePath Base path from which traverse the remote file server
* @param connectionSettings connection settings
* @param branchSelector a predicate for pruning the tree. Takes a remote folder and return true
* if you want to enter that remote folder.
* Default behaviour is full recursive which is equivalent with calling this function
* with [[ls(basePath,connectionSettings,f->true)]].
*
* Calling [[ls(basePath,connectionSettings,f->false)]] will emit only the files and folder in
* non-recursive fashion
*
* @return A [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s
*/
def ls(basePath: String, connectionSettings: S, branchSelector: Predicate[FtpFile]): Source[FtpFile, NotUsed]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s from a base path.
*
* @param basePath Base path from which traverse the remote file server
* @param connectionSettings connection settings
* @param branchSelector a predicate for pruning the tree. Takes a remote folder and return true
* if you want to enter that remote folder.
* Default behaviour is full recursive which is equivalent with calling this function
* with [[ls(basePath,connectionSettings,f->true)]].
*
* Calling [[ls(basePath,connectionSettings,f->false)]] will emit only the files and folder in
* non-recursive fashion
* @param emitTraversedDirectories whether to include entered directories in the stream
*
* @return A [[pekko.stream.javadsl.Source Source]] of [[FtpFile]]s
*/
def ls(basePath: String,
connectionSettings: S,
branchSelector: Predicate[FtpFile],
emitTraversedDirectories: Boolean): Source[FtpFile, NotUsed]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] from some file path.
*
* @param host FTP, FTPs or SFTP host
* @param path the file path
* @return A [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def fromPath(
host: String,
path: String): Source[ByteString, CompletionStage[IOResult]]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] from some file path.
*
* @param host FTP, FTPs or SFTP host
* @param username username
* @param password password
* @param path the file path
* @return A [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def fromPath(
host: String,
username: String,
password: String,
path: String): Source[ByteString, CompletionStage[IOResult]]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] from some file path.
*
* @param path the file path
* @param connectionSettings connection settings
* @return A [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def fromPath(
path: String,
connectionSettings: S): Source[ByteString, CompletionStage[IOResult]]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] from some file path.
*
* @param path the file path
* @param connectionSettings connection settings
* @param chunkSize the size of transmitted [[pekko.util.ByteString ByteString]] chunks
* @return A [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def fromPath(
path: String,
connectionSettings: S,
chunkSize: Int = DefaultChunkSize): Source[ByteString, CompletionStage[IOResult]]
/**
* Java API: creates a [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] from some file path.
*
* @param path the file path
* @param connectionSettings connection settings
* @param chunkSize the size of transmitted [[pekko.util.ByteString ByteString]] chunks
* @param offset the offset into the remote file at which to start the file transfer
* @return A [[pekko.stream.javadsl.Source Source]] of [[pekko.util.ByteString ByteString]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def fromPath(
path: String,
connectionSettings: S,
chunkSize: Int,
offset: Long): Source[ByteString, CompletionStage[IOResult]]
/**
* Java API for creating a directory in a given path
*
* @param basePath path to start with
* @param name name of a directory to create
* @param connectionSettings connection settings
* @return [[pekko.stream.javadsl.Source Source]] of [[Done]]
*/
def mkdir(basePath: String, name: String, connectionSettings: S): Source[Done, NotUsed]
/**
* Java API for creating a directory in a given path
*
* @param basePath path to start with
* @param name name of a directory to create
* @param connectionSettings connection settings
* @param materializer materializer
* @return [[java.util.concurrent.CompletionStage CompletionStage]] of [[pekko.Done]] indicating a materialized, asynchronous request
* @deprecated pass in the actor system instead of the materializer, since Alpakka 3.0.0
*/
@Deprecated
def mkdirAsync(basePath: String, name: String, connectionSettings: S, mat: Materializer): CompletionStage[Done]
/**
* Java API for creating a directory in a given path
*
* @param basePath path to start with
* @param name name of a directory to create
* @param connectionSettings connection settings
* @param system actor system
* @return [[java.util.concurrent.CompletionStage CompletionStage]] of [[pekko.Done]] indicating a materialized, asynchronous request
*/
def mkdirAsync(basePath: String,
name: String,
connectionSettings: S,
system: ClassicActorSystemProvider): CompletionStage[Done]
/**
* Java API: creates a [[pekko.stream.javadsl.Sink Sink]] of [[pekko.util.ByteString ByteString]] to some file path.
*
* @param path the file path
* @param connectionSettings connection settings
* @param append append data if a file already exists, overwrite the file if not
* @return A [[pekko.stream.javadsl.Sink Sink]] of [[pekko.util.ByteString ByteString]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def toPath(
path: String,
connectionSettings: S,
append: Boolean): Sink[ByteString, CompletionStage[IOResult]]
/**
* Java API: creates a [[pekko.stream.javadsl.Sink Sink]] of [[pekko.util.ByteString ByteString]] to some file path.
* If a file already exists at the specified target path, it will get overwritten.
*
* @param path the file path
* @param connectionSettings connection settings
* @return A [[pekko.stream.javadsl.Sink Sink]] of [[pekko.util.ByteString ByteString]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def toPath(
path: String,
connectionSettings: S): Sink[ByteString, CompletionStage[IOResult]]
/**
* Java API: creates a [[pekko.stream.javadsl.Sink Sink]] of a [[FtpFile]] that moves a file to some file path.
*
* @param destinationPath a function that returns path to where the [[FtpFile]] is moved.
* @param connectionSettings connection settings
* @return A [[pekko.stream.javadsl.Sink Sink]] of [[FtpFile]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def move(destinationPath: Function[FtpFile, String], connectionSettings: S): Sink[FtpFile, CompletionStage[IOResult]]
/**
* Java API: creates a [[pekko.stream.javadsl.Sink Sink]] of a [[FtpFile]] that removes a file.
*
* @param connectionSettings connection settings
* @return A [[pekko.stream.javadsl.Sink Sink]] of [[FtpFile]] that materializes to a [[java.util.concurrent.CompletionStage CompletionStage]] of [[IOResult]]
*/
def remove(connectionSettings: S): Sink[FtpFile, CompletionStage[IOResult]]
protected[javadsl] def func[T, R](f: T => R): pekko.japi.function.Function[T, R] =
new pekko.japi.function.Function[T, R] {
override def apply(param: T): R = f(param)
}