8.2.10.4.11.8. JSONField

class JSONField(*args, **kwargs)[source]

Methods

__call__

Render this field as HTML, using keyword args as additional attributes.

__delattr__

Implement delattr(self, name).

__dir__

Default dir() implementation.

__eq__

Return self==value.

__format__

Default object formatter.

__ge__

Return self>=value.

__getattribute__

Return getattr(self, name).

__getstate__

Helper for pickle.

__gt__

Return self>value.

__hash__

Return hash(self).

__html__

Returns a HTML representation of the field.

__init__

Construct a new field.

__init_subclass__

This method is called when a class is subclassed.

__le__

Return self<=value.

__lt__

Return self<value.

__ne__

Return self!=value.

__new__

__reduce__

Helper for pickle.

__reduce_ex__

Helper for pickle.

__repr__

Return repr(self).

__setattr__

Implement setattr(self, name, value).

__sizeof__

Size of object in memory, in bytes.

__str__

Returns a HTML representation of the field.

__subclasshook__

Abstract classes can override this to customize issubclass().

_run_validation_chain

Run a validation chain, stopping if any validator raises StopValidation.

_value

check_validators

gettext

Get a translation for the given message.

ngettext

Get a translation for a message which can be pluralized.

populate_obj

Populates obj.<name> with the field's data.

post_validate

Override if you need to run any field-level validation tasks after normal validation.

pre_validate

Override if you need field-level validation.

process

Process incoming data, calling process_data, process_formdata as needed, and run filters.

process_data

Process the Python data applied to this field and store the result.

process_formdata

Process data received over the wire from a form.

validate

Validates the field and returns True or False.

__init__(label=None, validators=None, filters=(), description='', id=None, default=None, widget=None, render_kw=None, name=None, _form=None, _prefix='', _translations=None, _meta=None)

Construct a new field.

Parameters:
  • label – The label of the field.

  • validators – A sequence of validators to call when validate is called.

  • filters – A sequence of callable which are run by process() to filter or transform the input data. For example StringForm(filters=[str.strip, str.upper]). Note that filters are applied after processing the default and incoming data, but before validation.

  • description – A description for the field, typically used for help text.

  • id – An id to use for the field. A reasonable default is set by the form, and you shouldn’t need to set this manually.

  • default – The default value to assign to the field, if no form or object input is provided. May be a callable.

  • widget – If provided, overrides the widget used to render the field.

  • render_kw (dict) – If provided, a dictionary which provides default keywords that will be given to the widget at render time.

  • name – The HTML name of this field. The default value is the Python attribute name.

  • _form – The form holding this field. It is passed by the form itself during construction. You should never pass this value yourself.

  • _prefix – The prefix to prepend to the form name of this field, passed by the enclosing form during construction.

  • _translations – A translations object providing message translations. Usually passed by the enclosing form during construction. See I18n docs for information on message translations.

  • _meta – If provided, this is the ‘meta’ instance from the form. You usually don’t pass this yourself.

If _form isn’t provided, an UnboundField will be returned instead. Call its bind() method with a form instance and a name to construct the field.

Attributes

__annotations__

__dict__

__doc__

__module__

__weakref__

list of weak references to the object

_formfield

_translations

do_not_call_in_templates

errors

process_errors

raw_data

validators

widget

_value()[source]
__annotations__ = {}
__doc__ = None
__module__ = 'schedula.utils.form.server.security'