Tree -> Form -> DB -> Back to Tree

I add items to my Tree via the HierarchicalContainer:

def item = container.addItem(obj)

…where obj is my domain object. I have a ValueChangeListener attached to my tree and when a node is selected I do the following:

if (event.getProperty().getValue() != null) {
      def node = event.getProperty().getValue()
      BHApplication.updateRightPanel(new DomainForm(Domain.get(

My DomainForm is a class that extends FormLayout and the code that displays the form is basically from the Vaadin Form demo. In the click handler for the apply button I need to have the Tree node update with the new data I’ve entered in the form. I’ve searched the forum but haven’t really found anything or I missed it.