Index: django/utils/feedconfigs.py
===================================================================
--- django/utils/feedconfigs.py	(revision 0)
+++ django/utils/feedconfigs.py	(revision 0)
@@ -0,0 +1,226 @@
+from django.utils import feedgenerator
+from django.models.core import sites
+from django.conf.settings import LANGUAGE_CODE, SETTINGS_MODULE
+from django.core import template_loader
+from django.core.template import Context
+"""
+This defines the parent classes for all the feed configuration objects.
+"""
+class RequiredFunctionError(Exception):
+	""" 
+	I saw this somewhere and liked it. This gets thrown when a required feild is not defined in a base class
+	"""
+	def __init__(self,function):
+		Exception.__init__(self,"Function: %s is a required method and needs to be overridden" % function.__name__)
+
+
+		
+class FeedConfiguration:
+	"""
+	This is the base Feed Configuration class, it maps with the Syntication Feed generator
+	"""
+	def __init__(self):
+		pass
+        	
+	def get_feed(self):
+		""" 
+		This return a feed generator, don't override this unless you know what your doing
+		"""
+		pass
+	#####
+	## Feed Options
+	#####
+	def set_param_slug(self,param_slug):
+		raise RequiredFunctionError(self.set_param_slug)
+
+	def get_slug(self):
+		raise RequiredFunctionError(self.get_slug)
+	
+	def _slug_getter(self):
+		return(self.get_slug())
+	
+	slug = property(_slug_getter)			
+	
+	def get_title(self):
+		raise RequiredFunctionError(self.get_title)
+	
+	def get_description(self):
+		return None
+	
+	def get_link(self):
+		raise RequiredFunctionError(self.get_link)			
+
+	
+	def get_language(self):
+		return None
+
+	def get_items(self):
+		raise RequiredFunctionError(self.get_items)
+		
+	def set_current_item(self, item):
+		raise RequiredFunctionError(self.__init__)
+
+	def get_item_title(self):
+		""" 
+		The default function loads the template, rss/{slug}_title.html
+		Context:
+		obj: The current item
+			site: The current site
+		override this only if really needed.
+		"""
+		return None
+
+	def get_item_description(self):
+		""" 
+		The default function loads the template, rss/{slug}_description.html
+		Context:
+			obj: The current item
+			site: The current site
+		override this only if really needed.
+		"""				
+		return None
+
+	def get_item_link(self):
+		raise RequiredFunctionError(self.get_link)
+
+	def get_item_author_email(self):
+		return None
+
+	def get_item_author_name(self):
+		return None
+
+	def get_item_pub_date(self):
+		"""
+		Returns: datetime.datetime
+		"""
+		return None
+
+	def get_item_comments(self):
+		return None
+
+	def get_item_unique_id(self):
+		return None
+
+	def get_item_enclosure(self):
+		"""
+		returns: dict{url,mime_type,length}
+		"""
+		return None
+	
+	def get_item_categories(self):
+		return None
+		
+class RssConfiguration(FeedConfiguration):
+	def __init__(self,Generator_Class=feedgenerator.DefaultRssFeed):
+		FeedConfiguration.__init__(self)
+		self.generator = Generator_Class
+		
+	def get_feed(self, param_slug=None):
+		"""
+		Returns a utils.feedgenerator.DefaultRssFeed object, fully populated,
+		representing this FeedConfiguration.
+		"""
+		current_site = sites.get_current()
+        
+		# Set the param slug
+		self.set_param_slug(param_slug)
+		
+		# Geth the feed generator object
+		f = self._get_feed_generator_object()
+
+		# Get the feed's slug
+		slug = self.get_slug()
+
+
+		# Get the feed's items
+		for obj in self.get_items():
+			# Set the current item so that the object can record it
+			self.set_current_item(obj)
+            
+            # Retrieve the current item's link
+			link = self.get_item_link()
+			if not link.startswith('http://'):
+				link = u'http://%s%s' % (current_site.domain, link)
+				
+
+			# Get the item's title
+			title = self.get_item_title()
+            # If the title returns None (default action),
+			if title == None:
+                # Generate it with the rss title template for this feed
+				title_template = template_loader.get_template('rss/%s_title' % slug)
+				title = title_template.render(Context({'obj': obj, 'site': current_site})).decode('utf-8')
+
+            # Get the item's description
+			description = self.get_item_description()
+            # If the description is None,
+			if description == None:
+                # Generate it with the rss description template for this feed
+				description_template = template_loader.get_template('rss/%s_description' % slug)				
+				description = description_template.render(Context({'obj': obj, 'site': current_site})).decode('utf-8')
+
+			#  Init the enc variable
+			enc = None
+			# Get the item's enclosure data
+			enc_data = self.get_item_enclosure()
+			# If the enclosure data is not null
+			if enc_data:
+        # Create an Enclosure object with that data
+				enc = feedgenerator.Enclosure(enc_data['url'].decode('utf-8'),
+											 (enc_data['length'] and str(enc_data['length']).decode('utf-8') or ''), 
+											 enc_data['mime_type'].decode('utf-8'))
+                                             
+            # Add the current item's data to the feed
+			f.add_item(
+				   title	   = title,
+				   description = description,
+				   link		= link,
+				   unique_id   = link,
+				   enclosure   = enc,
+				   pubdate	 = self.get_item_pub_date(),
+				   author_email= self.get_item_author_email(),
+				   author_name = self.get_item_author_name(),
+				   comments	= self.get_item_comments(),
+				   categories  = self.get_item_categories(),															 
+			)
+			return f
+		
+	def _get_feed_generator_object(self):
+		current_site = sites.get_current()
+		link = self.get_link().decode()
+		if not link.startswith('http://'):
+			link = u'http://%s%s' % (current_site.domain, link)
+			
+		return self.generator(
+			title = self.get_title(),
+			link = link,
+			description = self.get_description(),
+			language = LANGUAGE_CODE.decode(),
+		)
+
+
+def register_feed_modules(module_list):
+	"""
+	This function takes a list of module names and registers all the FeedConfiguration objects within that module
+	"""
+	import types
+	from django.core import rss
+	for module_name, attrs in module_list:
+			try:
+				# Load the module 
+				module = __import__(module_name,'','',[''])
+				# loop over each item in the module,
+				for name,value in module.__dict__.items():
+					# If the item in the module is a subclass of FeedConfiguration
+					if type(value) == types.ClassType and value != FeedConfiguration and issubclass(value,FeedConfiguration):
+						# if attrs is not None, init the class with the attrs
+						if attrs != None:
+							feed_config = value(**attrs)
+						# otherwise init it without it
+						else:
+							feed_config = value()
+
+						# call the register feed function
+						rss.register_feed(feed_config)
+			except ImportError,e:
+				raise e
Index: tests/othertests/new_rss.py
===================================================================
--- tests/othertests/new_rss.py	(revision 0)
+++ tests/othertests/new_rss.py	(revision 0)
@@ -0,0 +1,74 @@
+from django.utils import feedconfigs,feedgenerator
+"""
+These aren't the best unittests, not all that automated but they help document how the elements work
+"""
+
+import os,sys
+# Add the current path to the template dirs so that we can get the test templates
+
+class FakeFeedConfig(feedconfigs.RssConfiguration):
+
+	# Only define the required functions so that we know that the defaults
+	# don't kill anything
+	def set_param_slug(self,param_slug):
+		self.param_slug = param_slug
+	
+	def get_link(self):
+			return "/test"
+    
+	def get_title(self):
+		return "title"
+    
+	def get_slug(self):
+		return("test")
+    
+	def get_description(self):
+		return "description"
+    
+	def get_items(self):
+		items = []
+		for i in range(0,10):
+			data = { 
+             'title' : 'title_%s' % i,
+             'description' : 'title_%s' % i,
+             'link' : 'http://example.com/%s/' % i,
+            }
+			items.append(data)
+			return(items)
+    
+	def set_current_item(self,item):
+		self.item = item
+
+	def get_item_link(self):
+		return(self.item['link'])
+    
+	def get_item_title(self):
+		return(self.item['title'])
+    
+	def get_item_description(self):
+		return(self.item['description'])            
+
+if __name__ == '__main__':
+
+	# Lets start by testing that all the required items fail like they should
+	fc = FakeFeedConfig()
+	f = fc.get_feed()
+	f.write(sys.stdout,'utf-8')
+
+	# Custom Generator
+	fc = FakeFeedConfig(feedgenerator.RssUserland091Feed)
+	f = fc.get_feed()
+
+	f.write(sys.stdout,'utf-8')
+
+	feedconfigs.register_feed_modules([
+		        # Simple Config with no parameters
+													('new_rss',None),
+													# An example of a Feed Config class with parameters, this instance is for changing the generator
+			('new_rss',{'Generator_Class' : feedgenerator.RssUserland091Feed })
+													])
+	from django.core import rss
+	
+	f = rss.get_registered_feed('test')
+
+	assert 'FakeFeedConfig' in  str(f.__class__) , "Eric, your register_feed_modules function sucks."
