Java : I want to get the line number of the line where output stream has written the data in a file
<p>I am trying to write some data to file using Buffered Writer. I have requirement to create an index file with some time stamp and line number. For this I require the line number where the output stream had written. </p>

<p>Can you please suggest some method to achieve this</p>
