public static double estimateCardinalityOfExtension(NamedDescription description) {
    if ((description == null) ||
        (!NamedDescription.relationSupportsExtensionP(description))) {
      return (Stella.NULL_FLOAT);
    }
    { int estimate = Description.accessObservedCardinality(description);

      if ((estimate == Stella.NULL_INTEGER) &&
          (description.extension != null)) {
        estimate = description.extension.estimatedLength();
      }
      if (estimate == Stella.NULL_INTEGER) {
        estimate = 0;
      }
      return (((double)(Stella.integer_max(estimate, (NamedDescription.classDescriptionP(description) ? ((int)(Logic.ESTIMATED_SIZE_OF_CLASS_EXTENSION)) : ((int)(Logic.ESTIMATED_NUMBER_OF_PREDICATE_BINDINGS * Logic.ESTIMATED_NUMBER_OF_PREDICATE_BINDINGS * Logic.ESTIMATED_NUMBER_OF_PREDICATE_BINDINGS)))))));
    }
  }