• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Ron McLeod
  • Jeanne Boyarsky
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • paul wheaton
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Frits Walraven
Bartenders:
  • Piet Souris
  • Himai Minh

From HFEJB book- pg.108

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In HFEJB Book at page 108, i did'nt understand the concept "Represents a process" ? can anybody explain please !...............
 
Ranch Hand
Posts: 211
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by chandrasekhar muvvala:
In HFEJB Book at page 108, i did'nt understand the concept "Represents a process" ? can anybody explain please !...............



Let me try to explain. Before that do not forget to remember that a Session Bean represents a "process" and an entity bean represents a "thing" or "entity".

That means a session bean will do some job and may use entity beans (data) to convincingly accomplish the job. For instance, you may have a session bean (TellerBean) that performs the operation of a bank teller. Performing the operation of a teller is a process. To do this, the TellerBean needs Account, which can be modelled as an entity bean. In other way, the TellerBean uses Account to perform processes - processes like credit, debit, etc on an Account (our entity bean).

TellerBean (session bean)
- credit()
- debit()

Account (entity bean)
- getAccountNumber()
- getBalance()
- getHolderName()

As you might have observed from the above class model, an entity bean exposes methods that are primarily data-oriented. But the TellerBean is more intelligent in a way it knows how to play with entity beans and perform *real" operations, what are called processes. In this case, it does credit() and debit() processes.

Certain *things* are required to do a process. Model those *things* as entity beans. A process can be modelled as a method (stateless) or a group of co-ordinating methods (stateful) in a Session bean.

Hope it helps.
 
chandrasekhar muvvala
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Very Thanks Keerthi P Selvam
 
chandrasekhar muvvala
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
what about Message Driven Beans???
 
it's a teeny, tiny, wafer thin ad:
Free, earth friendly heat - from the CodeRanch trailboss
https://www.kickstarter.com/projects/paulwheaton/free-heat
reply
    Bookmark Topic Watch Topic
  • New Topic