gpt4 book ai didi

android - Xamarin - ‘Android.Content.IntentFilter' 不是属性类

转载 作者:塔克拉玛干 更新时间:2023-11-02 23:42:58 25 4
gpt4 key购买 nike

我创建了一个包含广播接收器实现的 Android 类库:

[IntentFilter(new string[] { "com.google.android.gcm.intent.RETRY" }, Categories = new string[] { "@PACKAGE_NAME@"})]
public class GcmBroadcastReceiver : BroadcastReceiver
{
public GcmBroadcastReceiver ()
{

}
}

当我尝试构建时收到消息“'Android.Content.IntentFilter' 不是属性类”

我需要做什么来构建这个版本?

最佳答案

您需要为 Android.Content 和 Android.App 添加 using 语句

关于android - Xamarin - ‘Android.Content.IntentFilter' 不是属性类,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29824275/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com