<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How do I search a portal for sync enabled webmaps? in ArcGIS Runtime SDK for Android Questions</title>
    <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-do-i-search-a-portal-for-sync-enabled-webmaps/m-p/654076#M4516</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Part of&amp;nbsp;my application&amp;nbsp;involves searching a portal for a list of portals items.&amp;nbsp; I&amp;nbsp;would like to list only the webmaps that include a Geodatabase that isSyncEnabled().&amp;nbsp; The most direct way to do this would be with the PortalQueryParameters.&amp;nbsp; Limiting the query to just webmaps is straight forward using the constructor that takes a vector of PortalItem.Type as the first parameter.&amp;nbsp; Is there a way to use the searchQuerry string to limit it to just webmaps that include a sync enabled geodatabase?&amp;nbsp; Or just to those that support offline use?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If&amp;nbsp;PortalQueryParamters&amp;nbsp;doesn't work, is there a way to check the PortalItems?&amp;nbsp; I know that I can find out if they support offline use:&amp;nbsp; OfflineMapTask(PortalItem).getOfflineMapCapabilitiesAsync() ---&amp;gt; getLayerCapabilities&lt;SPAN style="color: #353833; background-color: #ffffff;"&gt;() --&amp;gt; isSupportsOffline().&amp;nbsp; That helps, but offline use doesn't necessarily mean they support sync.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #353833; background-color: #ffffff;"&gt;The isSyncEnabled() method appears in two places in the documentation: Geodatabase::isSyncEnabled(), and ArcGISFeatureServiceInfo::isSyncEnabled().&amp;nbsp; It appears (from the single documented constructor) that a geodatabse can only be constructed from a local file after downloading the geodatabase (impractical).&amp;nbsp; And ArcGISFeatureServiceInfo has no documented constructors, appears nowhere in the documentation except its own page, and is a final class that extends Object.&amp;nbsp; So, from what I can tell, developers have no access to it.&amp;nbsp; Am I missing something here?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 17 Aug 2020 11:39:02 GMT</pubDate>
    <dc:creator>OrrinThomas</dc:creator>
    <dc:date>2020-08-17T11:39:02Z</dc:date>
    <item>
      <title>How do I search a portal for sync enabled webmaps?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-do-i-search-a-portal-for-sync-enabled-webmaps/m-p/654076#M4516</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Part of&amp;nbsp;my application&amp;nbsp;involves searching a portal for a list of portals items.&amp;nbsp; I&amp;nbsp;would like to list only the webmaps that include a Geodatabase that isSyncEnabled().&amp;nbsp; The most direct way to do this would be with the PortalQueryParameters.&amp;nbsp; Limiting the query to just webmaps is straight forward using the constructor that takes a vector of PortalItem.Type as the first parameter.&amp;nbsp; Is there a way to use the searchQuerry string to limit it to just webmaps that include a sync enabled geodatabase?&amp;nbsp; Or just to those that support offline use?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If&amp;nbsp;PortalQueryParamters&amp;nbsp;doesn't work, is there a way to check the PortalItems?&amp;nbsp; I know that I can find out if they support offline use:&amp;nbsp; OfflineMapTask(PortalItem).getOfflineMapCapabilitiesAsync() ---&amp;gt; getLayerCapabilities&lt;SPAN style="color: #353833; background-color: #ffffff;"&gt;() --&amp;gt; isSupportsOffline().&amp;nbsp; That helps, but offline use doesn't necessarily mean they support sync.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #353833; background-color: #ffffff;"&gt;The isSyncEnabled() method appears in two places in the documentation: Geodatabase::isSyncEnabled(), and ArcGISFeatureServiceInfo::isSyncEnabled().&amp;nbsp; It appears (from the single documented constructor) that a geodatabse can only be constructed from a local file after downloading the geodatabase (impractical).&amp;nbsp; And ArcGISFeatureServiceInfo has no documented constructors, appears nowhere in the documentation except its own page, and is a final class that extends Object.&amp;nbsp; So, from what I can tell, developers have no access to it.&amp;nbsp; Am I missing something here?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Aug 2020 11:39:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-do-i-search-a-portal-for-sync-enabled-webmaps/m-p/654076#M4516</guid>
      <dc:creator>OrrinThomas</dc:creator>
      <dc:date>2020-08-17T11:39:02Z</dc:date>
    </item>
    <item>
      <title>Re: How do I search a portal for sync enabled webmaps?</title>
      <link>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-do-i-search-a-portal-for-sync-enabled-webmaps/m-p/654077#M4517</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Orrin,&lt;/P&gt;&lt;P&gt;I'm sorry I can't speak to all of your points, however the following snippet may help you you access to `isSyncEnabled`. &lt;SPAN style="font-size: 11.0pt;"&gt;Bear in mind (and test) the load time of each of the Loadable objects in your environment) and the quantity of WebMaps and ServiceFeatureTables you are searching before you settle on this method. The following is untested: &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;```&lt;/P&gt;&lt;P&gt;ArcGISMap map = new ArcGISMap(portalItem);&lt;/P&gt;&lt;P&gt;...load map&lt;/P&gt;&lt;P&gt;List&amp;lt;Layer&amp;gt; layers = map.getOperationalLayers();&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;for (Layer layer : layers) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (layer instanceof FeatureLayer) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (((FeatureLayer)layer).getFeatureTable() != null) { // assume, may need to load FeatureLayer&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; FeatureTable table = ((FeatureLayer)layer).getFeatureTable(); &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (table instanceof ServiceFeatureTable) {&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (((ServiceFeatureTable)table).getUri() != null) { // assume, should not need to load ServiceFeatureTable&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // assume we get "..\FeatureServer\0", then remove "\n" to get "..FeatureServer"&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // if we didn't already look this server up, then look it up now&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if (!fetched(featureServer)) {&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; // Create and load a GeodatabaseSyncTask&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; GeodatabaseSyncTask syncTask = new GeodatabaseSyncTask("https://xxxxxxx.FeatureServer");&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ... load&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; boolean isSyncEnabled = syncTask.getFeatureServiceInfo().isSyncEnabled();&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;```&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Gayle.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 29 Sep 2020 12:00:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-runtime-sdk-for-android-questions/how-do-i-search-a-portal-for-sync-enabled-webmaps/m-p/654077#M4517</guid>
      <dc:creator>GayleYoung</dc:creator>
      <dc:date>2020-09-29T12:00:20Z</dc:date>
    </item>
  </channel>
</rss>

