expose data member is not good approach. I'd suggest init parent class(XWalkExtension) in the child classes(XWalkExternalExtension) constructor initialization list.