Evidence.GetEnumerator Method ()


The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Note: This API is now obsolete.

Enumerates all evidence in the set, both that provided by the host and that provided by the assembly.

Namespace:   System.Security.Policy
Assembly:  mscorlib (in mscorlib.dll)

[ObsoleteAttribute("GetEnumerator is obsolete. Please use GetAssemblyEnumerator and GetHostEnumerator instead.")]
public IEnumerator GetEnumerator()

Return Value

Type: System.Collections.IEnumerator

An enumerator for evidence added by both the AddHost method and the AddAssembly method.

The following code example shows the use of the GetEnumerator method. This example is part of a larger example provided for the Evidence class.

int p = 0;
Console.WriteLine("\nCurrent evidence = ");
if (null == myEvidence) return 0;
IEnumerator list = myEvidence.GetEnumerator();
while (list.MoveNext())

.NET Framework
Available since 1.1
Return to top