REF: Implement BaseMaskedArray class for integer/boolean ExtensionArrays
Todo item of https://github.com/pandas-dev/pandas/issues/29556, consolidating common code for IntegerArray and BooleanArray.

This is only a start, there is more to share.