Exemplo n.º 1
0
    def __init__(self, name='storage', dirs=None, extension=None, subdirs=False, fileformat=None, encoding=None,
                 delete_on_start=False, file=None):
        BaseSectionConfigurationData.__init__(self, name)

        self._dirs = None
        self._has_single_file = False

        if dirs is not None:
            if isinstance(dirs, (list,)) is False:
                self._dirs = [dirs]
                self._has_single_file = True

            else:
                self._dirs = dirs[:]
                self._has_single_file = False

        elif file is not None:
            self._dirs = [file]
            self._has_single_file = True

        self._extension = extension
        self._subdirs = subdirs

        self._format = fileformat
        self._encoding = encoding

        self._delete_on_start = delete_on_start
Exemplo n.º 2
0
 def __init__(self, service_name):
     BaseSectionConfigurationData.__init__(self, service_name)
     self._classname = None
     self._method = None
     self._host = None
     self._port = None
     self._url = None
Exemplo n.º 3
0
 def __init__(self, service_name):
     BaseSectionConfigurationData.__init__(self, service_name)
     self._classname = None
     self._method = None
     self._host = None
     self._port = None
     self._url = None
Exemplo n.º 4
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "defaults")
     self._default_get = "unknown"
     self._default_property = "unknown"
     self._default_map = "unknown"
     if os.name == 'posix':
         self._learn_filename = '/tmp/learnf.aiml'
     elif os.name == 'nt':
         self._learn_filename = 'C:\\Windows\\Temp\\leanf.aiml'
Exemplo n.º 5
0
 def __init__(self,
              name,
              filename=None,
              file_format="txt",
              encoding="utf-8",
              delete_on_start=False):
     BaseSectionConfigurationData.__init__(self, name)
     self._file = filename
     self._file_format = file_format
     self._encoding = encoding
     self._delete_on_start = delete_on_start
Exemplo n.º 6
0
 def __init__(self,
              name="files",
              files=None,
              file=None,
              extension=None,
              directories=False):
     BaseSectionConfigurationData.__init__(self, name)
     if files is None:
         self._files = []
     else:
         self._files = files
     self._file = file
     self._extension = extension
     self._directories = directories
Exemplo n.º 7
0
    def __init__(self):
        BaseSectionConfigurationData.__init__(self, "files")
        self._aiml_files = BrainAIMLFileConfiguration()
        self._set_files = BrainFileConfiguration("sets")
        self._map_files = BrainFileConfiguration("maps")
        self._rdf_files = BrainFileConfiguration("rdf")

        self._denormal = None
        self._normal = None
        self._gender = None
        self._person = None
        self._person2 = None
        self._properties = None
        self._variables = None
        self._triples = None
        self._preprocessors = None
        self._postprocessors = None
        self._regex_templates = None
Exemplo n.º 8
0
    def __init__(self):
        BaseSectionConfigurationData.__init__(self, "files")
        self._aiml_files = BrainAIMLFileConfiguration()
        self._set_files = BrainFileConfiguration("sets")
        self._map_files = BrainFileConfiguration("maps")
        self._rdf_files = BrainFileConfiguration("rdf")

        self._denormal = None
        self._normal = None
        self._gender = None
        self._person = None
        self._person2 = None
        self._properties = None
        self._variables = None
        self._triples = None
        self._preprocessors = None
        self._postprocessors = None
        self._regex_templates = None
Exemplo n.º 9
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "debugfiles")
     self._save_errors = False
     self._save_duplicates = False
     self._save_errors_collection = False
Exemplo n.º 10
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "openchatbots")
     self._openchatbots = {}
     self._protocols = ['http']
     self._domains = []
Exemplo n.º 11
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "oob")
     self._default = None
     self._oobs = {}
Exemplo n.º 12
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "oob")
     self._default = None
     self._oobs = {}
Exemplo n.º 13
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "binaries")
     self._save_binary = False
     self._load_binary = False
     self._load_aiml_on_binary_fail = False
Exemplo n.º 14
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "braintree")
     self._create = False
     self._save_as_user = "******"
Exemplo n.º 15
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "nodes")
     self._pattern_nodes = None
     self._template_nodes = None
Exemplo n.º 16
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "security")
     self._authorisation = None
     self._authentication = None
     self._account_linker = None
Exemplo n.º 17
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "defaults")
     self._default_get = "unknown"
     self._default_property = "unknown"
     self._default_map = "unknown"
     self._learnf_path = self._default_os_learnf_path()
Exemplo n.º 18
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "dynamic")
     self._dynamic_sets = {}
     self._dynamic_maps = {}
     self._dynamic_vars = {}
Exemplo n.º 19
0
    def test_init(self):

        section = BaseSectionConfigurationData("section")
        self.assertEquals(section.section_name, "section")
        with self.assertRaises(NotImplementedError):
            section.load_config_section(None, None, None)
Exemplo n.º 20
0
 def __init__(self, openchatbot_name):
     BaseSectionConfigurationData.__init__(self, openchatbot_name)
     self._url = None
     self._method = None
     self._authorization = None
     self._api_key = None
Exemplo n.º 21
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "defaults")
     self._default_get = "unknown"
     self._default_property = "unknown"
     self._default_map = "unknown"
Exemplo n.º 22
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "overrides")
     self._allow_system_aiml = False
     self._allow_learn_aiml = False
     self._allow_learnf_aiml = False
Exemplo n.º 23
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "services")
     self._services = {}
Exemplo n.º 24
0
 def __init__(self, name, filename=None, file_format="txt", encoding="utf-8", delete_on_start=False):
     BaseSectionConfigurationData.__init__(self, name)
     self._file = filename
     self._file_format = file_format
     self._encoding = encoding
     self._delete_on_start = delete_on_start
Exemplo n.º 25
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "braintree")
     self._file = None
     self._content = None
Exemplo n.º 26
0
 def __init__(self, oob_name):
     BaseSectionConfigurationData.__init__(self, oob_name)
     self._classname = None
Exemplo n.º 27
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "overrides")
     self._allow_system_aiml = False
     self._allow_learn_aiml = False
     self._allow_learnf_aiml = False
Exemplo n.º 28
0
 def __init__(self, service_name):
     BaseSectionConfigurationData.__init__(self, service_name)
     self._classname = None
     self._denied_srai = None
     self._denied_text = None
Exemplo n.º 29
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "security")
     self._authorisation = None
     self._authentication = None
Exemplo n.º 30
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "dynamic")
     self._dynamic_sets = {}
     self._dynamic_maps = {}
     self._dynamic_vars = {}
Exemplo n.º 31
0
 def __init__(self, service_name):
     BaseSectionConfigurationData.__init__(self, service_name)
     self._classname = None
     self._denied_srai = None
     self._denied_text = None
Exemplo n.º 32
0
    def test_init(self):

        section = BaseSectionConfigurationData("section")
        self.assertEquals(section.section_name, "section")
        with self.assertRaises(NotImplementedError):
            section.load_config_section(None, None, None)
Exemplo n.º 33
0
 def __init__(self):
     BaseSectionConfigurationData.__init__(self, "services")
     self._services = {}
Exemplo n.º 34
0
 def check_for_license_keys(self, license_keys):
     BaseSectionConfigurationData.check_for_license_keys(self, license_keys)
Exemplo n.º 35
0
 def __init__(self, name):
     BaseSectionConfigurationData.__init__(self, name)