P
Patrick Gundlach
Dear ruby hackers,
I'd wonder if there is a simple method in searching backward in
files. I want to read a pdf file, so I have to do the following:
1) goto the end of file (pdffile.seek(0,IO::SEEK_END))
2) search backward for the string "%%EOF" within the last 1024 bytes
3) search backward for "startxref"
4) read the next bytes,.....
Do I have to write my own seach backward routine or is there some
functionality for it?
Best regards,
Patrick
I'd wonder if there is a simple method in searching backward in
files. I want to read a pdf file, so I have to do the following:
1) goto the end of file (pdffile.seek(0,IO::SEEK_END))
2) search backward for the string "%%EOF" within the last 1024 bytes
3) search backward for "startxref"
4) read the next bytes,.....
Do I have to write my own seach backward routine or is there some
functionality for it?
Best regards,
Patrick