doublep commented on PR #232: URL: https://github.com/apache/commons-beanutils/pull/232#issuecomment-2129000279
I'd say keep all four `getReadMethod()` and `getWriteMethod()` overloads public. As these method names are very common, searching in publicly available code doesn't yield useful results (too many unrelated hits), but suppose someone somewhere has a valid usecase to access one of these methods. (I can't think of one myself, but I don't rule out the possibility that there might be.) If you now lower the visibility, you will break someone's code for no particularly good reason, forcing them to look for workarounds. E.g. subclassing, making the methods public and then explicitly downcasting to the created class when using from "outside". Basically, a lot of hassle for virtually nothing. It's not like `PropertyUtilsBean` is a high-level class where having a nice compact interface is a lot of value. So, I'd leave them all `public`, but add a "disclaimer" in the documentation that these methods are lower-level than the rest (e.g. `get*Property()`) and should generally not be needed outside of some special usecases. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
