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

Change the default representation pattern for content jaxrs resources to have more context in the represent method

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • None
    • 2.23.07
    • None
    • None

    Description

      Not yet sure how much extra context we need. Currently we have something like:

      HippoFolderRepresentation folderRep = new HippoFolderRepresentation().represent(folderBean);

      Now, the difficulty with this pattern is, that we cannot easily in the representation also show all the documents and create a link for the documents. Therefore, we at least need something like:

      represent(folderBean, requestContext);

      However, do we need more context? Like the request and response?

      Also, imo, I would like to be able in the representation to have the Link facilities, for example:

      protected Link getNodeLink(
      protected Link getRestLink(

      but now they can be only called from a Resource, not from a representation. I want to be able to easily create links in representation code as well.

      Attachments

        Activity

          People

            jsheriff Junaidh Kadhar Sheriff
            aschrijvers Ard Schrijvers
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: