core.signing.TimestampSigner.sign()

sign(value) [source] Sign value and append current timestamp to it.

core.validators.EmailValidator.code

code The error code used by ValidationError if validation fails. Defaults to "invalid".

core.signing.Signer

class Signer(key=None, sep=':', salt=None) [source] Returns a signer which uses key to generate signatures and sep to separate values. sep cannot be in the URL safe base64 alphabet. This alphabet contains alphanumeric characters, hyphens, and underscores.

core.serializers.json.DjangoJSONEncoder

class django.core.serializers.json.DjangoJSONEncoder The JSON serializer uses DjangoJSONEncoder for encoding. A subclass of JSONEncoder, it handles these additional types:

core.serializers.get_serializer()

django.core.serializers.get_serializer(format) You can also use a serializer object directly: XMLSerializer = serializers.get_serializer("xml") xml_serializer = XMLSerializer() xml_serializer.serialize(queryset) data = xml_serializer.getvalue() This is useful if you want to serialize data directly to a file-like object (which includes an HttpResponse): with open("file.xml", "w") as out: xml_serializer.serialize(SomeModel.objects.all(), stream=out) Note Calling get_serializer() with an

core.signing.loads()

loads(string, key=None, salt='django.core.signing', max_age=None) [source] Reverse of dumps(), raises BadSignature if signature fails. Checks max_age (in seconds) if given.

core.signing.dumps()

dumps(obj, key=None, salt='django.core.signing', compress=False) [source] Returns URL-safe, sha1 signed base64 compressed JSON string. Serialized object is signed using TimestampSigner.

core.paginator.Paginator.page_range

Paginator.page_range A 1-based range iterator of page numbers, e.g. yielding [1, 2, 3, 4]. Changed in Django 1.9: In older versions, page_range returned a list instead of an iterator.

core.paginator.Paginator.page()

Paginator.page(number) [source] Returns a Page object with the given 1-based index. Raises InvalidPage if the given page number doesn’t exist.

core.paginator.Page.start_index()

Page.start_index() [source] Returns the 1-based index of the first object on the page, relative to all of the objects in the paginator’s list. For example, when paginating a list of 5 objects with 2 objects per page, the second page’s start_index() would return 3.