Logo Search packages:      
Sourcecode: zope-attachmentfield version File versions  Download package

def AttachmentField::AttachmentHandler::AbstractHandler::getIndexableValue (   self,
  field,
  instance 
) [inherited]

getIndexableValue(self, field, instance) => (possibliy big) string
Return the ZCatalog-indexable string for that type.

Reimplemented in AttachmentField::OOAttachment::OOAttachment, and AttachmentField::PortalTransformsAttachment::PortalTransformsAttachment.

Definition at line 220 of file AttachmentHandler.py.

00220                                                 :
        """
        getIndexableValue(self, field, instance) => (possibliy big) string
        Return the ZCatalog-indexable string for that type.
        """
        Log(LOG_DEBUG, "converting field", field.getName(), self.index_arguments, self.__class__.__name__)
        index = self._convert(
            field,
            instance,
            self.index_program,
            self.index_arguments,
            self.index_encoding,
            )

        # Convert indexer output to plain "optimized" text
        index = striphtml.strip(index)
        words = []
        for w in string.split(index):
            stripped = string.lower(string.strip(w))
            if not stripped in words:
                words.append(stripped)
        words.sort
        return string.join(words, " ")

    def convertStringToIndex(self, content, content_type, instance):


Generated by  Doxygen 1.6.0   Back to index