code: private static Collection getExtentClasses(ClassDescriptor cld)
      {
          /**
           * 1. check if this class has a ojbConcreteClass attribute
           */
          FieldDescriptor fd = cld.getFieldDescriptorByName(ClassDescriptor.OJB_CONCRETE_CLASS);
          Collection classes = new HashSet();  // use same class only once
          if (fd != null)
          {
              classes.add(cld.getClassOfObject().getName());
          }
  
          /**
           * 2. if this class has extents/is an extent search for all extents
           */
          if (cld.isExtent())
          {
              Vector extentClasses = cld.getExtentClasses();
  
              /**
               * 3. get all extents for this class
               */
              for (int i = 0; i < extentClasses.size(); i++)
              {
                  Class ec = (Class) extentClasses.get(i);
                  ClassDescriptor extCld = cld.getRepository().getDescriptorFor(ec);
                  classes.addAll(getExtentClasses(extCld));
              }
          }
  
          return classes;
      }
docs: Searches the class descriptor for the ojbConcrete class attribute
  if it finds the concrete class attribute, append a where clause which
  specifies we can load all classes that are this type or extents of this type.
  @param cld
  @return the extent classes