The code that is generated by this refactoring operation is modeled by the encapsulate field code snippets feature.
此重构操作生成的代码将由封装字段代码段功能来建模。
Encapsulate field USES the comma as a boundary between fields, and initiates refactoring on the field that is nearest the cursor and on the same line as the cursor.
“封装字段”使用逗号作为字段之间的边界,并对与光标位于同一行且距离光标最近的某个字段启动重构。
Encapsulate field refactoring operation enables you to quickly create a property from an existing field, and then seamlessly update your code with references to the new property.
“封装字段”重构操作,可以从现有字段快速创建属性,然后使用对新属性的引用无缝更新代码。
You can also specify which field you want to encapsulate by selecting the name of that field in the declaration.
也可以通过在声明中选择该字段的名称来指定要封装的字段。
By using properties to encapsulate that field, you can disallow direct access to fields.
通过使用属性封装该字段,可以禁止对字段的直接访问。
Don't control object bother force me to write a special routine to encapsulate the modification of field a.
不要强迫我访问不要所以额外写些代码去封装对字段a的修改过程。
Don't control object bother force me to write a special routine to encapsulate the modification of field a.
不要强迫我访问不要所以额外写些代码去封装对字段a的修改过程。
应用推荐