compas-dev / compas-dev/compas_robots
Add public accessor(s) for proxied objects.
- Dominant language
- Python
- Stars
- 4
- Forks
- 8
- PR merge metrics
- No merged PRs in 30d
Description
submitting this as follow up of https://github.com/compas-dev/compas_robots/pull/25.
# Feature Request
Suggestion, add `unproxify()` and `unproxified()` to `ProxyObject` to allow public access to wrapped object wherever necessary, and return the original object or copy thereof correspondingly.
## Details
Currently done via accessing private attribute:
https://github.com/compas-dev/compas_robots/blob/eeb66626d72eb6ee2464dd47cf89e521ea76c48b/src/compas_robots/model/robot.py#L1040
**Is your feature request related to a problem? Please describe.**
The international high court for object oriented law has drawn our attention to the following potential violation of `Decree No. 42, Chapter 17, Sub-Chapter 8.3.1(c)(iv) — "The Inviolability of Encapsulation in Object-Oriented Programming"`.
**Describe alternatives you've considered.**
Stepping away from object oriented programming and re-writing the whole ecosystem in Haskell.
**Decision**: maybe another time.
Contributor guide
Assessment
This issue has not been assessed yet.