The entry point into the ArcGIS portal services hosted by ArcGIS Online and ArcGIS Enterprise. More...
Header | #include <Portal.h |
Since | Esri |
Inherits | Esri |
Public Functions
Portal( | |
Portal(bool login | |
Portal(const Q | |
Portal(const Q | |
virtual | ~ |
Esri | basemaps() const |
(since Esri Esri | basemaps3 |
(since Esri Q | culture() const |
(since Esri Esri | developer |
Esri | featured |
Esri | featured |
(since Esri Q | fetch3 |
(since Esri Q | fetch |
(since Esri Q | fetch |
(since Esri Q | fetch |
(since Esri Q | fetch |
(since Esri Q | fetch |
(since Esri Q | fetch |
(since Esri Q | fetch |
(since Esri Q | find |
(since Esri Q | find |
bool | is |
Esri | portal |
Esri | portal |
void | set |
(since Esri void | set |
Reimplemented Public Functions
virtual void | cancel |
(deprecated) virtual Esri | credential() const override |
virtual void | load() override |
virtual Esri | load |
virtual Esri | load |
(since Esri virtual Esri | request |
virtual void | retry |
(since Esri virtual void | set |
virtual Q | url() const override |
Signals
void | basemaps |
(since Esri void | developer |
void | done |
void | featured |
void | featured |
(since Esri void | fetch |
(since Esri void | fetch |
(since Esri void | fetch |
void | find |
void | find |
void | homepage |
void | load |
Detailed Description
ArcGIS portals are geospatial content management systems from ESRI that customers can use to securely store, manage, and access different types of content. There are two types of portals:
- ArcGIS Online portal - a service hosted by Esri that you can access with an ArcGIS Location Platform or ArcGIS Online account.
- ArcGIS Enterprise portal - a service hosted by ArcGIS Enterprise that you can access with an ArcGIS Enterprise account.
The Portal class is the main entry point into the ArcGIS Portal Directory REST API that allows you to work with users, groups and content hosted within ArcGIS Online or ArcGIS Enterprise portals. Once instantiated, you can use the Portal to search for items and groups and see portal content, such as services, layers, and so on.
For more information about authenticating your app or its users with a portal, see the Security and authentication guide.
The Portal class is the main entry point into the API used to work with portals and organization subscriptions. It implements all the operations to interface with the backend ArcGIS REST API. Use Portal to search for items and groups and see the contents of the portal, such as services, layers, and so on.
Portals allow users and organizations to publish and share content over the web. A portal can support subscriptions which provides organizations a sandboxed area on the portal. The website www.arcgis.com (ArcGIS Online) is an example of a portal.
Load the portal by calling load before using it.
This class is not a singleton and returns a new Portal object whenever the constructor is called.
Organizations
A Portal may contain multiple organizations. An organization has users in different roles including administrators, publishers, and other users.
- Administrators can add users to their organization subscriptions and have access to all content within the organization.
- Publishers within an organization can in addition create hosted services based on data files that they upload.
- All users can create web maps based on mashing up services that they have access to and can register services running on external servers.
Content
Users create and share content that organized into Items. A Portal can contain different types of content items including:
- Web maps
- Map services (that can be used as layers in web maps)
- Applications (that are built around web maps)
- Data files (that can be uploaded and downloaded)
Users can choose to keep the content they create private, or share it with other members of the same group, or make content public and accessible to everyone.
Users and Groups
A user of the Portal sees the view of the Portal that corresponds to their organization's subscription. This view includes users, groups, and items that belong to the organization or have been shared with them. This view may also include users, groups, and items that are external to the user's organization and have been shared with the user. A Portal can have users who are affiliated with an organization or users who are not.
Users can create and join groups.
Portal Constructors
Constructors are available that take some combination of these parameters.
url
- The URL of the portal to access. If not present, this defaults to www.arcgis.com (ArcGIS Online).loginRequired
- Determines whether the user is asked to log in (optional).- Set to
false
if you intend to access the portal anonymously ortrue
if you want to use a credential. - If set to
true
, an authentication challenge will be issued. - If set to
false
, the portal will be accessed anonymously. If the portal does not permit anonymous access, an authentication challenge will be issued.
When the credential property is set, the credential will be used regardless of the value of the
loginRequired
parameter.- Set to
credential
- The credential to use when accessing the portal (optional).parent
- The parent QObject (optional).
Example: Create a portal anonymously:
auto* portalAnon = new Portal(QUrl("http://www.arcgis.com"), parent);
Relevant samples:
- Access portal user info: Retrieve a user's details via a Portal.
- Add items to portal: This sample demonstrates how to add and delete items in a user's portal.
- Create and save map: Create and save a map as an ArcGIS `PortalItem` (i.e. web map).
- Create feature collection layer (Portal item): Create a feature collection layer from a portal item.
- Custom dictionary style: Use a custom dictionary style created from a web style or local style file (.stylx) to symbolize features using a variety of attribute values.
- Display KML: Display KML from a URL, portal item, or local KML file.
- Generate offline map: Take a web map offline.
- Integrated windows authentication: Uses Windows credentials to access services hosted on a portal secured with Integrated Windows Authentication (IWA).
- Open map (URL): Display a web map.
- Query features with Arcade expression: Query features on a map using an Arcade expression.
- Search for web map by keyword: Find webmap portal items by using a search term.
- Show organization basemaps: Connect to Portal to give users access to their organization's basemaps.
- Token authentication: Access a web map that is secured with ArcGIS token-based authentication.
See also PortalUser, PortalGroup, and PortalItem.
Member Function Documentation
[explicit]
Portal::Portal(QObject *parent = nullptr)
Default constructor with optional parent object.
[explicit]
Portal::Portal(bool loginRequired , QObject *parent = nullptr)
Creates a portal with anonymous or authenticated access as specified by the loginRequired parameter.
- loginRequired -
true
indicates that the user must login.false
indicates that the user must only login if required by the portal. - parent - The optional parent QObject.
If the loginRequired parameters is true
, then the user will be required to login to the portal in order to use it at all. If it is false
, then the user will only be required to login if the portal does not support anonymous access (that is, if the portal access type is PortalAccess::Private).
[explicit]
Portal::Portal(const QUrl &url, QObject *parent = nullptr)
Creates a portal using the portal URL with anonymous access.
- url - The URL to the portal.
- parent - The optional parent QObject.
The supported URL formats are:
- The URL of the portal (Example:
https://www.arcgis.com
) - The URL of the portal REST endpoint (Example:
https://www.arcgis.com/sharing/rest
) - The URL of the deprecated portal REST endpoint (Example:
https://www.arcgis.com/sharing
)
[explicit]
Portal::Portal(const QUrl &url, bool loginRequired , QObject *parent = nullptr)
Creates a portal using the portal URL with anonymous or authenticated access as specified by the loginRequired parameter.
- url - The URL to the portal.
- loginRequired -
true
indicates that the user must login.false
indicates that the user must only login if required by the portal. - parent - The optional parent QObject.
The supported URL formats are:
- The URL of the portal (Example:
https://www.arcgis.com
) - The URL of the portal REST endpoint (Example:
https://www.arcgis.com/sharing/rest
) - The URL of the deprecated portal REST endpoint (Example:
https://www.arcgis.com/sharing
)
If the loginRequired value is true
, then the user must login to the portal in order to use it. If it is false
, then the user will only be required to login if the portal does not support anonymous access. In this case, the portal access type is PortalAccess::Private.
[override virtual noexcept]
Portal::~Portal ()
Destructor.
Esri::ArcGISRuntime::BasemapListModel *Portal::basemaps() const
Returns the list of portal basemaps.
See also Basemap and Portal::fetchBasemaps.
[since Esri::ArcGISRuntime 200.7]
Esri::ArcGISRuntime::BasemapListModel *Portal::basemaps3D () const
*
Returns a list of portal 3D basemaps. *
*
This function was introduced in Esri::ArcGISRuntime 200.7.
See also Basemap and Portal::fetch3DBasemapsAsync.
[signal]
void Portal::basemapsChanged ()
Signal emitted when the fetchBasemaps task is completed.
See also Basemap.
[override virtual]
void Portal::cancelLoad ()
Reimplements: Loadable::cancelLoad().
Cancels loading the metadata for the object.
Cancels loading the metadata if the object is loading.
See Loadable.
[since Esri::ArcGISRuntime 100.11]
QString Portal::culture() const
Returns a code that specifies the culture-specific formatting to use when accessing Portal content.
The culture code provides localized content when viewing featured groups or items, adding or updating an item, adding a comment or rating to an item, and so on. If not explicitly set, the culture used by the device/machine is used. If the culture is not supported by the portal or set to an empty string, the culture specified in the portal/organization settings is used. The format for culture code is based on a language code and a country code separated by a dash. Example: "en-US".
This function was introduced in Esri::ArcGISRuntime 100.11.
See also setCulture().
[since Esri::ArcGISRuntime 100.12]
Esri::ArcGISRuntime::BasemapListModel *Portal::developerBasemaps () const
Returns the list of portal developer basemaps.
This function was introduced in Esri::ArcGISRuntime 100.12.
See also Basemap and Portal::fetchDeveloperBasemaps.
[signal, since Esri::ArcGISRuntime 100.12]
void Portal::developerBasemapsChanged ()
Signal emitted when the fetchDeveloperBasemaps task is completed.
This function was introduced in Esri::ArcGISRuntime 100.12.
See also Basemap.
[signal]
void Portal::doneLoading (const Esri::ArcGISRuntime::Error &error)
Signal emitted when this object is done loading.
- error - Details about any error that may have occurred.
Esri::ArcGISRuntime::PortalGroupListModel *Portal::featuredGroups () const
Returns the featured groups for the organization.
This property will return an empty list model until the groups are successfully fetched with fetchFeaturedGroups.
Subsequently it contains PortalGroup objects that are fully populated and have a load status of LoadStatus::Loaded.
[signal]
void Portal::featuredGroupsChanged ()
Signal emitted when the fetchFeaturedGroups task is completed.
See also PortalGroup.
Esri::ArcGISRuntime::PortalItemListModel *Portal::featuredItems () const
Returns the list of items featured for the portal.
See also PortalItem.
[signal]
void Portal::featuredItemsChanged ()
Signal emitted when the fetchFeaturedItems task is completed.
See also PortalItem.
[since Esri::ArcGISRuntime 200.7]
QFuture <void> Portal::fetch3DBasemapsAsync ()
Gets the collection of Basemap objects in the portal's 3D basemap gallery group.
The portal's 3D basemap gallery group is defined by the portal's administrator and contains the 3D basemaps that are displayed in the Scene Viewer basemap gallery. The basemaps in this collection are not loaded, but you can access their PortalItem metadata from Basemap::item.
This function was introduced in Esri::ArcGISRuntime 200.7.
See also Basemap, Portal::basemaps3D, and PortalInfo::basemap3DGalleryGroupQuery.
[since Esri::ArcGISRuntime 200.4]
QFuture <void> Portal::fetchBasemapsAsync ()
Gets the collection of Basemap objects in the portal's basemap gallery group.
The operation is complete when the QFuture is finished.
The portal's basemap gallery group is defined by the portal's administrator and contains the basemaps that are displayed in the Map Viewer basemap gallery if a user logs in with an ArcGIS Online or ArcGIS Enterprise account.
The basemaps in this collection are not loaded, but you can access their PortalItem metadata from Basemap::item.
{PortalInfo::basemapGalleryGroupQuery}, {Esri::ArcGISRuntime::Basemap} {Basemap}
Example:
Fetch the basemaps for a portal:
int basemapsCount = 0; auto fetchBasemapsFuture = portal->fetchBasemapsAsync().then( [portal, &basemapsCount]() { if (portal && portal->basemaps()) { basemapsCount = portal->basemaps()->rowCount(); } });
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
See also Esri::ArcGISRuntime::PortalInfo::basemapGalleryGroupQuery.
[since Esri::ArcGISRuntime 200.4]
QFuture <void> Portal::fetchDeveloperBasemapsAsync ()
Gets the collection of Basemap objects in the portal's developer basemap gallery group.
The operation is complete when the QFuture is finished.
The portal's developer basemap gallery group is defined by the portal's administrator and contains the basemaps that are displayed in the Map Viewer basemap gallery when a user logs in with an ArcGIS Location Platform account. The basemaps in the collection are not loaded, but you can access their PortalItem metadata from Basemap::item.
{PortalInfo::developerBasemapGalleryGroupQuery}, {Esri::ArcGISRuntime::Basemap::Basemap(Esri::ArcGISRuntime::BasemapStyle, QObject*)} {Basemap::Basemap(Esri::ArcGISRuntime::BasemapStyle, QObject*)}
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
See also Esri::ArcGISRuntime::PortalInfo::developerBasemapGalleryGroupQuery.
[since Esri::ArcGISRuntime 200.4]
QFuture <void> Portal::fetchFeaturedGroupsAsync ()
Retrieves the featured groups for the organization using the PortalInfo::featuredGroupsQueries query strings.
The operation is complete when the QFuture is finished.
The result is an unmodifiable list of PortalGroup objects, available via the featuredGroups method. These are fully populated and have a load status of LoadStatus::Loaded.
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
See also PortalGroup.
[since Esri::ArcGISRuntime 200.4]
QFuture <void> Portal::fetchFeaturedItemsAsync ()
Retrieves the set of featured items available from the portal using the PortalInfo::featuredItemsGroupQuery query string.
The operation is complete when the QFuture is finished.
After the items have been retrieved, the results are available via the featuredItems method.
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
See also PortalItem.
[since Esri::ArcGISRuntime 200.4]
QFuture <Esri::ArcGISRuntime::LicenseInfo > Portal::fetchLicenseInfoAsync ()
Executes a portal query that gets the current user's LicenseInfo including the entitlements and extensions.
The operation is complete when the QFuture is finished. The Qfuture will contain a pointer to the LicenseInfo
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
[signal, since Esri::ArcGISRuntime 100.7]
void Portal::fetchLicenseInfoCompleted (const QUuid &taskId , const Esri::ArcGISRuntime::LicenseInfo &licenseInfo )
Signal emitted when the fetchLicenseInfo task is completed.
- taskId - The task ID of the asynchronous task.
- licenseInfo - The LicenseInfo for the current user on the portal.
This function was introduced in Esri::ArcGISRuntime 100.7.
[since Esri::ArcGISRuntime 200.4]
QFuture <Esri::ArcGISRuntime::PortalQueryResultSetForItems *> Portal::fetchStylesAsync (QObject *parent = nullptr)
Retrieves a collection of styles using the PortalInfo::stylesGroupQuery query string.
- parent - The optional parent QObject.
The operation is complete when the QFuture is finished. The Qfuture will contain a pointer to the PortalQueryResultSetForItems
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
[signal, since Esri::ArcGISRuntime 100.12]
void Portal::fetchStylesCompleted (Esri::ArcGISRuntime::PortalQueryResultSetForItems *result)
Signal emitted when the fetchStyles operation completes.
The returned PortalQueryResultSetForItems contains the PortalItem objects with styles, and the signal includes the result.
This function was introduced in Esri::ArcGISRuntime 100.12.
[since Esri::ArcGISRuntime 200.4]
QFuture <Esri::ArcGISRuntime::PortalQueryResultSetForItems *> Portal::fetchSymbolSetsAsync (QObject *parent = nullptr)
Retrieves a collection of symbol sets using the PortalInfo::symbolSetsGroupQuery query string.
- parent - The optional parent QObject.
The operation is complete when the QFuture is finished. The Qfuture will contain a pointer to the PortalQueryResultSetForItems
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
[signal, since Esri::ArcGISRuntime 100.12]
void Portal::fetchSymbolSetsCompleted (Esri::ArcGISRuntime::PortalQueryResultSetForItems *result)
Signal emitted when the fetchSymbolSets operation completes.
The returned PortalQueryResultSetForItems contains the PortalItem objects with symbol sets, and the signal includes the result.
This function was introduced in Esri::ArcGISRuntime 100.12.
[since Esri::ArcGISRuntime 200.4]
QFuture <Esri::ArcGISRuntime::PortalQueryResultSetForGroups *> Portal::findGroupsAsync (const Esri::ArcGISRuntime::PortalQueryParametersForGroups &queryParameters , QObject *parent = nullptr)
Finds the portal groups that match the given query parameters.
- queryParameters - the query parameters.
- parent - The optional parent QObject.
This method obtains a PortalQueryResultSetForGroups object containing a collection of PortalGroup objects. The PortalGroup objects are fully populated and have a load status of LoadStatus::Loaded. Use the PortalQueryParameters to restrict the items returned by this method. If you provide a simple keyword string for the search, such as "federal", this method searches the default set of high performance index fields, such as id, title, description, snippet, tags, and owner.
For more advanced searches, you can preface your simple keyword strings with ArcGIS Portal Directory REST named fields followed by a colon (:). These advanced searches can take advantage of Boolean operators (AND, NOT, OR, -) and a range of special characters. For a more information, see the Search reference document in the ArcGIS Portal Directory REST API. Here are some examples of advanced search strings:
To find one specific portal group by its Id: "id:1db70a32f5f84ea9a88f5f460f22557b" To find all private portal groups with the word 'federal' in the Title field: "title:federal AND access:private" To find all portal groups with the word 'federal' in the Title field and the word 'restricted' in the Description field: "title:federal AND description:restricted" To find all portal groups with the word 'state' in the Title field and not have the word 'restricted' in the Description field: "title:state NOT description:restricted".
The operation is complete when the QFuture is finished. The Qfuture will contain a pointer to the PortalQueryResultSetForGroups
Example:
Use findGroupsAsync to retrieve all of the groups for a portal:
// example query to return all groups QString groupsQuery = "1==1"; PortalQueryParametersForGroups findGroupsQueryParameters(groupsQuery); int numberOfGroups = 0; auto findGroupsFuture = portal->findGroupsAsync(findGroupsQueryParameters).then([&numberOfGroups](PortalQueryResultSetForGroups* results) { numberOfGroups = results ? results->totalResults() : 0; });
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
[signal]
void Portal::findGroupsCompleted (Esri::ArcGISRuntime::PortalQueryResultSetForGroups *result)
Signal emitted when the findGroups task is completed. The signal includes the result.
The returned PortalQueryResultSetForGroups object has the Portal as its parent.
See also Returned QObjects Parenting and PortalQueryResultSetForGroups.
[since Esri::ArcGISRuntime 200.4]
QFuture <Esri::ArcGISRuntime::PortalQueryResultSetForItems *> Portal::findItemsAsync (const Esri::ArcGISRuntime::PortalQueryParametersForItems &queryParameters , QObject *parent = nullptr)
Finds the portal items that match the specified query parameters.
- queryParameters - the query parameters.
- parent - The optional parent QObject.
This method obtains a PortalQueryResultSetForItems object that contains PortalItem objects. Since portal items can be maps, layers, applications or tools, use the PortalQueryParameters to restrict which items are returned. If you provide a simple keyword string for the search, such as "florida", this method searches a default set of high performance index fields, such as title, tags, snippet, description, type, and typekeywords.
For more advanced searches, you can preface your simple keyword strings with ArcGIS Portal Directory REST named fields followed by a colon (:). These advanced searches can take advantage of Boolean operators (AND, NOT, OR, -) and a range of special characters. For a more information, see the Search reference document in the ArcGIS Portal Directory REST API. Here are some examples of advanced search strings:
- To find one specific portal item by its Id: "id:00e5e70929e14055ab686df16c842ec1"
- To find all WebMap portal items with the word 'florida' in the Title field: "title:florida AND type:web map"
- To find all Layer Package portal items with the word 'florida' in the Title field: "title:florida AND type:layer package"
- To find all portal items with the word 'florida' in the Title field and the word 'esri' in the LicenseInfo field: "title:florida AND licenseinfo:esri"
- To find all portal items with the word 'florida' in the Title field and not have the word 'esri' in the LicenseInfo field: "title:florida NOT licenseinfo:esri"
- To find all portal items with located within a specific spatial extent and the word 'esri' in the LicenseInfo: "extent:[-114.3458, 21.7518] - [-73.125, 44.0658] AND licenseinfo:esri"
- To find all portal items with a SpatialReference.WKID of 4267: "spatialreference:4267"
- To find all portal items with a SpatialReference.WKID of 4267 or have the word 'cancer' in the Title field: "spatialreference:4267 OR title:cancer"
The operation is complete when the QFuture is finished. The Qfuture will contain a pointer to the PortalQueryResultSetForItems
If you want to find items that belong to a group, then use Portal::findItemsAsync() to search group content.
Example:
Use findItems to retrieve web maps with specific tags from a portal:
// webmaps authored prior to July 2nd, 2014 are not supported // so search only from that date to the current time (in milliseconds) QString fromDate = QString("000000%1").arg(QDateTime::fromString(QDate(2014, 7, 2).toString()).toMSecsSinceEpoch()); QString toDate = QString("000000%1").arg(QDateTime::currentDateTime().toMSecsSinceEpoch()); PortalQueryParametersForItems query; query.setSearchString(QString("tags:\"%1\" AND +uploaded:[%2 TO %3]") .arg(keyword, fromDate, toDate)); query.setTypes(QList<PortalItemType>() << PortalItemType::WebMap); m_portal->findItemsAsync(query).then(this, [this](PortalQueryResultSetForItems* webmapResults) { onFindItemsCompleted(webmapResults); });
Canceling the QFuture will not stop this operation from completing, though the QFuture will report that it is canceled and the completion handler will not be called.
See Working with QFuture for further details.
This function was introduced in Esri::ArcGISRuntime 200.4.
[signal]
void Portal::findItemsCompleted (Esri::ArcGISRuntime::PortalQueryResultSetForItems *result)
Signal emitted when the findItems task is completed. The signal include the result.
The returned PortalQueryResultSetForItems object has the Portal as its parent.
See also Returned QObjects Parenting and PortalQueryResultSetForGroups.
[signal]
void Portal::homepageFeaturedContentChanged ()
Signal emitted when the fetchHomepageFeaturedContent task is completed.
See also PortalItem.
bool Portal::isLoginRequired () const
Returns true
requires the user to log in to the portal, false
allows anonymous access.
If the loginRequired value is true
, the user must log in to access the portal.
If it is false
, the user must log in only if the portal does not support anonymous access. In this case, the portal access type is PortalAccess::Private.
[override virtual]
void Portal::load()
Reimplements: Loadable::load().
Loads the metadata for the object asynchronously.
Loads the metadata if the object is not loaded.
See Loadable.
[override virtual]
Esri::ArcGISRuntime::Error Portal::loadError () const
Reimplements: Loadable::loadError() const.
Returns the load error.
See Loadable.
See also Error.
[override virtual]
Esri::ArcGISRuntime::LoadStatus Portal::loadStatus () const
Reimplements: Loadable::loadStatus() const.
Returns the load status.
See Loadable.
See also LoadStatus.
[signal]
void Portal::loadStatusChanged (Esri::ArcGISRuntime::LoadStatus loadStatus )
Signal emitted when the loadStatus changes for this object.
See also Loadable.
Esri::ArcGISRuntime::PortalInfo *Portal::portalInfo () const
Returns the details about the Portal instance, such as its name, logo, featured items, and supported protocols (http
vs https
).
A PortalInfo object represents details of the portal/organization as seen by the current user, anonymous or logged in. If the current user is a member of an organization on this portal, information about the user and organization is included.
This property will be a nullptr
until the portal is loaded.
Esri::ArcGISRuntime::PortalUser *Portal::portalUser () const
Returns the registered user of the portal.
This value is nullptr
if no user is signed in due to anonymous access or the portal is not loaded.
This information is available after successful initialization of the portal with a credential and load completes.
[override virtual]
void Portal::retryLoad ()
Reimplements: Loadable::retryLoad().
Loads or retries loading metadata for the object asynchronously.
Will retry loading the metadata if the object is failed to load. Will load the object if it is not loaded. Will not retry to load the object if the object is loaded. Will always call the done loading if this is called.
See Loadable.
void Portal::setCredential (Esri::ArcGISRuntime::Credential *credential)
Sets the portal's Credential to credential.
The Credential is used when calling Portal::load().
[since Esri::ArcGISRuntime 100.11]
void Portal::setCulture (const QString &culture)
Sets the culture to culture.
This function was introduced in Esri::ArcGISRuntime 100.11.
See also culture.
[override virtual]
QUrl Portal::url() const
Reimplements: RemoteResource::url() const.
Returns the URL of the portal.
If no URL has been set, it defaults to https://www.arcgis.com (ArcGIS Online).