Link to home
Start Free TrialLog in
Avatar of TheSilverBullet
TheSilverBullet

asked on

JNI and portability in java

Hi,
I ve got a general question:
If I write a piece of functionality in c++ and make it provided to my java classes via JNI, what is the impact of this crossing on the portability of my java apllication , will it work on linux supposed that the c++ dlls compiled on windows xp or vice versa or not? how to solve this kind of non-portability due to JNI in case there is any?

thanks
ASKER CERTIFIED SOLUTION
Avatar of Ajay-Singh
Ajay-Singh

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of CEHJ
Portability is limited. You can try recompiling under each platform - depends on what you're doing
depends on the portability of your C+ code. You solve it by making your native code portable.
Avatar of TheSilverBullet
TheSilverBullet

ASKER

Hi All,
Thanks for your invaluable contributions. actually I need to get the creation date of a list of files, java supports only getting file modification date, which does not suffice in my case, since my main application is written in java I would need a way to walk around this, is there alternative to c++ that migh work on other operating systems, at least the linux flavours ?

do I need to ask this in another thread or does suffice only to increase the points here?
Well different OSs treat file times in different ways too, so there again you would need to be in one #ifdef or other
you're best asking in a different TA, as its not really a Java question.