Uploaded image for project: 'Couchbase Documentation'
  1. Couchbase Documentation
  2. DOC-7815

Missing SDK sample geoSpatial code samples

    XMLWordPrintable

Details

    Description

      Missing SDK sample geoSpatial code samples here or into the SDK pages.

      Reporter: Jose Molina
      E-mail: jose.molina@couchbase.com

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            jose.molina Jose Molina created issue -
            richard.smedley Richard Smedley made changes -
            Field Original Value New Value
            Link This issue relates to DOC-7429 [ DOC-7429 ]
            richard.smedley Richard Smedley made changes -
            Component/s server dev guide and SDKs [ 11814 ]
            Fix Version/s sdk3.1-backlog [ 17244 ]
            Story Points 1
            Assignee Amarantha Kulkarni [ amarantha.kulkarni ] Richard Smedley [ richard smedley ]
            Priority Test Blocker [ 6 ]
            jose.molina Jose Molina added a comment - - edited

            What I was missing is having more practical information on the SDK pages. Something similar to https://blog.couchbase.com/how-to-geospatial-polygon-search/ & https://blog.couchbase.com/taming-the-gerrymander-with-geospatial-search/ . 

            Additionally, we should remark that polygon search was introduced into SDK +3.1 versions. 

            Here is a sample code, where you can see the input is a list of Coordinate and the class is GeoPolygonQuery for example. 

             

            public List<SearchRow> spatialSearch(List<Coordinate> polygon)
            {    
                   GeoPolygonQuery query = SearchQuery.geoPolygon(polygon);    
                   return cluster.searchQuery(GEOSPATIAL_INDEX_NAME, query).rows();
            }
            

             

            jose.molina Jose Molina added a comment - - edited What I was missing is having more practical information on the SDK pages. Something similar to https://blog.couchbase.com/how-to-geospatial-polygon-search/  & https://blog.couchbase.com/taming-the-gerrymander-with-geospatial-search/  .  Additionally, we should remark that polygon search was introduced into SDK +3.1 versions.  Here is a sample code, where you can see the input is a list of Coordinate and the class is GeoPolygonQuery for example.    public List<SearchRow> spatialSearch(List<Coordinate> polygon) {            GeoPolygonQuery query = SearchQuery.geoPolygon(polygon);             return cluster.searchQuery(GEOSPATIAL_INDEX_NAME, query).rows(); }  
            richard.smedley Richard Smedley made changes -
            Epic Link DOC-8196 [ 152156 ]
            Fix Version/s sdk3.2-backlog [ 17245 ]
            Labels collector-709818cb collector-709818cb fts search
            richard.smedley Richard Smedley made changes -
            Labels collector-709818cb fts search SDKDOC-improvement collector-709818cb fts search

            People

              richard.smedley Richard Smedley
              jose.molina Jose Molina
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty