File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes java n c++ Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "java n c++" Watch "java n c++" New topic

java n c++

Saras Thangaraju

Joined: Jan 30, 2004
Posts: 6
hi guys, any help plz
jus wonderin whether java commands or functions can be executed in c++ platform or in c....
are they like mixable?
Jeroen Wenting
Ranch Hand

Joined: Oct 12, 2000
Posts: 5093
no, unless you had an engine to use one as a scripting language for the other.

Marc Peabody
pie sneak

Joined: Feb 05, 2003
Posts: 4727

You can pull off running other languages in Java with native.

A good workman is known by his tools.
Saras Thangaraju

Joined: Jan 30, 2004
Posts: 6
hi guys,
jeroen, what do u mean use one as a scripting lang for the other? how do i do tt/ sorry i am realli new to this...h
Philip Herzer

Joined: Oct 21, 2003
Posts: 21
There are was to mix C++ and Java code. One way I am somewhat familiar with is to use a glue like language like Python. You could write some objects in java, others is c++, c, or whatever language, and use Python to glue them together. Here is a link to an article on how Python does it.
There is also a program called Jython that you could use Pythons interpreter embedded inside of java apps.
[ February 12, 2004: Message edited by: Philip Herzer ]

"Mejor morir de pie que vivir toda la vida arrodillas."<br /> Emilio Zapata
Saras Thangaraju

Joined: Jan 30, 2004
Posts: 6
hi guys thanx for the replies...
i think we can use JNI to do it as well.....jus one confusion
whats a native language?
Anand Ko
Ranch Hand

Joined: Dec 03, 2003
Posts: 79
Code written in other than Java (like C, C++). I mean code written for particular specifications (like Hardware, OS).

Anand<br />SCJP 1.4, SCWCD 1.4, SCEA 5.0(1/3)
Dirk Schreckmann

Joined: Dec 10, 2001
Posts: 7023
Sarasvathi T,
Welcome to JavaRanch!
We ain't got many rules 'round these parts, but we do got one. Please change your display name to comply with The JavaRanch Naming Policy. We'd like to not have single letter last names.
Thanks Pardner! Hope to see you 'round the Ranch!
[ February 17, 2004: Message edited by: Dirk Schreckmann ]

[How To Ask Good Questions] [JavaRanch FAQ Wiki] [JavaRanch Radio]
I agree. Here's the link:
subject: java n c++
It's not a secret anymore!