added private field visibilityAffectsDescendants and logic to use it.
Initialization of the field still hard coded to false to preserve current behaviour
Added visibiltyAffectsDescendants as param/prop/field to various interfaces and implementations so it can be used through configuration using internal DI or instantation through external DI, default value is false.