[英]C# new in method declaration
public new int AdjustedBaseValue
这里的新内容是什么意思或做什么?
In this case, new
is a modifier that hides an inherited member from the base class. 在这种情况下,
new
是一个修饰符,它隐藏了基类中的继承成员。 See the documentation . 请参阅文档 。
Here is a good forum post with some examples between the differences of using new
vs override
这是一篇很好的论坛帖子,其中介绍了使用
new
vs override
的不同之处
http://social.msdn.microsoft.com/Forums/en/Vsexpressvcs/thread/65e02299-300f-4b74-8f0a-679f490605f5 http://social.msdn.microsoft.com/Forums/en/Vsexpressvcs/thread/65e02299-300f-4b74-8f0a-679f490605f5
New is to hiding the baseclass implementation. 新的是隐藏基类实现。 Stoping the polymorphism...
确定多态性......
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.