Re: Netscape 4.05 support Java 1.1??

1998-10-05 Thread Chi-Ming Yang

Thanks Juergen, Mario, Dan, Dimitrios, and John.
Is there a RPM for the latest Netscape? (4.06?)
Why did Red Hat 5.1 give me an old Netscape?
It seems that Netscape is not taking Java seriously. Too bad.


On 2 Oct 1998, Chi-Ming Yang wrote:
> 
> > Hi there, 
> >  I got netscape 4.05 that came with RedHat 5.1. Does it support Java 1.1? I 
>tried the following and got errors:
> >  I have JDK1.1.6 installed. Will that help netscape? 
> > 
> If you had JDK 1.1.6 installed when you got these errors, clearly not.
> 
> You shouldn't use any netscape prior to 4.06: 4.04 has a problem with some
> web sites (mine couldn't tell me about the then new 4.3 Gb removable syquest
> disk, 4,05 has problems with forms and I gather all prior to 4.06 have
> security problems with mail.
> 
> 
> > Thanks
> > 
> > http://www.javasoft.com/applets/jdk/1.1/demo/NervousText/index.html
> > 
> > #Applet exception: error: java.lang.NoSuchMethodError: 
> > java.awt.Component: method addMouseListener 
> > (Ljava/awt/event/MouseListener;) V not found 
> >   at NervousText.init(NervousText.java:63)
> >   at netscape.applet.DeriveAppletFrame.run(DerivedAppletFrame.java)
> >   at java.lang.Thread.run(Thread.java)
> 
> Cheers
> John Summerfield
> http://os2.ami.com.au/os2/ for OS/2 support.
> Configuration, networking, combined IBM ftpsites index.
> 
> 
> 



-
See the original message at http://www.egroups.com/list/java-linux/?start=3846
--
Free e-mail group hosting at http://www.eGroups.com/



Re: Trouble JDK 1.1.6 + HOTJAVA

1998-10-05 Thread Steve Byrne

Michael Sinz writes:
 > On Fri, 02 Oct 1998 18:16:59 +0400, Alexander Davydenko wrote:
 > 
 > >>  > > * You DO NOT need to set JAVA_HOME.  Doing so can be bad for your health
 > >>
 > >> What makes you think HotJava needs JAVA_HOME?  Look at the launching script.  I
 > >> think you need to set JDK_HOME (or JRE_HOME) but not JAVA_HOME, but the script
 > >> is the final arbiter.
 > >
 > >I can't catch a thought... What wrong is to set JAVA_HOME ?
 > >
 > >The starter script is doing the same thing.
 > >
 > >I just make it work simpler, by setting up that. :)
 > 
 > If that is the only Java VM on your system, then it should not cause
 > a problem.  However, setting this can lead to problems if you install
 > a new JDK to try it and forget to unset it.  Or if you have another JVM
 > installed that may happen to use JAVA_HOME

Right.  It's bad practice that can lead to myserious lossages down the road.
You don't need to set it, and in the future it may cause you to lose.

Steve



Java-Linux networking problem < Connection refused >

1998-10-05 Thread Glenn Valenta

I'm new to Java and also not too experienced in Linux so forgive me 
if this is a simple question, but I couldn't find it in the FAQs.

When I try to open a network socket, I get...

   java.net.ConnectException: Connection refused 

at this line...

   socket = new Socket("localhost", 8205); 

I think I may have a permission problem somewhere but I can't even 
open the socket as root. Any Ideas?

Does this sound like a host.allow or host.deny problem?

At the moment, I have written a simple client / server app to simply
get started in java networking. The problem is with anything that opens 
a port. I have compiled sample code from a few books and get the same 
error each time.

I'm using jdk 1.1.6 on Redhat 5.1 with the updated lib.

I have placed the full source on my Webpage at...

http://ouray.cudenver.edu/~gavalent/java/problem1.html

-- 
Glenn Valenta   Engineering @ http://www.coloradostudios.com
[EMAIL PROTECTED]   http://ouray.cudenver.edu/~gavalent/
[EMAIL PROTECTED]   Personal mail
[EMAIL PROTECTED] Work mail



Re: jdk 1.1.6

1998-10-05 Thread Christoph Nadig

Uncle George wrote:

> it really hasn't been about the versions of the 21x64x processors, but rather
> of HTML space on my ISP. ( now its also about bandwidth @ 250 mb/month xfer ) .
> It just takes me about 36 min to do a complete compile ( .c & .java ), less if
> i just redo the .o's.
> such is life for me at the moment
> gat

Are you're diffs against the pristine Sun JDK1.1.6
available? I could compile it for older processors not having the
byte access opcodes (and even a version with Motif) and
make it available.

Cheers, Chris

--
Christoph Nadig| mailto:[EMAIL PROTECTED]
Switching Test Solutions AG| web   :http://www.stest.com
a Wandel & Goltermann Company  | Phone : +41 1 454-6726
Friesenbergstr. 75 | FAX   : +41 1 454-6605
CH-8055 Zurich |





Re: Netscape 4.05 support Java 1.1??

1998-10-05 Thread Java News Collector

At 04:58 AM 10/5/98 -, Chi-Ming Yang wrote:
>Thanks Juergen, Mario, Dan, Dimitrios, and John.
>Is there a RPM for the latest Netscape? (4.06?)
>Why did Red Hat 5.1 give me an old Netscape?
>It seems that Netscape is not taking Java seriously. Too bad.

Netscape is taking Java very seriously.  That statement is most unfair.
Have you noticed MicroSoft's priority on porting to other platforms and
supporting Java?  Its pretty easy to oversimplify the problem from the
outside looking in.

Douglas Toltzman

(who is thankful that Netscape is still in business and supporting the
other platforms)





Re: Dynamic modification of CLASSPATH

1998-10-05 Thread peter . pilgrim

 So I am afraid you must become one with "ClassLoader" (and maybe also 
 the "SecurityManager") class somewhere a long the line(!).


__ Reply Separator _
Subject: Re: Dynamic modification of CLASSPATH
Author:  Michael.Sinz ([EMAIL PROTECTED]) at lon-mime
Date:03/10/98 17:44


On Sat, 3 Oct 1998 12:10:04 -0300 (ADT), Kenny Freeman wrote:
 
>could you not get an instance of runtime and execute 
>'export CLASSPATH=/some/new/classpath' or set env, depending
>what shell your using. Then again, that is not very platfom independant 
>now is it?Well, it would work.
 
Well, it would only work if:
 
1)  THe security manager lets you do that
2)  You start a new JVM from within the context of the call.
 
The #2 thing is critical since the "export ..." will run in a sub-shell 
and will not directly affect the current JVM environment.
 
So, at best you could do:
 
"export CLASSPATH=... ; java startnewjvm"
 
And this is even less likely to be what you need or want and it is 
even less likely to work on many platforms or even the same platform 
with different installations.
 
 
Michael Sinz -- Director of Research & Development, NextBus Inc. 
mailto:[EMAIL PROTECTED] - http://www.nextbus.com 
My place on the web ---> http://www.users.fast.net/~michael_sinz
 



Re: Java-Linux networking problem < Connection refused >

1998-10-05 Thread Michael Sinz

On Mon, 05 Oct 1998 06:21:19 +, Glenn Valenta wrote:

>I'm new to Java and also not too experienced in Linux so forgive me 
>if this is a simple question, but I couldn't find it in the FAQs.
>
>When I try to open a network socket, I get...
>
>   java.net.ConnectException: Connection refused 
>
>at this line...
>
>   socket = new Socket("localhost", 8205); 
>
>I think I may have a permission problem somewhere but I can't even 
>open the socket as root. Any Ideas?
>
>Does this sound like a host.allow or host.deny problem?
>
>At the moment, I have written a simple client / server app to simply
>get started in java networking. The problem is with anything that opens 
>a port. I have compiled sample code from a few books and get the same 
>error each time.
>
>I'm using jdk 1.1.6 on Redhat 5.1 with the updated lib.
>
>I have placed the full source on my Webpage at...
>
>http://ouray.cudenver.edu/~gavalent/java/problem1.html

Well, the problem is nothing to do with security given that you are
running as a full application and are connected via localhost.

The first thing I noticed was that you are not connecting to the same
port that the server is "servicing".  You created the server socket on
port 4747.  You need to connect to that port.  I do not know what 8205 is
since you do not service that port in any of the code you have posted.

Also, just in case of a strange setup - check that you can "ping localhost"
meaning that your system knows that as a name.  (Normally one should
have that setup but I have run into people who either deleted that definiton
from their hosts file or never put it in...)

Michael Sinz -- Director of Research & Development, NextBus Inc.
mailto:[EMAIL PROTECTED] - http://www.nextbus.com
My place on the web ---> http://www.users.fast.net/~michael_sinz




Re: Netscape 4.05 support Java 1.1??

1998-10-05 Thread Dan Kegel

Chi-Ming Yang wrote:
> Is there a RPM for the latest Netscape? (4.06?)
The latest is 4.07, I think.  You're better off
downloading it from Netscape directly; it's pretty
easy to install even without the RPM.  Just install
it to /usr/local/nn4.07/ so you can uninstall it easily...

> Why did Red Hat 5.1 give me an old Netscape?
Because RH5.1 was put together many months ago, and
they only use things that have been stable for a while.

> It seems that Netscape is not taking Java seriously. Too bad.
I can't really complain.  Mozilla can now run using
Japhar as its JVM - it looks like Netscape is pretty serious
about providing a choice of JVM's in NN5.0.
- Dan



Re: Write Once Run Anywhere?

1998-10-05 Thread dan

Just a few points, but no real solution, I'm afraid.

Steve Cohen wrote:

>
> 2) Many wrote about the difficulties with copying files between the two
> systems.  This is not relevant either, since the files actually copied are jar
> files containing the class files.  This should be equivalent to zipping the
> files.

Actually, since a jar file is a binary file (i.e. it uses the 8th bit in each 8-bit
word), you still need to set the transfer mode to binary using FTP.  That said,
copying the file on a disk should work.

> Now here is a detail that may be more relevant:
> There are 19 .java files in the package.  The compilation under linux is making
> them into 19 class files.  When compiling under Win95, 27 class files are
> created.  Two of these are for non-public classes defined in other java files.
> The other six files have names like x$1.class where x.java is one of my
> project files (x.class is also created by the compilation).  I don't know
> what these extra files are for, but the NoClassDefFoundError message is telling
> me that the class it cannot find is x$1.  The extra files do not seem to be
> required under the linux environment, but they appear necessary under the Win95
> environment.

All of the "$1.class" files are actually just anonymous classes.  For instance
if you say something like:

button.addActionListener(new ActionListener() {
public void actionPerformed(ActionEvent e) {
// handle the button press here!!!
System.exit(0);
}
}

you are actually creating an anonymous class, extended from the ActionListener
class.  In order for Java to do the runtime lookup for this class, javac creates an
artificial class name for this anonymous class, as it does not have its own class
name (hence the label 'anonymous').  The name is created as 'x$#', where
'x' is the name of the class that contains the anonymous class, and '#' is the
#'th anonymous class found within the containing class.

As far as moving stuff back and forth between Win95, Linux, Solaris, and NT, I do
this all the time.  I don't have any good suggestions for you, other than to try a
fresh installation of Java on your Windows95 system, and make sure all of the
examples work before you try your own code.  I have had problems with Win95 & Java
when using native code, but these problems were not Java-related (native code
behaves markedly different under Win9x and WinNT, with errant code causing crashes
on Win9x, while running fine under NT).

-dan
[EMAIL PROTECTED]
[EMAIL PROTECTED]



Re: Write Once Run Anywhere? - MYSTERY SOLVED

1998-10-05 Thread dan

Steve Cohen wrote:

>
> MYSTERY SOLVED!
> Jar behaves rather oddly under Win95 and this caused me to become confused.
> When I unjarred the file under Win95, I looked in the Windows Explorer for
> the products.  I immediately noticed under the directory where I did the
> unjarring, a new path mirroring the path under linux where the files were
> created, which contained a bunch of class files.  I ALSO noticed some class
> files in the directory where I did the unjarring, but I assumed that these
> were from a previous compilation, deleted them, and copied in the ones from
> the unix-like path.  However, this set did NOT include any of the inner
> classes, the $1, $2 etc.  So I now had an incomplete set of files and the
> program wouldn't run.
>
> When I just ran the files that jar unzipped, it all worked fine.  Duh.
>
> I am wondering, however, why Jar makes this additional mirror of the
> original directory structure and places in it an incomplete set of files.
>

It turns out that the wildcard expansion under Win95 does not include filenames
containing '$'.  Thus, if you say, "jar cvf fubar.jar *.class", you won't get
any of your anonymous classes.

Fixes:
1)  Explicitly pass all .class files to the jar command line.

2)  Try using a *real* shell.  The dos shell, in a word, sucks.  Try the bash
shell, included in the Cygwin32 utilities, available from cygnus
(http://www.cygnus.com).  It behaves as expected, and makes the WinNT command
line almost as comfortable to me as the Linux command line.

-dan
[EMAIL PROTECTED]
[EMAIL PROTECTED]



Re: Kaffe

1998-10-05 Thread dan

Yes, I agree completely.

Additionally, Jikes also requires a more strict adherence to the Java
standard than javac.  The error messages are much more verbose and
precise, as well, making debugging much easier.  Finally, it has a
command-line that allows you to output gcc-like error messages, allowing
you to integrate jikes into the various Emacs versions (combine jikes with
jacob & XEmacs, and you've got a pretty good IDE).

-dan
[EMAIL PROTECTED]
[EMAIL PROTECTED]

John Summerfield wrote:

>
> The compilers won't make much difference to runtime speed. The fastest
> compiler I've seen is jikes (www.alphaworks.ibm.com) which is about an
> order of magnitude faster than javac and the compiled code of the one
> program I test it on is a little faster.
>
> jikes is now my preferred compiler. IBM has some other nice addons too
> including a GUI debugger written in java.
>
> Cheers
> John Summerfield
> http://os2.ami.com.au/os2/ for OS/2 support.
> Configuration, networking, combined IBM ftpsites index.



Re: jre failed

1998-10-05 Thread dan

When using the '-cp' flag in jdk1.1.x, the classpath specified at
runtime *replaces* the classpath specified in your environment.  Make
sure that you also specify the location of 'classes.zip' and
'swingall.jar' (if you are using swing, that is) in addition to
'testq.jar'.

-dan
[EMAIL PROTECTED]
[EMAIL PROTECTED]

Lukito Edi Nugroho wrote:

> Hi,
>
> I tried to run an application packed in a JAR file:
> $ jre -cp testq.jar QueueTest
> but got the following message:
>
> Unable to initialize threads: cannot find class java/lang/Thread
> Could not create Java VM
>
> I use jdk-1.1.6, RPM version (jdk-sbb-1.1.6-2.1.2glibc).
> CLASSPATH, JAVA_HOME, and JDK_HOME are all
> set appropriately (I think).
> Am I missing something ?
>
> TIA,
> Lukito



Does Java apps has to have .class extension?

1998-10-05 Thread Danny Lu

Hi,
Can anyone tell me does Java applications has to have .class 
in order for it be to executed in Linux?

Dan



Re: Does Java apps has to have .class extension?

1998-10-05 Thread Michael Sinz

On Mon, 5 Oct 1998 19:16:27 -0400 (EDT), Danny Lu wrote:

>Hi,
>   Can anyone tell me does Java applications has to have .class 
>in order for it be to executed in Linux?

???  Java does not directly need .class to run.  In fact, to use the
java binary support in the Linux kernal, you may want to not have .class
as the name of the main() class.

However, standard Java will load classes from .class files.
(Or the equiv in jar/zip files)

This means that when you do:

java Foo

You are telling Java to load Foo.class.

Same for if a class called Bar is used, the JVM will look for it as
Bar.class.  (Well, the default class loader will do that and if it is
already loaded, it will not need to look again)


Michael Sinz -- Director of Research & Development, NextBus Inc.
mailto:[EMAIL PROTECTED] - http://www.nextbus.com
My place on the web ---> http://www.users.fast.net/~michael_sinz




Re: Does Java apps has to have .class extension?

1998-10-05 Thread Danny Lu

But when I try to run a example program I wrote.. and I change
the extension.. I got an error stating "Can't find class Example"

okay at first I tried to compile my example program:
javac Example.java

and I got Example.class... now I change the name of the Example.class to 
Example:
mv Example.class Example

then I made the example executable:
chmod u+x Example

and then I ran it...
./Example

I got the error message saying:
"Can't find class Example"

that's what I was trying to say hehe =)

Dan



Re: Does Java apps has to have .class extension?

1998-10-05 Thread Java News Collector

At 08:19 PM 10/5/98 -0400, Danny Lu wrote:
>But when I try to run a example program I wrote.. and I change
>the extension.. I got an error stating "Can't find class Example"
>
>okay at first I tried to compile my example program:
>   javac Example.java
>
>and I got Example.class... now I change the name of the Example.class to 
>Example:
>   mv Example.class Example

Your requirement seems strange but, have you tried;

ln Example.class Example

and then execute Example ?  I don't know if this will address your problem
since you didn't tell us what you are trying to do.

Another solution may be to create a script that contains "java Example".

>then I made the example executable:
>   chmod u+x Example
>
>and then I ran it...
>   ./Example
>
>I got the error message saying:
>   "Can't find class Example"
>
>that's what I was trying to say hehe =)
>
>Dan

Just a work around if it helps.

Douglas Toltzman



Problem installing JDK

1998-10-05 Thread Bordelon




I am fairly new to the Unix (esp. Linux) 
world.  I am trying to set up a small Linux server for my client in an 
effort to demonstrate its capabilities as a web server.  Unfortunately, I 
am having troubles installing the JDK.  It is probably an error between the 
chair and desk, but if anyone can help me out, please reply.  Here are the 
steps I took:
 
1. On my Windows Machine (I know, I know), I 
downloaded the glibc version of 1.1.6 from the blackdown web site
2. Then I FTPed the file over to the Linux 
box.
3. Finally, I ran "tar xzvf 
jdk1_1_6-v2-glibc_tar.gz"
 
It unpacks a bunch of header files (*.h) under the 
directory:  ./jdk1.1.6/include
Than it returns the message "tar:skipping to next file 
header"
 
That's it.
 
I would really appreciate any help.
 
Thanks,
Michael Bordelon


Re: Problem installing JDK

1998-10-05 Thread Java News Collector

It sounds to me like you FTP'd the file in ASCII mode rather than IMAGE
(binary) mode!  You have a corrupted tar file.

At 08:46 AM 10/5/98 -0500, Bordelon wrote:
>I am fairly new to the Unix (esp. Linux) world.  I am trying to set up a
small Linux server for my client in an effort to demonstrate its
capabilities as a web server.  Unfortunately, I am having troubles
installing the JDK.  It is probably an error between the chair and desk,
but if anyone can help me out, please reply.  Here are the steps I took:
>
>1. On my Windows Machine (I know, I know), I downloaded the glibc version
of 1.1.6 from the blackdown web site
>2. Then I FTPed the file over to the Linux box.
>3. Finally, I ran "tar xzvf jdk1_1_6-v2-glibc_tar.gz"
>
>It unpacks a bunch of header files (*.h) under the directory:
./jdk1.1.6/include
>Than it returns the message "tar:skipping to next file header"
>
>That's it.
>
>I would really appreciate any help.
>
>Thanks,
>Michael Bordelon
>
>Attachment Converted: "P:\USR\MEMO\EMAIL\Problemi.htm"
>



Re: Write Once Run Anywhere? - MYSTERY SOLVED

1998-10-05 Thread mlorton



> It turns out that the wildcard expansion under Win95 does not include filenames
> containing '$'.  Thus, if you say, "jar cvf fubar.jar *.class", you won't get
> any of your anonymous classes.

In general, do not attempt to use wildcard expansion under DOS.
Different *programs* expand them in subly different way.  In
particular, DIR is more conservative than DEL, so you can test a
proposed expansion with DIR then delete *more* files than you
expected.  The day I found that out, I decided to resign from
Microsoft.

M.



Re: Java-Linux networking problem < Connection refused > SOLVED!

1998-10-05 Thread Glenn Valenta

Thanks to all who helped. As much as I thought I had both client and
server on the same port, I didn't. My code said I did, but what I 
compiled and posted on the webpage didn't.  Using telnet and netstat 
gave me my first clue.   Thanks all!


Michael Sinz wrote:
> 
> On Mon, 05 Oct 1998 06:21:19 +, Glenn Valenta wrote:
> 
> >I'm new to Java and also not too experienced in Linux so forgive me
> >if this is a simple question, but I couldn't find it in the FAQs.
> >
> >When I try to open a network socket, I get...
> >
> >   java.net.ConnectException: Connection refused
> >
> >at this line...
> >
> >   socket = new Socket("localhost", 8205);
> >
> >I think I may have a permission problem somewhere but I can't even
> >open the socket as root. Any Ideas?
> >
> >Does this sound like a host.allow or host.deny problem?
> >
> >At the moment, I have written a simple client / server app to simply
> >get started in java networking. The problem is with anything that opens
> >a port. I have compiled sample code from a few books and get the same
> >error each time.
> >
> >I'm using jdk 1.1.6 on Redhat 5.1 with the updated lib.
> >
> >I have placed the full source on my Webpage at...
> >
> >http://ouray.cudenver.edu/~gavalent/java/problem1.html
> 
> Well, the problem is nothing to do with security given that you are
> running as a full application and are connected via localhost.
> 
> The first thing I noticed was that you are not connecting to the same
> port that the server is "servicing".  You created the server socket on
> port 4747.  You need to connect to that port.  I do not know what 8205 is
> since you do not service that port in any of the code you have posted.
> 
> Also, just in case of a strange setup - check that you can "ping localhost"
> meaning that your system knows that as a name.  (Normally one should
> have that setup but I have run into people who either deleted that definiton
> from their hosts file or never put it in...)
> 
> Michael Sinz -- Director of Research & Development, NextBus Inc.
> mailto:[EMAIL PROTECTED] - http://www.nextbus.com
> My place on the web ---> http://www.users.fast.net/~michael_sinz

-- 
Glenn Valenta   Engineering @ http://www.coloradostudios.com
[EMAIL PROTECTED]   http://ouray.cudenver.edu/~gavalent/
[EMAIL PROTECTED]   Personal mail
[EMAIL PROTECTED] Work mail



**CRITICAL MESSAGE**

1998-10-05 Thread Trans World International




If you want tens of thousands of hits to your 
site,WITHOUT advertising, I can show you how to do it,IN 30 SECONDS! 
Click below for that information:
 
http://www.clueclub.com/hits


ask for help

1998-10-05 Thread Jie Yu

Hi, there,

I have a problem with the java.awt.TextArea. It seems that I can't 
setText or append on a TextArea.  Evening using something like this:
TextArea textarea = new TextArea("hello", 20, 30);
hello will not be displayed on the TextArea.

It is highly appreciated if anyone can help me with it. Thank you very much.


Jie Yu


2366 Main Mall  Tel: 604-221-9740(H)
Dept. of Computer Science604-822-8572(O) ext. 3
UBC, Vancouver, V6T 1Z4 ICQ: 16352804
BC, CANADA  http://www.cs.ubc.ca/spider/jyu




Re: Problem installing JDK

1998-10-05 Thread Brad Pepers

> Bordelon wrote:
> 
> I am fairly new to the Unix (esp. Linux) world.  I am trying to set up
> a small Linux server for my client in an effort to demonstrate its
> capabilities as a web server.  Unfortunately, I am having troubles
> installing the JDK.  It is probably an error between the chair and
> desk, but if anyone can help me out, please reply.  Here are the steps
> I took:
> 
> 1. On my Windows Machine (I know, I know), I downloaded the glibc
> version of 1.1.6 from the blackdown web site
> 2. Then I FTPed the file over to the Linux box.
> 3. Finally, I ran "tar xzvf jdk1_1_6-v2-glibc_tar.gz"
> 
> It unpacks a bunch of header files (*.h) under the directory:
> ./jdk1.1.6/include
> Than it returns the message "tar:skipping to next file header"

Sounds like the file got corrupted along the way.  Are you sure the ftp
from Windows to Linux was a binary ftp?  Otherwise it will do
conversions
of CR/LF to CR and things that are a bad idea with binary files!  Just
looking at your filename it seems that Windows has decided that the
extra
periods in the filename are a bad idea and changed them.  Try to either
get the Windows side to send the file without changes to Linux or just
get the file from within Linux.

> That's it.
> 
> I would really appreciate any help.
> 
> Thanks,
> Michael Bordelon

Brad Pepers
[EMAIL PROTECTED]