當前位置: 首頁>>代碼示例>>Java>>正文


Java HandshakeCompletedListener.handshakeCompleted方法代碼示例

本文整理匯總了Java中javax.net.ssl.HandshakeCompletedListener.handshakeCompleted方法的典型用法代碼示例。如果您正苦於以下問題:Java HandshakeCompletedListener.handshakeCompleted方法的具體用法?Java HandshakeCompletedListener.handshakeCompleted怎麽用?Java HandshakeCompletedListener.handshakeCompleted使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在javax.net.ssl.HandshakeCompletedListener的用法示例。


在下文中一共展示了HandshakeCompletedListener.handshakeCompleted方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: notifyHandshakeCompletedListeners

import javax.net.ssl.HandshakeCompletedListener; //導入方法依賴的package包/類
final void notifyHandshakeCompletedListeners() {
    if (listeners != null && !listeners.isEmpty()) {
        // notify the listeners
        HandshakeCompletedEvent event = new HandshakeCompletedEvent(this, getActiveSession());
        for (HandshakeCompletedListener listener : listeners) {
            try {
                listener.handshakeCompleted(event);
            } catch (RuntimeException e) {
                // The RI runs the handlers in a separate thread,
                // which we do not. But we try to preserve their
                // behavior of logging a problem and not killing
                // the handshaking thread just because a listener
                // has a problem.
                Thread thread = Thread.currentThread();
                thread.getUncaughtExceptionHandler().uncaughtException(thread, e);
            }
        }
    }
}
 
開發者ID:google,項目名稱:conscrypt,代碼行數:20,代碼來源:ConscryptSocketBase.java

示例2: notifyHandshakeCompletedListeners

import javax.net.ssl.HandshakeCompletedListener; //導入方法依賴的package包/類
private void notifyHandshakeCompletedListeners() {
    if (listeners != null && !listeners.isEmpty()) {
        // notify the listeners
        HandshakeCompletedEvent event =
            new HandshakeCompletedEvent(this, sslSession);
        for (HandshakeCompletedListener listener : listeners) {
            try {
                listener.handshakeCompleted(event);
            } catch (RuntimeException e) {
                // The RI runs the handlers in a separate thread,
                // which we do not. But we try to preserve their
                // behavior of logging a problem and not killing
                // the handshaking thread just because a listener
                // has a problem.
                Thread thread = Thread.currentThread();
                thread.getUncaughtExceptionHandler().uncaughtException(thread, e);
            }
        }
    }
}
 
開發者ID:keplersj,項目名稱:In-the-Box-Fork,代碼行數:21,代碼來源:OpenSSLSocketImpl.java

示例3: handshakeCompleted

import javax.net.ssl.HandshakeCompletedListener; //導入方法依賴的package包/類
public void handshakeCompleted() {
	if(listenerList.isEmpty()) {
		return;
	}
	final HandshakeCompletedEvent event = new HandshakeCompletedEvent(this, engine.getSession());
	for(HandshakeCompletedListener listener: listenerList) {
		listener.handshakeCompleted(event);
	}
}
 
開發者ID:HashEngineering,項目名稱:namecoinj,代碼行數:10,代碼來源:SSLEngineSSLSocket.java

示例4: startHandshake

import javax.net.ssl.HandshakeCompletedListener; //導入方法依賴的package包/類
@Override
public void startHandshake() throws IOException {
    Log.d(TAG, "SSLSocket.startHandshake");

    EidTlsClient client = new EidTlsClient(eidService, host, port);
    tlsClientProtocol.connect(client);

    this.session = new EidSSLSession(client);

    for (HandshakeCompletedListener listener : listeners) {
        listener.handshakeCompleted(new HandshakeCompletedEvent(this, this.session));
    }
}
 
開發者ID:egelke,項目名稱:eIDSuite,代碼行數:14,代碼來源:EidSSLSocket.java

示例5: startHandshake

import javax.net.ssl.HandshakeCompletedListener; //導入方法依賴的package包/類
@Override
public void startHandshake() throws IOException {
    for (HandshakeCompletedListener listener : listeners) {
        if (this.listeners != null) {
            listener.handshakeCompleted(null);
        } else {
            throw new Error(
                    "should not be here, at MockHandshake.startHandshake()");
        }
    }
}
 
開發者ID:shannah,項目名稱:cn1,代碼行數:12,代碼來源:StartTlsResponseImplTest.java

示例6: invokeHandshakeListeners

import javax.net.ssl.HandshakeCompletedListener; //導入方法依賴的package包/類
private void invokeHandshakeListeners() {
    final HandshakeCompletedEvent event = new HandshakeCompletedEvent(this, getSession());
    for (HandshakeCompletedListener listener : new ArrayList<>(handshakeCompletedListenerList)) {
        listener.handshakeCompleted(event);
    }
}
 
開發者ID:wildfly,項目名稱:wildfly-openssl,代碼行數:7,代碼來源:OpenSSLSocket.java


注:本文中的javax.net.ssl.HandshakeCompletedListener.handshakeCompleted方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。