ArcGISKit Documentation

Function update(_:​in:​gdb​Version:​)

public func update(
		_ features: [AGKFeature],
		in id: String,
		gdbVersion: String? = nil
	) 

Updates features in the FeatureLayer with the id of id.

To change the value of Greeting to "Hi!", you could write:

let layers = try await myFeatureServer
	.query(layerQueries: [.init(whereClause: "1=1", layerID: "0")])

var feature = layers[0].features[0]
feature.attributes!["Greeting"] = "Hi!"
let res = try await myFeatureServer.update([feature], in: "0")

Parameters

features [AGKFeature]

The Features you wish to update.

id String

The ID of the FeatureLayer that contains the Features you wish to update.

gdb​Version String?

The version of the geo-database you want to update features in.

Throws

AGKRequestError

Returns

[EditResponse].