nodes: 0, module; 1, function_definition; 2, function_name:find; 3, parameters; 4, block; 5, identifier:self; 6, identifier:text; 7, default_parameter; 8, default_parameter; 9, default_parameter; 10, default_parameter; 11, default_parameter; 12, default_parameter; 13, default_parameter; 14, default_parameter; 15, default_parameter; 16, default_parameter; 17, expression_statement; 18, if_statement; 19, identifier:magicKey; 20, None; 21, identifier:sourceCountry; 22, None; 23, identifier:bbox; 24, None; 25, identifier:location; 26, None; 27, identifier:distance; 28, float:3218.69; 29, identifier:outSR; 30, integer:102100; 31, identifier:category; 32, None; 33, identifier:outFields; 34, string:"*"; 35, identifier:maxLocations; 36, integer:20; 37, identifier:forStorage; 38, False; 39, comment:"""
          The find operation geocodes one location per request; the input
          address is specified in a single parameter.
  
          Inputs:
             text - Specifies the location to be geocoded. This can be a
              street address, place name, postal code, or POI.
             magicKey - The find operation retrieves results quicker when you
              pass in valid text and magicKey values than when you don't pass
              in magicKey. However, to get these advantages, you need to make
              a prior request to suggest, which provides a magicKey. This may
              or may not be relevant to your workflow.
             sourceCountry - A value representing the country. Providing this
              value increases geocoding speed. Acceptable values include the
              full country name in English or the official language of the
              country, the ISO 3166-1 2-digit country code, or the
              ISO 3166-1 3-digit country code.
             bbox - A set of bounding box coordinates that limit the search
              area to a specific region. This is especially useful for
              applications in which a user will search for places and
              addresses only within the current map extent.
             location - Defines an origin point location that is used with
              the distance parameter to sort geocoding candidates based upon
              their proximity to the location. The distance parameter
              specifies the radial distance from the location in meters. The
              priority of candidates within this radius is boosted relative
              to those outside the radius.
             distance - Specifies the radius of an area around a point
              location which is used to boost the rank of geocoding
              candidates so that candidates closest to the location are
              returned first. The distance value is in meters.
             outSR - The spatial reference of the x/y coordinates returned by
              a geocode request. This is useful for applications using a map
              with a spatial reference different than that of the geocode
              service.
             category - A place or address type which can be used to filter
              find results. The parameter supports input of single category
              values or multiple comma-separated values. The category
              parameter can be passed in a request with or without the text
              parameter.
             outFields - The list of fields to be returned in the response.
             maxLocation - The maximum number of locations to be returned by
              a search, up to the maximum number allowed by the service. If
              not specified, then one location will be returned.
             forStorage - Specifies whether the results of the operation will
              be persisted. The default value is false, which indicates the
              results of the operation can't be stored, but they can be
              temporarily displayed on a map for instance. If you store the
              results, in a database for example, you need to set this
              parameter to true.
          """; 40, call; 41, block; 42, else_clause; 43, identifier:isinstance; 44, argument_list; 45, expression_statement; 46, expression_statement; 47, if_statement; 48, if_statement; 49, if_statement; 50, if_statement; 51, if_statement; 52, if_statement; 53, if_statement; 54, if_statement; 55, if_statement; 56, return_statement; 57, block; 58, attribute; 59, tuple; 60, assignment; 61, assignment; 62, not_operator; 63, block; 64, not_operator; 65, block; 66, not_operator; 67, block; 68, not_operator; 69, block; 70, not_operator; 71, block; 72, not_operator; 73, block; 74, comparison_operator:outFields is None; 75, block; 76, else_clause; 77, not_operator; 78, block; 79, not_operator; 80, block; 81, call; 82, raise_statement; 83, identifier:self; 84, identifier:_securityHandler; 85, identifier:AGOLTokenSecurityHandler; 86, identifier:OAuthSecurityHandler; 87, identifier:url; 88, binary_operator:self._url + "/find"; 89, identifier:params; 90, dictionary; 91, comparison_operator:magicKey is None; 92, expression_statement; 93, comparison_operator:sourceCountry is None; 94, expression_statement; 95, comparison_operator:bbox is None; 96, expression_statement; 97, comparison_operator:location is None; 98, if_statement; 99, if_statement; 100, if_statement; 101, comparison_operator:outSR is None; 102, expression_statement; 103, comparison_operator:category is None; 104, expression_statement; 105, identifier:outFields; 106, None; 107, expression_statement; 108, block; 109, comparison_operator:maxLocations is None; 110, expression_statement; 111, comparison_operator:forStorage is None; 112, expression_statement; 113, attribute; 114, argument_list; 115, call; 116, attribute; 117, string:"/find"; 118, pair; 119, pair; 120, comment:#"token" : self._securityHandler.token; 121, identifier:magicKey; 122, None; 123, assignment; 124, identifier:sourceCountry; 125, None; 126, assignment; 127, identifier:bbox; 128, None; 129, assignment; 130, identifier:location; 131, None; 132, call; 133, block; 134, call; 135, block; 136, not_operator; 137, block; 138, identifier:outSR; 139, None; 140, assignment; 141, identifier:category; 142, None; 143, assignment; 144, assignment; 145, expression_statement; 146, identifier:maxLocations; 147, None; 148, assignment; 149, identifier:forStorage; 150, None; 151, assignment; 152, identifier:self; 153, identifier:_post; 154, keyword_argument; 155, keyword_argument; 156, keyword_argument; 157, keyword_argument; 158, keyword_argument; 159, identifier:Exception; 160, argument_list; 161, identifier:self; 162, identifier:_url; 163, string:"f"; 164, string:"json"; 165, string:"text"; 166, identifier:text; 167, subscript; 168, identifier:magicKey; 169, subscript; 170, identifier:sourceCountry; 171, subscript; 172, identifier:bbox; 173, identifier:isinstance; 174, argument_list; 175, expression_statement; 176, identifier:isinstance; 177, argument_list; 178, expression_statement; 179, comparison_operator:distance is None; 180, expression_statement; 181, subscript; 182, identifier:outSR; 183, subscript; 184, identifier:category; 185, subscript; 186, string:"*"; 187, assignment; 188, subscript; 189, identifier:maxLocations; 190, subscript; 191, identifier:forStorage; 192, identifier:url; 193, identifier:url; 194, identifier:param_dict; 195, identifier:params; 196, identifier:securityHandler; 197, attribute; 198, identifier:proxy_url; 199, attribute; 200, identifier:proxy_port; 201, attribute; 202, string:"This function works on the ArcGIS Online World Geocoder"; 203, identifier:params; 204, string; 205, identifier:params; 206, string; 207, identifier:params; 208, string; 209, identifier:location; 210, identifier:Point; 211, assignment; 212, identifier:location; 213, identifier:list; 214, assignment; 215, identifier:distance; 216, None; 217, assignment; 218, identifier:params; 219, string; 220, identifier:params; 221, string; 222, identifier:params; 223, string; 224, subscript; 225, identifier:outFields; 226, identifier:params; 227, string; 228, identifier:params; 229, string; 230, identifier:self; 231, identifier:_securityHandler; 232, identifier:self; 233, identifier:_proxy_url; 234, identifier:self; 235, identifier:_proxy_port; 236, string_content:magicKey; 237, string_content:sourceCountry; 238, string_content:bbox; 239, subscript; 240, attribute; 241, subscript; 242, binary_operator:"%s,%s" % (location[0], location[1]); 243, subscript; 244, identifier:distance; 245, string_content:outSR; 246, string_content:category; 247, string_content:outFields; 248, identifier:params; 249, string; 250, string_content:maxLocations; 251, string_content:forStorage; 252, identifier:params; 253, string; 254, identifier:location; 255, identifier:asDictionary; 256, identifier:params; 257, string; 258, string:"%s,%s"; 259, tuple; 260, identifier:params; 261, string; 262, string_content:outFields; 263, string_content:location; 264, string_content:location; 265, subscript; 266, subscript; 267, string_content:distance; 268, identifier:location; 269, integer:0; 270, identifier:location; 271, integer:1
code: def find(self,
               text,
               magicKey=None,
               sourceCountry=None,
               bbox=None,
               location=None,
               distance=3218.69,
               outSR=102100,
               category=None,
               outFields="*",
               maxLocations=20,
               forStorage=False):
          """
          The find operation geocodes one location per request; the input
          address is specified in a single parameter.
  
          Inputs:
             text - Specifies the location to be geocoded. This can be a
              street address, place name, postal code, or POI.
             magicKey - The find operation retrieves results quicker when you
              pass in valid text and magicKey values than when you don't pass
              in magicKey. However, to get these advantages, you need to make
              a prior request to suggest, which provides a magicKey. This may
              or may not be relevant to your workflow.
             sourceCountry - A value representing the country. Providing this
              value increases geocoding speed. Acceptable values include the
              full country name in English or the official language of the
              country, the ISO 3166-1 2-digit country code, or the
              ISO 3166-1 3-digit country code.
             bbox - A set of bounding box coordinates that limit the search
              area to a specific region. This is especially useful for
              applications in which a user will search for places and
              addresses only within the current map extent.
             location - Defines an origin point location that is used with
              the distance parameter to sort geocoding candidates based upon
              their proximity to the location. The distance parameter
              specifies the radial distance from the location in meters. The
              priority of candidates within this radius is boosted relative
              to those outside the radius.
             distance - Specifies the radius of an area around a point
              location which is used to boost the rank of geocoding
              candidates so that candidates closest to the location are
              returned first. The distance value is in meters.
             outSR - The spatial reference of the x/y coordinates returned by
              a geocode request. This is useful for applications using a map
              with a spatial reference different than that of the geocode
              service.
             category - A place or address type which can be used to filter
              find results. The parameter supports input of single category
              values or multiple comma-separated values. The category
              parameter can be passed in a request with or without the text
              parameter.
             outFields - The list of fields to be returned in the response.
             maxLocation - The maximum number of locations to be returned by
              a search, up to the maximum number allowed by the service. If
              not specified, then one location will be returned.
             forStorage - Specifies whether the results of the operation will
              be persisted. The default value is false, which indicates the
              results of the operation can't be stored, but they can be
              temporarily displayed on a map for instance. If you store the
              results, in a database for example, you need to set this
              parameter to true.
          """
          if isinstance(self._securityHandler, (AGOLTokenSecurityHandler, OAuthSecurityHandler)):
              url = self._url + "/find"
              params = {
                  "f" : "json",
                  "text" : text,
                  #"token" : self._securityHandler.token
              }
              if not magicKey is None:
                  params['magicKey'] = magicKey
              if not sourceCountry is None:
                  params['sourceCountry'] = sourceCountry
              if not bbox is None:
                  params['bbox'] = bbox
              if not location is None:
                  if isinstance(location, Point):
                      params['location'] = location.asDictionary
                  if isinstance(location, list):
                      params['location'] = "%s,%s" % (location[0], location[1])
                  if not distance is None:
                      params['distance'] = distance
              if not outSR is None:
                  params['outSR'] = outSR
              if not category is None:
                  params['category'] = category
              if outFields is None:
                  params['outFields'] = "*"
              else:
                  params['outFields'] = outFields
              if not maxLocations is None:
                  params['maxLocations'] = maxLocations
              if not forStorage is None:
                  params['forStorage'] = forStorage
              return self._post(url=url,
                                   param_dict=params,
                                   securityHandler=self._securityHandler,
                                   proxy_url=self._proxy_url,
                                   proxy_port=self._proxy_port)
          else:
              raise Exception("This function works on the ArcGIS Online World Geocoder")