Back to index

plone3  3.1.7
__init__.py
Go to the documentation of this file.
00001 # Marshall: A framework for pluggable marshalling policies
00002 # Copyright (C) 2004-2006 Enfold Systems, LLC
00003 #
00004 # This program is free software; you can redistribute it and/or modify
00005 # it under the terms of the GNU General Public License as published by
00006 # the Free Software Foundation; either version 2 of the License, or
00007 # (at your option) any later version.
00008 #
00009 # This program is distributed in the hope that it will be useful,
00010 # but WITHOUT ANY WARRANTY; without even the implied warranty of
00011 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012 # GNU General Public License for more details.
00013 #
00014 # You should have received a copy of the GNU General Public License
00015 # along with this program; if not, write to the Free Software
00016 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00017 #
00018 """
00019 $Id: __init__.py 5883 2006-02-06 10:00:28Z yenzenz $
00020 """
00021 
00022 from Products.Marshall import config
00023 from Products.Marshall.registry import registerComponent
00024 
00025 # Register default Archetypes marshallers
00026 from primaryfield import PrimaryFieldMarshaller
00027 from rfc822header import RFC822Marshaller
00028 
00029 registerComponent('primary_field', 'Primary Field Marshaller',
00030                   PrimaryFieldMarshaller)
00031 registerComponent('rfc822', 'RFC822 Marshaller',
00032                   RFC822Marshaller)
00033 
00034 if config.hasLibxml2:    
00035     # Now register our own xml marshallers
00036     from Products.Marshall.handlers.simple import SimpleXMLMarshaller
00037     from Products.Marshall.handlers.atxml import ATXMLMarshaller
00038 
00039     registerComponent('simple_xml', 'Simple XML Marshaller',
00040                       SimpleXMLMarshaller)
00041     registerComponent('atxml', 'ATXML Marshaller',
00042                       ATXMLMarshaller)