mutable
「mutable」的意思
adj. 可变的,易变的;反复无常的,用情不专的
adj.易变的,性情不定的
「mutable」的用法
mutable可变的 - 在PHP中,变量可以是可变的或不可变的。
「mutable」的例句
The array is mutable, so we can add elements to it.
这个数组是可变的,所以我们可以在它上面添加元素。
Mutable objects can be changed after they are created.
可变对象可以在创建后被修改。
The variable $x is mutable, meaning its value can be changed.
$x 这个变量是可变的,这意味着它的值可以被改变。
Mutable strings can be modified without creating a new string.
可变字符串可以在不创建新字符串的情况下进行修改。
The object's properties are mutable, allowing for dynamic changes.
对象的属性是可变的,允许进行动态更改。
$array['key'] = 'value'; // This modifies the array in place.
$array['key'] = 'value'; // 这会直接修改数组。
$str[0] = 'A'; // This modifies the string in place.
$str[0] = 'A'; // 这会直接修改字符串。
$obj->property = 'new value'; // This modifies the object's property.
$obj->property = 'new value'; // 这会修改对象的属性。
$arr[] = 42; // This adds an element to the array, making it mutable.
$arr[] = 42; // 这会向数组中添加一个元素,使其成为可变的。
$str .= ' World!'; // This appends to the string, making it mutable.
$str .= ' World!'; // 这会在字符串后面追加内容,使其成为可变的。