1 from random import choice
3 from zope.interface import implements
5 from TwistedQuotes import quoteproto
11 Return a static quote.
14 implements(quoteproto.IQuoter)
16 def __init__(self, quote):
27 Load quotes from a fortune-format file.
29 implements(quoteproto.IQuoter)
31 def __init__(self, filenames):
32 self.filenames = filenames
36 quoteFile = file(choice(self.filenames))
37 quotes = quoteFile.read().split('\n%\n')