C# HybridDictionary HybridDictionary(Int32)

Description

HybridDictionary HybridDictionary(Int32) creates a case-sensitive HybridDictionary with the specified initial size.

Syntax

HybridDictionary.HybridDictionary(Int32) has the following syntax.


public HybridDictionary(
  int initialSize
)

Parameters

HybridDictionary.HybridDictionary(Int32) has the following parameters.

  • initialSize - The approximate number of entries that the HybridDictionary can initially contain.

Example


using System;//from   w  ww. j ava 2 s  .co  m
using System.Collections;
using System.Collections.Specialized;

public class SamplesHybridDictionary  {

   public static void Main()  {
      HybridDictionary myCol = new HybridDictionary(10);
      myCol.Add( "F", "1.49" );
      myCol.Add( "A", "1.29" );
      myCol.Add( "B", "1.49" );

      foreach ( DictionaryEntry de in myCol )
         Console.WriteLine( "   {0,-25} {1}", de.Key, de.Value );
      Console.WriteLine();
   }
}

The code above generates the following result.





















Home »
  C# Tutorial »
    System.Collections.Specialized »




BitVector32
HybridDictionary
ListDictionary
OrderedDictionary
StringCollection
StringDictionary
StringEnumerator