+
    Tj                     D    ^ RI Ht ^ RIHt ^ RIHtHt  ! R R]4      tR# )    )GeometryField)DatabaseSchemaEditor)ColFuncc                      a a ] tR t^t oRtRtRtRtRtR t	V 3R lt
RR	/V 3R
 lltV 3R ltRV 3R lltR tV 3R ltR tRtVtV ;t# )PostGISSchemaEditorGISTGIST_GEOMETRY_OPS_NDzST_ConvexHull(%(expressions)s)zLALTER COLUMN %(column)s TYPE %(type)s USING ST_Force3D(%(column)s)::%(type)szLALTER COLUMN %(column)s TYPE %(type)s USING ST_Force2D(%(column)s)::%(type)sc                L    V P                   P                  P                  V4      # N)
connectionopsgeo_quote_name)selfnames   &&b/var/www/idalgo/venv/lib/python3.14/site-packages/django/contrib/gis/db/backends/postgis/schema.pyr   "PostGISSchemaEditor.geo_quote_name   s    ""11$77    c                L   < \        VR R4      '       d   R# \        SV `	  W4      # )spatial_indexFT)getattrsuper_field_should_be_indexed)r   modelfield	__class__s   &&&r   r   ,PostGISSchemaEditor._field_should_be_indexed   s%    5/511w/==r   fieldsNc                  < Ve*   \        V4      ^8w  g   \        V^ ,          R4      '       g   \        SV `  ! V3RV/VB # V P                  ! W^ ,          3/ VB # )Ngeodeticr   )lenhasattrr   _create_index_sql_create_spatial_index_sql)r   r   r   kwargsr   s   &&$,r   r#   %PostGISSchemaEditor._create_index_sql   sW    >S[A-WVAY
5S5S7,UL6LVLL--eAYI&IIr   c                  < \        VR4      '       d   \        VR4      '       g   \        SV `	  WW4WV4      # VP                  ^8X  d   VP                  ^8X  d   V P                  pM;VP                  ^8X  d   VP                  ^8X  d   V P
                  pMV P                  pVRV P                  VP                  4      RVRR/,          . 3. 3# )z&
Special case when dimension changed.
dimcolumntype	collation )	r"   r   _alter_column_type_sqlr(   sql_alter_column_to_3dsql_alter_column_to_2dsql_alter_column_type
quote_namer)   )	r   table	old_field	new_fieldnew_typeold_collationnew_collation	sql_alterr   s	   &&&&&&& r   r-   *PostGISSchemaEditor._alter_column_type_sql    s     y%((	50I0I71)}  ==A)--1"433I]]aIMMQ$633I22I dooi.>.>?H  
 	
r   c	                  < \         SV `  VVVVVVVVR 7       \        V\        4      ;'       d    VP                  p	\        V\        4      ;'       d    VP                  p
V	'       g+   V
'       d#   V P                  V P                  W4      4       R# V	'       d-   V
'       g#   V P                  V P                  W4      4       R# R# R# ))strictN)r   _alter_field
isinstancer   r   executer$   _delete_spatial_index_sql)r   r   r3   r4   old_typer5   old_db_paramsnew_db_paramsr;   old_field_spatial_indexnew_field_spatial_indexr   s   &&&&&&&&&  r   r<    PostGISSchemaEditor._alter_field>   s     	 	 		
 y-0LLY5L5L 	  y-0LLY5L5L 	  '+BLL77IJ$-DLL77IJ .E$r   c                f    V P                  VP                  P                  VP                  .R 4      # )_id)_create_index_name_metadb_tabler)   )r   r   r   s   &&&r   _create_spatial_index_name.PostGISSchemaEditor._create_spatial_index_name_   s'    &&u{{';';ell^USSr   c           	     |  < R pR pV.pVP                   R8X  d%   \        \        R V4      V P                  R7      pR pM0VP                  ^8  d    VP
                  '       g   V P                  .pVP                  R4      ;p'       g   V P                  W4      p\        SV `)  VVVRV P                  ,          VVR7      # )NRASTER)templater   z	 USING %s)r   r   using	opclassesexpressions)	geom_typer   r   rast_index_templater(   	geographygeom_index_ops_ndgetrK   r   r#   geom_index_type)	r   r   r   r%   rR   rQ   r   r   r   s	   &&&,    r   r$   -PostGISSchemaEditor._create_spatial_index_sqlb   s    	??h& s4/$:R:RSKFYY]5???//0I

6***225@Dw( 4 44# ) 
 	
r   c                F    V P                  W4      pV P                  W4      # r   )rK   _delete_index_sql)r   r   r   
index_names   &&& r   r?   -PostGISSchemaEditor._delete_spatial_index_sql{   s#    44UB
%%e88r    )F)__name__
__module____qualname____firstlineno__rX   rV   rT   r.   r/   r   r   r#   r-   r<   rK   r$   r?   __static_attributes____classdictcell____classcell__)r   __classdict__s   @@r   r   r      se     O.: 	W  	W 8>
J J
<KBT
29 9r   r   N)django.contrib.gis.db.modelsr   $django.db.backends.postgresql.schemar   django.db.models.expressionsr   r   r   r^   r   r   <module>rj      s    6 E 2w9. w9r   