Beispiel #1
0
        private RestAPIFeature <Polygon, RestAPITestAttributeModel> CreateSingleFeature()
        {
            var testName = CreateFeatureName();

            var ring = new Ring(new List <SimplePoint> {
                this._point1, this._point2, this._point3, this._point1
            });
            var polygonToAdd = new Polygon(new List <Ring> {
                ring
            });

            var attributesToAdd = new RestAPITestAttributeModel
            {
                Name        = testName,
                Description = testName
            };

            var featureToAdd = new RestAPIFeature <Polygon, RestAPITestAttributeModel>
            {
                Attributes = attributesToAdd,
                Geometry   = polygonToAdd
            };

            return(featureToAdd);
        }
		private RestAPIFeature<Polygon, RestAPITestAttributeModel> CreateSingleFeature()
		{
			var testName = CreateFeatureName();

			var ring = new Ring(new List<SimplePoint> { this._point1, this._point2, this._point3, this._point1 });
			var polygonToAdd = new Polygon(new List<Ring> { ring });

			var attributesToAdd = new RestAPITestAttributeModel
			{
				Name = testName,
				Description = testName
			};

			var featureToAdd = new RestAPIFeature<Polygon, RestAPITestAttributeModel>
			{
				Attributes = attributesToAdd,
				Geometry = polygonToAdd
			};

			return featureToAdd;
		}