tipy :: prdct :: PredictorRegistry :: Class PredictorRegistry
[hide private]
[frames] | no frames]

Class PredictorRegistry

source code

object --+    
         |    
      list --+
             |
            PredictorRegistry

List every predictors instances that are to be used for word prediction.

Class Hierarchy for PredictorRegistry
Class Hierarchy for PredictorRegistry

Instance Methods [hide private]
new empty list
__init__(self, config)
PredictorRegistry creator.
source code
 
set_predictors(self)
Read the configuration file and create needed predictors.
source code
 
add_predictor(self, predictorName)
Create and add a predictor to the list.
source code
 
close_databases(self)
Close every opened predictors database.
source code

Inherited from list: __add__, __contains__, __delitem__, __delslice__, __eq__, __ge__, __getattribute__, __getitem__, __getslice__, __gt__, __iadd__, __imul__, __iter__, __le__, __len__, __lt__, __mul__, __ne__, __new__, __repr__, __reversed__, __rmul__, __setitem__, __setslice__, __sizeof__, append, count, extend, index, insert, pop, remove, reverse, sort

Inherited from object: __delattr__, __format__, __reduce__, __reduce_ex__, __setattr__, __str__, __subclasshook__

Class Variables [hide private]

Inherited from list: __hash__

Properties [hide private]
  contextMonitor

Inherited from object: __class__

Method Details [hide private]

__init__(self, config)
(Constructor)

source code 

PredictorRegistry creator.

Parameters:
  • config (drvr.Configuration) - config is used to retrieve the PredictorRegistry settings and each Predictor settings from the config file. Also it needs to be passed to the predictors instances to allow them to retrieve their settings from the config file too.
Returns: new empty list
Overrides: object.__init__

add_predictor(self, predictorName)

source code 

Create and add a predictor to the list.

Create a predictor instance according to the predictor name and add it to the list.

Parameters:
  • predictorName (str) - The name of the predictor. It is used to retrieve the predictor settings from the config. It must correspond to a section of the config, otherwise no predictor will be created and added.

Property Details [hide private]

contextMonitor

Get Method:
unreachable.fget(self)
Set Method:
unreachable.fset(self, value)
Delete Method:
unreachable.fdel(self)