Encapsulation is keeping an object’s attributes behind its methods: users call the methods, which are the class’s interface, and leave the attributes alone. A class invariant is a property of the attributes that the constructor establishes and every method keeps.
书籍暂未推出简体中文版——当前显示英文版。
Computer Science · 术语表
什么是 Encapsulation, class invariant?
又称: encapsulation · class invariant