HashSet<T>.GetObjectData(SerializationInfo, StreamingContext) Method

Definition

Implementa l'interfaccia ISerializable e restituisce i dati necessari per serializzare un oggetto HashSet<T>.Implements the ISerializable interface and returns the data needed to serialize a HashSet<T> object.

public:
 virtual void GetObjectData(System::Runtime::Serialization::SerializationInfo ^ info, System::Runtime::Serialization::StreamingContext context);
public virtual void GetObjectData (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
[System.Security.SecurityCritical]
public virtual void GetObjectData (System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context);
abstract member GetObjectData : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> unit
override this.GetObjectData : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> unit
Public Overridable Sub GetObjectData (info As SerializationInfo, context As StreamingContext)

Parameters

info
SerializationInfo

Oggetto SerializationInfo contenente le informazioni necessarie per serializzare l'oggetto HashSet<T>.A SerializationInfo object that contains the information required to serialize the HashSet<T> object.

context
StreamingContext

Struttura StreamingContext che contiene l'origine e la destinazione del flusso serializzato associato all'oggetto HashSet<T>.A StreamingContext structure that contains the source and destination of the serialized stream associated with the HashSet<T> object.

Implements

Attributes

Exceptions

info è null.info is null.

Remarks

La chiamata a questo metodo è un'operazione O (n), in cui n è Count.Calling this method is an O(n) operation, where n is Count.

Applies to