public void close() {synchronized (lock) {if (isOpen()) {buf = null;}}}

public void close ( ) { synchronized ( lock ) { if ( isOpen ( ) ) { buf = null ; } } }
public override void close(){lock (@lock){if (isOpen()){buf = null;}}}
