EOModelMap hintsMap = new EOModelMap(fetchSpecMap.getMap("hints", true));
Map rawHintsMap = fetchSpecMap.getMap("hints", true); if (rawHintsMap == null) { rawHintsMap = new TreeMap(PropertyListComparator.AscendingPropertyListComparator); } EOModelMap hintsMap = new EOModelMap(rawHintsMap);
  public EOModelMap toMap() {    EOModelMap fetchSpecMap = myFetchSpecMap.cloneModelMap();    fetchSpecMap.setString("entityName", myEntity.getName(), true);    fetchSpecMap.setString("class", myClass, true);    fetchSpecMap.setInteger("fetchLimit", myFetchLimit);    fetchSpecMap.setBoolean("isDeep", myDeep, EOModelMap.YESNO);    fetchSpecMap.setBoolean("locksObjects", myLocksObjects, EOModelMap.YESNO);    fetchSpecMap.setSet("prefetchingRelationshipKeyPaths", myPrefetchingRelationshipKeyPaths, false);    fetchSpecMap.setBoolean("prompsAfterFetchLimit", myPromptsAfterFetchLimit, EOModelMap.YESNO);    if (myQualifier == null) {      fetchSpecMap.setMap("qualifier", null, true);    }    else {      fetchSpecMap.setMap("qualifier", EOQualifierFactory.createQualifierMapFromExpression(myQualifier), true);    }    fetchSpecMap.setSet("rawRowKeyPaths", myRawRowKeyPaths, false);    fetchSpecMap.setBoolean("refreshesRefetchedObjects", myRefreshesRefetchedObjects, EOModelMap.YESNO);    fetchSpecMap.setBoolean("requiresAllQualifierBindingVariables", myRequiresAllQualifierBindingVariables, EOModelMap.YESNO);    fetchSpecMap.setBoolean("usesDistinct", myUsesDistinct, EOModelMap.YESNO);    writeUserInfo(fetchSpecMap);    List sortOrderings = new LinkedList();    Iterator sortOrderingsIter = mySortOrderings.iterator();    while (sortOrderingsIter.hasNext()) {      EOSortOrdering sortOrdering = (EOSortOrdering) sortOrderingsIter.next();      EOModelMap sortOrderingMap = sortOrdering.toMap();      sortOrderings.add(sortOrderingMap);    }    fetchSpecMap.setList("sortOrderings", sortOrderings, true);    EOModelMap hintsMap = new EOModelMap(fetchSpecMap.getMap("hints", true));    hintsMap.setString("EOCustomQueryExpressionHintKey", myCustomQueryExpression, false);    String storedProcedureName = (myStoredProcedure != null) ? myStoredProcedure.getName() : null;    hintsMap.setString("EOStoredProcedureNameHintKey", storedProcedureName, true);    fetchSpecMap.setMap("hints", hintsMap, true);    return fetchSpecMap;  }