c#标记方法如反射调用

发布于 2025-01-27 20:32:47 字数 134 浏览 2 评论 0原文

我有一个课堂上有反射调用的方法,可以根据执行环境自动调用它们。

我想指出这些方法是通过反射调用的,因为它似乎不使用任何不知道应用程序的人。

我已经在班级的文档部分中指出了这一点,但我想询问是否有更好的方法来避免发出警报的声音。

I have a class whitch have methods called by reflection to call automatically them depending on execution environment.

I wanted to indicate that these methods are called by reflection because it seems not to be used to anyone who doesn't have knowledge of the application.

I have indicated it in the documentation section of the class but I want to ask if there is any better way also to avoid alerts of SonarQube.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

静若繁花 2025-02-03 20:32:47

我会尝试

有一个 sonarqube resharper clt clt Plugin 可能会对您有所帮助。

I would try UsedImplicitlyAttribute of JetBrains Annotations.

There is a SonarQube ReSharper CLT Plugin that might help you.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文