SFML 3.1.0
Loading...
Searching...
No Matches
Public Types | Public Member Functions | List of all members
sf::Sftp::Result Class Reference

SFTP result. More...

`#include <SFML/Network/Sftp.hpp>`

Inheritance diagram for sf::Sftp::Result:

## Public Types

enum class

Value {
Success , Disconnected , Timeout , Refused ,
Error , BannerReceive , BannerSend , InvalidMac ,
AllocationFailure , SocketSend , KeyExchangeFailure , HostKeyInitialization ,
HostKeySign , DecryptError , ProtocolError , PasswordExpired ,
FileError , MethodNone , AuthenticationFailed , PublicKeyUnverified ,
ChannelOutOfOrder , ChannelFailure , ChannelRequestDenied , ChannelUnknown ,
ChannelWindowExceeded , ChannelPacketExceeded , ChannelClosed , ChannelEofSent ,
ScpProtocol , ZlibError , RequestDenied , MethodNotSupported ,
InvalidData , PublicKeyProtocol , BufferTooSmall , BadUse ,
CompressError , OutOfBoundary , AgentProtocol , SocketRecv ,
EncryptError , BadSocket , KnownHosts , ChannelWindowFull ,
KeyFileAuthenticationFailed , EndOfFile , NoSuchFile , PermissionDenied ,
Failure , BadMessage , NoConnection , ConnectionLost ,
OperationUnsupported , InvalidHandle , NoSuchPath , FileAlreadyExists ,
WriteProtect , NoMedia , NoSpaceOnFileSystem , QuotaExceeded ,
UnknownPrincipal , LockConflict , DirectoryNotEmpty , NotADirectory ,
InvalidFilename , LinkLoop , SftpError
}

| Result values. More...

## Public Member Functions

| Result (Value value, std::string message="")
| Constructor.
bool | isOk () const
| Check if the result is a success.
Value | getValue () const
| Get the result value.
const std::string & | getMessage () const
| Get the result message.

## Detailed Description

SFTP result.

Definition at line 61 of file Sftp.hpp.

## Member Enumeration Documentation

## ◆ Value

enum class sf::Sftp::Result::Value

strong

Result values.

Enumerator
Success | Operation completed successfully.
Disconnected | The TCP socket has been disconnected.
Timeout | Operation timed out.
Refused | Connection refused.
Error | Generic error.
BannerReceive | Error during banner receive.
BannerSend | Error during banner send.
InvalidMac | Invalid message authentication code.
AllocationFailure | Allocation failure.
SocketSend | Error sending on socket.
KeyExchangeFailure | Key exchange failed.
HostKeyInitialization | Host key initialization failed.
HostKeySign | Host key signing failed.
DecryptError | Decryption failed.
ProtocolError | SSH protocol error.
PasswordExpired | Password expired.
FileError | File error.
MethodNone | No method found.
AuthenticationFailed | Authentication failed.
PublicKeyUnverified | Public key unverified.
ChannelOutOfOrder | Channel out of order.
ChannelFailure | Channel failure.
ChannelRequestDenied | Channel request denied.
ChannelUnknown | Channel unknown.
ChannelWindowExceeded | Channel window exceeded.
ChannelPacketExceeded | Channel packet exceeded.
ChannelClosed | Channel closed.
ChannelEofSent | Channel EOF sent.
ScpProtocol | SCP protocol error.
ZlibError | Zlib error.
RequestDenied | Request denied.
MethodNotSupported | Method not supported.
InvalidData | Invalid data.
PublicKeyProtocol | Public key protocol error.
BufferTooSmall | Buffer too small.
BadUse | Bad usage.
CompressError | Compression error.
OutOfBoundary | Out of boundary.
AgentProtocol | Agent protocol error.
SocketRecv | Socket receive error.
EncryptError | Encryption failed.
BadSocket | Bad socket.
KnownHosts | Known hosts error.
ChannelWindowFull | Channel window full.
KeyFileAuthenticationFailed | Key file authentication failed.
EndOfFile | End of file.
NoSuchFile | No such file.
PermissionDenied | Permission denied.
Failure | Failure.
BadMessage | Bad message.
NoConnection | No connection.
ConnectionLost | Connection lost.
OperationUnsupported | Operation unsupported.
InvalidHandle | Invalid handle.
NoSuchPath | No such path.
FileAlreadyExists | File already exists.
WriteProtect | Write protect.
NoMedia | No media.
NoSpaceOnFileSystem | No space on filesystem.
QuotaExceeded | Quota exceeded.
UnknownPrincipal | Unknown principal.
LockConflict | Lock conflict.
DirectoryNotEmpty | Directory not empty.
NotADirectory | Not a directory.
InvalidFilename | Invalid filename.
LinkLoop | Link loop.
SftpError | Generic SFTP error.

Definition at line 68 of file Sftp.hpp.

## Constructor & Destructor Documentation

## ◆ Result()

sf::Sftp::Result::Result | ( | Value | value,
|  | std::string | message = "" )

explicit

Constructor.

This constructor is used by the SFTP client to build the result.

Parameters

  value | Result value
  message | Result message

## Member Function Documentation

## ◆ getMessage()

const std::string & sf::Sftp::Result::getMessage | ( |  | ) | const

nodiscard

Get the result message.

Returns
  The result message

## ◆ getValue()

Value sf::Sftp::Result::getValue | ( |  | ) | const

nodiscard

Get the result value.

Returns
  The result value

## ◆ isOk()

bool sf::Sftp::Result::isOk | ( |  | ) | const

nodiscard

Check if the result is a success.

This function is defined for convenience, it is equivalent to testing if the result value is Value::Success.

Returns
  true if the result is Value::Success, false if it is not Value::Success

The documentation for this class was generated from the following file:

- Sftp.hpp