nsIDocument* GetDocument() const { return IsInDoc() ? GetOwnerDoc() : nsnull; }
nsGenericElement::GetDocument(nsIDocument*& aResult) const { NS_IF_ADDREF(mDocument); aResult = mDocument; return NS_OK; }
  nsIDocument* GetDocument() const  {    return IsInDoc() ? GetOwnerDoc() : nsnull;  }