public boolean startSsl(IoSession session) throws SSLException {
        SslHandler handler = getSslSessionHandler(session);
        boolean started;
        synchronized (handler) {
            if (handler.isOutboundDone()) {
                NextFilter nextFilter = (NextFilter) session
                        .getAttribute(NEXT_FILTER);
                handler.destroy();
                handler.init();
                handler.handshake(nextFilter);
                started = true;
            } else {
                started = false;
            }
        }

        handler.flushScheduledEvents();
        return started;
    }
public boolean startSsl ( IoSession session ) throws SSLException { SslHandler handler = getSslSessionHandler ( session ) ; boolean started ; synchronized ( handler ) { if ( handler . isOutboundDone ( ) ) { NextFilter nextFilter = ( NextFilter ) session . getAttribute ( NEXT_FILTER ) ; handler . destroy ( ) ; handler . init ( ) ; handler . handshake ( nextFilter ) ; started = true ; } else { started = false ; } } handler . flushScheduledEvents ( ) ; return started ; }
(Re)starts SSL session for the specified <tt>session</tt> if not started yet.
Please note that SSL session is automatically started by default, and therefore
you don't need to call this method unless you've used TLS closure.

@return <tt>true</tt> if the SSL session has been started, <tt>false</tt> if already started.
@throws SSLException if failed to start the SSL session