def __init__(self): self.target = '%Verb%' self.conn = connect(const.postgres_config) self.cur = self.conn.cursor() self.cur_B = self.conn.cursor() self.counter = 0
# When required, the dictionary 'sn_de' can be used to translate section_names # into German. # ------------------------------------------------------------------------------ # Dependencies: # requests, lxml, io # ------------------------------------------------------------------------------ import requests from lxml import etree from io import StringIO import unicodedata import re import json import constants as const from translations.database_handler import connect conn = connect(const.postgres_config) cur = conn.cursor() matcher = re.compile(r"^[^\|]*") # ============================================================================== # Constants # ============================================================================== sl = 'en' # default source language (Spanish - Español) tl = 'de' # target language (German). Actually a constant: # LEO is a German company uri = 'https://dict.leo.org/german-english/' #uri = 'http://dict.leo.org/german-english/' # LEO uri section_names = ( 'subst',
def __init__(self): self.conn = connect(const.postgres_config) self.cur = self.conn.cursor() self.reverso = ReversoDictionary()
def __init__(self): self.conn = connect(const.postgres_config) self.cur = self.conn.cursor()
def __init__(self): self.target = const.VERB self.conn = connect(const.postgres_config) self.cur = self.conn.cursor() self.cur_dwds = self.conn.cursor()