equals method
Compares this descriptor to a value. If the value is also a TypeDescriptor it compares their name and library fields. Otherwise this method returns false.
value
a value to compare. Returns true if value is identical TypeDescriptor and false otherwise.
Implementation
bool equals(value) {
if (value is TypeDescriptor) {
var otherType = value;
if (getName() != otherType.getName()) return false;
if (getLibrary() == null ||
otherType.getLibrary() == null ||
getLibrary() == otherType.getLibrary()) return true;
}
return false;
}