コード例 #1
0
        private bool TryParseLineString(RavenJObject obj, out object result)
        {
            RavenJToken coord;

            if (obj.TryGetValue("coordinates", out coord))
            {
                var coordinates = coord as RavenJArray;
                CoordinateInfo[] co;
                if (coordinates != null && TryParseCoordinateArray(coordinates, out co))
                {
                    result = _shapeConverter.ToLineString(co);
                    return(true);
                }
            }
            result = null;
            return(false);
        }
コード例 #2
0
        private object ParseLineStringInner(WktTokenQueue tokens, Dimensions dimensions)
        {
            var coords = ParseCoordinateSequence(tokens, dimensions);

            return(_shapeConverter.ToLineString(coords ?? new CoordinateInfo[0]));
        }