简体   繁体   English

NuGet的带有QuickGraph包的C#

[英]C# with QuickGraph package from NuGet

I have a problem while trying to use AdjacencyGraph class of QuickGraph package. 尝试使用QuickGraph包的AdjacencyGraph类时遇到问题 Allow me to show my code as first and then describe the problem: 请允许我先显示代码,然后描述问题:

using System.Collections.Generic;
using QuickGraph;

public class StrategicMap
{

    private IList<Fraction> fractions;
    private AdjacencyGraph<ProvinceOnMap, EdgeOnMap> provinces;

    public StrategicMap(IList<Fraction> fractions, AdjacencyGraph<ProvinceOnMap, EdgeOnMap> provinces)
    {
        this.fractions = fractions;
        this.provinces = provinces;
    }

在此处输入图片说明

I'm using a proper(?) import, well, "using". 我正在使用一个正确的(?)导入,好吧,“正在使用”。 However, the compiler still doesn't know which class I refer to. 但是,编译器仍然不知道我指的是哪个类。 From QuickGraph.Contracts or from QuickGraph . 来自QuickGraph.ContractsQuickGraph

Here is the last screenshot, which is telling more about the prob: 这是最后的屏幕截图,它更多地介绍了问题:

在此处输入图片说明

Quite late with the answer, but perhaps it'll help you, or somebody else. 答案很晚,但也许会对您或其他人有所帮助。
There are a few QuickGraph packages on NuGet. NuGet上有一些QuickGraph软件包。
I'm using this one 我正在用这个
https://www.nuget.org/packages/QuickGraphPCL/ https://www.nuget.org/packages/QuickGraphPCL/
and this seems to work fine. 这似乎工作正常。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM