Series: Subject: Topic:
Question: 249 of 249

What is the difference between normal Java object and EJB

Asked by: Interview Candidate | Asked on: Sep 5th, 2005
Showing Answers 1 - 18 of 18 Answers

Answered On : Mar 14th, 2005

Java Object:it's a reusable componetEJB:is reusable and deployable component which can be deployed in any container

Login to rate this answer.

Answered On : Apr 6th, 2005

Java Object: is a reusable component. EJB : is a distributed component used to develop business applications. Container provides runtime environment for EJBs.

Yes  1 User has rated as useful.
Login to rate this answer.

Answered On : Apr 26th, 2005

EJB is an Java object implemented according EJB specification. Deployability is a feature.

Login to rate this answer.

Answered On : May 26th, 2005

Java objects are reusable components which are having variables, methods. EJBs are also reusable components which can be placed at server side, EJBs are distributed component and can be deployed in EJB Container.

Login to rate this answer.
Rangaraajan B

Answered On : Jun 27th, 2005

When we need of abstract class and interface?

Login to rate this answer.
Thangamani Kasi

Answered On : Jul 4th, 2005

Java Object is created by user whereas EJB Object is created by container.

Login to rate this answer.

Answered On : Jul 9th, 2005

EJB is java object which complies to the EJB specification. EJB has some special features to address the problems like, Deployability on verious standardized servers, Transactions, Security, Persistence ..etc and increasing the reusability by externalizing these into deployment configurations

Yes  1 User has rated as useful.
Login to rate this answer.

Answered On : Jul 24th, 2005

Java object: not reusable it canot be used in distributed environment it has special security or system like container  ejb object: reusable used in distributed environment special security provided by ejb container

Login to rate this answer.
J. P. Naidu

Answered On : Jul 28th, 2005

Both are objects no doubt. But the EJB is the having implicit services that are provided by the container, in which it is deployed, as per the EJB spects.

Login to rate this answer.

Answered On : Aug 12th, 2005

Hi, I think everyone needs to brush their knowledge of basics in java and ejb. See a java object is like a live once instance and an ejb object works in a distrubuitable environment and it cab accessed remotely across connections

Login to rate this answer.
vamshidhar ghanpur

Answered On : Aug 27th, 2005

I'll give u best....... Java object is difinitly a reusable code,it needs JVM,in which it runs. Ejb object is also a reusable code,it needs a container where this component is deployed,and managed. container provides run-time environment to Ejb objects. Ejb objects are mean to be distributed over the network remotely.

Login to rate this answer.

Answered On : Aug 29th, 2005

As every thing in JAVA is implemented as objects so EJB is also a JAVA Object which is a distributed object hence can be used across multiple JVMs and of course is reusable.

Login to rate this answer.
Dheeraj Tanwar

Answered On : Sep 5th, 2005

Login to rate this answer.

Answered On : Sep 12th, 2005

An EJB is maintained by application server where as a normal Java Object is not maintained by application server which means the services such as transaction,security,object pooling are not probagated to java object

Login to rate this answer.

Answered On : Oct 20th, 2005

View all answers by ratul_dg

The world can exist without EJBs! But the basic purpose of writing EJBS is to save a programmer the effort of writing middleware services like transaction services, security, network services etc. Thankfully, a server that conforms to J2EE specifications provides these services free of cost! you don't have to write any code for getting these services. All you have to do is specify what service you want in a set of XML files called deployment descriptors. And rest is only about writing the business logic !

Login to rate this answer.

Answered On : Apr 13th, 2006

Interfaces:Have no method bodies or functionality whatsoever; all methods are implicitly abstract. Can be implemented on a class without affecting its ancestry.Can be used as a flag (as is the case with Cloneable and Serializable) to indicate that something is allowed to happen to a class.Cannot declare object attributes, but can implement static final attributesCan emulate attributes only by declaring getter and setter methods, which will require an implementing class to fill them with code.Abstract Classes:Can have both implemented bodies with functionality and abstract methods. The implemented methods become shared code for the classes that extend the abstract class.Can have private methods and attributes, just like an ordinary class.Cannot be instantiated by definition; it must be subclassed in order to utilize its functionality.Both Interfaces and Abstract Classes:Require that a subclass or implementing class write method bodies for each of the methods in the interface or just the methods declared abstract in the abstract ancestor. Can be used to cast objects that implement or subclass from them for the purpose of polymorphism.

Login to rate this answer.

Answered On : Jun 11th, 2008

View all answers by srinivask82

An EJB object is also an java object, but as it follows the EJB Specifications, it can be remotely identified in an Application server. An java object can be deployed in an application server, but cannot be idetified. i.e A java object can be in the classpath of an EJB or web application and can be put in the server and it can even contain business logic. But only EJBs can be identified by the JNDI (Java Naming Directory Interface). While deploying an EJB in an application server, like weblogic, we give a JNDI name to it, in the deployment descriptor and it can be only accessed using that name.

Login to rate this answer.

Answered On : Jun 16th, 2011

View all answers by rebolloomare

EJB is a specification to develop JEE applications.

Login to rate this answer.

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

Related Open Questions



twitter fb Linkedin GPlus RSS


Interview Question

 Ask Interview Question?


Latest Questions

Interview & Career Tips

Get invaluable Interview and Career Tips delivered directly to your inbox. Get your news alert set up today, Once you confirm your Email subscription, you will be able to download Job Inteview Questions Ebook . Please contact me if you there is any issue with the download.