simplify FrameworkMethod#equals

Inline some logic to improve readability.