C#XNA的Xbox HashSet的元组和 [英] C# XNA Xbox HashSet and Tuple
问题描述
由于从上面的问题,帮助现在的可选参数都工作,或者至少看起来好像他们应该工作
Thanks to help from the above question optional parameters are now working, or at least appear as if they should work.
不过我现在被困在HashSets和元组,没有出现可用两种。
However I'm now stuck on HashSets and Tuples, that don't appear to be available either.
我可以写我自己的两个类的版本。元组从无到有,HashSet的使用Dictonary(可能)。不过,我宁愿坚持使用标准的。
I could write my own version of both classes. Tuple from scratch and HashSet using a Dictonary (possibly). However I'd rather keep to using the standard ones.
如果在图书馆的电脑verstion存在这些类,那么我可以复制它们从PC C#粘贴图书馆到我自己的代码?
If these classes exist in the PC verstion of the library, then can I copy and paste them from the PC C# library into my own code?
在HashSet的[从元数据]使用转到定义的结果,是C ++头文件类似,因为它显示的类接口,但。没有实现
Using "Go To Definition" results in "HashSet [from metadata]" and is C++ header file like in that it shows the classes interface but no implementation.
推荐答案
有都是非常基本的数据结构,你可以做你自己的。
There both very basic data structures you can just make your own.
和这里是一个元组只需添加更多的项目需要。
And Here is a Tuple just add more items as needed.
public class Tuple<T1, T2>
{
public T1 Item1 { get; set; }
public T2 Item2 { get; set; }
public Tuple(T1 item1, T2 item2)
{
Item1 = item1;
Item2 = item2;
}
}
这篇关于C#XNA的Xbox HashSet的元组和的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!