Class ListenFailedAlert
java.lang.Object
com.frostwire.jlibtorrent.alerts.AbstractAlert<listen_failed_alert>
com.frostwire.jlibtorrent.alerts.ListenFailedAlert
- All Implemented Interfaces:
Alert<listen_failed_alert>
This alert is generated when none of the ports, given in the port range, to
session can be opened for listening. The
listenInterface() member is the
interface and port that failed, error() is the error code describing
the failure.
In the case an endpoint was created before generating the alert, it is represented by ``address`` and ``port``. The combinations of socket type and operation in which such address and port are not valid are: accept - i2p accept - socks5 enum_if - tcp
libtorrent may sometimes try to listen on port 0, if all other ports failed.
Port 0 asks the operating system to pick a port that's free). If that fails
you may see a ListenFailedAlert with port 0 even if you didn't ask to
listen on it.
-
Field Summary
Fields inherited from class com.frostwire.jlibtorrent.alerts.AbstractAlert
alertFields inherited from interface com.frostwire.jlibtorrent.alerts.Alert
ALL_CATEGORIES, BLOCK_PROGRESS_NOTIFICATION, CONNECT_NOTIFICATION, DHT_LOG_NOTIFICATION, DHT_NOTIFICATION, DHT_OPERATION_NOTIFICATION, ERROR_NOTIFICATION, FILE_PROGRESS_NOTIFICATION, INCOMING_REQUEST_NOTIFICATION, IP_BLOCK_NOTIFICATION, PEER_LOG_NOTIFICATION, PEER_NOTIFICATION, PERFORMANCE_WARNING, PICKER_LOG_NOTIFICATION, PIECE_PROGRESS_NOTIFICATION, PORT_MAPPING_LOG_NOTIFICATION, PORT_MAPPING_NOTIFICATION, SESSION_LOG_NOTIFICATION, STATUS_NOTIFICATION, STORAGE_NOTIFICATION, TORRENT_LOG_NOTIFICATION, TRACKER_NOTIFICATION, UPLOAD_NOTIFICATION -
Method Summary
Modifier and TypeMethodDescriptionaddress()The address libtorrent attempted to listen on.error()The error the system returned.The interface libtorrent attempted to listen on that failed.The specific low level operation that failed.intport()The port libtorrent attempted to listen on see alert's documentation for validity of this value.The type of listen socket this alert refers to.
-
Method Details
-
listenInterface
The interface libtorrent attempted to listen on that failed.- Returns:
- the listen interface (as string).
-
error
-
operation
-
socketType
The type of listen socket this alert refers to.- Returns:
- the socket type.
-
address
The address libtorrent attempted to listen on. See alert's documentation for validity of this value.- Returns:
- the address attempted to listen on.
-
port
public int port()The port libtorrent attempted to listen on see alert's documentation for validity of this value.- Returns:
- the port.
-