Reading Log from XML without reading whole file
I have an log file in XML format in which the log entry (fixed format) are inserted at irregular interval of time .
so I want to show all the log entry into table view and whenever the new log entry is appended to the file,
it should be appended to the table view also.
I am able to do this by reading the whole XML file after fixed interval of time or whenever the XML file is edited. But the performance is degraded (taking too much time) when too many log entries present in XML file.
Please suggest me is there any way to read only appended log entry in XML file rather than reading whole file.
Remember the position where the file ended last time (line number, for example), and then read from there using seek() functions.