added missing methods for buffered writer ,fix return values for method
call