Uploaded image for project: '[Read Only] - Hippo Site Toolkit 2'
  1. [Read Only] - Hippo Site Toolkit 2
  2. HSTTWO-3374

Update ContentNodeBinder interface to make it more clear

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • High
    • Resolution: Won't Do
    • 3.0.0
    • None
    • None

    Description

      The bind method of the ContentNodeBinder interface accepts the content to bind as an Object. When I asked why, Woonsan replied:

      "Actually WorkflowPersistenceManagerImpl#update() would
      throws an exception like the following if it is not a HippoBean:

      } else

      { throw new ObjectBeanPersistenceException("The content object parameter should be an instance of HippoBean."); }

      Anyway, probably that type was defined by me originally. I thought we
      were going to support real POJOs. e.g, instead of extending
      HippoItem/HippoDocument/..., defining pure POJO interfaces or classes
      with annotations.

      Anyway, that API doesn't seem to have been touched ever from the initial
      design."

      The improvement would be to add a new method like this:

      boolean bind(HippoBean content, Node node) throws ContentNodeBindingException;

      And deprecate the exisiting one. Makes what you need to do more clear, and anything else then a HippoBean won't work anyway.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              bleunis Bert Leunis (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: