I have Mastering Enterprise JavaBeans version 2.0
I thought that all queries made in the home interface had to start with 'findBy'
however, this book has an example called
i am assuming this is implemented by the container different right? can someone explain this to me?
getTotalBankValue() is Home business method, not the findBy method. You find matching 'ejbHome' prefix for these methodsin your bean class.
what is the difference between a findBy method and a non-method that is a sql call? they look to be the same thing.
findBy methods return only remote/local component interfaces. The home business methods return the any RMI/IIOP complaint data types.
The container will give the implementation of the finBy method and there won't be any corresponding method in the bean class. Where as for the other home business methods there has to be a 'ejbHome<homeMethodName>' method.
The home business methods are for when you need to do something with the bunch of records and not one .
hope that helps