@Override
    public void close() {
        // get current session
        Neo4JSession session = this.session.get();
        if (session != null) {
            // close session
            session.close();
            // remove session
            this.session.remove();
        }
        // synchronize access to set
        synchronized (closeListeners) {
            // notify consumers
            closeListeners.forEach(consumer -> consumer.accept(this));
        }
    }
@ Override public void close ( ) { Neo4JSession session = this . session . get ( ) ; if ( session != null ) { session . close ( ) ; this . session . remove ( ) ; } synchronized ( closeListeners ) { closeListeners . forEach ( consumer -> consumer . accept ( this ) ) ; } }
{@inheritDoc}