java bridge question [message #46522] |
Fri, 25 November 2005 00:24  |
Antonio Santiago
Messages: 201 Registered: February 2004
|
Senior Member |
|
|
Hi group,
I don't know if any of you has had the same problem with the
"idljavabrc" file. The problem is:
(1) If I use the sentence:
JVM Classpath = $CLASSPATH:$HOME/some_java_class_file
The idl (6.1) doesn't find the class.
(2) If I use the sentence with absolute path all is right:
JVM Classpath = $CLASSPATH:/path/to/some_java_class_file
Any ideas??
PD: I'm working on linux with IDL6.1.
--
-----------------------------------------------------
Antonio Santiago P�rez
( email: santiago<<at>>grahi.upc.edu )
( www: http://www.grahi.upc.edu/santiago )
( www: http://asantiago.blogsite.org )
-----------------------------------------------------
GRAHI - Grup de Recerca Aplicada en Hidrometeorologia
Universitat Polit�cnica de Catalunya
-----------------------------------------------------
|
|
|
Re: Java Bridge Question [message #50092 is a reply to message #46522] |
Thu, 14 September 2006 06:25   |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
pskellicker@ameritech.net writes:
> I would suggest verifying what is in the .jar file:
>
>> jar tf TryGeometry.jar
> .. should dump out the class names in the jar file. Verify you have
> a class called Point and not ("fanning.com.Point" or "point" or
> "TryGeometry$Point")
>
> Then verify that there is a public constructor for Point that takes 2
> floats as parameters.
>
>> javap -classpath TryGeometry.jar Point
> Should dump out the public methods of Point.
Sigh... Ok, I'm in that "learn everything at once"
stage.
When I downloaded the JAVA distribution, it
came with the NetBeans IDE, which is what I have been
using to edit, build, and run my JAVA programs. According
to the NetBeans documentation, when you "build" a project,
it creates a "package" of the objects in its "dist" directory.
This is, in fact, where I find the TryGeometry.jar file.
So, I agree I need to examine the contents of this file.
But I don't know how to access the "command line" where
these commands are to be run. I've tried the Windows
command line, but these commands are not recognized
as valid commands.
There is a disconnect, obviously, between the book I am
using to learn JAVA and the NetBeans IDE. (Not to mention
errors in the book, which I am learning to recognize, but
which nevertheless slow me down.) The book assumes a
command line, too, but doesn't mention how to install
it. (If that is what one does with it.) It does
suggest the JDK as a way to access these commands,
and I certainly have that, but don't have the foggiest
idea what to do with it or how to send a command to it.
I could probably spend 7-8 hours trying to figure this
out and become an expert in the damn thing in the process,
or maybe some kind soul can give me a clue. :-)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Java Bridge Question [message #50093 is a reply to message #46522] |
Thu, 14 September 2006 05:38   |
Nigel Wade
Messages: 286 Registered: March 1998
|
Senior Member |
|
|
pskellicker@ameritech.net wrote:
> I would suggest verifying what is in the .jar file:
>
>> jar tf TryGeometry.jar
> .. should dump out the class names in the jar file. Verify you have
> a class called Point and not ("fanning.com.Point" or "point" or
> "TryGeometry$Point")
>
> Then verify that there is a public constructor for Point that takes 2
> floats as parameters.
>
>> javap -classpath TryGeometry.jar Point
> Should dump out the public methods of Point.
>
If the constructor was invalid/missing the error would be:
% Constructor Point::Point(float,float) not found
I would agree that you need to look at the structure of the jar. Did you include
any paths in the jar? i.e. did you create the jar from the directory containing
the class files and specify them as *.class, so that there is no preceding
path? Java is very fussy about paths and packages, and the path must match the
package declaration exactly.
jar tf TryGeometry.jar
should list at least:
META-INF/
META-INF/MANIFEST.MF
Point.class
--
Nigel Wade, System Administrator, Space Plasma Physics Group,
University of Leicester, Leicester, LE1 7RH, UK
E-mail : nmw@ion.le.ac.uk
Phone : +44 (0)116 2523548, Fax : +44 (0)116 2523555
|
|
|
|
|
|
Re: Java Bridge Question [message #50181 is a reply to message #46522] |
Thu, 14 September 2006 12:07  |
news.qwest.net
Messages: 137 Registered: September 2005
|
Senior Member |
|
|
"David Fanning" <davidf@dfanning.com> wrote in message
news:MPG.1f7320e65f72c019989cc1@news.frii.com...
> Here is my basic problem:
>
> "By collaborating and exploiting core integration
> technology, tool producers can leverage platform
> reuse and concentrate on core competencies to
> create new development technology."
>
> I don't have the foggiest idea what the hell this means! :-(
Basically, a focus on core competencies presents challenges in
the context of strategic decision-making oriented to market
growth vectors.
Similarly, developing operational and conceptual learning means that
management must concentrate on the operational imperative of increasing the
visibility of key business metrics.
I hope that clears it up!
Cheers,
bob
|
|
|
Re: Java Bridge Question [message #50183 is a reply to message #46522] |
Thu, 14 September 2006 10:37  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Mike Wallace writes:
> Don't knock it just yet. The plug-in capability is one of Eclipse's
> strongest features. They are actually one of the few products that
> handled plug-ins/extensibility correctly.
Alright, I admit it, it's pretty cool. If you want me
in the next couple of months I'll be over at comp.lang.java,
hanging out, learning JAVA.
Cheers,
David
P.S. Who said there wasn't life after IDL!?
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Java Bridge Question [message #50184 is a reply to message #46522] |
Thu, 14 September 2006 09:34  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Mike Wallace writes:
> Don't knock it just yet. The plug-in capability is one of Eclipse's
> strongest features. They are actually one of the few products that
> handled plug-ins/extensibility correctly.
Oh, I'm not knocking it yet. (Although I do wish that
whoever is writing their technical documentation would
try to follow his own directions once.) I was just thinking
that the description of the product reminded me of another
piece of software I use frequently. In any case, I'm always
in favor of humor in technical documentation. It's the only
way to get through it, usually. :-)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Java Bridge Question [message #50185 is a reply to message #46522] |
Thu, 14 September 2006 09:21  |
Mike Wallace
Messages: 25 Registered: May 2006
|
Junior Member |
|
|
> Eclipse installed!! First line in the Overview:
>
> "Eclipse is a kind of universal tool platform -
> an open extensible IDE for anything and nothing
> in particular."
>
> Oh, oh. :-(
Don't knock it just yet. The plug-in capability is one of Eclipse's
strongest features. They are actually one of the few products that
handled plug-ins/extensibility correctly.
-Mike
|
|
|
Re: Java Bridge Question [message #50186 is a reply to message #46522] |
Thu, 14 September 2006 08:59  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Folks,
Eclipse installed!! First line in the Overview:
"Eclipse is a kind of universal tool platform -
an open extensible IDE for anything and nothing
in particular."
Oh, oh. :-(
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Java Bridge Question [message #50187 is a reply to message #46522] |
Thu, 14 September 2006 08:37  |
Maarten[1]
Messages: 176 Registered: November 2005
|
Senior Member |
|
|
David Fanning wrote:
> Here is my basic problem:
>
> "By collaborating and exploiting core integration
> technology, tool producers can leverage platform
> reuse and concentrate on core competencies to
> create new development technology."
>
> I don't have the foggiest idea what the hell this means! :-(
I'd file it under "Management bullshit", and just try to use Eclipse. I
*think* that that MBS piece is meant to otehr developers who might
consider using Eclipse as a basis for their development environment
(i.e. someone at ITTVIS is trying to figure out what that really
means).
Maarten
|
|
|
Re: Java Bridge Question [message #50188 is a reply to message #46522] |
Thu, 14 September 2006 08:19  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
David Fanning writes:
> Well, if you believe rumours, we are ALL going to be
> using this soon. Guess I better go download it and start
> getting used to it...You available this afternoon? I'll
> probably have questions. :-)
Here is my basic problem:
"By collaborating and exploiting core integration
technology, tool producers can leverage platform
reuse and concentrate on core competencies to
create new development technology."
I don't have the foggiest idea what the hell this means! :-(
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Java Bridge Question [message #50189 is a reply to message #46522] |
Thu, 14 September 2006 08:13  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Mike Wallace writes:
> The tryGeometry directory in your jar file should correspond to the
> package declaration in your java files. I'm not familiar with NetBeans,
> but it may have automatically added the package line for you when you
> created a new Java file. By convention package names in Java begin with
> a lowercase letter so the IDE may have lowercased the package name
> without you noticing.
It appears to have done just this. The odd thing though, is
that the name is spelled differently just about *everywhere*!
When I look in the Projects window, under "Source Packages" it
is spelled "trygeometry". Go figure.
> Since we're already on the topic, I'd like to take this moment to give a
> plug for Eclipse -- the best Java IDE out there. :-)
Well, if you believe rumours, we are ALL going to be
using this soon. Guess I better go download it and start
getting used to it...You available this afternoon? I'll
probably have questions. :-)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|
Re: Java Bridge Question [message #50190 is a reply to message #46522] |
Thu, 14 September 2006 08:01  |
Mike Wallace
Messages: 25 Registered: May 2006
|
Junior Member |
|
|
> OK, I added the JDK to my PATH and the commands now work
> from the command window. When I examine the contents of
> my TryGeometry jar file, I get this:
>
> tryGeometry/
> tryGeometry/Line.class
> tryGeometry/Main.class
> tryGeometry/Point.class
>
> I don't know WHY the tryGeometry here starts with a lowercase
> t instead of the UPPERCASE T I've used every other damn place,
> but that apparently is the problem! Now I can successfully
> create my object in IDL!
The tryGeometry directory in your jar file should correspond to the
package declaration in your java files. I'm not familiar with NetBeans,
but it may have automatically added the package line for you when you
created a new Java file. By convention package names in Java begin with
a lowercase letter so the IDE may have lowercased the package name
without you noticing.
Since we're already on the topic, I'd like to take this moment to give a
plug for Eclipse -- the best Java IDE out there. :-)
-Mike
|
|
|
Re: Java Bridge Question [message #50191 is a reply to message #50092] |
Thu, 14 September 2006 06:50  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
David Fanning writes:
> So, I agree I need to examine the contents of this file.
> But I don't know how to access the "command line" where
> these commands are to be run. I've tried the Windows
> command line, but these commands are not recognized
> as valid commands.
OK, I added the JDK to my PATH and the commands now work
from the command window. When I examine the contents of
my TryGeometry jar file, I get this:
tryGeometry/
tryGeometry/Line.class
tryGeometry/Main.class
tryGeometry/Point.class
I don't know WHY the tryGeometry here starts with a lowercase
t instead of the UPPERCASE T I've used every other damn place,
but that apparently is the problem! Now I can successfully
create my object in IDL!
IDL> obj = obj_new("IDLJAVAOBJECT$TRYGEOMETRY_POINT", $
"tryGeometry.Point", 0.25, 0.25)
Sigh... What a lot of work. Thanks, everyone, for your help.
Now, on to the next BIG thing... :-)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Sepore ma de ni thui. ("Perhaps thou speakest truth.")
|
|
|