Uploaded image for project: 'Hippo CMS'
  1. Hippo CMS
  2. CMS-12850

Add generic support to indicate on which objects the Page Model API should use $ref logic

    XMLWordPrintable

Details

    • New Feature
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • None
    • 14.2.0, 100.2.0
    • site-toolkit
    • None
    • 0.25
    • Quasar
    • Puma Sprint 229

    Description

      At this moment, the Page Model API version v1.0 contains this:

          private static final Class<?>[] KNOWN_PMA_ENTITIES = {
                  ComponentWindowModel.class,
                  HippoDocumentBean.class,
                  HippoFolderBean.class,
                  CommonMenu.class
          };
      

      through which the PageModelSerializer 'knows' on which object types to include the $ref logic (flatten the structure).

      However, it should be more flexible. Downstream projects should also be able to contribute their objects to be flattened via the $ref logic. Therefor, we can better replace the hardcoded KNOWN_PMA_ENTITIES logic with a marker interface

      PageModelEntity
      

      All objects implementing this marker interface will be flattened using the $ref logic

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              aschrijvers Ard Schrijvers
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: