Sign up ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free.

I'm developing a Java desktop application. I'm planning to use MVC architecture described at Oracle site: Java SE Application Design With MVC.

I need to store data in database so I decide to use Hibernate as it is very simple but there is any tutorial that use Swing+MVC+Hibernate.

It is possible to use them together?

share|improve this question
    
As a sidenote I would look at javafx, it is the successor to swing. – nablex Sep 25 '13 at 12:26

1 Answer 1

Why wouldn't it be possible?

Java Swing is a GUI toolkit, so you'll utilize that framework as part of your View layer.

Hibernate is a persistence layer, so you'll utilize that framework as part of your Model layer.

Sounds like a good combination of frameworks aligning with the MVC pattern. And by following the MVC pattern, you'll be setup to change out or modify those frameworks or layers more easily.

The other advantage of MVC is you can focus on each layer, one at a time. You mentioned looking for a tutorial on Swing+MVC+Hibernate but you don't need one. Follow the MVC tutorials you already mentioned and plugin those frameworks at their appropriate layer.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.