MCPcopy Create free account
hub / github.com/antlr/codebuff / equals

Method equals

output/java_guava/1.4.18/Cut.java:100–112  ·  view source on GitHub ↗
(Object obj)

Source from the content-addressed store, hash-verified

98 }
99
100 @SuppressWarnings("unchecked") // catching CCE
101 @Override
102 public boolean equals(Object obj) {
103 if (obj instanceof Cut) {
104 // It might not really be a Cut<C>, but we'll catch a CCE if it's not
105 Cut<C> that = (Cut<C>) obj;
106 try {
107 int compareResult = compareTo(that);
108 return compareResult == 0;
109 } catch (ClassCastException ignored) {}
110 }
111 return false;
112 }
113
114 /*
115 * The implementation neither produces nor consumes any non-null instance of type C, so

Callers

nothing calls this directly

Calls 1

compareToMethod · 0.95

Tested by

no test coverage detected