
                             % S r SSKJr  SSKrSSKJr  SSKJr  SSKJ	r	  SSKJ
r  SSK
Jr  SS	K
Jr  SS
K
Jr  \R                  S:  a  \/ \R                   4   r\\S'   O\r\\S'   S\R                   S\S\4S jrg)z<Legacy code that isn't split up into resource based clients.    )CallableN)	discovery)	TypeAlias)client_project)utils)bq_error)bq_id_utils)bq_processor_utils)   	      GetApiClienFunction	apiclientget_routines_api_clientget_models_api_clientc                    [        U[        R                  R                  5      (       a  Sn[        R
                  " XS9nU H&  n[        R                  " U5      U:X  d  M  SUS'   Us  $    [        U5      U:  a  [        R                  " SU< 35      e[        R                  " SU< 3SS0/ 5      e[        U[        R                  R                  5      (       a7  U R                  5       R                  " S0 [        U5      D6R!                  5       $ [        U[        R                  R"                  5      (       aL  [        U5      n[$        R&                  US	'   U R)                  5       R                  " S0 UD6R!                  5       $ [        U[        R                  R*                  5      (       a7  U R-                  5       R                  " S0 [        U5      D6R!                  5       $ [        U[        R                  R.                  5      (       aP  U" 5       R1                  5       R                  UR2                  UR4                  UR6                  S
9R!                  5       $ [        U[        R                  R8                  5      (       aP  U" 5       R;                  5       R                  UR2                  UR4                  UR<                  S9R!                  5       $ [        R>                  " S5      e)z<Get all data returned by the server about a specific object.i  )r   max_resultszbigquery#projectkindzUNumber of projects found exceeded limit, please instead run gcloud projects describe zUnknown reasonnotFoundaccessPolicyVersion)	projectId	datasetIdmodelId)r   r   	routineIdzeType of reference must be one of: ProjectReference, JobReference, DatasetReference, or TableReference ) 
isinstancer	   ApiClientHelperProjectReferencer   list_projectsr
   ConstructObjectReferencelenr   BigqueryErrorBigqueryNotFoundErrorJobReferencejobsgetdictexecuteDatasetReferencebq_client_utils MAX_SUPPORTED_IAM_POLICY_VERSIONdatasetsTableReferencetablesModelReferencemodelsr   r   r   RoutineReferenceroutinesr   BigqueryTypeError)r   r   r   	referencemax_project_resultsprojectsprojectrequests           (platform/bq/clients/client_deprecated.pyget_object_infor;      sm    	;66GGHH++H 		4	4W	=	J,  8}++"",58  
(
(!#h
%;R  	;66CCDD>>2$y/2::<<)[88IIJJ9oG88 !" ##.g.6688)[88GGHH!!4DO4<<>>)[88GGHH		))))%% 
 


 
	 )[88IIJJ!		)))))) 
 


 
	 
$
$	<     )__doc__collections.abcr   sysgoogleapiclientr   typing_extensionsr   clientsr   r   r+   r   r	   r
   version_infoResourcer   __annotations__r;   r   r<   r:   <module>rF      s~    B $ 
 % ' " ,   $
 y #+B	0B0B,B#CyC#+y+?!!?0? /?r<   