@Override
		public int compare(KeyedObject object1, KeyedObject object2) {
			KeyedObject ko1 = object1;
			KeyedObject ko2 = object2;
			int value1 = 0;
			int value2 = 0;
			try {
				value1 = getValue(ko1);
				try {
					value2 = getValue(ko2);
					if ((value1 - value2) != 0) {
						return (value1 - value2);
					}
					if ((ko1.key() - ko2.key()) < 0) {
						return -1;
					}
					else if ((ko1.key() - ko2.key()) > 0) {
						return +1;
					}
					else
						return 0;
				}
				catch (NoValueException exc2) {
					//ko1 is ok, ko2 fails.
					return -1;
				}
			}
			catch (ghidra.util.exception.NoValueException exc) {
				try {
					value2 = getValue(ko2);
					return 1; //ko2 is ok so it precedes ko1
				}
				catch (ghidra.util.exception.NoValueException exc2) {
					if ((ko1.key() - ko2.key()) < 0) {
						return -1;
					}
					else if ((ko1.key() - ko2.key()) > 0) {
						return +1;
					}
					else
						return 0;
				}
			}
		}
This class is a comparator (see java.util.Comparator) for
KeyedObjects having a IntegerAttribute. Keyed Objects are first
compared by the value of the attribute. Ties are broken by
considering the keys of the KeyedObjects.
Ghidra/Framework/Generic/src/main/java/ghidra/util/graph/attributes/IntegerAttribute.java