QOpcUaApplicationIdentity Class▲
-
Header: QOpcUaApplicationIdentity
-
Since: QtOpcUa 5.13
-
qmake: QT += opcua
Detailed Description▲
This info must be configured using QOpcUaClient::setApplicationIdentity. The application identity can be set up manually or derived from a certificate.
QOpcUaApplicationIdentity identity;
const QString applicationUri = QStringLiteral("urn:%1:%2:%3")
.arg(QHostInfo::localHostName())
.arg(QCoreApplication::organizationName())
.arg(QCoreApplication::applicationName());
const QString productUri = QStringLiteral("urn:%1:%2")
.arg(QCoreApplication::organizationName())
.arg(QCoreApplication::applicationName());
identity.setProductUri(productUri);
identity.setApplicationUri(applicationUri);
identity.setApplicationName(QCoreApplication::applicationName());
identity.setApplicationType(QOpcUaApplicationDescription::Client);
client->setApplicationIdentity(identity);In case your application authenticates using certificates the application identity has to match the used certificate. In this case all information is extracted from the certificate given in the PKI configuration.
QOpcUaApplicationIdentity identity;
identity = pkiConfig.applicationIdentity();Member Function Documentation▲
QOpcUaApplicationIdentity::QOpcUaApplicationIdentity(const QOpcUaApplicationIdentity &other)▲
Constructs an application identity from other.
QString QOpcUaApplicationIdentity::applicationName() const▲
Returns the human readable name of the application. This does not need to be unique.
See Also▲
See also https://()
int QOpcUaApplicationIdentity::applicationType() const▲
QString QOpcUaApplicationIdentity::applicationUri() const▲
Returns the application's application URI.
This must be unique for each installation instance of the application and must match the ApplicationURI in the application's certificate.
See Also▲
See also https://()
bool QOpcUaApplicationIdentity::isValid() const▲
Returns true if the application identity contains valid data.
QString QOpcUaApplicationIdentity::productUri() const▲
Returns the application's productUri.
This uniquely identifies the product.
See Also▲
See also https://()
void QOpcUaApplicationIdentity::setApplicationName(const QString &value)▲
void QOpcUaApplicationIdentity::setApplicationType(int value)▲
Sets the type of the application. Client applications should set value to Client.
The default value is Client.
See Also▲
See also https://()
void QOpcUaApplicationIdentity::setApplicationUri(const QString &value)▲
void QOpcUaApplicationIdentity::setProductUri(const QString &value)▲
QOpcUaApplicationIdentity &QOpcUaApplicationIdentity::operator=(const QOpcUaApplicationIdentity &rhs)▲
Sets the values of rhs in this https://.


