コード例 #1
0
        private async Task <Feature> UpdateElasticSearch(ICompleteOsmGeo osm, string name)
        {
            var feature = ConvertOsmToFeature(osm, name);

            if (feature != null)
            {
                await _elasticSearchGateway.UpdateNamesData(feature);
            }
            return(feature);
        }
コード例 #2
0
        private async Task <Feature> UpdateElasticSearch(ICompleteOsmGeo osm, string name)
        {
            var features = _osmGeoJsonPreprocessorExecutor.Preprocess(
                new Dictionary <string, List <ICompleteOsmGeo> >
            {
                { name, new List <ICompleteOsmGeo> {
                      osm
                  } }
            });
            var feature = features.Values.FirstOrDefault()?.FirstOrDefault();

            if (feature != null)
            {
                await _elasticSearchGateway.UpdateNamesData(feature);
            }
            return(feature);
        }