访问器没有实现? [英] Accessor does not have implementation?

查看:232
本文介绍了访问器没有实现?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我得到以下错误:


错误1方法'DoFoo'在类型
'MyNamespace.GenericFooClass_Accessor'1'
从程序集MyLibrary,
Version = 0.0.0.0,Culture = neutral,
PublicKeyToken = null'没有
实现。 Testing.MyLibrary

Error 1 Method 'DoFoo' in type 'MyNamespace.GenericFooClass_Accessor`1' from assembly 'MyLibrary, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' does not have an implementation. Testing.MyLibrary

我不知道它在说什么考虑的方法是实现...它不是抽象的。 p>

I have no idea what it's talking about considering the method is implemented... it isn't abstract.

public abstract class GenericFooClass<T> : IGenericFoo<T>
{
    public virtual void DoFoo() { ... }
}


推荐答案

访问器将被弃用,并且有很多错误。语言更新需要更多的资源来更新代码生成的访问器,因为它们会给出很多错误。

Accessors are going to be deprecated and have a lot of bugs in them. The language updates require more resources to update the accessors code-generation than they will give, hence a lot of bugs.

http://blogs.msdn.com/ b / vstsqualitytools / archive / 2010/01/18 / public-and-code-generation-for-visual-studio-2010.aspx

这篇关于访问器没有实现?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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