def __init__(self, cardinal, config):
        # Initialize logger
        self.logger = logging.getLogger(__name__)

        try:
            self._max_description_length = config['max_description_length']
        except KeyError:
            self.logger.warning("No max description length in config -- using"
                " defaults: %d" % DEFAULT_MAX_DESCRIPTION_LENGTH)
            self._max_description_length = DEFAULT_MAX_DESCRIPTION_LENGTH

        try:
            self._language_code = config['language_code']
        except KeyError:
            self.logger.warning("No language in config -- using defaults: %s" %
                DEFAULT_LANGUAGE_CODE)
            self._language_code = DEFAULT_LANGUAGE_CODE

        self._callback_id = cardinal.event_manager.register_callback(
            'urls.detection', self.url_callback)
This class read/write a elan based file.
dataset/ETHPy150Open JohnMaguire/Cardinal/plugins/wikipedia/plugin.py/WikipediaPlugin.__init__--crossover with--dataset/ETHPy150Open NeuralEnsemble/python-neo/neo/io/elanio.py/ElanIO.__init__