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

More efficiently load child beans for HippoItem

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Normal
    • Resolution: Fixed
    • None
    • 2.28.00-alpha-1, 2.28.00
    • None

    Description

      Currently, there is code that looks like:

      public <T extends HippoBean> List<T> getLinkedBeans(String relPath, Class<T> beanMappingClass) {

      // snip
      NodeIterator nodes = relNode.getNodes();
      while (nodes.hasNext()) {
      Node child = nodes.nextNode();
      if (child == null)

      { continue; }

      Object bean;
      try {
      bean = this.objectConverter.getObject(child);
      if (child.getName().equals(nodeName)) {

      this is horribly inefficient as relNode.getNodes() could already check the node name pattern.

      Attachments

        Issue Links

          Activity

            People

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

              Dates

                Created:
                Updated:
                Resolved: