SPARK-2761 refactor #maybeSpill into Spillable

Moved `#maybeSpill` in ExternalSorter and EAOM into `Spillable`.
What does `protected[this]` mean? It seems that we can just use `protected` here to keep the signatures simple.