ClientCredentials Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Initializes a new instance of the ClientCredentials class.
Overloads
ClientCredentials() |
Initializes a new instance of the ClientCredentials class. |
ClientCredentials(ClientCredentials) |
This is a copy constructor. |
Remarks
The most common way to use this class is to access its properties from the client object and not to instantiate it directly. The following code shows how to do this.
WSHttpBinding b = new WSHttpBinding();
EndpointAddress ea = new EndpointAddress("http://localhost/Calculator");
CalculatorClient client = new CalculatorClient(b, ea);
IssuedTokenClientCredential itcc = client.ClientCredentials.IssuedToken;
itcc.LocalIssuerAddress = new EndpointAddress("http://fabrikam.com/sts");
ClientCredentials()
- Source:
- ClientCredentials.cs
- Source:
- ClientCredentials.cs
- Source:
- ClientCredentials.cs
Initializes a new instance of the ClientCredentials class.
public:
ClientCredentials();
public ClientCredentials ();
Public Sub New ()
Examples
The most common way to use this class is to access its properties from the client object and not to instantiate it directly. The following code shows how to do this.
WSHttpBinding b = new WSHttpBinding();
EndpointAddress ea = new EndpointAddress("http://localhost/Calculator");
CalculatorClient client = new CalculatorClient(b, ea);
IssuedTokenClientCredential itcc = client.ClientCredentials.IssuedToken;
itcc.LocalIssuerAddress = new EndpointAddress("http://fabrikam.com/sts");
Remarks
This constructor creates a ClientCredentials object with default settings, for example, SupportInteractive = true
.
Applies to
ClientCredentials(ClientCredentials)
- Source:
- ClientCredentials.cs
- Source:
- ClientCredentials.cs
- Source:
- ClientCredentials.cs
This is a copy constructor.
protected:
ClientCredentials(System::ServiceModel::Description::ClientCredentials ^ other);
protected ClientCredentials (System.ServiceModel.Description.ClientCredentials other);
new System.ServiceModel.Description.ClientCredentials : System.ServiceModel.Description.ClientCredentials -> System.ServiceModel.Description.ClientCredentials
Protected Sub New (other As ClientCredentials)
Parameters
- other
- ClientCredentials
A ClientCredentials. All properties of the newly-constructed instance reflect the values of this parameter.
Examples
The most common way to use this class is to access its properties from the client object and not to instantiate it directly. The following code shows how to do this.
WSHttpBinding b = new WSHttpBinding();
EndpointAddress ea = new EndpointAddress("http://localhost/Calculator");
CalculatorClient client = new CalculatorClient(b, ea);
IssuedTokenClientCredential itcc = client.ClientCredentials.IssuedToken;
itcc.LocalIssuerAddress = new EndpointAddress("http://fabrikam.com/sts");
Applies to
意見反應
https://aka.ms/ContentUserFeedback。
即將登場:在 2024 年,我們將逐步淘汰 GitHub 問題作為內容的意見反應機制,並將它取代為新的意見反應系統。 如需詳細資訊,請參閱:提交並檢視相關的意見反應