ReSharper C#命名方法的私有方法和属性 [英] ReSharper C# naming style for private methods and properties

查看:119
本文介绍了ReSharper C#命名方法的私有方法和属性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我喜欢将私有方法,属性和事件的首字母小写,将公共方法,属性和事件的首字母大写.但是,在ReSharper 7.1中,C#命名样式下只有一个选项可以应用 all 方法,属性和事件.告诉ReSharper仅对 private 使用不同约定的最佳方法是什么?

I like to make the first letter of private methods, properties and events lowercase and the first letter of public methods, properties and events uppercase. However, in ReSharper 7.1 there is only one option under C# naming style that applies all methods, properties and events. What is the best way to tell ReSharper to use a different convention for private only?

推荐答案

您可以创建自己的命名样式规则.

You can create your own Naming Style Rule.

Resharper选项=>代码编辑=> [语言] =>命名样式=>高级选项=> +添加...

Resharper Options => Code Editing => [Language] => Naming Style => Advanced Options => +Add...

已验证使用此选项可以实现所请求的功能.

Verified that the requested functionality is possible using this option.

这篇关于ReSharper C#命名方法的私有方法和属性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆