docs: private CollectionDescriptorDef usedByCollection(ModelDef modelDef, FieldDescriptorDef fieldDef, boolean elementClassSuffices)
      {
          ClassDescriptorDef      ownerClass     = (ClassDescriptorDef)fieldDef.getOwner();
          String                  ownerClassName = ownerClass.getQualifiedName();
          String                  name           = fieldDef.getName();
          ClassDescriptorDef      classDef;
          CollectionDescriptorDef collDef;
          String                  elementClassName;
  
          for (Iterator classIt = modelDef.getClasses(); classIt.hasNext();)
          {
              classDef = (ClassDescriptorDef)classIt.next();
              for (Iterator collIt = classDef.getCollections(); collIt.hasNext();)
              {
                  collDef          = (CollectionDescriptorDef)collIt.next();
                  elementClassName = collDef.getProperty(PropertyHelper.OJB_PROPERTY_ELEMENT_CLASS_REF).replace('$', '.');
                  // if the owner class of the field is the element class of a normal collection
                  // and the field is a foreignkey of this collection
                  if (ownerClassName.equals(elementClassName))
                  {
                      if (collDef.hasProperty(PropertyHelper.OJB_PROPERTY_INDIRECTION_TABLE))
                      {
                          if (elementClassSuffices)
                          {
                              return collDef;
                          }
                      }
                      else if (new CommaListIterator(collDef.getProperty(PropertyHelper.OJB_PROPERTY_FOREIGNKEY)).contains(name))
                      {
                          // if the field is a foreignkey of this normal 1:n collection
                          return collDef;
                      }
                  }
              }
          }
          return null;
      }