db.models.Field.deconstruct()

deconstruct() [source] Returns a 4-tuple with enough information to recreate the field: The name of the field on the model. The import path of the field (e.g. "django.db.models.IntegerField"). This should be the most portable version, so less specific may be better. A list of positional arguments. A dict of keyword arguments. This method must be added to fields prior to 1.7 to migrate its data using Migrations.

db.models.query.QuerySet.distinct()

distinct(*fields) Returns a new QuerySet that uses SELECT DISTINCT in its SQL query. This eliminates duplicate rows from the query results. By default, a QuerySet will not eliminate duplicate rows. In practice, this is rarely a problem, because simple queries such as Blog.objects.all() don’t introduce the possibility of duplicate result rows. However, if your query spans multiple tables, it’s possible to get duplicate results when a QuerySet is evaluated. That’s when you’d use distinct(). N

db.models.DateField

class DateField(auto_now=False, auto_now_add=False, **options) [source] A date, represented in Python by a datetime.date instance. Has a few extra, optional arguments:

admin.ModelAdmin.get_urls()

ModelAdmin.get_urls() [source] The get_urls method on a ModelAdmin returns the URLs to be used for that ModelAdmin in the same way as a URLconf. Therefore you can extend them as documented in URL dispatcher: class MyModelAdmin(admin.ModelAdmin): def get_urls(self): urls = super(MyModelAdmin, self).get_urls() my_urls = [ url(r'^my_view/$', self.my_view), ] return my_urls + urls def my_view(self, request): # ... context = dic

forms.NullBooleanSelect

class NullBooleanSelect [source] Select widget with options ‘Unknown’, ‘Yes’ and ‘No’

gis.geos.GEOSGeometry.convex_hull

GEOSGeometry.convex_hull Returns the smallest Polygon that contains all the points in the geometry.

core.files.storage.Storage.open()

open(name, mode='rb') [source] Opens the file given by name. Note that although the returned file is guaranteed to be a File object, it might actually be some subclass. In the case of remote file storage this means that reading/writing could be quite slow, so be warned.

gis.gdal.OGRGeomType.django

django Returns the Django field type (a subclass of GeometryField) to use for storing this OGR type, or None if there is no appropriate Django type: >>> gt1.django 'PolygonField'

http.HttpResponse.writelines()

HttpResponse.writelines(lines) [source] Writes a list of lines to the response. Line separators are not added. This method makes an HttpResponse instance a stream-like object.

gis.gdal.Envelope.max_y

max_y The value of the maximum Y coordinate.