Package buildxml :: Package xmlgetter :: Module xml :: Class XMLEntry
[hide private]
[frames] | no frames]

Class XMLEntry

source code


An entry in the XML document that is the CompletionServer's input.

Instance Methods [hide private]
 
__init__(self, url, title, content, description=u'', language=u'de', created=u'', creator=u'', portal_type=u'', modified=u'', tags=[], sources=[])
Initialize the Entry.
source code
string
__str__(self)
Return prinatble and readable XML of the Entry.
source code

Inherited from log.BaseLogger: logger

Inherited from log.BaseLogger (private): _getLogger

Class Variables [hide private]
string _entry_template = ...
The XML template for an entry.
string _sources_template = ...
Template for a <source> XML tag.
string _tags_template = ...
Template for a <tag> XML tag.

Inherited from log.BaseLogger (private): _loggers

Instance Variables [hide private]
string url = None
The url of the entry.
string title = None
The title of the entry as displayed in the search results.
string content = None
The content of the entry.
string description = None
The description for the entry.
string language = None
The language of the entry.
string created = None
The creation date of the entry.
string modified = None
The modification date of the entry.
string creator = None
The author of the entry.
string portal_type = None
The Plone portal_type of the entry.
list of strings sources = None
The sources of the entry.
list of strings tags = None
The tags (aka.

Inherited from log.BaseLogger (private): _source_name

Method Details [hide private]

__init__(self, url, title, content, description=u'', language=u'de', created=u'', creator=u'', portal_type=u'', modified=u'', tags=[], sources=[])
(Constructor)

source code 

Initialize the Entry.

Parameters:
  • url (string) - The URL that references the source for this entry.
  • title (string) - The title of this entry as displayed in the search results.
  • content (string) - The Entry's content. This is where usually most of the data from the acquisition will be stored.
  • description (string) - The Entry's description.
  • language (string) - The language of the Entry's content.
  • created (string or datetime) - Time of creation of the Entry's source.
  • creator (string) - The creator of the Entry's source.
  • portal_type (string) - The type of the Entry's source. Will be the same as portal_type for plone entries.
  • modified (string or datetime) - The date of the last modification of the source.
  • tags (list) - List of tags (aka. keywords in Plone) that are assigned to the Entry. The words in this list will be weighted more heavily during index creation.
  • sources (list) - The names of the sources for this Entry's data.
Overrides: log.BaseLogger.__init__

__str__(self)
(Informal representation operator)

source code 

Return prinatble and readable XML of the Entry.

Returns: string
Readable and prinatble representation of the entry.

Class Variable Details [hide private]

_entry_template

The XML template for an entry.
Type:
string
Value:
"""
<entry>
  <url><![CDATA[${url}]]></url>
  <title><![CDATA[${title}]]></title>
  <description><![CDATA[${description}]]></description>
  <created><![CDATA[${created}]]></created>
  <modified><![CDATA[${modified}]]></modified>
  <creator><![CDATA[${creator}]]></creator>
...

_sources_template

Template for a <source> XML tag.
Type:
string
Value:
"""
  <source><![CDATA[${source}]]></source>"""

_tags_template

Template for a <tag> XML tag.
Type:
string
Value:
"""
  <tag><![CDATA[${tag}]]></tag>"""

Instance Variable Details [hide private]

tags

The tags (aka. keywords) of the entry.
Type:
list of strings
Value:
None