Subscribe

RSS Feed (xml)

Powered By

Skin Design:
Free Blogger Skins

Powered by Blogger


Thursday 27 November 2008

J2SE Interview Questions and Answers 3

What is CODEBASE ?
Works together with the code attribute in the tag to give a complete specification of where to find the main applet class file: code specifies the name of the file, and codebase specifies the URL of the directory containing the file.

What is comment ?
In a program, explanatory text that is ignored by the compiler. In programs written in the Java programming language, comments are delimited using // or /*...*/.

What is commit ?
The point in a transaction when all updates to any resources involved in the transaction are made permanent.

What is compilation unit ?
The smallest unit of source code that can be compiled. In the current implementation of the Java platform, the compilation unit is a file.

What is compiler ?
A program to translate source code into code to be executed by a computer. The Java compiler translates source code written in the Java programming language into bytecode for the Java virtual machine1. See also interpreter.

What is compositing ?
The process of superimposing one image on another to create a single image.

What is constructor ?
A pseudo-method that creates an object. In the Java programming language, constructors are instance methods with the same name as their class. Constructors are invoked using the new keyword.

What is const ?
A reserved Java keyword not used by current versions of the Java programming language.

What is continue ?
A Java keyword used to resume program execution at the end of the current loop. If followed by a label, continue resumes execution where the label occurs.

What is conversational state ?
The field values of a session bean plus the transitive closure of the objects reachable from the bean's fields. The transitive closure of a bean is defined in terms of the serialization protocol for the Java programming language, that is, the fields that would be stored by serializing the bean instance.

What is CORBA ?
Common Object Request Broker Architecture. A language independent, distributed object model specified by the Object Management Group (OMG).

What is core class ?
A public class (or interface) that is a standard member of the Java Platform. The intent is that the core classes for the Java platform, at minimum, are available on all operating systems where the Java platform runs. A program written entirely in the Java programming language relies only on core classes, meaning it can run anywhere. .

What is core packages ?
The required set of APIs in a Java platform edition which must be supported in any and all compatible implementations.

What is credentials ?
The information describing the security attributes of a principal. Credentials can be acquired only through authentication or delegation.

What is critical section ?
A segment of code in which a thread uses resources (such as certain instance variables) that can be used by other threads, but that must not be used by them at the same time.

What is declaration ?
A statement that establishes an identifier and associates attributes with it, without necessarily reserving its storage (for data) or providing the implementation (for methods). See also definition.

Tuesday 18 November 2008

J2SE Interview Questions with Answers 4

What is default ?
A Java keyword optionally used after all case conditions in a switch statement. If all case conditions are not matched by the value of the switch variable, the default keyword will be executed.

What is definition ?
A declaration that reserves storage (for data) or provides implementation (for methods). See also declaration.

What is delegation ?
An act whereby one principal authorizes another principal to use its identity or privileges with some restrictions.

What is deprecation ?
Refers to a class, interface, constructor, method or field that is no longer recommended, and may cease to exist in a future version.

What is derived from ?
Class X is "derived from" class Y if class X extends class Y. See also subclass, superclass.

What is distributed ?
Running in more than one address space.

What is distributed application ?
An application made up of distinct components running in separate runtime environments, usually on different platforms connected through a network. Typical distributed applications are two-tier (client/server), three-tier (client/middleware/server), and n-tier (client/multiple middleware/multiple servers).

What is do ?
A Java keyword used to declare a loop that will iterate a block of statements. The loop's exit condition can be specified with the while keyword.

What is DOM ?
Document Object Model. A tree of objects with interfaces for traversing the tree and writing an XML version of it, as defined by the W3C specification.

What is double ?
A Java keyword used to define a variable of type double.

What is double precision ?
In the Java programming language specification, describes a floating point number that holds 64 bits of data. See also single precision.

What is DTD ?
Document Type Definition. A description of the structure and properties of a class of XML files.

What is else ?
A Java keyword used to execute a block of statements in the case that the test condition with the if keyword evaluates to false.

What is Embedded Java Technology ?
The availability of Java 2 Platform, Micro Edition technology under a restrictive license agreement that allows a licensee to leverage certain Java technologies to create and deploy a closed-box application that exposes no APIs.

What is encapsulation ?
The localization of knowledge within a module. Because objects encapsulate data and implementation, the user of an object can view the object as a black box that provides services. Instance variables and methods can be added, deleted, or changed, but as long as the services provided by the object remain the same, code that uses the object can continue to use it without being rewritten. See also instance variable, instance method.

What is enum ?
A Java keyword used to declare an enumerated type.

What is enumerated type ?
A type whose legal values consist of a fixed set of constants.

J2SE Interview Questions and Answers 5

What is exception ?
An event during program execution that prevents the program from continuing normally; generally, an error. The Java programming language supports exceptions with the try, catch, and throw keywords. See also exception handler.

What is exception handler ?
A block of code that reacts to a specific type of exception. If the exception is for an error that the program can recover from, the program can resume executing after the exception handler has executed.

What is executable content ?
An application that runs from within an HTML file. See also applet.

What is extends ?
Class X extends class Y to add functionality, either by adding fields or methods to class Y, or by overriding methods of class Y. An interface extends another interface by adding methods. Class X is said to be a subclass of class Y. See also derived from.

What is field ?
A data member of a class. Unless specified otherwise, a field is not static.

What is final ?
A Java keyword. You define an entity once and cannot change it or derive from it later. More specifically: a final class cannot be subclassed, a final method cannot be overridden and a final variable cannot change from its initialized value.

What is finally ?
A Java keyword that executes a block of statements regardless of whether a Java Exception, or run time error, occurred in a block defined previously by the try keyword.

What is float ?
A Java keyword used to define a floating point number variable.

What is for ?
A Java keyword used to declare a loop that reiterates statements. The programmer can specify the statements to be executed, exit conditions, and initialization variables for the loop.

What is FTP ?
File Transfer Protocol. FTP, which is based on TCP/IP, enables the fetching and storing of files between hosts on the Internet. See also TCP/IP.

What is formal parameter list ?
The parameters specified in the definition of a particular method. See also actual parameter list.

What is garbage collection ?
The automatic detection and freeing of memory that is no longer in use. The Java runtime system performs garbage collection so that programmers never explicitly free objects.

What is generic ?
A class, interface, or method that declares one or more type variables. These type variables are known as type parameters. A generic declaration defines a set of parameterized types, one for each possible invocation of the type parameter section. At runtime, all of these parameterized types share the same class, interface, or method.

What is goto ?
This is a reserved Java keyword. However, it is not used by current versions of the Java programming language.

http://interviewquestionsadda.blogspot.com/

What is GUI ?
Graphical User Interface. Refers to the techniques involved in using graphics, along with a keyboard and a mouse, to provide an easy-to-use interface to some program.

What is hexadecimal ?
The numbering system that uses 16 as its base. The marks 0-9 and a-f (or equivalently A-F) represent the digits 0 through 15. In programs written in the Java programming language, hexadecimal numbers must be preceded with 0x. See also octal.

J2SE Interview Questions and Answers 6

What is group ?
A collection of principals within a given security policy domain.

What is hierarchy ?
A classification of relationships in which each item except the top one (known as the root) is a specialized form of the item above it. Each item can have one or more items below it in the hierarchy. In the Java class hierarchy, the root is the Object class.

What is HTML ?
Hypertext Markup Language. This is a file format, based on SGML, for hypertext documents on the Internet. It is very simple and allows for the embedding of images, sounds, video streams, form fields and simple text formatting. References to other objects are embedded using URLs.

What is HTTP ?
Hypertext Transfer Protocol. The Internet protocol, based on TCP/IP, used to fetch hypertext objects from remote hosts. See also TCP/IP.

What is HTTPS ?
Hypertext Transfer Protocol layered over the SSL protocol.

What is IDL ?
Interface Definition Language. APIs written in the Java programming language that provide standards-based interoperability and connectivity with CORBA (Common Object Request Broker Architecture).

What is identifier ?
The name of an item in a program written in the Java programming language.

What is IIOP ?
Internet Inter-ORB Protocol. A protocol used for communication between CORBA object request brokers.

What is if ?
A Java keyword used to conduct a conditional test and execute a block of statements if the test evaluates to true.

What is impersonation ?
An act whereby one entity assumes the identity and privileges of another entity without restrictions and without any indication visible to the recipients of the impersonator's calls that delegation has taken place. Impersonation is a case of simple delegation.

What is implements ?
A Java keyword included in the class declaration to specify any interfaces that are implemented by the current class.

What is import ?
A Java keyword used at the beginning of a source file that can specify classes or entire packages to be referred to later without including their package names in the reference.

What is inheritance ?
The concept of classes automatically containing the variables and methods defined in their super types. See also super class, subclass.

What is instance ?
An object of a particular class. In programs written in the Java programming language, an instance of a class is created using the new operator followed by the class name.

What is instance method ?
Any method that is invoked with respect to an instance of a class. Also called simply a method. See also class method.

What is instance variable ?
Any item of data that is associated with a particular object. Each instance of a class has its own copy of the instance variables defined in the class. Also called a field. See also class variable.

What is instanceof ?
A two-argument Java keyword that tests whether the runtime type of its first argument is assignment compatible with its second argument.