doc: improve doc for .write()/.end()

agree.