Below is the code which I am using to select feature but the problem is that it is not zooming or extent to that feature. How can I achieve this thing?
let queryParams = AGSQueryParameters()
queryParams.whereClause = "Name = '60 EAST BROADWAY, NEW YORK, NY ,10002'"
self.featureTable.queryFeatures(with: queryParams, completion: { [weak self] (result:AGSFeatureQueryResult?, error:Error?) -> Void in
if let error = error {
print(error.localizedDescription)
}
else if let features = result?.featureEnumerator().allObjects {
if features.count > 0 {
self?.featureLayer.select(features)
//zoom to the selected feature
self?.mapView.setViewpointCenter(features[0].geometry! as! AGSPoint, completion: nil)
}
else {
// SVProgressHUD.showError(withStatus: "No state by that name", maskType: .gradient)
}
}
})