Compares this mutable to another in ascending order.

@param other  the other mutable to compare to, not null
@return negative if this is less, zero if equal, positive if greater
184158
@Override
    public int compareTo(final MutableInt other) {
        return (this.value > other.value) ? 1 : ((this.value == other.value) ? 0 : -1);
    }
1011798
@Override
  public int compareTo(RuleMatch other) {
    Objects.requireNonNull(other);
    return Integer.compare(getFromPos(), other.getFromPos());
  }
153948
@Override
  public int compareTo(StatusRepresentation o) {
    Long mine = getStatusId();
    Long other = o.getStatusId();
    return mine != null ? (other != null ? mine.compareTo(other) : 1)
        : (mine == other ? 0 : -1);
  }
54569
public int compareTo(ContentCodingType other) {
		int comp = this.type.compareToIgnoreCase(other.type);
		if (comp != 0) {
			return comp;
		}
		comp = this.parameters.size() - other.parameters.size();
		if (comp != 0) {
			return comp;
		}
		TreeSet<String> thisAttributes = new TreeSet<String>(String.CASE_INSENSITIVE_ORDER);
		thisAttributes.addAll(this.parameters.keySet());
		TreeSet<String> otherAttributes = new TreeSet<String>(String.CASE_INSENSITIVE_ORDER);
		otherAttributes.addAll(other.parameters.keySet());
		Iterator<String> thisAttributesIterator = thisAttributes.iterator();
		Iterator<String> otherAttributesIterator = otherAttributes.iterator();
		while (thisAttributesIterator.hasNext()) {
			String thisAttribute = thisAttributesIterator.next();
			String otherAttribute = otherAttributesIterator.next();
			comp = thisAttribute.compareToIgnoreCase(otherAttribute);
			if (comp != 0) {
				return comp;
			}
			String thisValue = this.parameters.get(thisAttribute);
			String otherValue = other.parameters.get(otherAttribute);
			if (otherValue == null) {
				otherValue = "";
			}
			comp = thisValue.compareTo(otherValue);
			if (comp != 0) {
				return comp;
			}
		}
		return 0;
	}
311599
@Override
    public int compareTo(final AbstractAttr<T> otherObj) {
        if (otherObj == null) {
            return 1;
        } else {
            return value.compareTo(otherObj.value);
        }
    }
159234
public int compareTo(OffsetCharSequence other) {
        int len1 = length();
        int len2 = other.length();
        int lim = Math.min(len1, len2);

        for (int i = 0; i  < lim; i++) {
            char c1 = charAt(i);
            char c2 = other.charAt(i);
            if (c1 != c2) {
                return c1 - c2;
            }
        }
        return len1 - len2;
    }
922959
public static int compare(Term self, Term other) {

		// Sanity check.
		if (self == null || other == null) {
			throw new NullPointerException();
		}

		// Identical objects are always equal.
		if (self == other) {
			return 0;
		}

		// Easy case is when they are not the same type of term.
		if (self.isKey() != other.isKey()) {
			return (self.isKey()) ? 1 : -1;
		}

		// Compare the underlying values.
		try {
			if (self.isKey()) {
				return self.getKey().compareTo(other.getKey());
			} else {
				return self.getIndex().compareTo(other.getIndex());
			}
		} catch (InvalidTermException consumed) {
			// This statement can never be reached because both objects are
			// either keys or indexes. This try/catch block is only here to make
			// the compiler happy.
			assert (false);
			return 0;
		}
	}
1065297
public void toEqual(T other) {
		if (this.value == null && other == null) {
			return;
		}
		expectNotNull(this.value, "Expected null to be equal '%s'", other);
		expectNotNull(other, "Expected '%s' to be equal null", this.value);
		expectTrue(this.value.equals(other), "Expected '%s' to be equal '%s'", this.value, other);
	}
15638
@Nullable
    public T getOrElse(@Nullable T other) {
        return throwable == null ? value : other;
    }
180065
public static <T extends Comparable> int compare(@Nullable T first, @Nullable T second) {
        return compare(first, second, Comparable::compareTo);
    }
941131
@Pure /* not guaranteed, since compareTo() is invoked */
	@Inline("($1.compareTo($2) <= 0)")
	public static <C> boolean operator_lessEqualsThan(Comparable<? super C> left, C right) {
		return left.compareTo(right) <= 0;
	}
1066828
@Pure /* not guaranteed, since compareTo() is invoked */
	@Inline("($1.compareTo($2) > 0)")
	public static <C> boolean operator_greaterThan(Comparable<? super C> left, C right) {
		return left.compareTo(right) > 0;
	}
465436
public static <T extends Comparable<? super T>> boolean lessThanOrEquals(final T object,
            final T other) {

        return JudgeUtils.lessThanOrEquals(object, other);
    }
369227
@Override
  public int compareTo(Comparable<?> other) {
    if (other instanceof Region) {
      Region r = (Region) other;
      if (this.start < r.start) {
        return -1;
      } else if (this.end > r.end) {
        return 1;
      } else {
        return 0;
      }
    } else if (other instanceof Long) {
      Long l = (Long) other;
      if (l > end) {
          return -1;
      } else if (l < start) {
          return 1;
      } else {
          return 0;
      }
    } else {
      throw new AssertionError();
    }
  }
1142478
public boolean lessThanOrEqual(Object left, Object right) {
    if (left == right) {
      return true;
    }
    else if (left == null || right == null) {
      return false;
    }
    else {
      return compare(left, right, "<=") <= 0;
    }
  }
1212606
@Override
    public int compareTo(Task<R> another) {
        int me = Constants.PRIORITY_MAP[priority&Constants.PRIORITY_MASK];
        int you = Constants.PRIORITY_MAP[another.priority&Constants.PRIORITY_MASK];
        return me == you ?
                seqNumber - another.seqNumber :
                you - me;
    }
927948
@Override
	public int compareTo(ShortValue o) {
		final int other = o.value;
		return this.value < other ? -1 : this.value > other ? 1 : 0;
	}