isCanonical property
override
Implementation
@override
bool get isCanonical {
if (!isPublic) return false;
if (library != canonicalLibrary) return false;
// If there's no inheritance to deal with, we're done.
if (this is! Inheritable) return true;
var i = this as Inheritable;
// If we're the defining element, or if the defining element is not in the
// set of libraries being documented, then this element should be treated as
// canonical (given library == canonicalLibrary).
return i.enclosingElement == i.canonicalEnclosingContainer;
}