corrected naming and references in ref/spiders doc

--HG--
extra : convert_revision : svn%3Ab85faa78-f9eb-468e-a121-7cced6da292c%40817
This commit is contained in:
Ismael Carnales 2009-01-31 06:01:33 +00:00
parent 6220609718
commit fa8ebd1147
2 changed files with 8 additions and 9 deletions

View File

@ -4,7 +4,7 @@
Available Spiders
=================
.. module:: scrapy.item
.. module:: scrapy.spider
BaseSpider
==========
@ -186,7 +186,6 @@ links, and item links, parsing the latter with the *parse_item* method. For
each item response, some data will be extracted from the HTML using XPath, and
a ScrapedItem will be filled with it.
XMLFeedSpider
=============
@ -284,19 +283,19 @@ prints them out, and stores some random data in ScrapedItems.
CSVFeedSpider
=============
.. class:: XMLFeedSpider.CSVFeedSpider
.. class:: CSVFeedSpider
.. warning:: The API of the XMLFeedSpider is not yet stable. Use with caution.
.. warning:: The API of the CSVFeedSpider is not yet stable. Use with caution.
This spider is very similar to the XMLFeedSpider, although it iterates through
rows, instead of nodes. It also has other two different attributes:
.. attribute:: XMLFeedSpider.delimiter
.. attribute:: CSVFeedSpider.delimiter
A string with the separator character for each field in the CSV file
Defaults to ``','`` (comma).
.. attribute:: XMLFeedSpider.headers
.. attribute:: CSVFeedSpider.headers
A list of the rows contained in the file CSV feed which will be used for
extracting fields from it.
@ -304,7 +303,7 @@ rows, instead of nodes. It also has other two different attributes:
In this spider, the method that gets called in each row iteration ``parse_row``
instead of ``parse_item`` (like in :class:`XMLFeedSpider`).
.. method:: XMLFeedSpider.parse_row(response, row)
.. method:: CSVFeedSpider.parse_row(response, row)
Receives a response and a dict (representing each row) with a key for each
provided (or detected) header of the CSV file. This spider also gives the

View File

@ -16,9 +16,9 @@ For spiders, the scraping cycle goes through something like this:
those requests.
The first requests to perform are obtained by calling the
:meth:`BaseSpider.start_requests` method which (by default) generates
:meth:`scrapy.spiders.BaseSpider.start_requests` method which (by default) generates
:class:`~scrapy.http.Request` for the URLs specified in the
:attr:`BaseSpider.start_urls` and the ``BaseSpider.parse`` method as
:attr:`scarpy.spiders.BaseSpider.start_urls` and the ``BaseSpider.parse`` method as
callback function for the Requests.
2. In the callback function you parse the response (web page) and return an