For Server-To-Client Pings it automatically responds with a result (pong), in enabled.
It also allows to ping the server (Client-To-Server Pings) or to ping other XMPP entities (Client-to-Client Pings).
463464465466467468469470471472473474475
}); MenuItem pingMenuItem = new MenuItem("Ping"); pingMenuItem.setOnAction(new EventHandler<ActionEvent>() { @Override public void handle(ActionEvent actionEvent) { PingManager pingManager = xmppSession.getExtensionManager(PingManager.class); try { pingManager.pingServer(); } catch (XmppException e) { e.printStackTrace(); } } });