An immutable copy of a component in a particular workspace or stream is called a baseline.
特定工作区或流中的某个组件的不可变副本称为基准。
StringBuilder; one is immutable and changes to it cause the creation of a new copy, the other allows for in-place modification.
一个是不可变的,当需要修改的时候它会创建一个新的副本,而另一个则允许直接在其上进行修改。
You should always use collections to create immutable lists rather than arrays. Although it is possible to copy arrays defensively, it leads to some undesirable side-effects.
您应该始终使用集合而不是数组来创建不可变列表,尽管防御性的数组复制也是可行的,但这会带来一些不希望见到的副作用。
应用推荐