本文整理汇总了C#中IHashCodeProvider类的典型用法代码示例。如果您正苦于以下问题:C# IHashCodeProvider类的具体用法?C# IHashCodeProvider怎么用?C# IHashCodeProvider使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
IHashCodeProvider类属于命名空间,在下文中一共展示了IHashCodeProvider类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: makediffs
private static IDiff[] makediffs (IList original, IList [] changed, IComparer comparer, IHashCodeProvider hashcoder)
{
IDiff[] diffs = new IDiff[changed.Length];
for (int i = 0; i < changed.Length; i++)
diffs [i] = new Diff (original, changed [i], comparer, hashcoder);
return diffs;
}
示例2: Diff
public Diff(IList left, IList right, IComparer comparer, IHashCodeProvider hashcoder)
{
this.left = left;
this.right = right;
this.comparer = comparer;
this.hashcoder = hashcoder;
init();
}
示例3: Diff
public Diff(IList left, IList right, IComparer comparer, IHashCodeProvider hashcoder)
{
if (left == null) throw new ArgumentNullException("left");
if (right == null) throw new ArgumentNullException("right");
this.left = left;
this.right = right;
this.comparer = comparer;
this.hashcoder = hashcoder;
init();
}
示例4: k_HashTable
public k_HashTable(int ai_Capacity, double ad_LoadFactor, IHashCodeProvider ak_HashProvider, IComparer ak_Comparer)
{
if (ad_LoadFactor <= .0 || ad_LoadFactor > 1.0)
throw new ArgumentException("Load factor must be greater than .0 and smaller or equal to 1.0", "ad_LoadFactor");
md_LoadFactor = ad_LoadFactor;
double ld_Size = ai_Capacity/ad_LoadFactor;
if (ld_Size > int.MaxValue)
throw new ArgumentException("k_HashTable overflow");
int li_TableSize = FindPrimeGreater((int)ld_Size);
mk_Buckets = new r_Bucket[li_TableSize];
mi_GrowSize = (md_LoadFactor < 1.0) ? (int)(md_LoadFactor * li_TableSize) : li_TableSize-1;
mk_HashProvider = ak_HashProvider;
mk_Comparer = ak_Comparer;
mk_End = new k_PinnedBucketIterator(this, -1);
}
示例5: NameObjectCollectionBase
protected NameObjectCollectionBase(int capacity,
IHashCodeProvider hashProvider,
IComparer comparer)
{
if(capacity < 0)
{
throw new ArgumentOutOfRangeException
("capacity", S._("ArgRange_NonNegative"));
}
if(hashProvider == null)
{
hashProvider = CaseInsensitiveHashCodeProvider.Default;
}
if(comparer == null)
{
comparer = CaseInsensitiveComparer.Default;
}
table = new Entry [HashTableSize];
hcp = hashProvider;
cmp = comparer;
entries = new ArrayList(capacity);
readOnly = false;
}
示例6: Hashtable
public Hashtable(IDictionary d, IHashCodeProvider hcp, IComparer comparer)
: this(d, 1.0f, hcp, comparer) {
}
示例7: CompatibleComparer
internal CompatibleComparer(IComparer comparer, IHashCodeProvider hashCodeProvider) {
_comparer = comparer;
_hcp = hashCodeProvider;
}
示例8: StringIntegerHashtable
public StringIntegerHashtable(IDictionary dictionary, float loadFactor, IHashCodeProvider codeProvider, IComparer comparer)
{
innerHash = new Hashtable (dictionary, loadFactor, codeProvider, comparer);
}
示例9: IntegerHashtable
public IntegerHashtable(int capacity, IHashCodeProvider codeProvider, IComparer comparer)
{
innerHash = new Hashtable (capacity, codeProvider, comparer);
}
示例10: NameValueCollection
public NameValueCollection(IHashCodeProvider hashProvider, IComparer comparer)
: base(hashProvider, comparer) {
}
示例11: ComparableHashtable
public ComparableHashtable(int capacity, IHashCodeProvider hcp, IComparer comparer) : base(capacity, hcp, comparer) { }
示例12: UnitTestNameObjectCollectionBase
public UnitTestNameObjectCollectionBase (int capacity, IHashCodeProvider provider, IComparer comparer)
: base (capacity, provider, comparer)
{
}
示例13: NameObjectCollectionBase
protected NameObjectCollectionBase(IHashCodeProvider hashProvider, IComparer comparer) {
_keyComparer = new CompatibleComparer( comparer, hashProvider);
Reset();
}
示例14: ReadOnlyNameValueCollection
public ReadOnlyNameValueCollection(IHashCodeProvider hcp, IComparer comp) : base(hcp, comp)
{
}
示例15: FrameworkInfoDictionary
public FrameworkInfoDictionary(IDictionary dictionary, IHashCodeProvider codeProvider, IComparer comparer)
{
_innerHash = new Hashtable (dictionary, codeProvider, comparer);
}