Ignore:
Timestamp:
26 Apr 2011, 11:03:36 (14 years ago)
Author:
uli
Message:

Rename HurryImageFile? to WAeUPImageFile.

Location:
main/waeup.sirp/trunk/src/waeup/sirp/image
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/image/README.txt

    r5974 r5979  
    44The image file widget is built on top of the ImageFile object::
    55
    6   >>> from waeup.sirp.image import ImageFile
    7   >>> file = ImageFile('foo.jpg', 'mydata')
     6  >>> from waeup.sirp.image import WAeUPImageFile
     7  >>> file = WAeUPImageFile('foo.jpg', 'mydata')
    88  >>> file.filename
    99  'foo.jpg'
     
    1616  'mydata'
    1717
    18 We can also create ImageFile objects from file-like objects::
     18We can also create WAeUPImageFile objects from file-like objects::
    1919
    2020  >>> from StringIO import StringIO
     
    3333  'test data'
    3434
    35 The ImageFile object normally stores the file data using ZODB
     35The WAeUPImageFile object normally stores the file data using ZODB
    3636persistence. Files can however also be stored by tramline.  If
    3737tramline is installed in Apache, the Tramline takes care of generating
     
    7070just '1') will now be created::
    7171
    72   >>> file = ImageFile('foo.jpg', '1')
     72  >>> file = WAeUPImageFile('foo.jpg', '1')
    7373
    7474The data is now '1', referring to the real file::
     
    9999We expect the same behavior as when tramline is not installed::
    100100
    101   >>> file = ImageFile('foo.jpg', 'data')
     101  >>> file = WAeUPImageFile('foo.jpg', 'data')
    102102  >>> f = file.file
    103103  >>> f.read()
  • main/waeup.sirp/trunk/src/waeup/sirp/image/__init__.py

    r5975 r5979  
    33Includings schemas, widgets and the content components.
    44"""
    5 from waeup.sirp.image.image import ImageFile
     5from waeup.sirp.image.image import WAeUPImageFile
  • main/waeup.sirp/trunk/src/waeup/sirp/image/image.py

    r5976 r5979  
    2525from hurry.file import HurryFile
    2626from zope.interface import implements
    27 from waeup.sirp.image.interfaces import IImageFile
     27from waeup.sirp.image.interfaces import IWAeUPImageFile
    2828
    29 class ImageFile(HurryFile):
     29class WAeUPImageFile(HurryFile):
    3030    """A file prepared for storing image files.
    3131
    3232    This file type is built upon :class:`hurry.file.HurryFile`.
    3333    """
    34     implements(IImageFile)
     34    implements(IWAeUPImageFile)
  • main/waeup.sirp/trunk/src/waeup/sirp/image/interfaces.py

    r5693 r5979  
    2222"""Interfaces for waeup.sirp.image
    2323"""
    24 from zope.app.file.interfaces import IImage
    25 from hurry.file.interfaces import IFile, IFileRetrieval
     24from hurry.file.interfaces import IFile, IFileRetrieval, IHurryFile
    2625
    27 class IImageFile(IFile, IImage):
     26class IImageFile(IFile):
    2827    """Image file field.
    2928    """
    30 
     29   
     30class IWAeUPImageFile(IHurryFile):
     31    """Image file.
     32    """
     33   
    3134class IImageFileRetrieval(IFileRetrieval):
    3235    """A file retrieval for images.
  • main/waeup.sirp/trunk/src/waeup/sirp/image/schema.py

    r5972 r5979  
    2525from hurry.file.schema import File
    2626from waeup.sirp.image.interfaces import IImageFile
    27 from waeup.sirp.image.image import ImageFile as ImageFileContent
     27from waeup.sirp.image.image import WAeUPImageFile
    2828
    2929class ImageFile(File):
    30     """An image file.
     30    """An image file field.
     31
     32    Suitable for interfaces that wish to store image files in an
     33    attribute.
    3134    """
    3235    implements(IImageFile)
    3336
    34     _type = ImageFileContent
     37    _type = WAeUPImageFile
Note: See TracChangeset for help on using the changeset viewer.