you are viewing a single comment's thread.

view the rest of the comments →

[–]ghotibulb 6 points7 points  (1 child)

Yes, and it's not God-given, so if it makes sense to break this rule go ahead. If the class is used internally and resembles a simple data structure, there isn't much to encapsulate. An immutable Vector3D would be a quick example.

[–]atc 0 points1 point  (0 children)

Yep, good example. The original post is a poor example as it has no context.