HttpWebRequest Constructors

Definition

Initialise une nouvelle instance de la classe HttpWebRequest.Initializes a new instance of the HttpWebRequest class. Ces constructeurs sont obsolètes. Pour plus d’informations, consultez la section Remarques.These constructors are obsolete; see the Remarks section for details.

Overloads

HttpWebRequest()

Initialise une nouvelle instance de la classe HttpWebRequest.Initializes a new instance of the HttpWebRequest class. Ce constructeur est obsolète.This constructor is obsolete.

HttpWebRequest(Uri)
HttpWebRequest(SerializationInfo, StreamingContext)

Initialise une nouvelle instance de la classe HttpWebRequest à partir des instances spécifiées des classes SerializationInfo et StreamingContext.Initializes a new instance of the HttpWebRequest class from the specified instances of the SerializationInfo and StreamingContext classes. Ce constructeur est obsolète.This constructor is obsolete.

Remarks

Les deux constructeurs HttpWebRequest sont obsolètes et ne doivent pas être utilisés.Both HttpWebRequest constructors are obsolete and should not be used. Appelez la méthode WebRequest.CreateHttp pour initialiser de nouveaux objets HttpWebRequest.Call the WebRequest.CreateHttp method to initialize new HttpWebRequest objects.

HttpWebRequest()

Warning

This API is now obsolete.

Initialise une nouvelle instance de la classe HttpWebRequest.Initializes a new instance of the HttpWebRequest class. Ce constructeur est obsolète.This constructor is obsolete.

public:
 HttpWebRequest();
[System.Obsolete("This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.", true)]
public HttpWebRequest ();
Public Sub New ()
Attributes

HttpWebRequest(Uri)

public:
 HttpWebRequest(Uri ^ uri);
public HttpWebRequest (Uri uri);
new System.Net.HttpWebRequest : Uri -> System.Net.HttpWebRequest
Public Sub New (uri As Uri)

Parameters

uri
Uri

HttpWebRequest(SerializationInfo, StreamingContext)

Warning

This API is now obsolete.

Initialise une nouvelle instance de la classe HttpWebRequest à partir des instances spécifiées des classes SerializationInfo et StreamingContext.Initializes a new instance of the HttpWebRequest class from the specified instances of the SerializationInfo and StreamingContext classes. Ce constructeur est obsolète.This constructor is obsolete.

protected:
 HttpWebRequest(System::Runtime::Serialization::SerializationInfo ^ serializationInfo, System::Runtime::Serialization::StreamingContext streamingContext);
[System.Obsolete("Serialization is obsoleted for this type.  https://go.microsoft.com/fwlink/?linkid=14202")]
protected HttpWebRequest (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
[System.Obsolete("Serialization is obsoleted for this type.  http://go.microsoft.com/fwlink/?linkid=14202")]
protected HttpWebRequest (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
[System.Obsolete("Serialization is obsoleted for this type.  https://go.microsoft.com/fwlink/?linkid=14202")]
[System.Obsolete("Serialization is obsoleted for this type.  https://go.microsoft.com/fwlink/?linkid=14202")]
protected HttpWebRequest (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
protected HttpWebRequest (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
[System.Obsolete("Serialization is obsoleted for this type", false)]
protected HttpWebRequest (System.Runtime.Serialization.SerializationInfo serializationInfo, System.Runtime.Serialization.StreamingContext streamingContext);
new System.Net.HttpWebRequest : System.Runtime.Serialization.SerializationInfo * System.Runtime.Serialization.StreamingContext -> System.Net.HttpWebRequest
Protected Sub New (serializationInfo As SerializationInfo, streamingContext As StreamingContext)

Parameters

serializationInfo
SerializationInfo

Objet SerializationInfo qui contient les informations requises pour sérialiser le nouvel objet HttpWebRequest.A SerializationInfo object that contains the information required to serialize the new HttpWebRequest object.

streamingContext
StreamingContext

Objet StreamingContext qui contient la source et la destination du flux sérialisé associé au nouvel objet HttpWebRequest.A StreamingContext object that contains the source and destination of the serialized stream associated with the new HttpWebRequest object.

Attributes

Remarks

Une application doit s’exécuter en mode de confiance totale lors de l’utilisation de la sérialisation.An application must run in full trust mode when using serialization.

See also

Applies to