TIBCO Software Core Java Interview Questions Answers

TIBCO Software Most Frequently Asked Core Java Interview Questions Answers

What Is A Compilation Unit?

A compilation unit is a Java source code file.

What Is A Task's Priority And How Is It Used In Scheduling?

A task’s priority is an integer value that identifies the relative order in which it should be executed with respect to other tasks. The scheduler attempts to schedule higher priority tasks before lower priority tasks.

What Value Does Readline() Return When It Has Reached The End Of A File?

The readLine() method returns null when it has reached the end of a file.

Can An Object's Finalize() Method Be Invoked While It Is Reachable?

An object’s finalize() method cannot be invoked by the garbage collector while the object is still reachable. However, an object’s finalize() method may be invoked by other objects.

Does Garbage Collection Guarantee That A Program Will Not Run Out Of Memory?

Garbage collection does not guarantee that a program will not run out of memory. It is possible for programs to use up memory resources faster than they are garbage collected. It is also possible for programs to create objects that are not subject to garbage collection.

Is Sizeof A Keyword?

The sizeof operator is not a keyword.

What State Does A Thread Enter When It Terminates Its Processing?

When a thread terminates its processing, it enters the dead state.

Can A Lock Be Acquired On A Class?

Yes, a lock can be acquired on a class. This lock is acquired on the class’s Class object.
TIBCO Software Most Frequently Asked Core Java Interview Questions Answers
TIBCO Software Most Frequently Asked Core Java Interview Questions Answers

How Are Observer And Observable Used?

Objects that subclass the Observable class maintain a list of observers. When an Observable object is updated it invokes the update() method of each of its observers to notify the observers that it has changed state. The Observer interface is implemented by objects that observe Observable objects.

What Is A Transient Variable?

transient variable is a variable that may not be serialized.

Wha Is The Output From System.out.println("hello"+null); ?

Hellonull.

What Are E And Pi?

E is the base of the natural logarithm and PI is mathematical value pi.

If An Object Is Garbage Collected, Can It Become Reachable Again?

Once an object is garbage collected, it ceases to exist. It can no longer become reachable again.

Can An Exception Be Rethrown?

Yes, an exception can be rethrown.

What Is The Purpose Of The File Class?

The File class is used to create objects that provide access to the files and directories of a local file system.

Is A Class Subclass Of Itself?

No. A class is not a subclass of itself.

What Modifiers May Be Used With An Interface Declaration?

An interface may be declared as public or abstract.

What Classes Of Exceptions May Be Caught By A Catch Clause?

A catch clause can catch any exception that may be assigned to the Throwable type. This includes the Error and Exception types.

What Is The Difference Between The Reader/writer Class Hierarchy And The Inputstream/outputstream Class Hierarchy?

The Reader/Writer class hierarchy is character-oriented, and the InputStream/OutputStream class hierarchy is byte-oriented.

Can An Object Be Garbage Collected While It Is Still Reachable?

A reachable object cannot be garbage collected. Only unreachable objects may be garbage collected.

What Is An Object's Lock And Which Object's Have Locks?

An object’s lock is a mechanism that is used by multiple threads to obtain synchronized access to the object. A thread may execute a synchronized method of an object only after it has acquired the object’s lock. All objects and classes have locks. A class’s lock is acquired on the class’s Class object.

How Are Commas Used In The Intialization And Iteration Parts Of A For Statement?

Commas are used to separate multiple statements within the initialization and iteration parts of a for statement.

What Must A Class Do To Implement An Interface?

It must provide all of the methods in the interface and identify the interface in its implements clause.

What Is The Difference Between Preemptive Scheduling And Time Slicing?

Under preemptive scheduling, the highest priority task executes until it enters the waiting or dead states or a higher priority task comes into existence. Under time slicing, a task executes for a predefined slice of time and then reenters the pool of ready tasks. The scheduler then determines which task should execute next, based on priority and other factors.

What Restrictions Are Placed On The Location Of A Package Statement Within A Source Code File?

A package statement must appear as the first line in a source code file (excluding blank lines and comments).

What Are Wrapped Classes?

Wrapped classes are classes that allow primitive types to be accessed as objects.

Is It Possible To Specify Multiple Jndi Names When Deploying An Ejb?

No. To achieve this you have to deploy your EJB multiple times each specifying a different JNDI name.

What Is Java And Their Uses?

Java is an object-programming language that was designed to be portable across multiple platforms and operating systems. Developed by Sun Microsystems, Java is modeled after the C++ programming language and includes special features that make it ideal for programs on the Internet. Still, you may be wondering why Java is suddenly receiving so much hype, and what possible improvements could have been made to this new language so as to push aside a well-established language such as C++.

First and foremost, Java makes it easy to put interactive graphics and other special effects on a World Wide Web page. As with any programming language, Java lets you write programs. Special Java programs, called applets, execute inside a Web page with a capacity matching that of any traditional program. Furthermore, when you run a Java applet, the remote server, Java transmits the applet to your browser across the Internet. So rather than going out to a computer store to buy software, Java applets let you download applications automatically when you need them.

Post a Comment

Previous Post Next Post