Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.java.programmer > #22502

Re: offsets in a FileChannel ...

Path csiph.com!usenet.pasdenom.info!aioe.org!.POSTED!not-for-mail
From Roedy Green <see_website@mindprod.com.invalid>
Newsgroups comp.lang.java.programmer
Subject Re: offsets in a FileChannel ...
Date Mon, 25 Feb 2013 04:09:06 -0800
Organization Canadian Mind Products
Lines 19
Message-ID <2rkmi8hjbqisimmd7bcsalbqjs6f8l9ngp@4ax.com> (permalink)
References <kgain5$4pl$1@speranza.aioe.org> <aos2kgFqnonU1@mid.individual.net>
Reply-To Roedy Green <see_website@mindprod.com.invalid>
NNTP-Posting-Host K2Qzzs3EAqXk5RLzfhxcSw.user.speranza.aioe.org
Mime-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Transfer-Encoding 7bit
X-Complaints-To abuse@aioe.org
X-Notice Filtered by postfilter v. 0.8.2
X-Newsreader Forte Agent 6.00/32.1186
Xref csiph.com comp.lang.java.programmer:22502

Show key headers only | View raw


On Sat, 23 Feb 2013 15:39:08 +0100, Robert Klemme
<shortcutter@googlemail.com> wrote, quoted or indirectly quoted
someone who said :

>UTF8 is not an encoding with a fixed width.  

You could use UTF-16.  Then you could interconvert 8 byte and char
offsets. with a simple shift.

You could build a table of interesting byte offsets when you construct
the stream.  

You could embed binary counts in bytes/chars at the head of phrases.
You build and take the stream apart with ByteArrayStreams.
-- 
Roedy Green Canadian Mind Products http://mindprod.com
One thing I love about having a website, is that when I complain about
something, I only have to do it once. It saves me endless hours of 
grumbling.

Back to comp.lang.java.programmer | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

offsets in a FileChannel ... qwertmonkey@syberianoutpost.ru - 2013-02-23 14:11 +0000
  Re: offsets in a FileChannel ... Robert Klemme <shortcutter@googlemail.com> - 2013-02-23 15:39 +0100
    Re: offsets in a FileChannel ... Roedy Green <see_website@mindprod.com.invalid> - 2013-02-25 04:09 -0800
      Re: offsets in a FileChannel ... Robert Klemme <shortcutter@googlemail.com> - 2013-02-25 21:50 +0100
        Re: offsets in a FileChannel ... Roedy Green <see_website@mindprod.com.invalid> - 2013-02-26 08:05 -0800

csiph-web