• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Are EJBs allowed to retrieve resources (images, texts, properties, etc)

 
Yi Meng
Ranch Hand
Posts: 270
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I read this from http://www.certcities.com/editorial/popquiz/print.asp?EditorialsID=54
EJBs are allowed to retrieve resources (images, texts, properties, etc) that have been bundled within the same enterprise application archive.
is this true? I know that ejbs are not allowed to access local file system. is "retrieve resources" a form of "access local file system" ?
 
Vladas Razas
Ranch Hand
Posts: 385
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"EJBs are allowed to invoke Class.getResource in order to retrieve bundled resources (images, texts, properties, etc)."
It doesn't say that local file system will be used directly.. You can not access files from bean, you're right. But if the container takes care to load some resource for you to use, you can get it. This is "unfair" question, they are asking you things that everybody knows are not part of the exam.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic