X509ExtensionEnumerator 类

定义

支持对 X509ExtensionCollection 执行简单迭代。Supports a simple iteration over a X509ExtensionCollection. 无法继承此类。This class cannot be inherited.

public ref class X509ExtensionEnumerator sealed : System::Collections::IEnumerator
public sealed class X509ExtensionEnumerator : System.Collections.IEnumerator
type X509ExtensionEnumerator = class
    interface IEnumerator
Public NotInheritable Class X509ExtensionEnumerator
Implements IEnumerator
继承
X509ExtensionEnumerator
实现

注解

枚举器提供对集合中数据的只读访问。Enumerators provide read-only access to the data in the collection. 枚举器不能用于修改基础集合。Enumerators cannot be used to modify the underlying collection.

最初,枚举数定位在集合中第一个元素的前面。Initially, the enumerator is positioned before the first element in the collection. Reset 也会将枚举器放回此位置。Reset also brings the enumerator back to this position. 在此位置,调用 Current 会引发异常。At this position, calling Current throws an exception. 因此,在读取 MoveNext 的值之前,必须调用 Current 将枚举器向前移动到集合的第一个元素。Therefore, you must call MoveNext to advance the enumerator to the first element of the collection before reading the value of Current.

此类继承自 IEnumerator 接口。This class inherits from the IEnumerator interface. 有关枚举集合的详细信息,请参阅 IEnumerator 主题。For more information about enumerating over a collection, see the IEnumerator topic.

属性

Current

获取 X509ExtensionCollection 中的当前元素。Gets the current element in the X509ExtensionCollection.

方法

Equals(Object)

确定指定的对象是否等于当前对象。Determines whether the specified object is equal to the current object.

(继承自 Object)
GetHashCode()

用作默认哈希函数。Serves as the default hash function.

(继承自 Object)
GetType()

获取当前实例的 TypeGets the Type of the current instance.

(继承自 Object)
MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(继承自 Object)
MoveNext()

将枚举数推进到 X509ExtensionCollection 中的下一个元素。Advances the enumerator to the next element in the X509ExtensionCollection.

Reset()

将枚举数设置到其初始位置,该位置位于 X509ExtensionCollection 中第一个元素之前。Sets the enumerator to its initial position, which is before the first element in the X509ExtensionCollection.

ToString()

返回一个表示当前对象的 string。Returns a string that represents the current object.

(继承自 Object)

显式接口实现

IEnumerator.Current

从集合中获取一个对象。Gets an object from a collection.

适用于