protected void disconnect () { if (_conn != null) { _conn.close(); _conn = null; } }
@Override public void close () { for (Connection c : conns) c.close(); } @Override public Connection once () {
protected void disconnect () { if (_conn != null) { _conn.close(); _conn = null; } }
@Override public void close () { for (Connection c : conns) c.close(); } @Override public Connection once () {
/** @deprecated Call {@link #close} instead. */ @Deprecated public void disconnect () { close(); }
/** @deprecated Call {@link #close} instead. */ @Deprecated public void disconnect () { close(); }
@Override protected void disconnect () { super.disconnect(); if (conn != null) conn.close(); } };
@Override protected void disconnect () { super.disconnect(); if (conn != null) conn.close(); } };
@Override protected void connectionRemoved () { super.connectionRemoved(); if (!hasConnections() && _conn != null) { _conn.close(); _conn = null; } }
@Override public Connection connectNotify (Listener<? super T> listener) { // connect before calling emit; if the listener changes the value in the body of onEmit, it // will expect to be notified of that change; however if onEmit throws a runtime exception, // we need to take care of disconnecting the listener because the returned connection // instance will never reach the caller Connection conn = connect(listener); try { listener.onChange(get(), null); return conn; } catch (RuntimeException re) { conn.close(); throw re; } catch (Error e) { conn.close(); throw e; } }
@Override protected void wasRemoved () { _upconn.close(); updateBars(null); // make sure bars get destroyed in case we don't get added again super.wasRemoved(); }
@Override protected void connectionRemoved () { super.connectionRemoved(); if (!hasConnections() && _conn != null) { _conn.close(); _conn = null; } }
@Override public Connection connectNotify (Listener<? super T> listener) { // connect before calling emit; if the listener changes the value in the body of onEmit, it // will expect to be notified of that change; however if onEmit throws a runtime exception, // we need to take care of disconnecting the listener because the returned connection // instance will never reach the caller Connection conn = connect(listener); try { listener.onChange(get(), null); return conn; } catch (RuntimeException re) { conn.close(); throw re; } catch (Error e) { conn.close(); throw e; } }
oldField._textConnection.close();