本文整理匯總了Java中net.jodah.lyra.event.ConnectionListener類的典型用法代碼示例。如果您正苦於以下問題:Java ConnectionListener類的具體用法?Java ConnectionListener怎麽用?Java ConnectionListener使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
ConnectionListener類屬於net.jodah.lyra.event包,在下文中一共展示了ConnectionListener類的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: getConnectionListeners
import net.jodah.lyra.event.ConnectionListener; //導入依賴的package包/類
@Override
public Collection<ConnectionListener> getConnectionListeners() {
return connectionListeners != null ? connectionListeners : parent != null ? parent.getConnectionListeners()
: Collections.<ConnectionListener>emptyList();
}
示例2: withConnectionListeners
import net.jodah.lyra.event.ConnectionListener; //導入依賴的package包/類
@Override
public Config withConnectionListeners(ConnectionListener... connectionListeners) {
this.connectionListeners = Arrays.asList(connectionListeners);
return this;
}
示例3: getConnectionListeners
import net.jodah.lyra.event.ConnectionListener; //導入依賴的package包/類
/**
* Returns the connection's listeners else empty list if none were configured.
*
* @see #withConnectionListeners(ConnectionListener...)
*/
Collection<ConnectionListener> getConnectionListeners();
示例4: withConnectionListeners
import net.jodah.lyra.event.ConnectionListener; //導入依賴的package包/類
/**
* Sets the {@code connectionListeners} to call on connection related events.
*/
ConnectionConfig withConnectionListeners(ConnectionListener... connectionListeners);