KContacts::ResourceLocatorUrl Class

class KContacts::ResourceLocatorUrl

Class that holds a Resource Locator. More...

Header: #include <KContacts/ResourceLocatorUrl>
CMake: find_package(KF6 REQUIRED COMPONENTS Contacts)
target_link_libraries(mytarget PRIVATE KF6::Contacts)
Since: 5.0

Public Types

List
flags Type
(since 5.12) enum TypeFlag { Unknown, Home, Work, Profile, Ftp, …, Other }

Properties

Public Functions

ResourceLocatorUrl()
(since 5.12) bool isPreferred() const
bool isValid() const
(since 5.12) void setPreferred(bool preferred)
(since 5.12) void setType(KContacts::ResourceLocatorUrl::Type type)
void setUrl(const QUrl &url)
QString toString() const
(since 5.12) KContacts::ResourceLocatorUrl::Type type() const
QUrl url() const
bool operator!=(const KContacts::ResourceLocatorUrl &other) const
bool operator==(const KContacts::ResourceLocatorUrl &other) const
QDataStream &operator<<(QDataStream &stream, const KContacts::ResourceLocatorUrl &object)
QDataStream &operator>>(QDataStream &stream, KContacts::ResourceLocatorUrl &object)

Detailed Description

Member Type Documentation

ResourceLocatorUrl::List

[since 5.12] enum ResourceLocatorUrl::TypeFlag
flags ResourceLocatorUrl::Type

URL types.

ConstantValueDescription
KContacts::ResourceLocatorUrl::Unknown0No or unknown URL type is set
KContacts::ResourceLocatorUrl::Home1Personal website
KContacts::ResourceLocatorUrl::Work2Work website
KContacts::ResourceLocatorUrl::Profile4Profile website
KContacts::ResourceLocatorUrl::Ftp (since Qt 6.0)8Ftp website
KContacts::ResourceLocatorUrl::Reservation (since Qt 6.0)16Reservation website
KContacts::ResourceLocatorUrl::AppInstallPage (since Qt 6.0)32Application installation website
KContacts::ResourceLocatorUrl::Other64Other website

This enum was introduced in 5.12.

The Type type is a typedef for QFlags<TypeFlag>. It stores an OR combination of TypeFlag values.

Property Documentation

isPreferred : bool

Access functions:

bool isPreferred() const
void setPreferred(bool preferred)

[read-only] isValid : const bool

Access functions:

bool isValid() const

type : Type

Access functions:

KContacts::ResourceLocatorUrl::Type type() const
void setType(KContacts::ResourceLocatorUrl::Type type)

url : QUrl

Access functions:

QUrl url() const
void setUrl(const QUrl &url)

Member Function Documentation

ResourceLocatorUrl::ResourceLocatorUrl()

[since 5.12] bool ResourceLocatorUrl::isPreferred() const

Returns whether this is the preferred website.

Note: Getter function for property isPreferred.

This function was introduced in 5.12.

bool ResourceLocatorUrl::isValid() const

Note: Getter function for property isValid.

[since 5.12] void ResourceLocatorUrl::setPreferred(bool preferred)

Sets that this is the preferred website.

Note: Setter function for property isPreferred.

This function was introduced in 5.12.

See also isPreferred().

[since 5.12] void ResourceLocatorUrl::setType(KContacts::ResourceLocatorUrl::Type type)

Sets the URL type.

Note: Setter function for property type.

This function was introduced in 5.12.

See also type().

void ResourceLocatorUrl::setUrl(const QUrl &url)

Note: Setter function for property url.

See also url().

QString ResourceLocatorUrl::toString() const

[since 5.12] KContacts::ResourceLocatorUrl::Type ResourceLocatorUrl::type() const

Returns the type of the URL.

Note: Getter function for property type.

This function was introduced in 5.12.

See also setType().

QUrl ResourceLocatorUrl::url() const

Note: Getter function for property url.

See also setUrl().

bool ResourceLocatorUrl::operator!=(const KContacts::ResourceLocatorUrl &other) const

bool ResourceLocatorUrl::operator==(const KContacts::ResourceLocatorUrl &other) const

Related Non-Members

QDataStream &operator<<(QDataStream &stream, const KContacts::ResourceLocatorUrl &object)

QDataStream &operator>>(QDataStream &stream, KContacts::ResourceLocatorUrl &object)