You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by ba...@generationjava.com on 2002/02/23 05:17:51 UTC

ByteArrays.java

I have a class I'm about to add to Lang which turns byte[] into
hexadecimal String and viceversa. It builds on simple java.lang stuff, so
I've always placed it in lang, but as I was committing I realised it could
be viewed as a codec.

Any views on whether it's central enough to be lang, or should go in
codec?

Bay


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: ByteArrays.java

Posted by Daniel Rall <dl...@finemaltcoding.com>.
<ba...@generationjava.com> writes:

> I have a class I'm about to add to Lang which turns byte[] into
> hexadecimal String and viceversa. It builds on simple java.lang stuff, so
> I've always placed it in lang, but as I was committing I realised it could
> be viewed as a codec.
>
> Any views on whether it's central enough to be lang, or should go in
> codec?

Definitely codec (regardless of whether it's merged with HexDump).

- Dan

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: ByteArrays.java

Posted by Scott Sanders <sa...@apache.org>.
So ByteArrays and HexDump could move together, or do you see them as independent?

Scott

On Sat, Feb 23, 2002 at 04:05:12AM -0500, bayard@generationjava.com wrote:
> 
> They are pretty similar I think.
> 
> HexDump seems to do more than just convert a byte[] to a String, but that
> could just be me not taking the time to delve into the bit-shifting going
> on, and not being the type of coder who uses bit-shifting a lot. It's tied
> to an OutputStream, and it doesn't take an InputStream to a byte[].
> 
> Bay
> 
> On Fri, 22 Feb 2002, Scott Sanders wrote:
> 
> > How is this different from the HexDump class that was in util (I think
> > it is in codec now)?
> >
> > Scott
> >
> > On Fri, Feb 22, 2002 at 11:17:51PM -0500, bayard@generationjava.com wrote:
> > > I have a class I'm about to add to Lang which turns byte[] into
> > > hexadecimal String and viceversa. It builds on simple java.lang stuff, so
> > > I've always placed it in lang, but as I was committing I realised it could
> > > be viewed as a codec.
> > >
> > > Any views on whether it's central enough to be lang, or should go in
> > > codec?
> > >
> > > Bay
> > >
> > >
> > > --
> > > To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> > > For additional commands, e-mail: <ma...@jakarta.apache.org>
> > >
> >
> > --
> > Scott Sanders - sanders@apache.org
> >
> > --
> > To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> > For additional commands, e-mail: <ma...@jakarta.apache.org>
> >
> >
> 
> 
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
> 

-- 
Scott Sanders - sanders@apache.org

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: ByteArrays.java

Posted by ba...@generationjava.com.
They are pretty similar I think.

HexDump seems to do more than just convert a byte[] to a String, but that
could just be me not taking the time to delve into the bit-shifting going
on, and not being the type of coder who uses bit-shifting a lot. It's tied
to an OutputStream, and it doesn't take an InputStream to a byte[].

Bay

On Fri, 22 Feb 2002, Scott Sanders wrote:

> How is this different from the HexDump class that was in util (I think
> it is in codec now)?
>
> Scott
>
> On Fri, Feb 22, 2002 at 11:17:51PM -0500, bayard@generationjava.com wrote:
> > I have a class I'm about to add to Lang which turns byte[] into
> > hexadecimal String and viceversa. It builds on simple java.lang stuff, so
> > I've always placed it in lang, but as I was committing I realised it could
> > be viewed as a codec.
> >
> > Any views on whether it's central enough to be lang, or should go in
> > codec?
> >
> > Bay
> >
> >
> > --
> > To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> > For additional commands, e-mail: <ma...@jakarta.apache.org>
> >
>
> --
> Scott Sanders - sanders@apache.org
>
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
>
>



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: ByteArrays.java

Posted by Scott Sanders <sa...@apache.org>.
How is this different from the HexDump class that was in util (I think it is in codec now)?

Scott

On Fri, Feb 22, 2002 at 11:17:51PM -0500, bayard@generationjava.com wrote:
> I have a class I'm about to add to Lang which turns byte[] into
> hexadecimal String and viceversa. It builds on simple java.lang stuff, so
> I've always placed it in lang, but as I was committing I realised it could
> be viewed as a codec.
> 
> Any views on whether it's central enough to be lang, or should go in
> codec?
> 
> Bay
> 
> 
> --
> To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
> For additional commands, e-mail: <ma...@jakarta.apache.org>
> 

-- 
Scott Sanders - sanders@apache.org

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>