File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Other Application Frameworks and the fly likes Play! Framework - Viable replacement for JPA's find() method in Ebeans Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Other Application Frameworks
Bookmark "Play! Framework - Viable replacement for JPA Watch "Play! Framework - Viable replacement for JPA New topic
Author

Play! Framework - Viable replacement for JPA's find() method in Ebeans

Samuel Bird
Ranch Hand

Joined: Jul 19, 2013
Posts: 96

I have been trying to pick up the Play! Framework recently and decided to go through the tutorial they provide for building a blog. I am aware that this is using JPA which is no longer supported by Play! and has been replaced by Ebeans. However, I decided to give it a go anyway and ad-hoc it a bit. Anyway, I got to the part saying that I have got to add a connect method (see the tutorial fro details) and I have to make use of the find() method found in play.jpa.Model. However, no such method exists in play.ebean.Model. I am looking to find an alternative or another approach I could take for this method.

I have done some research and have come across the ebean.find() method. However, I do not see how I can use this for my purpose. I would greatly appreciate it if anyone could give me any advice on how to move forward. Thanks in advance.
Samuel Bird
Ranch Hand

Joined: Jul 19, 2013
Posts: 96

Hmmm, I just came across this fetch. This look as though it could be useful. Does anyone know if it could help?

EDIT: It appears to have something to do with Lists. I have a feeling this won't be much use.
Samuel Bird
Ranch Hand

Joined: Jul 19, 2013
Posts: 96

This may be completely wrong but I have changed the original connect method:



to a method that uses fetch and find:



I don't think this works but I would appreciate other opinions on if I am going int he right direction.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Play! Framework - Viable replacement for JPA's find() method in Ebeans