def generate_presigned_url(self, ClientMethod, Params=None, ExpiresIn=3600, HttpMethod=None):
 client_method = ClientMethod
 params = Params
 expires_in = ExpiresIn
 http_method = HttpMethod
 request_signer = self._request_signer
 serializer = self._serializer
 try:
  operation_name = self._PY_TO_OP_NAME[client_method]
 except KeyError:
  raise UnknownClientMethodError(method_name=client_method)
 operation_model = self.meta.service_model.operation_model(operation_name)
 request_dict = serializer.serialize_to_request(params, operation_model)
 if (http_method is not None):
  request_dict['method'] = http_method
 prepare_request_dict(request_dict, endpoint_url=self.meta.endpoint_url)
 return request_signer.generate_presigned_url(request_dict=request_dict, expires_in=expires_in, operation_name=operation_name)

def generate_presigned_url ( self , ClientMethod , Params = None , ExpiresIn = 3600 , HttpMethod = None ) : client_method = ClientMethod params = Params expires_in = ExpiresIn http_method = HttpMethod request_signer = self . _request_signer serializer = self . _serializer try : operation_name = self . _PY_TO_OP_NAME [ client_method ] except KeyError : raise UnknownClientMethodError ( method_name = client_method ) operation_model = self . meta . service_model . operation_model ( operation_name ) request_dict = serializer . serialize_to_request ( params , operation_model ) if ( http_method is not None ) : request_dict [ 'method' ] = http_method prepare_request_dict ( request_dict , endpoint_url = self . meta . endpoint_url ) return request_signer . generate_presigned_url ( request_dict = request_dict , expires_in = expires_in , operation_name = operation_name )
generate a presigned url given a client .