• Post Reply Bookmark Topic Watch Topic
  • New Topic

Compile time vs Run time  RSS feed

 
Piet Snot
Greenhorn
Posts: 18
Firefox Browser IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hey all

I'm currently on a project were we are bugfixing an application. I've run in to a problem with exceptions, this was the situation.

Operatorbean ==> Entitybean

public void delete(OperatorTO to) throws ReferenceStillExistsException {
...
}

OperatorLocal ==> EJBLocalObject
public void delete(OperatorTO to) throws ActiviteitRecordStillExistsException;


At compiletime this doesn't give a problem but at runtime when the methods throws an ReferenceStillExistsException exception I get an EJBException. Is it possible to check at compile time?
 
Jeanne Boyarsky
author & internet detective
Sheriff
Posts: 37253
519
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Piet,
I'm thinking no. How would you know whether the reference exists before you run the code.
 
Piet Snot
Greenhorn
Posts: 18
Firefox Browser IntelliJ IDE Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jeanne

Don't know, what about the J2EE Verifier could it detect these kind of errors?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!