##############################################################################
#
# Copyright (c) 2002 Ingeniweb SARL
#
# This software is subject to the provisions of the Zope Public License,
# Version 2.0 (ZPL).  A copy of the ZPL should accompany this distribution.
# THIS SOFTWARE IS PROVIDED "AS IS" AND ANY AND ALL EXPRESS OR IMPLIED
# WARRANTIES ARE DISCLAIMED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF TITLE, MERCHANTABILITY, AGAINST INFRINGEMENT, AND FITNESS
# FOR A PARTICULAR PURPOSE
#
##############################################################################

"""
AttachmentField product
"""
from global_symbols import *

import AttachmentHandler

attach_globals = globals()

class DummyAttachment(AttachmentHandler.AbstractHandler):
    """
    ZDummyAttachment -> This class simulates an empty attachment so that ValueErrors won't be called whenever
    ZAttachmentAttribute's __underlyingFile__ will be None...
    """
    # attachment properties (MUST BE DERIVED)
    icon_file = "unknown.gif"
    small_icon_file = "unknown_small.gif"
    content_types = (None, )
    converter_type = None
    
    index_path = None
    index_arguments = None
    index_encoding = None
    
    preview_path = None
    preview_arguments = None
    preview_encoding = None
    preview_format = None

AttachmentHandler.registerHandler(DummyAttachment)
##raise "test", AttachmentHandler.__HANDLERS__
