disconnectable

Returns true if this is a connection state for which disconnecting is valid. Generally, applications should be aware of the life cycle of their sockets, so checking the state of a connection is unnecessary (and a code smell). However, unconditionally disconnecting some connected sockets can be useful when it needs to occur "out-of-bound" (not tied to the application normal life cycle), such as in response to a signal.

bool
disconnectable

Meta