我找不到 PostSharp.Patterns

I cannot find PostSharp.Patterns

我下载并安装了 Postsharp essentials 版本,根据他们网站上的矩阵,它包括缓存。

我通过右键单击并选择“添加 Postsharp”选项将其添加到我的项目中。

当我进入我的项目进行测试时,我输入:

using PostSharp.Patterns

模式不适合我,我有方面、集合、约束...但没有模式。

我是否遗漏了参考资料,这是许可证问题吗?

PostSharp 被拆分成多个 NuGet 包。选择 "Add PostSharp to project" 仅安装核心包 (PostSharp)。在您的情况下,您需要安装 PostSharp.Patterns.Caching。请注意,您还需要指定缓存后端,请参阅 the documentation on caching