public static Cons sortedContexts() {
    { Cons contextnames = Stella.NIL;

      { Module m = null;
        Iterator iter000 = Stella.allModules();

        while (iter000.nextP()) {
          m = ((Module)(iter000.value));
          if ((!((BooleanWrapper)(KeyValueList.dynamicSlotValue(m.dynamicSlots, OntosaurusUtil.SYM_STELLA_CODE_ONLYp, Stella.FALSE_WRAPPER))).wrapperValue) &&
              (!((BooleanWrapper)(KeyValueList.dynamicSlotValue(m.dynamicSlots, OntosaurusUtil.SYM_STELLA_NAMESPACEp, Stella.FALSE_WRAPPER))).wrapperValue)) {
            contextnames = Cons.cons(StringWrapper.wrapString(m.name()), contextnames);
          }
        }
      }
      return (contextnames.sort(Native.find_java_method("edu.isi.stella.StringWrapper", "wrappedStringLessThanP", new java.lang.Class [] {Native.find_java_class("edu.isi.stella.StringWrapper"), Native.find_java_class("edu.isi.stella.StringWrapper")})));
    }
  }