Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / December 2005

Tip: Looking for answers? Try searching our database.

CRC32

Thread view: 
palmis - 21 Dec 2005 08:38 GMT
Hi,
I want create a method that receive as input a byte[] and calculate its
crc32. How can I do?
I have found java.util.zip.CRC32 but I'm using JDK 1.3.
Can you halp me?
Thanks
Roedy Green - 21 Dec 2005 11:00 GMT
>I have found java.util.zip.CRC32 but I'm using JDK 1.3.

I thought it came out in JDK 1.1.

Anyway, how to use it is documented at
http://mindprod.com/jgloss/crc.html

I have the source code for a CRC-16 posted there.  Perhaps you could
generalise it to 32 bit.
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

palmis - 21 Dec 2005 11:13 GMT
I'm unable to see "how you compute a 32-bit CRC using Java' native
method" into mindprod site. I have this message error:
java.lang.ClassNotFoundException:com.mindprod.jdisplay.JDisplay.class
Please can you cut and past the code and send me it ?
Roedy Green - 21 Dec 2005 12:39 GMT
>I'm unable to see "how you compute a 32-bit CRC using Java' native
>method" into mindprod site. I have this message error:
>java.lang.ClassNotFoundException:com.mindprod.jdisplay.JDisplay.class
>Please can you cut and past the code and send me it ?

you likely don't have your java installed correctly. See
http://mindprod.com/jgloss/jre.html#TESTING
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

palmis - 21 Dec 2005 15:03 GMT
It's too complicate!
I have need to resolve my problem before possible.
Thanks
Roedy Green - 21 Dec 2005 15:22 GMT
>It's too complicate!
>I have need to resolve my problem before possible.
>Thanks

If you are JRE/JDK is not installed properly you are not going to get
very far until you sort that out.
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

Roedy Green - 21 Dec 2005 12:28 GMT
On Wed, 21 Dec 2005 11:00:27 GMT, Roedy Green
<my_email_is_posted_on_my_website@munged.invalid> wrote, quoted or
indirectly quoted someone who said :

>I have the source code for a CRC-16 posted there.  Perhaps you could
>generalise it to 32 bit.

I did quick look on the net and found a FORTH and an Pascal version.
If you need a Java version, I will translate it for you into Java and
guarantee it gives the same answers as Sun's CRC32 for $50.
Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

palmis - 21 Dec 2005 15:04 GMT
No thanks.
Luc The Perverse - 21 Dec 2005 21:57 GMT
> No thanks.

LOL - that was not a bad deal.

If only I could get Roedy to make my CR10 RS232 Communication library in
Java for 50$.   I have code in C++ which 'mostly' works.

I wrote a CRC algorithm in C++ once, and could translate it. - <humor> I can
underbid Roedy, but only give 80% guarantee that it will work.   </humor>

--
LTP

:)
palmis - 22 Dec 2005 08:12 GMT
I do not want to buy null. I will find on the net
Roedy Green - 22 Dec 2005 09:36 GMT
>I do not want to buy null. I will find on the net

What is "null"?  Do you mean "custom written"?

Signature

Canadian Mind Products, Roedy Green.
http://mindprod.com Java custom programming, consulting and coaching.

Luc The Perverse - 22 Dec 2005 10:29 GMT
>>I do not want to buy null. I will find on the net
>
> What is "null"?  Do you mean "custom written"?

Null = Zero

If I were attempting to interprit this statement I would translate null as
"anything"

--
LTP

:)
Thomas Weidenfeller - 22 Dec 2005 10:52 GMT
>  What is "null"?  Do you mean "custom written"?

He is probably deeply offended by the unthinkable idea of first fixing
his Java installation and then just using the since 1.2 included CRC32
class. Which happens to be based on a CRC implementation in native code.

/Thomas
Signature

The comp.lang.java.gui FAQ:
ftp://ftp.cs.uu.nl/pub/NEWS.ANSWERS/computer-lang/java/gui/faq
http://www.uni-giessen.de/faq/archiv/computer-lang.java.gui.faq/

palmis - 22 Dec 2005 11:46 GMT
Yes I want say anything.
Excuse me but I don't speak english very well.
I'm Italian.
Andrew Thompson - 22 Dec 2005 14:25 GMT
> Yes I want say anything.
> Excuse me but I don't speak english very well.
> I'm Italian.

It might help to post both English *and* Italian versions.
Many people here will get more from the 'native language' version.

[ Though posting in Italian *only*, would not be very welcome. ]

Signature

Andrew Thompson
physci, javasaver, 1point1c, lensescapes - athompson.info/andrew

Luc The Perverse - 22 Dec 2005 20:02 GMT
> Yes I want say anything.
> Excuse me but I don't speak english very well.
> I'm Italian.

No problem.

You should just download the latest JDK

--
LTP

:)
palmis - 22 Dec 2005 08:12 GMT
I cannot buy null.


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.