3i Infotech Papers: Sample Questions 975 - 976 of 1245

Examrace Placement Series prepares you for the toughest placement exams to top companies.

Question number: 975

» Languages » Java

Essay Question▾

Describe in Detail

What is JNI?

Explanation

Understanding of java netive intarface.

Understanding of Java Netive Intarface.

Understanding of java netive intarface.

  • Java Native Interface (JNI) programming framework enables Java code running in a Java Virtual Machine (JVM) to call and be called by native applications (programs specific to a hardware and operating system platform) and libraries written in other languages such as C, C++ and assembly.

  • “JNI” enables use of native codes to overcome the memory management and performance constrains in java.

Motivation for JNI

  • Code reusability:

    Reuse existing/legacy code with java.

  • Performance:

    • Native code used to be 20 times faster than java, when running in interpreted mode

    • JIT compilers make this a moot point.

  • Allow java to tap into low level O/S, H/W routines.

Problems with JNI

  • JNI code is not portable.

  • JNI involves two languages and runtimes.

Question number: 976

» Languages » Java

Essay Question▾

Describe in Detail

What is JFC?

Explanation

Understanding of JFC.

Understanding of JFC.

Understanding of JFC.

  • Java Foundation Classes is a set of graphical user interface (GUI) components for java applications that streamline software and application development.

  • Comparable to the Microsoft foundation class (MFC) library.

  • Extension of the original java abstract windowing toolkit.

  • JFC and swing provide an additional set of program components.

  • A programmer can write programs that are independent of the window system within a particular operating system.

  • Advantage is its components are pluggable and require fewer lines of code.

  • The performance of a GUI created through JFC is predictable.

  • Runs seamlessly across OS’s.