summaryrefslogtreecommitdiff
path: root/django/contrib/gis/models.py
blob: e379e82a7b3df03e49149d97670a48e1fd48b420 (plain)
1
2
3
4
5
6
7
8
9
from django.db import connection

if (hasattr(connection.ops, 'spatial_version') and
    not connection.ops.mysql):
    # Getting the `SpatialRefSys` and `GeometryColumns`
    # models for the default spatial backend.  These
    # aliases are provided for backwards-compatibility.
    SpatialRefSys = connection.ops.spatial_ref_sys()
    GeometryColumns = connection.ops.geometry_columns()