omines / datatables-bundle

DataTables bundle for Symfony
https://omines.github.io/datatables-bundle/
MIT License
252 stars 113 forks source link

Extendability of classes is kind of reduced by using private on a lot of fields and functions #193

Closed pkly closed 3 years ago

pkly commented 3 years ago

Would it be possible to get most, if not all, fields changed to protected? Some classes like AutomaticQueryBuilder seem like something that could easily be extended, yet basically need to be copied into a different class to change anything because of how restricted they are. There isn't much reason most of the functions and variables should be private, changing them to protected would simply make it easier to change parts of the code without rewriting everything from scratch.

curry684 commented 3 years ago

We follow this vision: http://fabien.potencier.org/pragmatism-over-theory-protected-vs-private.html

Protected functions and fields are an API. We're open to discussion on 'opening' parts of that API, but not as a blanket replace all private=>protected.