saveAs

suspend fun saveAs(portal: Portal, folder: PortalFolder?, title: String, description: String, tags: Iterable<String>, thumbnail: BitmapDrawable?): Result<Unit>

Saves this feature collection as a new feature collection item on the specified portal with the given title in the given folder.

Once completed, FeatureCollection.item will be populated with the new portal item. Note that if the feature collection already has a valid item property (either because the feature collection was created using an item or was previously saved), that property will be replaced with a new item, effectively duplicating the feature collection on the portal.

Return

a Result indicating whether the feature collection was successfully saved. The result will be a failure with type:

Since

200.2.0

Parameters

portal

The portal to save the feature collection to.

folder

The folder in which to save the feature collection. If null, it will be added to the user's root folder.

title

The title of the feature collection.

description

The description of the feature collection.

tags

The tags to be associated with the newly created portal item.

thumbnail

The thumbnail of the feature collection.