Class FtpMessage

    • Constructor Detail

      • FtpMessage

        public FtpMessage​(Message message)
        Constructs copy of given message.
        Parameters:
        message -
    • Method Detail

      • command

        public static FtpMessage command​(org.apache.commons.net.ftp.FTPCmd command)
        Sets the ftp command.
        Parameters:
        command -
        Returns:
      • connect

        public static FtpMessage connect​(String sessionId)
        Creates new connect command message.
        Parameters:
        sessionId -
        Returns:
      • put

        public static FtpMessage put​(String localPath)
        Creates new put command message.
        Parameters:
        localPath -
        Returns:
      • put

        public static FtpMessage put​(String localPath,
                                     org.apache.ftpserver.ftplet.DataType type)
        Creates new put command message.
        Parameters:
        localPath -
        type -
        Returns:
      • put

        public static FtpMessage put​(String localPath,
                                     String remotePath,
                                     org.apache.ftpserver.ftplet.DataType type)
        Creates new put command message.
        Parameters:
        localPath -
        remotePath -
        type -
        Returns:
      • get

        public static FtpMessage get​(String remotePath)
        Creates new get command message.
        Parameters:
        remotePath -
        Returns:
      • get

        public static FtpMessage get​(String remotePath,
                                     org.apache.ftpserver.ftplet.DataType type)
        Creates new get command message.
        Parameters:
        remotePath -
        type -
        Returns:
      • get

        public static FtpMessage get​(String remotePath,
                                     String localPath,
                                     org.apache.ftpserver.ftplet.DataType type)
        Creates new get command message.
        Parameters:
        remotePath -
        localPath -
        type -
        Returns:
      • delete

        public static FtpMessage delete​(String remotePath)
        Creates new delete command message.
        Parameters:
        remotePath -
        Returns:
      • list

        public static FtpMessage list​(String remotePath)
        Creates new delete command message.
        Parameters:
        remotePath -
        Returns:
      • success

        public static FtpMessage success​(int replyCode)
      • success

        public static FtpMessage success​(int replyCode,
                                         String replyString)
      • error

        public static FtpMessage error​(int replyCode)
      • error

        public static FtpMessage error​(int replyCode,
                                       String replyString)
      • result

        public static FtpMessage result​(int replyCode,
                                        String replyString,
                                        boolean success)
      • deleteResult

        public static FtpMessage deleteResult​(int replyCode,
                                              String replyString,
                                              boolean success)
      • putResult

        public static FtpMessage putResult​(int replyCode,
                                           String replyString,
                                           boolean success)
      • arguments

        public FtpMessage arguments​(String arguments)
        Sets the command args.
        Parameters:
        arguments -
      • getSignal

        public String getSignal()
        Gets the ftp command signal.
      • getArguments

        public String getArguments()
        Gets the command args.
      • getReplyCode

        public Integer getReplyCode()
        Gets the reply code.
      • hasReplyCode

        public boolean hasReplyCode()
        Check if reply code is set on this message.
        Returns:
      • hasException

        public boolean hasException()
        Check if reply code is set on this message.
        Returns:
      • getReplyString

        public String getReplyString()
        Gets the reply string.