2009-07-09 11:29:04 -03:00
|
|
|
.. _ref-newitem-fields:
|
|
|
|
|
|
|
|
====================
|
|
|
|
Item Field Reference
|
|
|
|
====================
|
|
|
|
|
|
|
|
.. module:: scrapy.contrib_exp.newitem.fields
|
|
|
|
|
|
|
|
Field options
|
|
|
|
=============
|
|
|
|
|
|
|
|
``default``
|
|
|
|
-----------
|
|
|
|
|
|
|
|
.. attribute:: Field.default
|
|
|
|
|
|
|
|
The default value for the field.
|
|
|
|
|
|
|
|
|
|
|
|
Field types
|
|
|
|
===========
|
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
StringField
|
|
|
|
-----------
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. class:: StringField
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
A text field.
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
IntegerField
|
|
|
|
------------
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. class:: IntegerField
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
An integer.
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
DecimalField
|
|
|
|
------------
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. class:: DecimalField
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
A fixed-precision decimal number, represented in Python by a `Decimal`_
|
|
|
|
instance.
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. _Decimal: http://docs.python.org/library/decimal.html#decimal.Decimal
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
FloatField
|
|
|
|
----------
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. class:: FloatField
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
A floating-point number represented in Python by a ``float`` instance.
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
BooleanField
|
|
|
|
------------
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. class:: BooleanField
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
A boolean (true/false) field.
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
DateTimeField
|
|
|
|
-------------
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. class:: DateTimeField
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
A date with time, represented in Python by a `datetime.datetime`_ instance.
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. _datetime.datetime: http://docs.python.org/library/datetime.html#datetime.datetime
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
DateField
|
|
|
|
---------
|
|
|
|
|
|
|
|
.. class:: DateField
|
|
|
|
|
|
|
|
A date, represented in Python by a `datetime.date`_ instance.
|
2009-07-09 11:29:04 -03:00
|
|
|
|
2009-07-11 21:26:52 -03:00
|
|
|
.. _datetime.date: http://docs.python.org/library/datetime.html#datetime.date
|
2009-07-09 11:29:04 -03:00
|
|
|
|