Enum Class Sftp.Mode

java.lang.Object
java.lang.Enum<Sftp.Mode>
org.aoju.bus.extra.ssh.Sftp.Mode
All Implemented Interfaces:
Serializable, Comparable<Sftp.Mode>, Constable
Enclosing class:
Sftp

public static enum Sftp.Mode extends Enum<Sftp.Mode>
JSch支持的三种文件传输模式
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    追加模式,如果目标文件已存在,传输的文件将在目标文件后追加
    完全覆盖模式,这是JSch的默认文件传输模式,即如果目标文件已经存在,传输的文件将完全覆盖目标文件,产生新的文件
    恢复模式,如果文件已经传输一部分,这时由于网络或其他任何原因导致文件传输中断,如果下一次传输相同的文件,则会从上一次中断的地方续传
  • Method Summary

    Modifier and Type
    Method
    Description
    static Sftp.Mode
    Returns the enum constant of this class with the specified name.
    static Sftp.Mode[]
    Returns an array containing the constants of this enum class, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • OVERWRITE

      public static final Sftp.Mode OVERWRITE
      完全覆盖模式,这是JSch的默认文件传输模式,即如果目标文件已经存在,传输的文件将完全覆盖目标文件,产生新的文件
    • RESUME

      public static final Sftp.Mode RESUME
      恢复模式,如果文件已经传输一部分,这时由于网络或其他任何原因导致文件传输中断,如果下一次传输相同的文件,则会从上一次中断的地方续传
    • APPEND

      public static final Sftp.Mode APPEND
      追加模式,如果目标文件已存在,传输的文件将在目标文件后追加
  • Method Details

    • values

      public static Sftp.Mode[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static Sftp.Mode valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null