Version: 3.3.1
Loading...
Searching...
No Matches

#include <wx/webrequest.h>

Detailed Description

Simple class containing the username and password to use for authenticating.

Since
3.1.5

Library:  wxNet
Category:  Networking
See also
wxWebAuthChallenge

Public Member Functions

 wxWebCredentials (const wxString &user=wxString(), const wxSecretValue &password=wxSecretValue())
 Create the new credentials object.
bool IsOk () const
 Return true if user name is set.
const wxStringGetUser () const
 Return the user.
const wxSecretValueGetPassword () const
 Return the password.

Constructor & Destructor Documentation

◆ wxWebCredentials()

wxWebCredentials::wxWebCredentials ( const wxString & user = wxString(),
const wxSecretValue & password = wxSecretValue() )

Create the new credentials object.

Note that the password is a wxSecretValue object, to construct it from a string you need to explicitly use wxSecretValue ctor.

Member Function Documentation

◆ GetPassword()

const wxSecretValue & wxWebCredentials::GetPassword ( ) const

Return the password.

See also
wxSecretString

◆ GetUser()

const wxString & wxWebCredentials::GetUser ( ) const

Return the user.

◆ IsOk()

bool wxWebCredentials::IsOk ( ) const

Return true if user name is set.

This can be used to distinguish this object from the default-constructed one.

Since
3.3.2