Class DetailedSftpErrorStatusDataHandler

  • All Implemented Interfaces:
    SftpErrorStatusDataHandler

    public class DetailedSftpErrorStatusDataHandler
    extends java.lang.Object
    implements SftpErrorStatusDataHandler
    An SftpErrorStatusDataHandler implementation that returns an elaborate message string for the thrown exception - thus potentially "leaking" information about the internal implementation and/or real paths. Recommended for debugging or systems where such leakage is not considered a security risk
    • Constructor Detail

      • DetailedSftpErrorStatusDataHandler

        public DetailedSftpErrorStatusDataHandler()
    • Method Detail

      • resolveErrorMessage

        public java.lang.String resolveErrorMessage​(SftpSubsystemEnvironment sftpSubsystem,
                                                    int id,
                                                    java.lang.Throwable e,
                                                    int subStatus,
                                                    int cmd,
                                                    java.lang.Object... args)
        Specified by:
        resolveErrorMessage in interface SftpErrorStatusDataHandler
        Parameters:
        sftpSubsystem - The SFTP subsystem instance
        id - The command identifier
        e - Thrown exception
        subStatus - The sub-status code obtained from invocation of resolveSubStatus
        cmd - The command that was attempted
        args - The relevant command arguments - Note: provided only for logging purposes and subject to type and/or order change at any version
        Returns:
        The human readable text message that explains the failure reason
        See Also:
        SftpHelper.resolveStatusMessage(int)