Tag: design-patterns


  1. Play!> framework design pattern #3 : Avoid Anemic Domain Model

    In my last post about data integrity, I noticed that with the MVC model of Play, you tend to put many logic in the controller, even a part of the domain model, thus creating an Anemic Domain ModelĀ as described by Martin Fowler. And it’s what I made…

    AnemicDomainModel, design patterns, java, play framework

  2. Play!> framework design pattern #2 reviewed

    In this post I write about a pattern to avoid code duplication for rendering the same objects (like combo boxes and so) in different views (a view to create an item or a view to edit existing ones). It has 2 things that couldn’t be done with the…

    design patterns, play framework

  3. Play!> framework design pattern #2 : avoid code duplication to render same objects in differents views

    If you have common code in your controllers to render objects in differents views, you’ll duplicate your code to instanciate your java objects in each method and pass them to the render method. The goal of this pattern is to avoid code duplication using the @Before/@After annotations…

    design patterns, play framework

  4. Play!> framework design pattern #1

    A bad pattern is to handle different code to manage edition of items and creation of new items in the forms. Typically you’ll pass an issue to the form when editing an existing one, and no one for the form to create new ones. Taking codeboard as an…

    design patterns, play framework

  5. JAXB and ObservableList

    If you don’t customize your schemas with JAXB, your generated classes will not handle correctly the list in your UI (using beans binding functionnality). If you have lists in your xml, you’ll probably handle them with Jtable or JList in your UI. Modifications of objects (from…

    beans binding, design patterns, GUI, jaxb, xml binding

  6. JTable row highlighting and Decorator design pattern

    I’ve been looking a moment to find how add row highlighting on JTables. To modify the behaviour of the cell rendering, you’ll have to set a new CellRenderer to JTable for each data types you want to show in the table. The way I use is…

    design patterns, GUI, JTable, swing

  7. Design Patterns Quick Reference (and others)

    Ever wanted a poster of Design Patterns ? Here is one for free on Jason McDonald’s blog. You can also find many useful poster or "Refcardz" on dzone.com. The Design Patterns one is also made by Jason. ou’ll find others on Java, Netbeans, eclipse or others.…

    design patterns, Eclipse, Netbeans, svn