[Checkins] SVN: Products.CMFCore/trunk/Products/CMFCore/interfaces/_tools.py Updated interface definitions
Charlie Clark
charlie at begeistert.org
Sun Oct 9 09:09:52 EST 2011
Log message for revision 123035:
Updated interface definitions
Changed:
U Products.CMFCore/trunk/Products/CMFCore/interfaces/_tools.py
-=-
Modified: Products.CMFCore/trunk/Products/CMFCore/interfaces/_tools.py
===================================================================
--- Products.CMFCore/trunk/Products/CMFCore/interfaces/_tools.py 2011-10-07 19:41:41 UTC (rev 123034)
+++ Products.CMFCore/trunk/Products/CMFCore/interfaces/_tools.py 2011-10-09 14:09:51 UTC (rev 123035)
@@ -1270,6 +1270,34 @@
""",
)
+ period = Attribute(
+ """
+ :str
+ Syndication period for the site: 'hourly', 'daily', 'weekly', 'monthly'
+ """
+ )
+
+ frequency = Attribute(
+ """
+ :int
+ frequency * period calculates the actual update time
+ """
+ )
+
+ base = Attribute(
+ """
+ :datetime
+ The baseline timestamp for site syndication
+ """
+ )
+
+ max_items = Attribute(
+ """
+ :int
+ The maximum number of items to be included in a feed
+ """
+ )
+
def enableSyndication(obj):
""" Enable syndication for the passed-in object
@@ -1362,30 +1390,50 @@
class ISyndicationInfo(Interface):
""" Provides syndication about a particular object"""
- def get_info():
+ enabled = Attribute(
"""
- Return the syndication information from the object if available
- or from the site settings if not.
+ :`bool`
+ Whether syndication is available for the object or not.
+ For this to be true both site syndication and object syndication must
+ be enabled.
- Syndication information is a dictionary
+ Objects that can be syndicated provide the ISyndicatable interface
"""
+ )
- def set_info(period, frequency, base, max_items):
- """ Set syndication for an object."""
+ period = Attribute(
+ """
+ :`str`
+ The period (daily, weekly, monthly) when the feed
+ is updated
+ """
+ )
- enabled = Attribute(
+ frequency = Attribute(
"""
- Boolean as to whether syndication is available for the object or not.
- For this to be true both site syndication and object syndication must
- be enabled.
+ :`int`
+ The frequency of the period for updates
+ """
+ )
- Objects that can be syndicated provide the ISyndicatable interface
+ base = Attribute(
"""
+ :`datetime.datime`
+ The baseline timestamp for calculating updates
+ """
)
+ max_items = Attribute(
+ """
+ :`int`
+ The maximum number of items included in a feed
+ """
+ )
+
def revert():
"""
- Remove any folderish specific syndication settings.
+ Remove any object specific syndication settings and revert to site
+ settings
"""
def enable():
More information about the checkins
mailing list