Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > systems level programming in Java

Reply
Thread Tools

systems level programming in Java

 
 
jrefactors@hotmail.com
Guest
Posts: n/a
 
      01-08-2005
Sometimes I heard people saying systems level programming in Java. And
I have seen some job posting also say that. Systems level programming
usually are done in C/C++. Can Java do that? Any examples?
please advise. thanks!!

 
Reply With Quote
 
 
 
 
Sudsy
Guest
Posts: n/a
 
      01-08-2005
http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:
> Sometimes I heard people saying systems level programming in Java. And
> I have seen some job posting also say that. Systems level programming
> usually are done in C/C++. Can Java do that? Any examples?
> please advise. thanks!!


An interesting question. One of the major attractions of a language like
Java is that it is platform agnostic; system programming is typically
platform specific. A device driver I write in C for HP-UX 8.0 is not
likely to run on AIX 5.0. Heck, a device driver for Linux kernel 2.4 is
not guaranteed to run on a 2.6 kernel!
You use the appropriate tools for the jobs at the appropriate layers.
Some people don't see the need for entity EJBs when they can implement
similar functionality in stateless session EJBs with "generic" JDBC
calls. Trust me, it doesn't always work that way...
I would suggest that you not consider use of Java to implement low-
level functionality. If you're willing to write to the JNI layer then
you're going to be bound to the platform at that juncture.
Peruse the javadocs to obtain confirmation that the Java framework
functions at a much higher layer than the "bits-and-bytes" details.
Why do you think that Sun provides methods such as
java.lang.System.getProperty( String s ) where s can be "file.separator"
or "path.separator"?
Answer: platform agnosticism.
And let's not even get into the use of the HAL (Hardware Abstraction
Layer) by M$...
 
Reply With Quote
 
 
 
 
jrefactors@hotmail.com
Guest
Posts: n/a
 
      01-09-2005

Sudsy wrote:

>A device driver I write in C for HP-UX 8.0 is not
>likely to run on AIX 5.0. Heck, a device driver for Linux kernel 2.4

is
>not guaranteed to run on a 2.6 kernel!


But the source code is unchange for different platform, but we need to
compile the code on different platform for different binary file.
correct?

 
Reply With Quote
 
Sudsy
Guest
Posts: n/a
 
      01-09-2005
(E-Mail Removed) wrote:
<snip>
> But the source code is unchange for different platform, but we need to
> compile the code on different platform for different binary file.
> correct?


Only if you go to a great deal of effort and use a lot of #ifdefs.
That's where Java has a distinct advantage. The downside is that you
can't get at the lower layers of the platform unless you're willing
to use JNI. At that point your code is no longer platform agnostic,
one of the reasons for going to Java in the first place!
 
Reply With Quote
 
jrefactors@hotmail.com
Guest
Posts: n/a
 
      01-10-2005
so you mean systems program usually are platform specific, it may have
different sets of source code for different platform? What is JNI?

 
Reply With Quote
 
Sudsy
Guest
Posts: n/a
 
      01-10-2005
(E-Mail Removed) wrote:
> so you mean systems program usually are platform specific, it may have
> different sets of source code for different platform? What is JNI?


Absolutely! Different models of systems, within the same line, from the
same manufacturer might require different approaches. Seemingly simple
things like ISA vs PCI bus can have a profound impact on the required
code. Things get even gnarlier when you're crossing wider gaps.
Ever try to port software running on Solaris on an UltraSPARC 5 to a
Linux box built upon a wintel platform? Problems galore!
JNI is the Java Native Interface. It lets you integrate platform-
specific code (typically C/C++) with Java. But then you lose
portability...
Which is why I suggested from the outset that Java was not the right
language for system programming efforts; it's strengths lie in
completely different directions.
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
"Low-level vs High-level Programming" and a lot more... Scorpiion VHDL 1 12-25-2008 04:27 PM
Voip PBX,Private Phone Systems,PBX Telephone Systems, Business Phone Systems broadbandera@gmail.com UK VOIP 9 07-24-2006 03:44 PM
c is a low-level language or neither low level nor high level language pabbu C Programming 8 11-07-2005 03:05 PM
systems programming versus application programming Matt Java 35 07-22-2004 08:10 AM
java as a systems administration/systems programming language? Mike Java 2 06-17-2004 03:33 PM



Advertisments