docs: protected Query buildPrefetchQuery(Collection ids)
      {
          CollectionDescriptor cds = getCollectionDescriptor();
          QueryByCriteria query = buildPrefetchQuery(ids, cds.getForeignKeyFieldDescriptors(getItemClassDescriptor()));
  
          // check if collection must be ordered
          if (!cds.getOrderBy().isEmpty())
          {
              Iterator iter = cds.getOrderBy().iterator();
              while (iter.hasNext())
              {
                  query.addOrderBy((FieldHelper) iter.next());
              }
          }
  
          return query;
      }