Re: [gentoo-user] Java error
Hello! On 14:37 Wed 28 May, Jose Gonzalez Gomez wrote: From the java.security.MessageDigest javadoc: MessageDigest md = MessageDigest.getInstance(SHA); try { md.update(toChapter1); MessageDigest tc1 = md.clone(); byte[] toChapter1Digest = tc1.digest(); md.update(toChapter2); ...etc. } catch (CloneNotSupportedException cnse) { throw new DigestException(couldn't make digest of partial content); } I think you'd be very surprised about all the thing Java can do. Regards Jose Ha ha. I requested not byte array, but STRING! Try to convert this array to string and you will see that this is not so easy :) Best regards, Andrew. -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wednesday 28 May 2003 16:31, Andrew Kirilenko wrote: Ha ha. I requested not byte array, but STRING! Try to convert this array to string and you will see that this is not so easy :) If you're unable to create a hex string representation of a byte array, you're hardly in posession of the competence required to judge the language, wouldn't you say? - --Erik S. Johansen http://www.darkfallonline.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.2 (GNU/Linux) iD8DBQE+1Ls+ds9m9uhAobARAhNpAKCBBPl6hXeBGLfAoSk917hiE5D1MQCfZck/ CnVOHHjJfAFQGBxr2ExYF8E= =ulEv -END PGP SIGNATURE- -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
Hello! On 16:35 Wed 28 May, Erik S. Johansen wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wednesday 28 May 2003 16:31, Andrew Kirilenko wrote: Ha ha. I requested not byte array, but STRING! Try to convert this array to string and you will see that this is not so easy :) If you're unable to create a hex string representation of a byte array, you're hardly in posession of the competence required to judge the language, wouldn't you say? I've donr this, of course. But code is __UGLY__. And, try to do this yourself, and you will see that this is not so easy, believe me. Best regards, Andrew. -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
Andrew, byte[] yourDigest = ...; String yourDigestAsString = new String( yourDigest ); Anyway, discussing about the power of a language based on this question is a nonsense and really off track. Regards Jose Andrew Kirilenko wrote: Hello! On 14:37 Wed 28 May, Jose Gonzalez Gomez wrote: From the java.security.MessageDigest javadoc: MessageDigest md = MessageDigest.getInstance("SHA"); try { md.update(toChapter1); MessageDigest tc1 = md.clone(); byte[] toChapter1Digest = tc1.digest(); md.update(toChapter2); ...etc. } catch (CloneNotSupportedException cnse) { throw new DigestException("couldn't make digest of partial content"); } I think you'd be very surprised about all the thing Java can do. Regards Jose Ha ha. I requested not byte array, but STRING! Try to convert this array to string and you will see that this is not so easy :) Best regards, Andrew. -- [EMAIL PROTECTED] mailing list -- OTN sign Jose Gonzlez Gmez Software Architect +34 635 575 994 [EMAIL PROTECTED] http://www.opentechnet.com
Re: [gentoo-user] Java error
Hello! On 15:48 Wed 28 May, Jose Gonzalez Gomez wrote: Andrew, byte[] yourDigest = ...; String yourDigestAsString = new String( yourDigest ); Anyway, discussing about the power of a language based on this question is a nonsense and really off track. Regards Jose try this code, and you will see, that it won't work. Best regards, Andrew. -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
On Wed, May 28, 2003 at 04:57:06PM +0300, Andrew Kirilenko wrote: Hello! On 15:48 Wed 28 May, Jose Gonzalez Gomez wrote: Andrew, byte[] yourDigest = ...; String yourDigestAsString = new String( yourDigest ); Anyway, discussing about the power of a language based on this question is a nonsense and really off track. Might I recommend a Java mailing list for this discussion? There are many fine ones to choose from. Nathan Meyers [EMAIL PROTECTED] -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
[EMAIL PROTECTED] ~ $ date ; echo ${bryce verdier} Wednesday 28 May 2003 07:05 am I'm new to the whole java language. Anyway, i'm using kdevelop as my ide, and i have this simple java code: There was a thread a few days back, please read it. HINT: pet hate. I hope you enjoy the reading ;-) Norberto pgp0.pgp Description: signature
Re: [gentoo-user] Java error-SOLVED
Thank you Ragu, that solved my problem. Sorry for almost starting a flame war based on language preferences. It was not my intent. But thanks for the reading material! ;) And to Norberto Bensa: Thank you very much for telling me to read up on Pet Hate. Appreciate the advice. However, i felt that writing that email was appropriate because java in gentoo is handled differently than other linux distros( might i even go as far as to say to improved??) via java-config. And if i was to bring this up in another list, say a generic java list, they might not know enough about gentoo to help me out if this was a gentoo related problem. It wasn't, but i didn't know that when the problem occurred. Thanks everyone for helping in your own little ways. bryce On Wednesday 28 May 2003 03:47, Ragu wrote: Bryce, This error occurs, when the classpath is not set properly. You have to set the classpath before running/compiling your java files. export CLASSPATH=$CLASSPATH:current-dir Hope this helps you out. Cheers Ragu - Original Message - From: bryce verdier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, May 28, 2003 3:35 PM Subject: [gentoo-user] Java error I'm new to the whole java language. Anyway, i'm using kdevelop as my ide, and i have this simple java code: class Main{ public static void main( String[] args ){ System.out.println( Hello, world! ); } } and when i try to compile it i get this error: Exception in thread main java.lang.NoClassDefFoundError: Main I know this may not be the right place to talk about this... but any help would be appreciated. thanks, bryce -- [EMAIL PROTECTED] mailing list -- [EMAIL PROTECTED] mailing list -- [EMAIL PROTECTED] mailing list
[gentoo-user] Java error
I'm new to the whole java language. Anyway, i'm using kdevelop as my ide, and i have this simple java code: class Main{ public static void main( String[] args ){ System.out.println( Hello, world! ); } } and when i try to compile it i get this error: Exception in thread main java.lang.NoClassDefFoundError: Main I know this may not be the right place to talk about this... but any help would be appreciated. thanks, bryce -- [EMAIL PROTECTED] mailing list
RE: [gentoo-user] Java error
I'm new to the whole java language. Anyway, i'm using kdevelop as my ide, and i have this simple java code: class Main{ public static void main( String[] args ){ System.out.println( Hello, world! ); } } and when i try to compile it i get this error: Exception in thread main java.lang.NoClassDefFoundError: Main This is indeed the wrong place to discuss basic java programming, but anyway. I suspect you issued: java Main.java rather than: javac Main.java(compile) java Main (run) Gwendolyn. -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
Hello! On 03:05 Wed 28 May, bryce verdier wrote: I'm new to the whole java language. Anyway, i'm using kdevelop as my ide, and i have this simple java code: class Main{ public static void main( String[] args ){ System.out.println( Hello, world! ); } } and when i try to compile it i get this error: Exception in thread main java.lang.NoClassDefFoundError: Main I know this may not be the right place to talk about this... but any help would be appreciated. public class Main Purchace good java book, or better purchace good C++ book - java isn't good language at all. Best regards, Andrew. -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
Bryce, This error occurs, when the classpath is not set properly. You have to set the classpath before running/compiling your java files. export CLASSPATH=$CLASSPATH:current-dir Hope this helps you out. Cheers Ragu - Original Message - From: bryce verdier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, May 28, 2003 3:35 PM Subject: [gentoo-user] Java error I'm new to the whole java language. Anyway, i'm using kdevelop as my ide, and i have this simple java code: class Main{ public static void main( String[] args ){ System.out.println( Hello, world! ); } } and when i try to compile it i get this error: Exception in thread main java.lang.NoClassDefFoundError: Main I know this may not be the right place to talk about this... but any help would be appreciated. thanks, bryce -- [EMAIL PROTECTED] mailing list -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wednesday 28 May 2003 13:17, Andrew Kirilenko wrote: Purchace good java book, or better purchace good C++ book - java isn't good language at all. That's bait if I've ever seen it ;) java *was* a bad language... in it's current state it runs at 70-80% of natively compiled code speed, and has features that definitely makes it the right choice for a lot of tasks. - --Erik S. Johansen http://www.darkfallonline.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.2 (GNU/Linux) iD8DBQE+1JTKds9m9uhAobARAkVZAJ9GLSb5L8Mwy1kh35h+3KqnGg0jvQCdHyVn CplCPleDWUwZc454Mv/zAT4= =+pg5 -END PGP SIGNATURE- -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
Hello! On 13:51 Wed 28 May, Erik S. Johansen wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wednesday 28 May 2003 13:17, Andrew Kirilenko wrote: Purchace good java book, or better purchace good C++ book - java isn't good language at all. That's bait if I've ever seen it ;) java *was* a bad language... in it's current state it runs at 70-80% of natively compiled code speed, and has features that definitely makes it the right choice for a lot of tasks. Can you please paste java code here, which will calc md5 sum? I'd like to get 5d41402abc4b2a76b9719d911017c592 from hello. Best regards, Andrew. -- [EMAIL PROTECTED] mailing list
Re: [gentoo-user] Java error
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Wednesday 28 May 2003 14:01, Andrew Kirilenko wrote: Can you please paste java code here, which will calc md5 sum? I'd like to get 5d41402abc4b2a76b9719d911017c592 from hello. I could mock something up, but it's besides the point actually. Any good programmer chooses the toolset that best suits the task ahead. I've been programming in a multitude of languages over the years, and the one thing I've learned is that there simply isn't any best language Currently I use C++ as a general purpose language, I use borland's delphi or kylix if i want a quick GUI, i use java if i want to build something that need to run as is on a few platforms. At the company where I work (ref. sig), I'm responsible for the networking core code, and as such use C++ for most my work due to strong ties to OS specifics. The people that work with the high-level logic parts use java, avoiding a memory management hell in an extremely complex design. The windows launcher for our product's currently a Delphi thing, because it took 30 mins to get a decent GUI for it. The core number crunching and graphics engine is C++, to squeeze as much performance out of it as possible. My point is, you can't simply claim that a language is bad. It might be bad for your purpose, but that doesn't mean it's a generally bad language. Sure, there might be failed languages that doesn't suit any particular task well, but most of the languages that're being used today are better than others for certain tasks. Now, back to MD5. If i needed MD5 functionality, I'd use OpenSSL's implementation. It's premade, it works. I could ofcourse write a MD5 implementation using shellscript and e.g. awk, but that would definitely be a bad choice of tools. I could write it in java if the main purpose of the project at hand was better suited to java. Or, I could write it in C or C++ if MD5 functionality was the core of the project, and I didn't want to depend on external libraries. But, let's not make this a flame war. You're just as entitled to your opinion as I am to mine, so let's just agree to disagree ;) - --Erik S. Johansen http://www.darkfallonline.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.2 (GNU/Linux) iD8DBQE+1Jsods9m9uhAobARAkNHAJ9KdlPQyxhnC2JggIuoscx8z492KgCdH+ot yZd+/9fcuTvcw1+BmzzbmQU= =UPEe -END PGP SIGNATURE- -- [EMAIL PROTECTED] mailing list
RE: [gentoo-user] Java error
BTW, why are you using outlook express? Don't tell me, you are running it under wine :) I'm running regular Outlook on w2k. Company policy... But, to my defence, I run fetchmail/pine at home. Gwendolyn. -- [EMAIL PROTECTED] mailing list