They provide a mutable wrapper for otherwise immutable object references.
它们为那些用其他方式不可改变的对象引用提供了一个可改变的包装器。
Because we used a set, we have to use tuple as we can only use an immutable object.
由于使用了集合,因此必须使用元组(tuple),因为只能使用不可修改的对象。
If you have an immutable object, you must set whatever state it will contain in the constructor.
如果您有一个不可变对象,则必须要在构造函数中设置该对象将包含的任何状态。
If you want to change an immutable object, you don't - you create a new object with the changed value and point your reference to it.
如果您想要改变一个不可变对象的话,您不会改变它,而是使用修改后的值来创建一个新的对象,并把您的引用指向它。
There can be no side effects on immutable objects, and caching a reference to an immutable object is always safe from alias problems.
不可变对象上没有副作用,并且缓存不可变对象的引用总是安全的,不会出现别名问题。
A context item is an immutable object and contains state.
上下文项是不可变的对象,并包含状态。
It provides an immutable object used by sockets for binding, connecting, or as returned values.
其提供一个用于套接字绑定、连接或作为返回值的不变对象。
It provides an immutable object used by sockets for binding, connecting, or as returned values.
其提供一个用于套接字绑定、连接或作为返回值的不变对象。
应用推荐