Extract XBlock handler machinery into a separate base class.