Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
997c9f70
Kaydet (Commit)
997c9f70
authored
Ara 31, 2016
tarafından
Tim Graham
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Refs #25665 -- Removed deprecated getter/setter of Point.tuple.
üst
19d8e64a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
24 deletions
+3
-24
point.py
django/contrib/gis/geos/point.py
+0
-16
2.0.txt
docs/releases/2.0.txt
+3
-0
test_geos.py
tests/gis_tests/geos_tests/test_geos.py
+0
-8
No files found.
django/contrib/gis/geos/point.py
Dosyayı görüntüle @
997c9f70
import
warnings
from
ctypes
import
c_uint
from
django.contrib.gis
import
gdal
...
...
@@ -6,7 +5,6 @@ from django.contrib.gis.geos import prototypes as capi
from
django.contrib.gis.geos.error
import
GEOSException
from
django.contrib.gis.geos.geometry
import
GEOSGeometry
from
django.utils
import
six
from
django.utils.deprecation
import
RemovedInDjango20Warning
from
django.utils.six.moves
import
range
...
...
@@ -151,19 +149,5 @@ class Point(GEOSGeometry):
"Sets the coordinates of the point with the given tuple."
self
.
_cs
[
0
]
=
tup
def
get_coords
(
self
):
warnings
.
warn
(
"`get_coords()` is deprecated, use the `tuple` property instead."
,
RemovedInDjango20Warning
,
2
)
return
self
.
tuple
def
set_coords
(
self
,
tup
):
warnings
.
warn
(
"`set_coords()` is deprecated, use the `tuple` property instead."
,
RemovedInDjango20Warning
,
2
)
self
.
tuple
=
tup
# The tuple and coords properties
coords
=
tuple
docs/releases/2.0.txt
Dosyayı görüntüle @
997c9f70
...
...
@@ -330,3 +330,6 @@ these features.
* The ``get_x()``, ``set_x()``, ``get_y()``, ``set_y()``, ``get_z()``, and
``set_z()`` methods of ``django.contrib.gis.geos.Point`` are removed.
* The ``get_coords()`` and ``set_coords()`` methods of
``django.contrib.gis.geos.Point`` are removed.
tests/gis_tests/geos_tests/test_geos.py
Dosyayı görüntüle @
997c9f70
...
...
@@ -1316,14 +1316,6 @@ class GEOSTest(SimpleTestCase, TestDataMixin):
p
.
transform
(
2774
)
self
.
assertEqual
(
p
,
Point
(
srid
=
2774
))
@ignore_warnings
(
category
=
RemovedInDjango20Warning
)
def
test_deprecated_point_tuple_getters_setters
(
self
):
p
=
Point
(
1
,
2
,
3
)
self
.
assertEqual
(
p
.
get_coords
(),
(
p
.
x
,
p
.
y
,
p
.
z
))
p
.
set_coords
((
3
,
2
,
1
))
self
.
assertEqual
(
p
.
get_coords
(),
(
3
,
2
,
1
))
@ignore_warnings
(
category
=
RemovedInDjango20Warning
)
def
test_deprecated_cascaded_union
(
self
):
for
geom
in
self
.
geometries
.
multipolygons
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment