示例#1
0
 def get_operation(self, name):
     if name == "EditWord" and self._dictionary is not None:
         op = OperationEditWord(self._dictionary)
     elif name == "FindInWeb" and self._cfg is not None:
         op = OperationFindInWeb(self._cfg)
     elif name == "ShowStatistic" and self._dictionary is not None and self._cfg is not None:
         op = OperationShowStatistic(self._dictionary, self._cfg, self)
     else:
         op = BaseOperation()
     return op
示例#2
0
 def __init__(self, dictionary, cfg, factory):
     BaseOperation.__init__(self)
     self._dictionary = dictionary
     self._cfg = cfg
     self._factory = factory
示例#3
0
 def __init__(self, cfg):
     BaseOperation.__init__(self)
     self._cfg = cfg
 def __init__(self, dictionary):
     BaseOperation.__init__(self)
     self._dictionary = dictionary
示例#5
0
 def __init__(self, dictionary):
     BaseOperation.__init__(self)
     self._dictionary = dictionary
 def __init__(self, cfg):
     BaseOperation.__init__(self)
     self._cfg = cfg
 def __init__(self, dictionary, cfg, factory):
     BaseOperation.__init__(self)
     self._dictionary = dictionary
     self._cfg = cfg
     self._factory = factory