[prev in list] [next in list] [prev in thread] [next in thread]
List: racket-dev
Subject: [racket-dev] random-access file reading
From: a.rottmann () gmx ! at (Andreas Rottmann)
Date: 2010-09-28 22:04:20
Message-ID: 87lj6lcyor.fsf () delenn ! lan
[Download RAW message or body]
John Clements <clements at brinckerhoff.org> writes:
> I want to read a chunk from the middle of a 50-megabyte file. As far
> as I can see, there are no random-access file primitives currently in
> DrRacket. Also, I don't see a "skip-bytes", so it looks like I should
> be allocating a junk buffer and then repeatedly calling read-bytes to
> read the skipped portion into the junk buffer.
>
> Tell me if there's a simpler way to do this; doc pointers always appreciated.
>
http://docs.racket-lang.org/reference/port-buffers.html?q=binary-input-p#%28def._%28%28quote._~23~25kernel%29._file-position%29%29
I think this should do the job.
Cheers, Rotty
--
Andreas Rottmann -- <http://rotty.yi.org/>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic