From a49603fc09d54729bc9b09d3aab5cbade1a9254a Mon Sep 17 00:00:00 2001 From: Konstantin Schulz <schulzkx@hu-berlin.de> Date: Fri, 27 Oct 2023 14:25:53 +0200 Subject: [PATCH] add Vischer vocabulary --- .gitignore | 2 + README.md | 4 +- mc_backend/mcserver/app/api/exerciseAPI.py | 2 +- mc_backend/mcserver/app/api/fileAPI.py | 2 +- mc_backend/mcserver/app/api/h5pAPI.py | 3 +- mc_backend/mcserver/app/api/kwicAPI.py | 3 +- .../mcserver/app/api/vectorNetworkAPI.py | 2 +- mc_backend/mcserver/app/api/vocabularyAPI.py | 2 +- mc_backend/mcserver/app/api/zenodoAPI.py | 3 +- .../assets/vocabulary/vocabulary_vischer.json | 5887 +++++++++++++++++ mc_backend/mcserver/app/models.py | 1 + mc_backend/mcserver/config.py | 1 + mc_backend/openapi/.openapi-generator/FILES | 45 + mc_backend/openapi/.openapi-generator/VERSION | 2 +- mc_backend/openapi/git_push.sh | 7 +- mc_backend/openapi/openapi_server/__main__.py | 1 + .../controllers/default_controller.py | 78 +- .../controllers/security_controller.py | 2 + mc_backend/openapi/openapi_server/encoder.py | 5 +- .../openapi/openapi_server/models/__init__.py | 12 - .../openapi_server/models/annis_response.py | 35 +- .../openapi_server/models/base_model.py | 68 + .../openapi/openapi_server/models/corpus.py | 33 +- .../openapi_server/models/exercise_author.py | 9 +- .../models/exercise_author_extension.py | 9 +- .../openapi_server/models/exercise_base.py | 41 +- .../models/exercise_extension.py | 33 +- .../models/exercise_type_path.py | 18 +- .../openapi_server/models/file_type.py | 17 +- .../openapi_server/models/frequency_item.py | 19 +- .../openapi_server/models/graph_data.py | 25 +- .../openapi/openapi_server/models/link.py | 25 +- .../models/matching_exercise.py | 83 +- .../openapi/openapi_server/models/node_mc.py | 49 +- .../openapi_server/models/phenomenon.py | 13 +- .../openapi/openapi_server/models/sentence.py | 13 +- .../openapi/openapi_server/models/solution.py | 13 +- .../openapi_server/models/solution_element.py | 21 +- .../openapi_server/models/static_exercise.py | 13 +- .../openapi_server/models/text_complexity.py | 65 +- .../openapi_server/models/vocabulary_mc.py | 14 +- .../models/zenodo_metadata_prefix.py | 9 +- .../zenodo_metadata_prefix_extension.py | 9 +- .../openapi_server/models/zenodo_record.py | 45 +- .../openapi_server/openapi/openapi.yaml | 352 +- .../openapi/openapi_server/typing_utils.py | 2 - mc_backend/openapi/openapi_server/util.py | 15 +- mc_backend/openapi/requirements.txt | 1 + mc_backend/openapi/setup.py | 2 - mc_backend/openapi/test-requirements.txt | 6 +- mc_backend/openapi_models.yaml | 6 +- mc_backend/tests.py | 9 +- mc_frontend/.gitignore | 1 + mc_frontend/openapi/.openapi-generator/FILES | 35 + .../openapi/.openapi-generator/VERSION | 2 +- mc_frontend/openapi/README.md | 39 +- mc_frontend/openapi/api.module.ts | 2 - mc_frontend/openapi/api/default.service.ts | 1391 ++-- mc_frontend/openapi/configuration.ts | 82 + mc_frontend/openapi/encoder.ts | 1 - mc_frontend/openapi/git_push.sh | 7 +- mc_frontend/openapi/index.ts | 3 +- mc_frontend/openapi/model/exerciseTypePath.ts | 4 +- mc_frontend/openapi/model/matchingExercise.ts | 3 - mc_frontend/openapi/model/models.ts | 9 - mc_frontend/openapi/model/vocabularyMC.ts | 5 +- mc_frontend/openapi/param.ts | 69 + .../src/app/doc-software/doc-software.page.ts | 2 +- .../src/app/doc-voc-unit/doc-voc-unit.page.ts | 2 +- .../exercise-parameters.page.spec.ts | 3 +- .../exercise-parameters.page.ts | 5 +- mc_frontend/src/app/exercise.service.ts | 3 +- mc_frontend/src/app/imprint/imprint.page.ts | 2 +- mc_frontend/src/app/models/enum.ts | 1 + .../src/app/semantics/semantics.page.ts | 2 +- .../src/app/sequences/sequences.page.ts | 4 +- .../src/app/show-text/show-text.page.ts | 2 +- .../vocabulary-check.page.spec.ts | 2 - .../src/app/vocabulary.service.spec.ts | 5 +- mc_frontend/src/app/vocabulary.service.ts | 8 +- mc_frontend/src/assets/i18n/de.json | 1 + mc_frontend/src/assets/i18n/en.json | 1 + 82 files changed, 7763 insertions(+), 1069 deletions(-) create mode 100644 mc_backend/mcserver/app/assets/vocabulary/vocabulary_vischer.json create mode 100644 mc_backend/openapi/.openapi-generator/FILES create mode 100644 mc_backend/openapi/openapi_server/controllers/security_controller.py create mode 100644 mc_backend/openapi/openapi_server/models/base_model.py create mode 100644 mc_frontend/openapi/.openapi-generator/FILES create mode 100644 mc_frontend/openapi/param.ts diff --git a/.gitignore b/.gitignore index 42e8f8d..76652b7 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,5 @@ builds/ venv/ *.log + +openapitools.json diff --git a/README.md b/README.md index 6a756ed..8499249 100644 --- a/README.md +++ b/README.md @@ -39,10 +39,10 @@ via `docker run -it SNAPSHOT_ID`. To generate class structures for this project automatically: -1. Install OpenAPI Generator (using, e.g., `brew install openapi-generator`). +1. Install OpenAPI Generator (using, e.g., `npm i @openapitools/openapi-generator-cli -g`). 2. -Run: `openapi-generator generate -i mc_backend/mcserver/mcserver_api.yaml -g typescript-angular -o mc_frontend/openapi/ && openapi-generator generate -i mc_backend/mcserver/mcserver_api.yaml -g python-flask -o mc_backend/openapi/ && python mc_backend/openapi_generator.py` +Run: `openapi-generator-cli generate -i mc_backend/mcserver/mcserver_api.yaml -g typescript-angular -o mc_frontend/openapi/ && openapi-generator-cli generate -i mc_backend/mcserver/mcserver_api.yaml -g python-flask -o mc_backend/openapi/ && python mc_backend/openapi_generator.py` . Note: If an **unused Enum** is specified in the API documentation, it will not be generated. To force-generate its diff --git a/mc_backend/mcserver/app/api/exerciseAPI.py b/mc_backend/mcserver/app/api/exerciseAPI.py index 2aad378..557ad73 100644 --- a/mc_backend/mcserver/app/api/exerciseAPI.py +++ b/mc_backend/mcserver/app/api/exerciseAPI.py @@ -14,7 +14,7 @@ from mcserver.app.services import AnnotationService, CorpusService, NetworkServi DatabaseService, ExerciseService from mcserver.config import Config from mcserver.models_auto import Exercise, TExercise, UpdateInfo -from openapi.openapi_server.models import ExerciseForm +from openapi.openapi_server.models.exercise_form import ExerciseForm def adjust_solutions(exercise_data: ExerciseData, exercise_type: str, solutions: List[Solution]) -> List[Solution]: diff --git a/mc_backend/mcserver/app/api/fileAPI.py b/mc_backend/mcserver/app/api/fileAPI.py index 617d53e..28d8722 100644 --- a/mc_backend/mcserver/app/api/fileAPI.py +++ b/mc_backend/mcserver/app/api/fileAPI.py @@ -13,7 +13,7 @@ from mcserver.app.models import FileType, ResourceType, DownloadableFile, MimeTy from mcserver.app.services import FileService, NetworkService, DatabaseService from mcserver.config import Config from mcserver.models_auto import Exercise, UpdateInfo, LearningResult -from openapi.openapi_server.models import FileForm +from openapi.openapi_server.models.file_form import FileForm def clean_tmp_folder(): diff --git a/mc_backend/mcserver/app/api/h5pAPI.py b/mc_backend/mcserver/app/api/h5pAPI.py index 99e7b65..75c5147 100644 --- a/mc_backend/mcserver/app/api/h5pAPI.py +++ b/mc_backend/mcserver/app/api/h5pAPI.py @@ -13,8 +13,9 @@ from mcserver import Config from mcserver.app.models import Language, ExerciseType, Solution, MimeType, FileType from mcserver.app.services import TextService, NetworkService, DatabaseService from mcserver.models_auto import Exercise -from openapi.openapi_server.models import H5PForm, ExerciseAuthor +from openapi.openapi_server.models import ExerciseAuthor from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.h5_p_form import H5PForm def determine_language(lang: str) -> Language: diff --git a/mc_backend/mcserver/app/api/kwicAPI.py b/mc_backend/mcserver/app/api/kwicAPI.py index c09b3d4..f527204 100644 --- a/mc_backend/mcserver/app/api/kwicAPI.py +++ b/mc_backend/mcserver/app/api/kwicAPI.py @@ -12,7 +12,8 @@ from flask import Response from mcserver.app.models import ExerciseType, ExerciseData, LinkMC, NodeMC, make_solution_element_from_salt_id from mcserver.app.services import AnnotationService, NetworkService, CorpusService from mcserver.config import Config -from openapi.openapi_server.models import KwicForm, GraphData, Solution +from openapi.openapi_server.models import GraphData, Solution +from openapi.openapi_server.models.kwic_form import KwicForm def post(kwic_data: dict) -> Response: diff --git a/mc_backend/mcserver/app/api/vectorNetworkAPI.py b/mc_backend/mcserver/app/api/vectorNetworkAPI.py index f5b4fa8..4fee4a7 100644 --- a/mc_backend/mcserver/app/api/vectorNetworkAPI.py +++ b/mc_backend/mcserver/app/api/vectorNetworkAPI.py @@ -13,7 +13,7 @@ from numpy.core.multiarray import ndarray, dot from mcserver import Config from mcserver.app.services import NetworkService -from openapi.openapi_server.models import VectorNetworkForm +from openapi.openapi_server.models.vector_network_form import VectorNetworkForm def add_edges(keys: List[str], w2v: Word2Vec, nearest_neighbor_count: int, min_count: int, graph: Graph) -> None: diff --git a/mc_backend/mcserver/app/api/vocabularyAPI.py b/mc_backend/mcserver/app/api/vocabularyAPI.py index 19b43b9..5bbc3d2 100644 --- a/mc_backend/mcserver/app/api/vocabularyAPI.py +++ b/mc_backend/mcserver/app/api/vocabularyAPI.py @@ -6,7 +6,7 @@ from flask import Response from mcserver.app.models import VocabularyCorpus, GraphData, Sentence, AnnisResponse, TextComplexityMeasure from mcserver.app.services import FileService, CorpusService, AnnotationService, NetworkService, TextService, \ TextComplexityService -from openapi.openapi_server.models import VocabularyForm +from openapi.openapi_server.models.vocabulary_form import VocabularyForm def add_sentence(current_lemmata: Dict[int, str], vocabulary_set: Set[str], sentences: List[Sentence], diff --git a/mc_backend/mcserver/app/api/zenodoAPI.py b/mc_backend/mcserver/app/api/zenodoAPI.py index 8ff564e..0cd951c 100644 --- a/mc_backend/mcserver/app/api/zenodoAPI.py +++ b/mc_backend/mcserver/app/api/zenodoAPI.py @@ -9,7 +9,8 @@ from sickle.models import Record from mcserver import Config from mcserver.app.services import NetworkService -from openapi.openapi_server.models import ZenodoRecord, ZenodoForm, ZenodoMetadataPrefix +from openapi.openapi_server.models import ZenodoRecord, ZenodoMetadataPrefix +from openapi.openapi_server.models.zenodo_form import ZenodoForm def get() -> Response: diff --git a/mc_backend/mcserver/app/assets/vocabulary/vocabulary_vischer.json b/mc_backend/mcserver/app/assets/vocabulary/vocabulary_vischer.json new file mode 100644 index 0000000..d856208 --- /dev/null +++ b/mc_backend/mcserver/app/assets/vocabulary/vocabulary_vischer.json @@ -0,0 +1,5887 @@ +[ + "-met", + "Aeneas", + "Asia", + "Bacchus", + "Caesar", + "Caesaris", + "December", + "Dirae", + "Hesperus", + "Ianuarius", + "Ianus", + "Iuno", + "Kalendae", + "Mars", + "Martius", + "Musa", + "Nonae", + "Quiris", + "Rhenus", + "Scipio", + "Sextilis", + "Tauri", + "a", + "ab", + "abdere", + "abdicare", + "abducere", + "aberrare", + "abesse", + "abhorrere", + "abicere", + "abiectus", + "abies", + "abigere", + "abire", + "abnegare", + "abnuere", + "abolere", + "abripere", + "abrogare", + "abrumpere", + "abscedere", + "abscindere", + "abscondere", + "absens", + "absistere", + "absolutus", + "absolvere", + "absorbere", + "absterrere", + "abstinere", + "abstrahere", + "absumere", + "absurdus", + "abundantia", + "abundare", + "abunde", + "abuti", + "ac", + "acanthus", + "accedere", + "accelerare", + "accendere", + "accersere", + "accessio", + "accessus", + "accidere", + "accidit", + "accingere", + "accingi", + "accipere", + "accipiter", + "accire", + "accola", + "accommodare", + "accrescere", + "accuratus", + "accurrere", + "accusare", + "accusatio", + "accusator", + "acer", + "acerbitas", + "acerbus", + "acere", + "acervus", + "acetum", + "acidus", + "aciem", + "acies", + "acquiescere", + "acquirere", + "acta", + "actio", + "actiones", + "actor", + "actuarius", + "actus", + "acuere", + "acumen", + "acutus", + "ad", + "adaequare", + "adamantinus", + "adamas", + "addere", + "addicere", + "adducere", + "adeo", + "adesse", + "adferre", + "adhaerere", + "adhibere", + "adhortari", + "adhuc", + "adicere", + "adigere", + "adimere", + "adipisci", + "adire", + "aditus", + "adiumentum", + "adiuncta", + "adiungere", + "adiutare", + "adiutor", + "adiutrix", + "adiuvare", + "administer", + "administrare", + "administratio", + "admirabilis", + "admirari", + "admiratio", + "admiscere", + "admittere", + "admodum", + "admonere", + "admonitu", + "admovere", + "adnectere", + "adniti", + "adnuere", + "adolere", + "adolescere", + "adoptio", + "adorare", + "adoriri", + "adulari", + "adulatio", + "adulescens", + "adulescentia", + "adulescentulus", + "adulter", + "adulterium", + "adultus", + "adumbrare", + "aduncus", + "adurere", + "advehere", + "advena", + "advenire", + "adventare", + "adventicius", + "adventus", + "adversari", + "adversarius", + "adversus", + "advertere", + "advocare", + "advocatus", + "advolare", + "adytum", + "aedes", + "aedificare", + "aedificium", + "aedilis", + "aedilitas", + "aeger", + "aegis", + "aegre", + "aegrimonia", + "aegritudo", + "aegrotare", + "aegrotatio", + "aegrotus", + "aemulari", + "aemulatio", + "aemulus", + "aeneus", + "aenum", + "aenus", + "aequabilis", + "aequabilitas", + "aequalis", + "aequare", + "aequitas", + "aequor", + "aequoreus", + "aequus", + "aer", + "aera", + "aerarium", + "aeratus", + "aereus", + "aerius", + "aerugo", + "aerumna", + "aes", + "aestas", + "aestimare", + "aestimatio", + "aestiva", + "aestivus", + "aestuare", + "aestuosus", + "aestus", + "aetas", + "aeternitas", + "aeternus", + "aether", + "aetherius", + "aevum", + "affari", + "affectare", + "affectio", + "affectus", + "afficere", + "affici", + "affigere", + "affinis", + "affinitas", + "affirmare", + "afflare", + "affligere", + "affluere", + "age", + "agellus", + "ager", + "agere", + "agger", + "aggerare", + "aggredi", + "aggregare", + "agilis", + "agitare", + "agitatio", + "agmen", + "agna", + "agnoscere", + "agnus", + "agrarius", + "agrestis", + "agricola", + "agricultura", + "ah!", + "aio", + "ala", + "alacer", + "alacritas", + "alarius", + "albere", + "albescere", + "album", + "albus", + "alea", + "alere", + "ales", + "alicubi", + "alicunde", + "alienare", + "alienus", + "aliialii", + "alimentum", + "aliquamdiu", + "aliquando", + "aliquantum", + "aliquantus", + "aliqui", + "aliquid", + "aliquis", + "aliquot", + "aliter", + "alius", + "allabi", + "allaborare", + "allicere", + "alligare", + "alloqui", + "almus", + "alumnus", + "ambire", + "ambitio", + "ambitiosus", + "ambitus", + "amburere", + "amens", + "amentia", + "amici", + "amicire", + "amictus", + "amissio", + "amittere", + "amovere", + "amplecti", + "amplexari", + "amplexus", + "amputare", + "anceps", + "angeh\u00e4ngtes", + "annona", + "anquirere", + "ante", + "antea", + "antecapere", + "antecedere", + "anteferre", + "antegredi", + "anteire", + "anteponere", + "antesignanus", + "antevenire", + "aperte", + "apium", + "apparare", + "apparatus", + "apparere", + "apparet", + "appellare", + "appellere", + "appetere", + "appetitio", + "appetitus", + "applicare", + "apponere", + "apportare", + "approbare", + "approbatio", + "appropinquare", + "apricus", + "aptare", + "aptus", + "apud", + "aqua", + "aquari", + "aquila", + "aquilo", + "aquosus", + "ara", + "arare", + "aratio", + "arator", + "aratrum", + "arbiter", + "arbitrari", + "arbitratu", + "arbitrium", + "arbor", + "arboreus", + "arbustum", + "arbutum", + "arbutus", + "arca", + "arcanus", + "arcere", + "arcessere", + "architectus", + "arcus", + "ardere", + "ardescere", + "ardor", + "arduus", + "area", + "arere", + "argentum", + "arguere", + "argumentari", + "argumentum", + "argutus", + "aridus", + "aries", + "arista", + "arma", + "armamenta", + "armare", + "armatura", + "armentum", + "armiger", + "armipotens", + "armus", + "arridere", + "arrigere", + "arripere", + "arrogans", + "arrogantia", + "arrogare", + "ars", + "artifex", + "artificiosus", + "artificium", + "artus", + "arvum", + "arx", + "as", + "ascendere", + "ascensus", + "ascire", + "asciscere", + "ascribere", + "asellus", + "aspectare", + "aspectus", + "asper", + "aspergere", + "asperitas", + "aspernari", + "aspicere", + "aspirare", + "assensio", + "assensus", + "assentari", + "assentatio", + "assentator", + "assentiri", + "assequi", + "asseverare", + "assidere", + "assiduus", + "assignare", + "assimulare", + "assistere", + "assuefacere", + "assuescere", + "assumere", + "assurgere", + "assus", + "ast", + "astare", + "astringere", + "astrologus", + "astrum", + "astus", + "astutus", + "at", + "ater", + "atomi", + "atomus", + "atque", + "atquin", + "atrium", + "atrocitas", + "atrox", + "attat!", + "attendere", + "attentus", + "atterere", + "attinere", + "attingere", + "attollere", + "attonare", + "attribuere", + "au!", + "auceps", + "auctio", + "auctor", + "auctoritas", + "audacia", + "audax", + "audere", + "audire", + "auditor", + "auditus", + "aufferre", + "augere", + "augur", + "augurari", + "augurium", + "augustus", + "aula", + "aulaeum", + "aura", + "auratus", + "aureus", + "auricula", + "auriga", + "auris", + "aurora", + "aurum", + "auscultare", + "auspex", + "auspicari", + "auspicium", + "auster", + "austerus", + "ausum", + "aut", + "autaut", + "autem", + "autumnus", + "auxiliaris", + "auxiliarius", + "auxilii", + "auxilium", + "avaritia", + "avarus", + "ave!", + "avehere", + "avellere", + "avena", + "avere", + "aversari", + "avertere", + "avidus", + "avis", + "avitus", + "avius", + "avocare", + "avunculus", + "avus", + "axis", + "baca", + "bacchari", + "baculum", + "balare", + "balatus", + "balbus", + "balneum", + "balteus", + "barathrum", + "barba", + "barbaria", + "barbaricus", + "barbarus", + "barbitos", + "beare", + "beatus", + "bellare", + "bellator", + "bellicosus", + "bellicus", + "bellum", + "bellus", + "belua", + "bene", + "beneficentia", + "beneficium", + "beneficus", + "benevolentia", + "benignitas", + "benignus", + "bestia", + "bibere", + "bibulus", + "bidens", + "biduum", + "bigae", + "biiugi", + "biiugis", + "bilis", + "bini", + "bipennis", + "bis", + "blandimentum", + "blandiri", + "blanditia", + "blandus", + "bonae", + "bonitas", + "bono", + "bonus", + "boreas", + "bos", + "bracchium", + "brevis", + "brevitas", + "bruma", + "bustum", + "buxus", + "caballus", + "cacumen", + "cadaver", + "cadere", + "caducus", + "cadus", + "caecitas", + "caecus", + "caedere", + "caedes", + "caelare", + "caelebs", + "caeles", + "caelestis", + "caelicola", + "caelum", + "caerimonia", + "caeruleus", + "caerulus", + "caesaries", + "caespes", + "caestus", + "caetra", + "caetratus", + "calamitas", + "calamitosus", + "calamus", + "calathus", + "calcare", + "calceus", + "calere", + "calidus", + "caligo", + "calix", + "calliditas", + "callidus", + "calo", + "calor", + "calumnia", + "calx", + "caminus", + "campester", + "campus", + "candere", + "candidatus", + "candidus", + "candor", + "canere", + "cani", + "canis", + "canities", + "canna", + "canorus", + "cantare", + "cantor", + "cantus", + "canus", + "capax", + "capella", + "caper", + "capere", + "capessere", + "capillus", + "capitalis", + "capra", + "caprea", + "capsa", + "captare", + "captiosus", + "captivitas", + "captivus", + "captus", + "capulus", + "caput", + "carbasus", + "carbo", + "carcer", + "cardo", + "carere", + "carina", + "caritas", + "carmen", + "carnifex", + "caro", + "carpere", + "carrus", + "carus", + "casa", + "casia", + "castanea", + "castellum", + "castigare", + "castra", + "castus", + "casus", + "catena", + "caterva", + "catillus", + "catinus", + "catulus", + "catus", + "cauda", + "caulis", + "caupo", + "caupona", + "caurus", + "causa", + "cautes", + "cautus", + "cava", + "cavare", + "cave", + "cavea", + "cavere", + "caverna", + "cavus", + "cedere", + "cedo", + "cedrus", + "celare", + "celeber", + "celebrare", + "celebritas", + "celer", + "celerare", + "celeritas", + "cella", + "celsus", + "cena", + "cenare", + "censere", + "censor", + "censorius", + "censura", + "census", + "centimanus", + "centum", + "centuria", + "centurio", + "cera", + "cerebrum", + "cereus", + "cernere", + "certare", + "certatim", + "certatio", + "certe", + "certiorem", + "certo", + "certus", + "cerva", + "cervix", + "cervus", + "cessare", + "ceu", + "chaos", + "charta", + "chiragra", + "chlamys", + "chorda", + "chorea", + "chorus", + "cibus", + "cicada", + "cicer", + "cicuta", + "ciere", + "cingere", + "cinis", + "circiter", + "circum", + "circumagere", + "circumcidere", + "circumdare", + "circumducere", + "circumfundere", + "circumicere", + "circumire", + "circumitus", + "circummittere", + "circummunire", + "circumsedere", + "circumsistere", + "circumspicere", + "circumstare", + "circumvallare", + "circumvehi", + "circumvenire", + "circus", + "ciris", + "cis", + "citare", + "citerior", + "cithara", + "citra", + "citus", + "civicus", + "civilis", + "civis", + "civitas", + "clades", + "clam", + "clamare", + "clamitare", + "clamor", + "clanculum", + "clangor", + "claritudo", + "clarus", + "classis", + "claudere", + "claustra", + "clavis", + "clavus", + "clemens", + "clementia", + "cliens", + "clientela", + "clipeus", + "clitellae", + "clivus", + "clunis", + "coaequare", + "coalescere", + "codex", + "codicillus", + "coemere", + "coepisse", + "coeptare", + "coeptum", + "coercere", + "coetus", + "coeunt", + "cogere", + "cogitare", + "cogitatio", + "cognatio", + "cognatus", + "cognitio", + "cognitor", + "cognomen", + "cognomentum", + "cognoscere", + "cohaerere", + "coheres", + "cohibere", + "cohors", + "cohortari", + "coire", + "coit", + "coitus", + "colere", + "collabi", + "collatio", + "collaudare", + "collega", + "collegium", + "colligare", + "colligere", + "collis", + "collocare", + "colloqui", + "colloquium", + "collucere", + "collum", + "collustrare", + "colonia", + "colonus", + "color", + "coluber", + "columba", + "columna", + "coma", + "comans", + "comburere", + "comedere", + "comere", + "comes", + "comicus", + "comis", + "comitari", + "comitas", + "comitatus", + "comitium", + "commaculare", + "commeare", + "commeatus", + "commemorare", + "commendare", + "commendatio", + "commentari", + "commentarius", + "commenticius", + "commercium", + "commerere", + "commilito", + "comminisci", + "comminus", + "commiscere", + "committere", + "commoditas", + "commodum", + "commodus", + "commorari", + "commotio", + "commovere", + "communicare", + "communire", + "communis", + "communitas", + "commutare", + "commutatio", + "comoedia", + "comparare", + "comparatio", + "compellare", + "compellere", + "compensare", + "comperire", + "compes", + "compescere", + "compilare", + "compitum", + "complecti", + "complere", + "complexus", + "complures", + "componere", + "comportare", + "compos", + "compositio", + "comprehendere", + "comprehensio", + "comprimere", + "comprobare", + "comptus", + "conari", + "conatus", + "concavus", + "concedere", + "concentus", + "concha", + "conchylium", + "concidere", + "conciere", + "conciliare", + "concilium", + "concinere", + "concinnus", + "concipere", + "concitare", + "concitatio", + "conclamare", + "concludere", + "conclusio", + "concordia", + "concors", + "concrescere", + "concubitus", + "concumbere", + "concupiscere", + "concurrere", + "concursio", + "concursus", + "concutere", + "condemnare", + "condere", + "condicio", + "condire", + "condiscere", + "conditor", + "condonare", + "conducere", + "conducit", + "conectere", + "conexus", + "conferre", + "confertus", + "confessio", + "confestim", + "conficere", + "confidere", + "configere", + "confirmare", + "confiteri", + "conflare", + "conflictare", + "confligere", + "conformare", + "conformatio", + "confugere", + "confundere", + "confusio", + "congerere", + "conglobare", + "congredi", + "congregare", + "congressus", + "congruere", + "conicere", + "coniectare", + "coniector", + "coniectura", + "coniti", + "coniugium", + "coniunctio", + "coniungere", + "coniurare", + "coniuratio", + "coniuratus", + "coniux", + "conqueri", + "conquiescere", + "consangineus", + "conscendere", + "conscientia", + "conscius", + "conscribere", + "consecrare", + "consectari", + "consensus", + "consentaneus", + "consentire", + "consequi", + "conserere", + "conservare", + "conservatio", + "conservator", + "conservus", + "consessus", + "considerare", + "considere", + "consignare", + "consilium", + "consimilis", + "consistere", + "consolari", + "consolatio", + "consors", + "conspectus", + "conspicari", + "conspicere", + "conspicuus", + "constans", + "constantia", + "constare", + "consternare", + "consternere", + "constituere", + "constitutio", + "constringere", + "construere", + "consuescere", + "consuetudo", + "consul", + "consularis", + "consulatus", + "consulere", + "consules", + "consultare", + "consulto", + "consultor", + "consultum", + "consultus", + "consumere", + "consurgere", + "contabulatio", + "contagio", + "contaminare", + "contegere", + "contemnere", + "contemplari", + "contemplatio", + "contemptio", + "contemptus", + "contendere", + "contentio", + "contentus", + "conterere", + "contexere", + "conticescere", + "continens", + "continentia", + "continere", + "contingere", + "continnus", + "continuare", + "continuo", + "contio", + "contionari", + "contorquere", + "contra", + "contractio", + "contrahere", + "contrarium", + "contrarius", + "controversia", + "contubernium", + "contueri", + "contumacia", + "contumelia", + "contundere", + "conturbare", + "contus", + "conu", + "convalescere", + "convallis", + "convehere", + "convellere", + "conveniens", + "convenientia", + "convenire", + "conventus", + "conversio", + "convertere", + "convexa", + "convexus", + "convicium", + "convictor", + "convincere", + "conviva", + "convivium", + "convocare", + "cooriri", + "copia", + "copiae", + "copiosus", + "copulare", + "coquere", + "cor", + "coram", + "corium", + "corniger", + "cornix", + "cornu", + "cornum", + "corona", + "coronare", + "corpus", + "correctio", + "corrigere", + "corripere", + "corruere", + "corrumpere", + "corruptela", + "cortex", + "coruscare", + "coruscus", + "corvus", + "corylus", + "cos", + "costa", + "cothurnus", + "cottidianus", + "cottidie", + "cras", + "crassitudo", + "crassus", + "crastinus", + "crater", + "cratis", + "creare", + "creber", + "crebro", + "credere", + "credibilis", + "credulitas", + "credulus", + "cremare", + "crepare", + "crepitare", + "crescere", + "crimen", + "criminari", + "criminatio", + "crinis", + "crista", + "croceus", + "crocodilus", + "crocus", + "cruciare", + "cruciatus", + "crudelis", + "crudelitas", + "crudus", + "cruentus", + "cruor", + "crus", + "crustulum", + "crux", + "cubare", + "cubiculum", + "cubile", + "cubitus", + "culex", + "culina", + "culmen", + "culmus", + "culpa", + "culpare", + "culter", + "cultor", + "cultura", + "cultus", + "cum", + "cumba", + "cumera", + "cumque", + "cumtum", + "cumulare", + "cunae", + "cunctari", + "cunctatio", + "cunctatum", + "cunctus", + "cuneus", + "cuniculus", + "cunnus", + "cupere", + "cupiditas", + "cupido", + "cupidus", + "cupressus", + "cur", + "cura", + "curare", + "curatio", + "curia", + "curiosus", + "currere", + "curriculum", + "curru", + "currus", + "cursus", + "curtus", + "curulis", + "curvare", + "curvus", + "cuspis", + "custodia", + "custodire", + "custos", + "cutis", + "cyathus", + "cycnus", + "cylindrus", + "cytisus", + "damma", + "damnare", + "damnatio", + "damnatus", + "damnosus", + "damnum", + "daps", + "dare", + "de", + "de-lectare", + "dea", + "debellare", + "debere", + "debilis", + "debilitare", + "debilitas", + "decedere", + "decedit", + "decem", + "decemvir", + "decemviri", + "decere", + "decernere", + "decerpere", + "decertare", + "decidere", + "deciens", + "decimus", + "decipere", + "declarare", + "declinare", + "declinatio", + "declivis", + "decor", + "decorare", + "decori", + "decorus", + "decretum", + "decumanus", + "decurrere", + "decus", + "decutere", + "dedecere", + "dedecus", + "dedere", + "dedicare", + "dedignari", + "dediticius", + "deditio", + "deditus", + "deducere", + "deesse", + "defatigare", + "defectio", + "defendere", + "defensare", + "defensio", + "defensor", + "deferre", + "defetisci", + "deficere", + "defigere", + "definire", + "definitio", + "deflagrare", + "defluere", + "defodere", + "deformis", + "defundere", + "defungi", + "degener", + "degenerare", + "degere", + "degredi", + "dehinc", + "dehiscere", + "deicere", + "deinceps", + "deinde", + "delabi", + "delatio", + "delator", + "delectatio", + "delectus", + "delenire", + "delere", + "deliberare", + "deliberatio", + "deliberavi", + "delibutus", + "delicatus", + "deliciae", + "delictum", + "deligare", + "deligere", + "delinquere", + "delirare", + "delirus", + "delphin", + "delubrum", + "demens", + "dementia", + "demere", + "demergere", + "demigrare", + "deminuere", + "demissus", + "demittere", + "demonstrare", + "demorari", + "demovere", + "demum", + "denarius", + "denegare", + "deni", + "denique", + "dens", + "densere", + "densus", + "denuntiare", + "deorsum", + "depascere", + "depellere", + "deperdere", + "deplorare", + "deponere", + "depopulari", + "deportare", + "deposcere", + "depravare", + "deprecari", + "deprehendere", + "deprimere", + "depromere", + "depugnare", + "deputare", + "deridere", + "deripere", + "derisor", + "descendere", + "desciscere", + "describere", + "deserere", + "desertor", + "desertus", + "desiderare", + "desidere", + "desiderium", + "desidia", + "designare", + "desilire", + "desinere", + "desipere", + "desistere", + "despectus", + "desperare", + "desperatio", + "despicere", + "despondere", + "destinare", + "destituere", + "destringere", + "desuetus", + "desuper", + "detegere", + "deterior", + "deterrere", + "detestabilis", + "detestari", + "detinere", + "detorquere", + "detractare", + "detrahere", + "detrectare", + "detrimentum", + "detrudere", + "deturbare", + "deus", + "devehere", + "devenire", + "devexus", + "devincere", + "devincire", + "devius", + "devovere", + "dexter", + "dextra", + "di", + "dialectica", + "dialecticus", + "dica", + "dicare", + "dicax", + "dicere", + "dicio", + "dictare", + "dictator", + "dictatura", + "dictitare", + "dictum", + "diducere", + "dies", + "differentia", + "differre", + "differtus", + "difficilis", + "difficultas", + "diffidere", + "diffindere", + "diffingere", + "diffugere", + "diffundere", + "digerere", + "digitus", + "dignari", + "dignatio", + "dignitas", + "dignoscere", + "dignus", + "digredi", + "diiudicare", + "dilabi", + "dilatare", + "dilectus", + "diligens", + "diligentia", + "diligere", + "dilucidus", + "diluvium", + "dimicare", + "dimicatio", + "dimidium", + "dimidius", + "dimittere", + "dimovere", + "dirae", + "directus", + "dirigere", + "dirimere", + "diripere", + "diruere", + "dirus", + "dis", + "discedere", + "disceptare", + "disceptatio", + "discere", + "discernere", + "discessus", + "discingere", + "disciplina", + "discipulus", + "disconvenire", + "discordare", + "discordia", + "discors", + "discrepare", + "discribere", + "discrimen", + "discriptio", + "discumbere", + "discurrere", + "discus", + "disertus", + "disicere", + "disiungere", + "dispar", + "dispergere", + "dispertire", + "dispicere", + "displicere", + "disponere", + "disputare", + "disputatio", + "dissensio", + "dissentire", + "disserere", + "dissidere", + "dissilire", + "dissimilis", + "dissimilitudo", + "dissimulare", + "dissimulatio", + "dissipare", + "dissolutus", + "dissolvere", + "distare", + "distendere", + "distinctio", + "distinere", + "distinguere", + "distorquere", + "distrahere", + "distribuere", + "disturbare", + "ditare", + "diu", + "diurnus", + "diuturnitas", + "diuturnus", + "divellere", + "diversi", + "diversitas", + "diversus", + "dives", + "dividere", + "divinare", + "divinatio", + "divinitas", + "divinus", + "divisio", + "divitiae", + "divus", + "docere", + "docilis", + "doctor", + "doctrina", + "doctus", + "documentum", + "dolere", + "dolium", + "dolor", + "dolosus", + "dolus", + "domare", + "domesticus", + "domi", + "domicilium", + "domina", + "dominari", + "dominatio", + "dominatus", + "dominus", + "domitor", + "domus", + "donare", + "donec", + "donum", + "dormire", + "dormitare", + "dorsum", + "dos", + "draco", + "druides", + "dryas", + "dubitare", + "dubitatio", + "dubius", + "ducenti", + "ducere", + "ductare", + "ductor", + "ductus", + "dudum", + "duellum", + "dulcedo", + "dulcis", + "dulex", + "dum", + "dumetum", + "dummodo", + "dumt\u00e1xat", + "dumus", + "duo", + "duodecim", + "duodecimus", + "duodeviginti", + "duplicare", + "durare", + "duritia", + "durus", + "duumvir", + "dux", + "e", + "e-minere", + "ea", + "ebrius", + "ebur", + "eburneus", + "eburnus", + "ecastor!", + "ecce", + "eccum", + "echinus", + "ecquis", + "eculeus", + "edax", + "edepol!", + "edere", + "edicere", + "edictum", + "ediscere", + "editus", + "edocere", + "educare", + "educere", + "effari", + "effector", + "effeminare", + "efferre", + "efferus", + "effetus", + "efficax", + "efficere", + "effigies", + "effingere", + "effluere", + "effodere", + "effrenatus", + "effugere", + "effugium", + "effulgere", + "effundere", + "egens", + "egenus", + "egere", + "egestas", + "ego", + "egredi", + "egregius", + "egressus", + "ehem", + "eheu", + "ehodum", + "ei", + "eia", + "eicere", + "eiusmodi", + "elabi", + "elaborare", + "elaboratus", + "elatio", + "electrum", + "elegans", + "elegantia", + "elegi", + "elementum", + "elephantus", + "elicere", + "elidere", + "eligere", + "eloquens", + "eloquentia", + "eloqui", + "eloquium", + "elucere", + "eludere", + "em", + "emendare", + "emensus", + "emere", + "emerere", + "emergere", + "emetiri", + "emicare", + "eminus", + "emittere", + "emolumentum", + "emori", + "emovere", + "emptio", + "emptor", + "emungere", + "en", + "enicare", + "enim", + "enimvero", + "eniti", + "ensis", + "enumerare", + "enuntiare", + "enuntiatio", + "eo", + "eodem", + "eos", + "eous", + "epistula", + "epulae", + "epulari", + "equa", + "eques", + "equester", + "equidem", + "equinus", + "equitare", + "equitatus", + "equus", + "era", + "erga", + "ergo", + "erigere", + "erilis", + "eripere", + "errare", + "error", + "erubescere", + "erudire", + "eruditio", + "eruere", + "erumpere", + "eruptio", + "erus", + "esca", + "escendere", + "esse", + "essedarius", + "essedum", + "esurire", + "et", + "etenim", + "etet", + "etiam", + "etiamnunc", + "etiamsi", + "etneque", + "etsi", + "eu", + "euhoe", + "eum", + "eunuchus", + "eurus", + "evadere", + "evanescere", + "evehere", + "evellere", + "evenire", + "eventum", + "eventus", + "evertere", + "evidens", + "evincere", + "evincire", + "evocare", + "ex", + "exaggerare", + "exagitare", + "examen", + "exardescere", + "exaudire", + "excedere", + "excellens", + "excellentia", + "excellere", + "excelsus", + "excerpere", + "excidere", + "excidium", + "excipere", + "excire", + "excitare", + "exclamare", + "excludere", + "excogitare", + "excolere", + "excors", + "excruciare", + "excubare", + "excubiae", + "excudere", + "excursio", + "excusare", + "excusatio", + "excutere", + "exedere", + "exemplar", + "exemplum", + "exercere", + "exercitare", + "exercitatio", + "exercitus", + "exhalare", + "exhaurire", + "exhibere", + "exhortari", + "exigere", + "exiguitas", + "exiguus", + "exilis", + "exim", + "eximere", + "eximius", + "exinde", + "exire", + "existimare", + "existimatio", + "exitiosus", + "exitium", + "exitus", + "exolescere", + "exoletus", + "exoptare", + "exorare", + "exordiri", + "exordium", + "exoriri", + "exornare", + "exosus", + "expedire", + "expedit", + "expeditio", + "expeditus", + "expellere", + "expendere", + "expergisci", + "experientia", + "experimentum", + "experiri", + "expers", + "expertus", + "expetere", + "expiare", + "explanare", + "explere", + "explicare", + "explicatio", + "explodere", + "explorare", + "explorator", + "exponere", + "exposcere", + "expostulare", + "exprimere", + "exprobrare", + "expugnare", + "expurgare", + "exquirere", + "exsanguis", + "exscindere", + "exsecare", + "exsequi", + "exsequiae", + "exsilire", + "exsilium", + "exsistere", + "exsolvere", + "exspectare", + "exspectatio", + "exspirare", + "exstare", + "exstimulare", + "exstinguere", + "exstruere", + "exsul", + "exsulare", + "exsultare", + "exsuperare", + "exsurgere", + "exta", + "extemplo", + "extendere", + "extenuare", + "exter", + "exterior", + "exterminare", + "externus", + "exterrere", + "extimescere", + "extollere", + "extorquere", + "extra", + "extrahere", + "extremitas", + "extrinsecus", + "extrudere", + "extundere", + "exturbare", + "exuere", + "exurere", + "exuviae", + "faba", + "fabella", + "faber", + "fabrica", + "fabricari", + "fabula", + "fabulam", + "fabulosus", + "facere", + "facetus", + "facies", + "facile", + "facilis", + "facilitas", + "facinus", + "factio", + "factiosus", + "factitare", + "factum", + "facultas", + "facundia", + "facundus", + "faex", + "fagus", + "fallacia", + "fallax", + "fallere", + "fallit", + "falsus", + "falx", + "fama", + "fames", + "familia", + "familiaris", + "familiaritas", + "famosus", + "famula", + "famulus", + "fanum", + "far", + "farcire", + "fari", + "fas", + "fasces", + "fascis", + "fasti", + "fastidiosus", + "fastidire", + "fastidium", + "fastigium", + "fastus", + "fatalis", + "fateri", + "fatigare", + "fatiscere", + "fatum", + "fauces", + "faustus", + "fautor", + "favere", + "favilla", + "favor", + "favus", + "fax", + "febris", + "fecundus", + "felicitas", + "felix", + "femina", + "femineus", + "femur", + "fenerator", + "fenestra", + "fenus", + "fera", + "feralia", + "feralis", + "ferax", + "fere", + "feriae", + "ferinus", + "ferire", + "feritas", + "ferme", + "ferocia", + "ferox", + "ferratus", + "ferre", + "ferreus", + "ferri", + "ferrugo", + "ferrum", + "fertilis", + "ferus", + "fervere", + "fervidus", + "fessus", + "festinare", + "festinatio", + "festum", + "festus", + "fetiales", + "fetus", + "fibra", + "fibula", + "ficus", + "fidelis", + "fidem", + "fidere", + "fides", + "fidicen", + "fiducia", + "fidus", + "fieri", + "figere", + "figura", + "filia", + "filius", + "filum", + "fimum", + "findere", + "fingere", + "finire", + "finis", + "finitimus", + "firmare", + "firmitas", + "firmus", + "fiscus", + "fissum", + "fistula", + "fit", + "flagellum", + "flagitare", + "flagitiosus", + "flagitium", + "flagrare", + "flamen", + "flamma", + "flammare", + "flare", + "flatus", + "flavere", + "flavus", + "flebilis", + "flectere", + "flere", + "fletus", + "flexus", + "florere", + "flos", + "fluctuare", + "fluctus", + "fluentum", + "fluere", + "fluitare", + "flumen", + "fluvius", + "fluxus", + "focus", + "fodere", + "foedare", + "foederatus", + "foedus", + "folium", + "fomentum", + "fons", + "foramen", + "foras", + "forceps", + "forensis", + "foris", + "forma", + "formare", + "formica", + "formidare", + "formido", + "formidolosus", + "formosus", + "formula", + "fornax", + "fornix", + "fors", + "fortasse", + "fortassis", + "fortis", + "fortisan", + "fortitudo", + "fortuitus", + "fortuna", + "fortunatus", + "forum", + "fossa", + "fovea", + "fovere", + "fragilis", + "fragmen", + "fragor", + "fragrare", + "frangere", + "frater", + "fraternus", + "fraudare", + "fraus", + "fraxinus", + "fremere", + "fremitus", + "frenare", + "frenum", + "frequentare", + "frequentia", + "fretum", + "fretus", + "frigere", + "frigidus", + "frigus", + "frondere", + "frondosus", + "frons", + "fructuosus", + "fructus", + "frugalitas", + "frugi", + "frui", + "frumentari", + "frumentarius", + "frumentatio", + "frumentum", + "frustra", + "frustrari", + "frustum", + "frutex", + "frux", + "fr\u011bquens", + "fucus", + "fuga", + "fugare", + "fugax", + "fugere", + "fugit", + "fugitare", + "fugitivus", + "fulcire", + "fulcus", + "fulgere", + "fulgor", + "fulgur", + "fulmen", + "fumare", + "fumus", + "funda", + "fundamentum", + "fundare", + "fundere", + "funditor", + "funditus", + "fundus", + "funestus", + "fungi", + "funis", + "funus", + "fur", + "furca", + "furcifer", + "furere", + "furia", + "furialis", + "furiosus", + "furnus", + "furor", + "furtim", + "furtivus", + "furtum", + "fuscus", + "fuse", + "fustis", + "futilis", + "futurus", + "galea", + "gallina", + "gallus", + "garrire", + "garrulus", + "gaudere", + "gaudium", + "gaza", + "gelidus", + "gelu", + "gemellus", + "gemere", + "geminare", + "geminus", + "gemitus", + "gemma", + "gena", + "gener", + "generare", + "generatim", + "generosus", + "genetrix", + "genialis", + "genitor", + "genius", + "gens", + "genu", + "genus", + "geometres", + "geometria", + "geometricus", + "gerere", + "germanus", + "gestare", + "gestire", + "gestus", + "gignere", + "glacies", + "gladiator", + "gladius", + "glans", + "glaucus", + "gleba", + "gliscere", + "globosus", + "globus", + "glomerare", + "gloria", + "gloriari", + "gloriosus", + "gnarus", + "gnatus", + "gracilis", + "gradatim", + "gradi", + "gradum", + "gradus", + "gramen", + "gramineus", + "grammatica", + "grammaticus", + "grandis", + "grando", + "granum", + "grassari", + "gratari", + "grates", + "gratia", + "gratiam", + "gratificari", + "gratiosus", + "gratis", + "gratuitus", + "gratulari", + "gratulatio", + "gratus", + "gravare", + "grave", + "gravidus", + "gravis", + "gravitas", + "gregarius", + "gremium", + "gressus", + "grex", + "grus", + "gubernare", + "gubernator", + "gula", + "gurges", + "gustare", + "gutta", + "guttur", + "gymnasium", + "gyrus", + "habena", + "habere", + "habilis", + "habitare", + "habitus", + "hac", + "hactenus", + "haec", + "haedus", + "haerere", + "hahahae!", + "hallec", + "hamus", + "harena", + "harundo", + "haruspex", + "haruspicina", + "hasta", + "hastati", + "hastatus", + "hastile", + "haud", + "haudquaquam", + "haurire", + "hebes", + "hedera", + "helleborum", + "hem!", + "herba", + "hercule!", + "hereditas", + "heres", + "heros", + "hesperius", + "hesternus", + "heu", + "heus!", + "hiare", + "hiatus", + "hiberna", + "hibernare", + "hibernus", + "hic", + "hiemare", + "hiems", + "hilaris", + "hilaritas", + "hilarus", + "hinc", + "hircus", + "hirsutus", + "hispidus", + "historia", + "histrio", + "hoc", + "hodie", + "hodiernus", + "holus", + "homo", + "honestas", + "honestus", + "honorare", + "honores", + "honos", + "hora", + "hornus", + "horrendus", + "horrere", + "horrescere", + "horreum", + "horribilis", + "horridus", + "horror", + "hortari", + "hortulus", + "hortus", + "hospes", + "hospitalis", + "hospitium", + "hospitus", + "hostes", + "hostia", + "hostilis", + "hostis", + "hui", + "huiuscemodi", + "humanitas", + "humanus", + "humare", + "humi", + "humidus", + "humilis", + "humilitas", + "humor", + "humus", + "hyacinthus", + "hydrus", + "hymenaeus", + "h\u011bri", + "i", + "iacere", + "iactare", + "iactura", + "iactus", + "iaculari", + "iaculum", + "iam", + "iambus", + "iamiam", + "ianitor", + "ianua", + "ibi", + "ibidem", + "icisse", + "ictus", + "id", + "idcirco", + "idem", + "identidem", + "ideo", + "idoneus", + "idus", + "iecur", + "ieiunium", + "ieiunus", + "igitur", + "ignarus", + "ignavia", + "ignavus", + "igneus", + "ignipotens", + "ignis", + "ignobilis", + "ignominia", + "ignorare", + "ignoratio", + "ignoscere", + "ignotus", + "ilex", + "ilia", + "ilicet", + "ilico", + "illabi", + "illacrimabilis", + "ille", + "illecebra", + "illic", + "illicere", + "illidere", + "illigare", + "illinc", + "illinere", + "illo", + "illuc", + "illudere", + "illustrare", + "illustris", + "illutus", + "imago", + "imbecillitas", + "imbecillus", + "imbellis", + "imber", + "imberbis", + "imbuere", + "imitari", + "imitatio", + "imitator", + "immanis", + "immemor", + "immensus", + "immerens", + "immeritus", + "imminere", + "imminuere", + "immitis", + "immittere", + "immo", + "immobilis", + "immoderatus", + "immodicus", + "immolare", + "immortalis", + "immortalitas", + "immotus", + "immundus", + "immunis", + "immutabilis", + "immutare", + "impar", + "impatiens", + "impavidus", + "impedimentum", + "impedire", + "impeditus", + "impendere", + "impensa", + "imperare", + "imperator", + "imperatorius", + "imperiosus", + "imperitare", + "imperitia", + "imperitus", + "imperium", + "impertire", + "impetrare", + "impetus", + "impiger", + "impius", + "implere", + "implicare", + "implorare", + "imponere", + "importare", + "importunus", + "impotens", + "impransus", + "imprimere", + "imprimis", + "improbare", + "improbitas", + "improbus", + "improvisus", + "imprudens", + "imprudentia", + "impubis", + "impudens", + "impudentia", + "impudicitia", + "impugnare", + "impulsus", + "impune", + "impunitas", + "impurus", + "imputare", + "imus", + "in", + "inaedificare", + "inanis", + "inauditus", + "incalescere", + "incassum", + "incautus", + "incedere", + "incendere", + "incendium", + "inceptare", + "inceptum", + "incertus", + "incessere", + "incessus", + "incestus", + "incidere", + "incingere", + "incipere", + "incitamentum", + "incitare", + "inclinare", + "inclinatio", + "includere", + "inclutus", + "incognitus", + "incohare", + "incola", + "incolere", + "incolumis", + "incolumitas", + "incommodum", + "incommodus", + "incomptus", + "inconcinnus", + "inconditus", + "inconstans", + "inconstantia", + "incontinens", + "incorruptus", + "incredibilis", + "increpare", + "increpitare", + "incruentus", + "incubare", + "incultus", + "incumbere", + "incuria", + "incuriosus", + "incurrere", + "incursare", + "incursio", + "incursus", + "incus", + "incusare", + "incutere", + "inde", + "indecoris", + "indecorus", + "indere", + "index", + "indicare", + "indicere", + "indicium", + "indigentia", + "indigere", + "indignari", + "indignatio", + "indignitas", + "indignus", + "individuum", + "individuus", + "indocilis", + "indoctus", + "indolentia", + "indolescere", + "indomitus", + "indotatus", + "inducere", + "induere", + "indulgere", + "industria", + "indutiae", + "ineptus", + "inermis", + "iners", + "inertia", + "inesse", + "inexpertus", + "infamia", + "infamis", + "infandus", + "infans", + "infaustus", + "infectus", + "infelix", + "infensus", + "inferi", + "inferiae", + "infernus", + "inferre", + "inferus", + "infestus", + "inficere", + "infidelis", + "infidus", + "infigere", + "infinitas", + "infinitio", + "infinitus", + "infirmare", + "infirmitas", + "infirmus", + "infit", + "infitiari", + "inflammare", + "inflare", + "inflectere", + "influere", + "infodere", + "informare", + "informis", + "infra", + "infringere", + "infundere", + "ingeminare", + "ingemiscere", + "ingeniosus", + "ingenium", + "ingens", + "ingenuus", + "ingerere", + "inglorius", + "ingratus", + "ingredi", + "ingruere", + "inguen", + "inhaerere", + "inhiare", + "inhibere", + "inhonestus", + "inhospitalis", + "inhumanus", + "inhumatus", + "inicere", + "iniquitas", + "iniquus", + "inire", + "initia", + "initium", + "iniungere", + "iniuria", + "iniuriosus", + "iniurius", + "iniussu", + "iniustitia", + "iniustus", + "innare", + "innasci", + "innatus", + "innectere", + "inniti", + "innocens", + "innocentia", + "innocuus", + "innoxius", + "innumerabilis", + "innumerus", + "innupta", + "inopia", + "inopinans", + "inopinatus", + "inops", + "inquam", + "inquietus", + "inquinare", + "inquirere", + "insania", + "insanire", + "insanus", + "insciens", + "inscientia", + "inscitia", + "inscitus", + "inscius", + "inscribere", + "insectari", + "insequi", + "inserere", + "insidere", + "insidiae", + "insigne", + "insignis", + "insimulare", + "insipiens", + "insistere", + "insolens", + "insolentia", + "insolitus", + "insonare", + "insons", + "inspectare", + "inspicere", + "inspirare", + "instar", + "instare", + "instaurare", + "instigare", + "instillare", + "instituere", + "institutio", + "institutum", + "instruere", + "instrumentum", + "insuetus", + "insula", + "insultare", + "insumere", + "insuper", + "insurgere", + "intactus", + "integer", + "integere", + "integritas", + "intellegentia", + "intellegere", + "intemperantia", + "intempestivus", + "intempestus", + "intendere", + "intentare", + "inter", + "intercedere", + "intercessio", + "intercipere", + "intercludere", + "interdicere", + "interdictum", + "interdiu", + "interdum", + "interea", + "interesse", + "interfector", + "interficere", + "intericere", + "interim", + "interimere", + "interior", + "interire", + "interitus", + "intermittere", + "internoscere", + "internus", + "interpellare", + "interponere", + "interpres", + "interpretari", + "interpretatio", + "interregum", + "interrex", + "interritus", + "interrogare", + "interrogatio", + "interrumpere", + "intervallum", + "intervenire", + "intestinus", + "intexere", + "intimus", + "intolerabilis", + "intolerandus", + "intonare", + "intonsus", + "intorquere", + "intra", + "intrare", + "intro", + "introducere", + "introire", + "introitus", + "intromittere", + "introrsum", + "introspicere", + "intueri", + "intumescere", + "intus", + "intutus", + "inula", + "inultus", + "inunguere", + "inusitatus", + "inutilis", + "invadere", + "invalidus", + "invehere", + "invehi", + "invenire", + "inventio", + "inventor", + "inventum", + "invertere", + "investigare", + "investigatio", + "inveterare", + "inveterascere", + "invicem", + "invictus", + "invidere", + "invidia", + "invidiosus", + "invidus", + "inviolatus", + "invisere", + "invisus", + "invitare", + "invitus", + "invius", + "invocare", + "involvere", + "io!", + "iocari", + "iocosus", + "ipse", + "ira", + "iracundia", + "iracundus", + "irasci", + "iratus", + "ire", + "irridere", + "irrigare", + "irriguus", + "irritare", + "irritus", + "irruere", + "irrumpere", + "is", + "iste", + "istic", + "istinc", + "istuc", + "ita", + "itan", + "itaque", + "item", + "iter", + "iterare", + "iterum", + "itidem", + "iuba", + "iubeo", + "iubere", + "iucunditas", + "iucundus", + "iudex", + "iudicare", + "iudicium", + "iugalis", + "iugerum", + "iugis", + "iugulare", + "iugulum", + "iugum", + "iumentum", + "iunctura", + "iungere", + "iunior", + "iuniores", + "iurare", + "iuratus", + "iure", + "iurgare", + "iurgium", + "ius", + "iussu", + "iussum", + "iustitia", + "iustus", + "iuvare", + "iuvenalis", + "iuvencus", + "iuvenis", + "iuventa", + "iuventas", + "iuventus", + "iuxta", + "labare", + "labefactare", + "labes", + "labi", + "labor", + "laborare", + "laboremne", + "laboriosus", + "labrum", + "lac", + "lacer", + "lacerare", + "lacertus", + "lacessere", + "lacrima", + "lacrimare", + "lacrimosus", + "lactuca", + "lacus", + "laedere", + "laetari", + "laetitia", + "laetus", + "laevus", + "lagoena", + "lambere", + "lamentari", + "lamentatio", + "lampas", + "lana", + "laneus", + "languere", + "languidus", + "languor", + "laniare", + "laniger", + "lanx", + "lapillus", + "lapis", + "lapsus", + "laqueus", + "lar", + "largiri", + "largitio", + "largus", + "laridum", + "lascivia", + "lascivire", + "lascivus", + "lassare", + "lassitudo", + "lassus", + "latebra", + "later", + "latere", + "latericius", + "latex", + "latitudo", + "latrare", + "latratus", + "latro", + "latrocinium", + "latus", + "laudabilis", + "laudare", + "laudatio", + "laudator", + "laurea", + "laurus", + "laus", + "lautus", + "lavare", + "laxare", + "laxus", + "lectica", + "lector", + "lectus", + "legare", + "legatio", + "legatus", + "legere", + "leges", + "legio", + "legionarius", + "legiones", + "legitimus", + "lembus", + "lenire", + "lenis", + "lenitas", + "leno", + "lentus", + "leo", + "lepidus", + "lepos", + "lepus", + "letalis", + "letum", + "levamentum", + "levare", + "levatio", + "levis", + "levitas", + "lex", + "libare", + "libellus", + "libens", + "liber", + "liberalis", + "liberalitas", + "liberare", + "liberi", + "libertas", + "libertinus", + "libertus", + "libet", + "libidinosus", + "libido", + "libra", + "librare", + "libum", + "liburna", + "liburnica", + "licens", + "licentia", + "licet", + "lictor", + "ligare", + "lignum", + "ligo", + "ligurrire", + "lilium", + "lima", + "limare", + "limen", + "limes", + "limus", + "linea", + "lineamentum", + "linere", + "lingua", + "linquere", + "linter", + "linteum", + "linum", + "lippus", + "liquefacere", + "liquere", + "liqui", + "liquidus", + "liquor", + "lis", + "littera", + "litteras", + "litteris", + "litura", + "litus", + "lituus", + "lividus", + "livor", + "lixa", + "loca", + "locare", + "loci", + "loculus", + "locuples", + "locupletare", + "locus", + "longaevus", + "longe", + "longinquitas", + "longinquus", + "longitudo", + "longurius", + "longus", + "loquax", + "loqui", + "lorica", + "lorum", + "lubricus", + "luce", + "lucellum", + "lucere", + "lucerna", + "lucidus", + "lucifer", + "lucrum", + "luctari", + "luctuosus", + "luctus", + "lucus", + "ludere", + "ludibrium", + "ludicer", + "ludicrum", + "ludos", + "ludus", + "luere", + "lugere", + "lugubris", + "lumbus", + "lumen", + "luna", + "lupinum", + "lupinus", + "lupus", + "luridus", + "lustrare", + "lustrum", + "lusus", + "lutulentus", + "lutum", + "lux", + "luxuria", + "luxuriare", + "luxuries", + "luxuriosus", + "luxus", + "lympha", + "lynx", + "lyra", + "macellum", + "macer", + "macerare", + "machina", + "machinatio", + "macies", + "mactare", + "macula", + "maculare", + "madefacere", + "madere", + "madidus", + "maerere", + "maeror", + "maestitia", + "maestus", + "magicus", + "magis", + "magister", + "magistra", + "magistratus", + "magna", + "magnam", + "magnanimus", + "magnificentia", + "magnificus", + "magnitudo", + "magno", + "magnopere", + "magnum", + "magnus", + "magus", + "maiestas", + "maiestatis", + "maior", + "maiores", + "mala", + "maledicere", + "maledictum", + "maleficium", + "malignus", + "malitia", + "malitiosus", + "malle", + "malum", + "malus", + "malva", + "mamma", + "manare", + "mancipium", + "mancus", + "mandare", + "mandatum", + "mandere", + "mane", + "manere", + "manes", + "manifestus", + "manipularis", + "manipulus", + "mannus", + "mansuetudo", + "manus", + "mappa", + "mare", + "margo", + "marinus", + "maritimus", + "maritus", + "marmor", + "marmoreus", + "mas", + "masculus", + "mater", + "materia", + "materies", + "maternus", + "mathematicus", + "matrimonium", + "matrona", + "maturare", + "maturitas", + "maturus", + "matutinus", + "maximus", + "mea", + "meare", + "mederi", + "media", + "medicamen", + "medicina", + "medicus", + "medimnum", + "mediocris", + "mediocritas", + "meditari", + "meditatio", + "meditatus", + "medium", + "medius", + "medulla", + "mehercules!", + "mei", + "meis", + "mel", + "membra", + "membrana", + "membrum", + "meminisse", + "memor", + "memorabilis", + "memorare", + "memoria", + "memoriter", + "mendacium", + "mendax", + "mendosus", + "mendum", + "mens", + "mensa", + "mensis", + "mensura", + "mensus", + "mentio", + "mentiri", + "mentitus", + "mentum", + "mercari", + "mercator", + "mercatura", + "mercennarius", + "merces", + "merere", + "meretricius", + "meretrix", + "mergere", + "meridies", + "merito", + "meritum", + "meritus", + "mersare", + "merula", + "merum", + "merus", + "merx", + "messis", + "meta", + "metallum", + "metere", + "metiri", + "metuere", + "metus", + "micare", + "migrare", + "miles", + "militare", + "militaris", + "milites", + "militia", + "mille", + "mima", + "mimus", + "mina", + "minae", + "minari", + "minax", + "mingere", + "minister", + "ministerium", + "ministrare", + "minitari", + "minor", + "minuere", + "minus", + "minutus", + "mirabilis", + "miraculum", + "mirari", + "mirificus", + "mirum", + "mirus", + "miscere", + "miser", + "miserabilis", + "miserari", + "miseratio", + "misereri", + "miseret", + "miseria", + "misericordia", + "missibils", + "missio", + "mitigare", + "mitis", + "mitte", + "mittere", + "mobilis", + "mobilitas", + "moderari", + "moderatio", + "moderator", + "moderatus", + "modestia", + "modestus", + "modicus", + "modius", + "modo", + "modulari", + "modulus", + "modus", + "moechus", + "moenia", + "mola", + "moles", + "molestia", + "molestus", + "moliri", + "mollire", + "mollis", + "mollitia", + "momenta", + "momentum", + "monere", + "monimentum", + "monitor", + "monitum", + "monitus", + "mons", + "monstrare", + "monstrum", + "montanus", + "montes", + "mora", + "morari", + "moratus", + "morbundus", + "morbus", + "mordax", + "mordere", + "more", + "morem", + "mori", + "mors", + "morsus", + "mortalis", + "mortifer", + "mortuus", + "mos", + "motio", + "motus", + "movere", + "mox", + "mucro", + "mugire", + "mugitus", + "mula", + "mulcere", + "muliebris", + "mulier", + "multa", + "multare", + "multi", + "multiplex", + "multitudo", + "multo", + "multum", + "multus", + "mulus", + "mundus", + "munera", + "munia", + "municeps", + "municipium", + "munificentia", + "munimentum", + "munire", + "munitio", + "munus", + "murex", + "muria", + "murmur", + "murra", + "murus", + "mus", + "musculus", + "muscus", + "musica", + "musicus", + "mutabilis", + "mutare", + "mutatio", + "mutuari", + "mutus", + "mutuus", + "myrica", + "myrtus", + "mysteria", + "naias", + "nam", + "namque", + "nancisci", + "narcissus", + "nardus", + "nare", + "naris", + "narrare", + "nasci", + "nasus", + "natales", + "natalis", + "natare", + "natio", + "natu", + "natura", + "naturalis", + "natus", + "naufragium", + "naufragus", + "nauta", + "nauticus", + "navalis", + "navigare", + "navigatio", + "navigium", + "navis", + "navita", + "navus", + "ne", + "ne-", + "nebula", + "nebulo", + "necare", + "necdum", + "necessarius", + "necesse", + "necessitas", + "necessitudo", + "necne", + "necopinatus", + "nectar", + "nectere", + "nedum", + "nefandus", + "nefarius", + "nefas", + "nefastus", + "negare", + "neglegentia", + "neglegere", + "negotiari", + "negotiator", + "negotium", + "nemo", + "nempe", + "nemus", + "nenia", + "nepos", + "neptis", + "nequam", + "nequaquam", + "neque", + "nequeet", + "nequiquam", + "nequire", + "nequitia", + "nervus", + "nescire", + "nescius", + "neu", + "neuter", + "neutiquam", + "neve", + "nex", + "ni", + "nidor", + "nidus", + "niger", + "nigrans", + "nihil", + "nihili", + "nihilo", + "nihilum", + "nil", + "nimbus", + "nimirum", + "nimis", + "nimium", + "nimius", + "nisi", + "nisus", + "nitere", + "niti", + "nitidus", + "nitor", + "nivalis", + "niveus", + "nix", + "nobilis", + "nobilitare", + "nobilitas", + "nocens", + "nocere", + "noctu", + "nocturnus", + "nodosus", + "nodus", + "nolle", + "nomen", + "nominare", + "nominatim", + "non", + "nondum", + "nonne", + "nonnullus", + "nonnumquam", + "nono", + "nonus", + "norma", + "nos", + "noscere", + "noster", + "nota", + "notabilis", + "notare", + "notio", + "notitia", + "notus", + "novare", + "novem", + "noverca", + "noviens", + "novissima", + "novissimum", + "novissimus", + "novitas", + "novus", + "nox", + "noxa", + "noxia", + "noxius", + "nubere", + "nubes", + "nubilus", + "nudare", + "nudus", + "nuere", + "nugae", + "nugari", + "nullus", + "num", + "numen", + "numerare", + "numero", + "numerus", + "nummus", + "numnam", + "numquam", + "nunc", + "nunciam", + "nuncupare", + "nuntiare", + "nuntius", + "nuper", + "nuptiae", + "nurus", + "nusquam", + "nutare", + "nutrire", + "nutrix", + "nutus", + "nux", + "nympha", + "o", + "ob", + "obducere", + "obesse", + "obesus", + "obicere", + "obiectare", + "obiex", + "obire", + "obitus", + "obiurgare", + "oblectare", + "oblectatio", + "obligare", + "oblinere", + "obliquus", + "oblitterare", + "oblitus", + "oblivio", + "oblivisci", + "oblivium", + "obnoxius", + "oboedire", + "oboriri", + "obruere", + "obscaenus", + "obscurare", + "obscuritas", + "obscurus", + "obsecrare", + "obsequi", + "obsequium", + "observare", + "observatio", + "obses", + "obsessio", + "obsidere", + "obsidetur", + "obsidio", + "obsidium", + "obsignare", + "obsistere", + "obsoletus", + "obsonium", + "obstare", + "obstetrix", + "obstinatus", + "obstrepere", + "obstringere", + "obstruere", + "obstupescere", + "obtemperare", + "obtendere", + "obtenditur", + "obtestari", + "obtinere", + "obtingere", + "obtrectare", + "obtruncare", + "obtundere", + "obtutus", + "obvenire", + "obvertere", + "obvia", + "obviam", + "obvius", + "occasio", + "occasus", + "occidere", + "occipere", + "occulere", + "occultare", + "occultus", + "occumbere", + "occupare", + "occupatio", + "occurrere", + "occursare", + "ocellus", + "ocior", + "ocius", + "octavus", + "octingenti", + "octo", + "octoginta", + "oculus", + "odiosus", + "odisse", + "odium", + "odor", + "odorari", + "odoratus", + "odores", + "offendere", + "offensa", + "offensio", + "offensus", + "offerre", + "officere", + "officia", + "officina", + "officiosus", + "officium", + "offundere", + "oh!", + "olea", + "oleaster", + "olere", + "oleum", + "olim", + "oliva", + "olivum", + "olor", + "omasum", + "omen", + "omittere", + "omnia", + "omnino", + "omnipotens", + "omnis", + "onerare", + "onerarius", + "onniti", + "onus", + "onustus", + "opacus", + "opera", + "operam", + "operire", + "operosus", + "opifex", + "opimus", + "opinabilis", + "opinari", + "opinatio", + "opinio", + "oportet", + "opperiri", + "oppetere", + "oppidanus", + "oppidum", + "opponere", + "opportunitas", + "opportunus", + "opprimere", + "opprobrium", + "oppugnare", + "oppugnatio", + "ops", + "optabilis", + "optare", + "optimates", + "optimus", + "optio", + "opto", + "opulentia", + "opulentus", + "opus", + "opusculum", + "ora", + "oraculum", + "orare", + "oratio", + "orationem", + "orator", + "oratorius", + "orbare", + "orbis", + "orbitas", + "orbus", + "ordinare", + "ordiri", + "ordo", + "orgia", + "oriens", + "origo", + "oriri", + "ornamentum", + "ornare", + "ornatus", + "ornus", + "ortus", + "os", + "osculum", + "ostendere", + "ostentare", + "ostentatio", + "ostentum", + "ostium", + "ostrea", + "ostrum", + "otiosus", + "otium", + "ovare", + "ovile", + "ovis", + "ovum", + "pabulari", + "pabulatio", + "pabulator", + "pabulum", + "pacare", + "pacatus", + "pace", + "pacisci", + "pactio", + "pactum", + "paelex", + "paene", + "paenitentia", + "paenitere", + "paenitet", + "pagina", + "pagus", + "palam", + "palari", + "palatum", + "palla", + "pallere", + "pallescere", + "pallidus", + "pallor", + "palma", + "palmes", + "palus", + "paluster", + "pampineus", + "pampinus", + "pandere", + "pandus", + "pangere", + "pangisse", + "panis", + "pannus", + "papae!", + "papaver", + "par", + "parare", + "parasitus", + "paratus", + "parcere", + "parcus", + "parens", + "parere", + "paries", + "pariter", + "parma", + "parochus", + "parricida", + "parricidium", + "pars", + "parsimonia", + "partes", + "particeps", + "particula", + "partim", + "partiri", + "partitio", + "partitus", + "parturire", + "partus", + "parum", + "parvulus", + "parvus", + "pascere", + "pascuum", + "passim", + "passus", + "pastor", + "pastus", + "patefacere", + "pater", + "patera", + "patere", + "paternus", + "patet", + "pati", + "patiens", + "patientia", + "patina", + "patrare", + "patres", + "patria", + "patricius", + "patrimonium", + "patrius", + "patrocinium", + "patronus", + "patruus", + "patulus", + "pauci", + "paucitas", + "paullatim", + "paullisper", + "paullulus", + "paullus", + "paulo", + "paulum", + "pauper", + "pauperies", + "pauperitas", + "pavere", + "pavidus", + "pavo", + "pavor", + "pax", + "peccare", + "peccatum", + "pecten", + "pectus", + "pecunia", + "pecus", + "pedem", + "pedes", + "pedester", + "pedibus", + "peditatus", + "pelagus", + "pellere", + "pellis", + "penates", + "pendere", + "penes", + "penetralia", + "penetralis", + "penetrare", + "penitus", + "penna", + "pensum", + "penuria", + "per", + "peragere", + "peragrare", + "percellere", + "perceptio", + "percipere", + "percontari", + "percunctari", + "percurrere", + "percussor", + "percutere", + "perdere", + "perditus", + "perducere", + "peregre", + "peregrinus", + "pererrare", + "perfectio", + "perfectus", + "perferre", + "perficere", + "perfidia", + "perfidus", + "perfringere", + "perfrui", + "perfuga", + "perfugere", + "perfugium", + "perfundere", + "pergere", + "perhibere", + "perhorrescere", + "periclitari", + "periculosus", + "periculum", + "perimere", + "perinde", + "perire", + "peritia", + "peritus", + "periurium", + "periurius", + "perlegere", + "perlucidus", + "permagnus", + "permanare", + "permanere", + "permiscere", + "permittere", + "permovere", + "permultus", + "permutare", + "perna", + "pernicies", + "perniciosus", + "pernix", + "pernoscere", + "perorare", + "perosus", + "perpauci", + "perpellere", + "perpeti", + "perpetrare", + "perpetuitas", + "perpetuus", + "perrumpere", + "persaepe", + "perscribere", + "persequi", + "perseverare", + "persolvere", + "persona", + "personare", + "perspicere", + "perspicuitas", + "perspicuus", + "perstare", + "persuadere", + "pertemptare", + "perterrere", + "pertimescere", + "pertinacia", + "pertinax", + "pertinere", + "pertractare", + "perturbare", + "perturbatio", + "perunguere", + "perurere", + "pervadere", + "pervenire", + "perversus", + "pervertere", + "pervicax", + "pervincere", + "pervius", + "pes", + "pestifer", + "pestilens", + "pestis", + "petere", + "petitio", + "petorritum", + "phalanx", + "pharetra", + "philosophari", + "philosophia", + "philosophus", + "physia", + "physicus", + "piaculum", + "piare", + "picea", + "piceus", + "pictor", + "pictura", + "pietas", + "piger", + "piget", + "pignus", + "pila", + "pilum", + "pilus", + "pineus", + "pingere", + "pinguis", + "pinna", + "pinus", + "piper", + "pirata", + "pirus", + "piscis", + "pistrinum", + "pituita", + "pius", + "pix", + "placare", + "placenta", + "placere", + "placet", + "placidus", + "placitus", + "plaga", + "plane", + "plangere", + "plangor", + "planities", + "planta", + "plantanus", + "planus", + "platea", + "plaudere", + "plaustrum", + "plausus", + "plebeius", + "plebis", + "plecti", + "plectrum", + "plenus", + "plerique", + "plerumque", + "plicare", + "plorare", + "pluit", + "pluma", + "plus", + "pluteus", + "pluvia", + "pluvius", + "poculum", + "poema", + "poena", + "poeta", + "pol!", + "polire", + "pollere", + "pollex", + "polliceri", + "pollicitatio", + "polluere", + "pollutus", + "polus", + "pomifer", + "pompa", + "pomum", + "ponderare", + "pondo", + "pondus", + "pone", + "ponere", + "pons", + "pontifex", + "pontificius", + "pontus", + "popina", + "poples", + "populare", + "populari", + "popularis", + "populatio", + "populus", + "porcus", + "porrigere", + "porro", + "porrum", + "porta", + "portare", + "portendere", + "portentum", + "porticus", + "portus", + "poscere", + "posse", + "possessio", + "possidere", + "post", + "postea", + "posteaquam", + "posterior", + "posteritas", + "posterus", + "posthac", + "postilla", + "postis", + "postponere", + "postquam", + "postremum", + "postremus", + "postridie", + "postulare", + "postulatum", + "potare", + "potens", + "potentia", + "potestas", + "potio", + "potior", + "potiri", + "potis", + "potius", + "potor", + "potus", + "prae", + "praeacutus", + "praebere", + "praecedere", + "praeceps", + "praeceptum", + "praecidere", + "praecingere:", + "praecipere", + "praecipitare", + "praecipue", + "praecipuus", + "praeclarus", + "praecludere", + "praeco", + "praeconium", + "praecordia", + "praecurrere", + "praeda", + "praedari", + "praedicare", + "praedicere", + "praedictio", + "praedictum", + "praediscere", + "praeditus", + "praedium", + "praedo", + "praeesse", + "praeferre", + "praefigere", + "praefluere", + "praegravare", + "praegredi", + "praemittere", + "praemium", + "praeoccupare", + "praeparare", + "praeponere", + "praepotens", + "praeruptus", + "praescribere", + "praesens", + "praesensio", + "praesentia", + "praesentire", + "praesepe", + "praesertim", + "praesidere", + "praesidium", + "praestabilis", + "praestans", + "praestantia", + "praestare", + "praestat", + "praesto", + "praesumere", + "praetendere", + "praeter", + "praeterea", + "praeterire", + "praeteritus", + "praetermittere", + "praeterquam", + "praetexere", + "praetexta", + "praetor", + "praetorianus", + "praetorium", + "praetorius", + "praetura", + "praevalere", + "praevalidus", + "praevenire", + "praevertere", + "prandere", + "pratum", + "pravitas", + "pravus", + "precari", + "preces", + "prehendere", + "premere", + "prensare", + "pretiosus", + "pretium", + "pridem", + "pridie", + "primarius", + "primas", + "primordium", + "primoris", + "primum", + "primus", + "princeps", + "principatus", + "principia", + "principium", + "prior", + "priscus", + "pristinus", + "prius", + "priusquam", + "privare", + "privatim", + "privatus", + "privignus", + "privus", + "pro", + "pro-", + "proavus", + "probabilis", + "probare", + "probatus", + "probitas", + "probrosus", + "probrum", + "probus", + "procax", + "procedere", + "procella", + "proceres", + "procerus", + "procidere", + "proclivis", + "proconsul", + "procreare", + "procul", + "procumbere", + "procurare", + "procuratio", + "procurator", + "procurrere", + "procus", + "prodere", + "prodesse", + "prodigium", + "prodigus", + "prodire", + "proditio", + "proditor", + "producere", + "proeliari", + "proelium", + "profanus", + "profecto", + "proferre", + "profestus", + "profiteri", + "profligare", + "profligatus", + "profugere", + "profugus", + "profundere", + "profundum", + "profundus", + "progenies", + "prognatus", + "progredi", + "progressio", + "prohibere", + "proicere", + "proinde", + "prolabi", + "prolatare", + "proles", + "prologus", + "proloqui", + "proluere", + "promere", + "prominere", + "promiscuus", + "promissum", + "promittere", + "promonturium", + "promovere", + "promptus", + "promulgare", + "pronuntiare", + "pronus", + "propago", + "prope", + "propellere", + "propemodum", + "propensus", + "properare", + "properus", + "propinquare", + "propinquitas", + "propinquus", + "propior", + "proponere", + "propositum", + "propraetor", + "proprius", + "propter", + "propterea", + "propugnare", + "propulsare", + "prorepere", + "prorogare", + "prorsus", + "proruere", + "prorumpere", + "proscribere", + "proscriptio", + "prosequi", + "prosilire", + "prospectare", + "prospectus", + "prosperus", + "prospicere", + "prosternere", + "protegere", + "protendere", + "proterere", + "protervus", + "proturbare", + "prout", + "provehere", + "provenire", + "proverbium", + "providentia", + "providere", + "providus", + "provincia", + "provincialis", + "provocare", + "provocatio", + "provolvere", + "proximi", + "prudens", + "prudentia", + "pruina", + "psaltria", + "puber", + "pubes", + "pubescere", + "publicanus", + "publicare", + "publice", + "publicus", + "pudendus", + "pudens", + "pudet", + "pudicitia", + "pudicus", + "pudor", + "puella", + "puer", + "puerilis", + "pueritia", + "puerpera", + "pugil", + "pugio", + "pugna", + "pugnare", + "pugnax", + "pugnus", + "pulcher", + "pulchritudo", + "pullus", + "pulmentum", + "pulmo", + "pulpitum", + "pulsare", + "pulsus", + "pultare", + "pulverulentus", + "pulvis", + "pumex", + "punctum", + "pungere", + "puniceus", + "punire", + "pupillus", + "puppis", + "purgare", + "purpura", + "purpureus", + "purus", + "pusillus", + "putare", + "puteal", + "puter", + "putere", + "puteus", + "putidus", + "pyra", + "qua", + "quadraginta", + "quadrans", + "quadrare", + "quadrigae", + "quadrigenti", + "quadrupes", + "quaerere", + "quaeritare", + "quaero", + "quaeso", + "quaestio", + "quaestor", + "quaestura", + "quaestus", + "quali", + "qualis", + "qualiscumque", + "qualitas", + "quam", + "quamlibet", + "quamquam", + "quamvis", + "quando", + "quando-", + "quandocumque", + "quandoque", + "quanto", + "quantum", + "quantus", + "quapropter", + "quare", + "quartus", + "quasi", + "quassare", + "quatenus", + "quater", + "quatere", + "quattuor", + "que", + "quem", + "quemadmodum", + "quercus", + "querela", + "queri", + "querimonia", + "querulus", + "questus", + "qui", + "quia", + "quicumque", + "quid", + "quid?", + "quidam", + "quidem", + "quidni?", + "quies", + "quiescere", + "quietus", + "quilibet", + "quin", + "quin?", + "quindecim", + "quingenti", + "quini", + "quinquaginta", + "quinque", + "quinqueremis", + "quintus", + "quippe", + "quire", + "quis", + "quisnam?", + "quispiam", + "quisquam", + "quisque", + "quisquis", + "quo", + "quoad", + "quocirca", + "quocumque", + "quod", + "quodsi", + "quom", + "quominus", + "quomodo", + "quondam", + "quoniam", + "quoque", + "quoqueversus", + "quor", + "quorsum?", + "quot", + "quotiens", + "quotus", + "rabidus", + "rabies", + "racemus", + "radere", + "radiare", + "radius", + "radix", + "raeda", + "ramus", + "rana", + "rapax", + "rapere", + "rapidus", + "rapina", + "raptare", + "raptim", + "raptor", + "raptum", + "raptus", + "rapulum", + "raro", + "rarus", + "raster", + "ratio", + "rationem", + "ratis", + "ratus", + "raucus", + "ravus", + "reapse", + "rebellare", + "rebellio", + "rebellis", + "recedere", + "recens", + "receptus", + "recessus", + "recidere", + "recinere", + "recipere", + "recitare", + "reclinare", + "recludere", + "reconciliare", + "recondere", + "reconditus", + "recordari", + "recordatio", + "recreare", + "recte", + "rector", + "rectus", + "recubare", + "recumbere", + "recuperare", + "recuperator", + "recurrere", + "recurvus", + "recusare", + "redarguere", + "reddere", + "redigere", + "redimere", + "redimire", + "redintegrare", + "redire", + "reditus", + "redonare", + "reducere", + "redundare", + "redux", + "refellere", + "referre", + "refert", + "refertus", + "reficere", + "refigere", + "reflectere", + "refluere", + "reformidare", + "refugere", + "refulgere", + "refundere", + "regalis", + "regere", + "regia", + "regimen", + "regina", + "regio", + "regius", + "regnare", + "regnari", + "regnator", + "regnum", + "regredi", + "regressus", + "regula", + "regulus", + "reicere", + "relabi", + "relaxare", + "relegare", + "relevare", + "religare", + "religio", + "religionem", + "religiosus", + "relinquere", + "reliquiae", + "reliquum", + "reliquus", + "remanere", + "remeare", + "remedium", + "remex", + "remigium", + "remissus", + "remittere", + "remorari", + "removere", + "remugire", + "remus", + "renasci", + "renes", + "renidere", + "renovare", + "renuere", + "renuntiare", + "reparare", + "repellere", + "repente", + "repentinus", + "repere", + "reperire", + "repetere", + "replere", + "reponere", + "reportare", + "reposcere", + "reprehendere", + "reprehensio", + "reprimere", + "repudiare", + "repugnare", + "repulsa", + "reputare", + "requies", + "requiescere", + "requirere", + "reri", + "res", + "rescindere", + "resciscere", + "rescribere", + "resecare", + "reserare", + "reservare", + "residere", + "resignare", + "resistere", + "resolvere", + "resonare", + "respicere", + "respirare", + "responare", + "respondere", + "respondet", + "responsum", + "restare", + "restinguere", + "restituere", + "resultare", + "resumere", + "resupinus", + "resurgere", + "rete", + "retegere", + "retemptare", + "reticere", + "retinere", + "retorquere", + "retractare", + "retrahere", + "retro", + "retrosum", + "reum", + "reus", + "revehere", + "revellere", + "reverentia", + "reversus", + "reverti", + "revincire", + "revisere", + "revocare", + "revolvere", + "rex", + "rhetor", + "rhetoricus", + "rhombus", + "rictus", + "ridere", + "ridiculus", + "rigare", + "rima", + "rimari", + "ripa", + "risus", + "rite", + "ritus", + "rivalis", + "rivus", + "rixa", + "robur", + "robustus", + "rodere", + "rogare", + "rogatio", + "rogitare", + "rogus", + "rorare", + "ros", + "rosa", + "roscidus", + "roseus", + "rostrum", + "rota", + "rotare", + "rotundus", + "ruber", + "rubere", + "rubescere", + "rubor", + "rudens", + "rudere", + "rudis", + "ruere", + "ruga", + "ruina", + "rumor", + "rumpere", + "rupes", + "ruricola", + "rursus", + "rus", + "rusticus", + "rutilus", + "saccus", + "sacer", + "sacerdos", + "sacerdotium", + "sacramentum", + "sacrare", + "sacrarium", + "sacrificare", + "sacrificium", + "sacrilegus", + "sacrum", + "saeculum", + "saepe", + "saepenumero", + "saepes", + "saepire", + "saeta", + "saevire", + "saevitia", + "saevus", + "sagax", + "sagitta", + "sagittarius", + "sal", + "salire", + "salix", + "salsus", + "saltare", + "saltem", + "saltus", + "saluber", + "salus", + "salutare", + "salutaris", + "salutem", + "salve!", + "salvere", + "salvus", + "sanare", + "sancire", + "sanctitas", + "sanctus", + "sane", + "sanguineus", + "sanguinulentus", + "sanguis", + "sanies", + "sanitas", + "sanus", + "sapere", + "sapiens", + "sapientia", + "sapor", + "sarcina", + "sarcire", + "sat", + "sata", + "satelles", + "satiare", + "satietas", + "satisfacere", + "satius", + "satur", + "satura", + "saturare", + "satus", + "satyrus", + "sauciare", + "saucius", + "saxum", + "scabies", + "scaena", + "scalae", + "scalpere", + "scandere", + "scapha", + "sceleratus", + "scelestus", + "scelus", + "sceptrum", + "schola", + "sciens", + "scientia", + "scilicet", + "scindere", + "scire", + "sciscere", + "scitum", + "scitus", + "scopulus", + "scortum", + "scriba", + "scribere", + "scrinium", + "scriptor", + "scriptum", + "scriptura", + "scrobis", + "scrupulus", + "scrutari", + "scurra", + "scurrari", + "scutum", + "scyphus", + "se", + "secare", + "secedere", + "secernere", + "secessio", + "secretum", + "secretus", + "sectari", + "secundo", + "secundum", + "secundus", + "securis", + "securitas", + "securus", + "secus", + "sed", + "sedare", + "sedatio", + "sedecim", + "sedere", + "sedes", + "sedile", + "seditio", + "seditiosus", + "seducere", + "sedulitas", + "sedulo", + "sedulus", + "seges", + "segnis", + "segnitia", + "segregare", + "seiungere", + "selectio", + "sella", + "sellam", + "semel", + "semen", + "semesus", + "seminex", + "semita", + "semovere", + "semper", + "sempiternus", + "senator", + "senatorius", + "senatus", + "senecta", + "senectus", + "senescere", + "senex", + "seni", + "senilis", + "senior", + "sensim", + "sensus", + "sententia", + "sentire", + "sentis", + "separare", + "separatim", + "sepelire", + "seponere", + "septem", + "septeni", + "septentriones", + "septimus", + "septingenti", + "septuaginta", + "sepulcrum", + "sepultura", + "sequax", + "sequi", + "sera", + "serenus", + "serere", + "series", + "serius", + "sermo", + "serpens", + "serpere", + "serta", + "serus", + "serva", + "servare", + "servilis", + "servire", + "servitium", + "servitus", + "servulus", + "servus", + "sescenti", + "sestertius", + "setius", + "seu", + "severitas", + "severus", + "sex", + "sexaginta", + "sextus", + "sexus", + "si", + "sibi", + "sic", + "sica", + "sicarius", + "siccare", + "siccus", + "sicuti", + "sidere", + "sidereus", + "sidus", + "sigillum", + "signa", + "signare", + "signifer", + "significare", + "significatio", + "signum", + "silentium", + "silere", + "silex", + "silva", + "silvestris", + "similis", + "similitudo", + "simplex", + "simplicitas", + "simul", + "simulac", + "simulacrum", + "simulare", + "simulat", + "simulatio", + "simultas", + "sin", + "sincerus", + "sine", + "sinere", + "singularis", + "singuli", + "sinister", + "sinus", + "siquidem", + "sis", + "sistere", + "sistit", + "sitire", + "sitis", + "situs", + "sive", + "sobrius", + "soccus", + "socer", + "socialis", + "sociare", + "societas", + "socius", + "socordia", + "socors", + "socrus", + "sodalis", + "sodes", + "sol", + "solacium", + "solari", + "solea", + "soleo", + "solere", + "solidus", + "solitudo", + "solium", + "sollemnis", + "sollers", + "sollertia", + "sollicitare", + "sollicitudo", + "sollicitus", + "solum", + "solus", + "solutus", + "solvere", + "somniare", + "somnium", + "somnus", + "sonare", + "sonipes", + "sonitus", + "sonorus", + "sonus", + "sopire", + "sopor", + "sordere", + "sordes", + "sordidus", + "sorites", + "soror", + "sors", + "sortiri", + "sospes", + "spargere", + "spatiari", + "spatiosus", + "spatium", + "specere", + "species", + "speciosus", + "spectabilis", + "spectaculum", + "spectare", + "spectator", + "spectatus", + "specula", + "speculari", + "speculator", + "speculum", + "specus", + "spelunca", + "sperare", + "spernere", + "spes", + "sphaera", + "spiculum", + "spina", + "spira", + "spirare", + "spiritus", + "spissus", + "splendere", + "splendidus", + "splendor", + "spolia", + "spoliare", + "spolium", + "spondere", + "sponsio", + "sponsor", + "sponsus", + "spuma", + "spumare", + "spumeus", + "squalere", + "squalidus", + "squalor", + "squama", + "squilla", + "stabilire", + "stabilis", + "stabilitas", + "stabulum", + "stadium", + "stagnum", + "stamen", + "stant", + "stare", + "statim", + "statio", + "stativa", + "stativus", + "statua", + "statuere", + "status", + "stella", + "sterilis", + "sternere", + "stertere", + "stilus", + "stimulare", + "stimulus", + "stipare", + "stipendia", + "stipendium", + "stipes", + "stipula", + "stirps", + "stola", + "stomachari", + "stomachus", + "strages", + "stramentum", + "stratum", + "strenuus", + "strepere", + "strepitus", + "stridere", + "stridor", + "stringere", + "struere", + "studere", + "studiosus", + "studium", + "stultitia", + "stultus", + "stupefacere", + "stupere", + "stuprum", + "suadere", + "suavis", + "suavitas", + "sub", + "subdere", + "subdolus", + "subducere", + "subesse", + "subicere", + "subigere", + "subinde", + "subire", + "subitus", + "sublabi", + "sublevare", + "sublica", + "sublime", + "sublimis", + "submergere", + "submittere", + "submovere", + "subnectere", + "subnisus", + "suboles", + "subridere", + "subsellium", + "subsequi", + "subsidere", + "subsidium", + "subsistere", + "subter", + "subtilis", + "subtilitas", + "subtrahere", + "suburbanus", + "subvenire", + "subvertere", + "succedere", + "succendere", + "successor", + "successus", + "succidere", + "succingere", + "succumbere", + "succurrere", + "sucus", + "sudare", + "sudis", + "sudor", + "suescere", + "suetus", + "suevisse", + "sufficere", + "suffragium", + "suffundere", + "sui", + "sulcus", + "sulphur", + "sumere", + "summa", + "summum", + "summus", + "sumptus", + "suo", + "supellex", + "super", + "superare", + "superbia", + "superbus", + "superesse", + "superi", + "superior", + "supernus", + "superstes", + "superstitio", + "superstitiosus", + "superus", + "supervacuaneus", + "supervacuus", + "supervenire", + "supinus", + "suppeditare", + "suppetere", + "supplementum", + "supplere", + "supplex", + "supplicare", + "supplicatio", + "supplicium", + "supponere", + "supportare", + "supprimere", + "supra", + "supremus", + "sura", + "surdus", + "surgere", + "surripere", + "sus", + "suscensere", + "suscipere", + "suscitare", + "suspectare", + "suspectus", + "suspendere", + "suspensus", + "suspicari", + "suspicere", + "suspicio", + "suspirare", + "sustentare", + "sustinere", + "sutor", + "suus", + "tabella", + "taberna", + "tabernaculum", + "tabes", + "tabula", + "tabulae", + "tabulatum", + "tabum", + "tacere", + "taciturnus", + "tacitus", + "tactus", + "taeda", + "taedet", + "taedium", + "taeter", + "talentum", + "talis", + "talus", + "tam", + "tamen", + "tametsi", + "tamquam", + "tandem", + "tangere", + "tantisper", + "tantopere", + "tantulus", + "tantum", + "tantummodo", + "tantus", + "tantusdem", + "tardare", + "tarditas", + "tardus", + "taurus", + "taxus", + "te", + "tectum", + "tegere", + "tegimen", + "tegimentum", + "tela", + "tellus", + "telum", + "temerare", + "temerarius", + "temere", + "temeritas", + "temnere", + "temperantia", + "temperare", + "temperatio", + "tempestas", + "tempestivus", + "templum", + "temptare", + "tempus", + "temulentus", + "tenax", + "tendere", + "tenebrae", + "tener", + "tenere", + "tentorium", + "tenuare", + "tenuis", + "tenuitas", + "tenus", + "tepefacere", + "tepere", + "tepidus", + "ter", + "terere", + "teres", + "terga", + "tergum", + "terminare", + "terminus", + "terni", + "terra", + "terrenus", + "terrere", + "terrester", + "terribilis", + "territare", + "terror", + "tertius", + "testa", + "testamentum", + "testari", + "testatus", + "testificari", + "testimonium", + "testis", + "testudo", + "texere", + "thalamus", + "theatrum", + "thesaurus", + "thymum", + "thyrsus", + "tibia", + "tibicen", + "tignum", + "tigris", + "timeo", + "timere", + "timiditas", + "timidus", + "timor", + "tinea", + "tinguere", + "titulus", + "toga", + "togatus", + "tolerabilis", + "tolerare", + "tollere", + "tonare", + "tondere", + "tonitrus", + "tonsor", + "toral", + "tormentum", + "torpedo", + "torpere", + "torquere", + "torrens", + "torrere", + "tortuosus", + "torus", + "torvus", + "tot", + "totidem", + "totiens", + "totus", + "trabs", + "tractare", + "tractus", + "tradere", + "traducere", + "tragicus", + "tragoedia", + "tragoedus", + "tragula", + "trahere", + "traicere", + "trames", + "tranare", + "tranquillitas", + "tranquillus", + "trans", + "transcendere", + "transferre", + "transfuga", + "transgredi", + "transigere", + "transilire", + "transire", + "transitus", + "transmittere", + "transportare", + "transtrum", + "transvehere", + "transversus", + "trecenti", + "tremefacere", + "tremendus", + "tremere", + "tremescere", + "tremor", + "tremulus", + "trepidare", + "trepidatio", + "trepidus", + "tres", + "triarii", + "tribuere", + "tribunal", + "tribunatus", + "tribunicius", + "tribunus", + "tribus", + "tributum", + "tridens", + "triduum", + "triformis", + "triginta", + "trilinguis", + "trini", + "tripertitus", + "triplex", + "tripudium", + "triremis", + "tristis", + "tristitia", + "triumphalis", + "triumphare", + "triumphus", + "triumvir", + "trivium", + "tropaeum", + "trucidare", + "trudere", + "truncus", + "trutina", + "trux", + "tu", + "tuba", + "tueri", + "tugurium", + "tum", + "tumere", + "tumidus", + "tumultuarius", + "tumultus", + "tumulus", + "tunc", + "tundere", + "tunica", + "turba", + "turbare", + "turbidus", + "turbo", + "turbulentus", + "turdus", + "turgere", + "turgidus", + "turma", + "turpare", + "turpis", + "turpitudo", + "turris", + "tus", + "tutari", + "tutela", + "tuto", + "tutor", + "tutus", + "tuus", + "tympanum", + "tyrannus", + "uber", + "ubertas", + "ubi", + "ubicumque", + "ubique", + "udus", + "ulcerare", + "ulcisci", + "ullus", + "ulmus", + "ulterior", + "ultima", + "ultio", + "ultor", + "ultra", + "ultrix", + "ultro", + "ululare", + "ululatus", + "ulva", + "umbo", + "umbra", + "umbrosus", + "umere", + "umerus", + "umquam", + "una", + "uncus", + "unda", + "undare", + "unde", + "undecim", + "undecimus", + "undique", + "unguentum", + "unguere", + "unguis", + "ungula", + "unicus", + "universa", + "universum", + "universus", + "unus", + "unusquisque", + "urbanus", + "urbs", + "urere", + "urgere", + "uri", + "urna", + "ursa", + "ursus", + "usitatus", + "usquam", + "usque", + "usu", + "usui", + "usurpare", + "usus", + "ut", + "utcumque", + "uter", + "uterque", + "uterus", + "uti", + "utilis", + "utilitas", + "utinam", + "utique", + "utpote", + "utrimque", + "utut", + "uva", + "uvidus", + "uxor", + "vacare", + "vacat", + "vacca", + "vacua", + "vacuitas", + "vacuus", + "vadere", + "vadimonium", + "vadum", + "vae", + "vafer", + "vagari", + "vagina", + "vagus", + "vah!", + "valde", + "vale!", + "valens", + "valere", + "valescere", + "valetudo", + "validus", + "vallis", + "vallum", + "vallus", + "vanitas", + "vanus", + "vappa", + "vapulare", + "variare", + "varietas", + "varius", + "varus", + "vas", + "vasa", + "vastare", + "vastitas", + "vastus", + "vates", + "vaticinari", + "vaticinatio", + "ve", + "vecordia", + "vecors", + "vectigal", + "vehemens", + "vehere", + "vehiculum", + "vel", + "velamen", + "velare", + "velati", + "velle", + "vellere", + "vellus", + "velocitas", + "velox", + "velum", + "veluti", + "vena", + "venalis", + "venari", + "venator", + "venatus", + "vendere", + "venditor", + "veneficium", + "venenum", + "venerari", + "veneratio", + "venia", + "venire", + "venter", + "ventitare", + "ventosus", + "ventus", + "venus", + "venustas", + "ver", + "verba", + "verbena", + "verber", + "verberare", + "verbi", + "verbo", + "verbum", + "verecundia", + "verecundus", + "vereri", + "vergere", + "veri", + "verisimilis", + "veritas", + "verna", + "vernus", + "vero", + "verrere", + "versare", + "versari", + "versiculus", + "versus", + "versutus", + "vertere", + "vertex", + "verti", + "vertitur", + "veru", + "verum", + "verus", + "vesci", + "vesper", + "vespere", + "vespertinus", + "vester", + "vestibulum", + "vestigare", + "vestigium", + "vestimentum", + "vestire", + "vestis", + "vestitus", + "vetare", + "veteranus", + "veto", + "vetula", + "vetulus", + "vetus", + "vetustas", + "vetustus", + "vexare", + "vexillarius", + "vexillium", + "via", + "viaticum", + "viator", + "vibrare", + "vice", + "vicem", + "vicensimus", + "vicilus", + "vicina", + "vicinitas", + "vicinus", + "vicis", + "vicissim", + "vicissitudo", + "victima", + "victor", + "victoria", + "victrix", + "victus", + "vicus", + "videlicet", + "videre", + "videri", + "videtur", + "vidua", + "viduus", + "vigere", + "vigil", + "vigilare", + "vigilia", + "viginti", + "vigor", + "vilis", + "villa", + "villula", + "villus", + "vimen", + "vincere", + "vincire", + "vinculum", + "vindemia", + "vindex", + "vindicare", + "vindicta", + "vinea", + "vinetum", + "vinosus", + "vinum", + "viola", + "violare", + "violens", + "violentia", + "violentus", + "vipera", + "vipereus", + "viperinus", + "vir", + "virere", + "virga", + "virginea", + "virgineus", + "virginitas", + "virgo", + "virgultum", + "viridare", + "viridis", + "virilis", + "virtus", + "virus", + "vis", + "viscera", + "visere", + "visio", + "visum", + "visus", + "vita", + "vitabundus", + "vitalis", + "vitare", + "vitellus", + "vitiare", + "vitiosus", + "vitis", + "vitium", + "vitreus", + "vitrum", + "vitta", + "vitula", + "vitulus", + "vituperare", + "vivax", + "vivere", + "vividus", + "vivus", + "vix", + "vixdum", + "vocabulum", + "vocare", + "vociferari", + "volantes", + "volare", + "volatus", + "volens", + "volitare", + "volo", + "volucer", + "volucris", + "volumen", + "voluntarius", + "voluntas", + "voluptarius", + "voluptas", + "volutare", + "volvere", + "vomer", + "vomere", + "vorago", + "vos", + "votum", + "vovere", + "vovitus", + "vox", + "vulgare", + "vulgaris", + "vulgo", + "vulgus", + "vulnerare", + "vulnus", + "vulpes", + "vult", + "vultus", + "zephyrus", + "zona", + "\u03c0\u03ac\u03d1\u03bf\u03c2", + "\u1f41\u03c1\u03bc\u03ae" +] \ No newline at end of file diff --git a/mc_backend/mcserver/app/models.py b/mc_backend/mcserver/app/models.py index 5a5a662..bad2694 100644 --- a/mc_backend/mcserver/app/models.py +++ b/mc_backend/mcserver/app/models.py @@ -157,6 +157,7 @@ class VocabularyCorpus(Enum): agldt = Config.VOCABULARY_AGLDT_FILE_NAME bws = Config.VOCABULARY_BWS_FILE_NAME proiel = Config.VOCABULARY_PROIEL_FILE_NAME + vischer = Config.VOCABULARY_VISCHER_FILE_NAME viva = Config.VOCABULARY_VIVA_FILE_NAME diff --git a/mc_backend/mcserver/config.py b/mc_backend/mcserver/config.py index 799fd9a..ef74a11 100644 --- a/mc_backend/mcserver/config.py +++ b/mc_backend/mcserver/config.py @@ -173,6 +173,7 @@ class Config(object): VOCABULARY_BWS_FILE_NAME = "vocabulary_bamberg_core.json" VOCABULARY_DIRECTORY = os.path.join(ASSETS_DIRECTORY, "vocabulary") VOCABULARY_PROIEL_FILE_NAME = "vocabulary_proiel_treebank.json" + VOCABULARY_VISCHER_FILE_NAME = "vocabulary_vischer.json" VOCABULARY_VIVA_FILE_NAME = "vocabulary_viva.json" ZENODO_API_URL = "https://zenodo.org/oai2d" ZENODO_SET = "user-lexiprojekt-latin-unipotsdam" diff --git a/mc_backend/openapi/.openapi-generator/FILES b/mc_backend/openapi/.openapi-generator/FILES new file mode 100644 index 0000000..a6805dc --- /dev/null +++ b/mc_backend/openapi/.openapi-generator/FILES @@ -0,0 +1,45 @@ +.dockerignore +.gitignore +.travis.yml +Dockerfile +README.md +git_push.sh +openapi_server/__init__.py +openapi_server/__main__.py +openapi_server/controllers/__init__.py +openapi_server/controllers/default_controller.py +openapi_server/controllers/security_controller.py +openapi_server/encoder.py +openapi_server/models/__init__.py +openapi_server/models/annis_response.py +openapi_server/models/base_model.py +openapi_server/models/corpus.py +openapi_server/models/exercise_author.py +openapi_server/models/exercise_author_extension.py +openapi_server/models/exercise_base.py +openapi_server/models/exercise_extension.py +openapi_server/models/exercise_type_path.py +openapi_server/models/file_type.py +openapi_server/models/frequency_item.py +openapi_server/models/graph_data.py +openapi_server/models/link.py +openapi_server/models/matching_exercise.py +openapi_server/models/node_mc.py +openapi_server/models/phenomenon.py +openapi_server/models/sentence.py +openapi_server/models/solution.py +openapi_server/models/solution_element.py +openapi_server/models/static_exercise.py +openapi_server/models/text_complexity.py +openapi_server/models/vocabulary_mc.py +openapi_server/models/zenodo_metadata_prefix.py +openapi_server/models/zenodo_metadata_prefix_extension.py +openapi_server/models/zenodo_record.py +openapi_server/openapi/openapi.yaml +openapi_server/test/__init__.py +openapi_server/typing_utils.py +openapi_server/util.py +requirements.txt +setup.py +test-requirements.txt +tox.ini diff --git a/mc_backend/openapi/.openapi-generator/VERSION b/mc_backend/openapi/.openapi-generator/VERSION index ecedc98..73a86b1 100644 --- a/mc_backend/openapi/.openapi-generator/VERSION +++ b/mc_backend/openapi/.openapi-generator/VERSION @@ -1 +1 @@ -4.3.1 \ No newline at end of file +7.0.1 \ No newline at end of file diff --git a/mc_backend/openapi/git_push.sh b/mc_backend/openapi/git_push.sh index ced3be2..f53a75d 100644 --- a/mc_backend/openapi/git_push.sh +++ b/mc_backend/openapi/git_push.sh @@ -1,7 +1,7 @@ #!/bin/sh # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ # -# Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" "gitlab.com" +# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com" git_user_id=$1 git_repo_id=$2 @@ -38,14 +38,14 @@ git add . git commit -m "$release_note" # Sets the new remote -git_remote=`git remote` +git_remote=$(git remote) if [ "$git_remote" = "" ]; then # git remote not defined if [ "$GIT_TOKEN" = "" ]; then echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git else - git remote add origin https://${git_user_id}:${GIT_TOKEN}@${git_host}/${git_user_id}/${git_repo_id}.git + git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git fi fi @@ -55,4 +55,3 @@ git pull origin master # Pushes (Forces) the changes in the local repository up to the remote repository echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git" git push origin master 2>&1 | grep -v 'To https' - diff --git a/mc_backend/openapi/openapi_server/__main__.py b/mc_backend/openapi/openapi_server/__main__.py index 6f69b80..239e751 100644 --- a/mc_backend/openapi/openapi_server/__main__.py +++ b/mc_backend/openapi/openapi_server/__main__.py @@ -11,6 +11,7 @@ def main(): app.add_api('openapi.yaml', arguments={'title': 'Machina Callida Backend REST API'}, pythonic_params=True) + app.run(port=8080) diff --git a/mc_backend/openapi/openapi_server/controllers/default_controller.py b/mc_backend/openapi/openapi_server/controllers/default_controller.py index 8fed3d1..6093f30 100644 --- a/mc_backend/openapi/openapi_server/controllers/default_controller.py +++ b/mc_backend/openapi/openapi_server/controllers/default_controller.py @@ -1,5 +1,7 @@ import connexion -import six +from typing import Dict +from typing import Tuple +from typing import Union from openapi.openapi_server.models.annis_response import AnnisResponse # noqa: E501 from openapi.openapi_server.models.corpus import Corpus # noqa: E501 @@ -23,7 +25,7 @@ def mcserver_app_api_corpus_api_delete(cid): # noqa: E501 :param cid: Corpus identifier. :type cid: int - :rtype: bool + :rtype: Union[bool, Tuple[bool, int], Tuple[bool, int, Dict[str, str]] """ return 'do some magic!' @@ -36,7 +38,7 @@ def mcserver_app_api_corpus_api_get(cid): # noqa: E501 :param cid: Corpus identifier. :type cid: int - :rtype: Corpus + :rtype: Union[Corpus, Tuple[Corpus, int], Tuple[Corpus, int, Dict[str, str]] """ return 'do some magic!' @@ -55,7 +57,7 @@ def mcserver_app_api_corpus_api_patch(cid, author=None, source_urn=None, title=N :param title: Corpus title. :type title: str - :rtype: Corpus + :rtype: Union[Corpus, Tuple[Corpus, int], Tuple[Corpus, int, Dict[str, str]] """ return 'do some magic!' @@ -68,7 +70,7 @@ def mcserver_app_api_corpus_list_api_get(last_update_time): # noqa: E501 :param last_update_time: Time (in milliseconds) of the last update. :type last_update_time: int - :rtype: Corpus + :rtype: Union[Corpus, Tuple[Corpus, int], Tuple[Corpus, int, Dict[str, str]] """ return 'do some magic!' @@ -81,18 +83,42 @@ def mcserver_app_api_exercise_api_get(eid): # noqa: E501 :param eid: Unique identifier (UUID) for the exercise. :type eid: str - :rtype: AnnisResponse + :rtype: Union[AnnisResponse, Tuple[AnnisResponse, int], Tuple[AnnisResponse, int, Dict[str, str]] """ return 'do some magic!' -def mcserver_app_api_exercise_api_post(): # noqa: E501 +def mcserver_app_api_exercise_api_post(instructions, search_values, type, urn, correct_feedback=None, general_feedback=None, incorrect_feedback=None, language=None, partially_correct_feedback=None, work_author=None, work_title=None, type_translation=None): # noqa: E501 """Creates a new exercise. # noqa: E501 - - :rtype: AnnisResponse + :param instructions: Hints for how to complete the exercise. + :type instructions: str + :param search_values: Search queries that were used to build the exercise. + :type search_values: str + :param type: Type of exercise, concerning interaction and layout. + :type type: str + :param urn: CTS URN for the text passage from which the exercise was created. + :type urn: str + :param correct_feedback: Feedback for successful completion of the exercise. + :type correct_feedback: str + :param general_feedback: Feedback for finishing the exercise. + :type general_feedback: str + :param incorrect_feedback: Feedback for failing to complete the exercise successfully. + :type incorrect_feedback: str + :param language: ISO 639-1 Language Code for the localization of exercise content. + :type language: str + :param partially_correct_feedback: Feedback for successfully completing certain parts of the exercise. + :type partially_correct_feedback: str + :param work_author: Name of the person who wrote the base text for the exercise. + :type work_author: str + :param work_title: Title of the base text for the exercise. + :type work_title: str + :param type_translation: Localized expression of the exercise type. + :type type_translation: str + + :rtype: Union[AnnisResponse, Tuple[AnnisResponse, int], Tuple[AnnisResponse, int, Dict[str, str]] """ return 'do some magic!' @@ -111,7 +137,7 @@ def mcserver_app_api_exercise_list_api_get(lang, frequency_upper_bound=None, las :param vocabulary: Identifier for a reference vocabulary. :type vocabulary: dict | bytes - :rtype: List[MatchingExercise] + :rtype: Union[List[MatchingExercise], Tuple[List[MatchingExercise], int], Tuple[List[MatchingExercise], int, Dict[str, str]] """ if connexion.request.is_json: vocabulary = VocabularyMC.from_dict(connexion.request.get_json()) # noqa: E501 @@ -130,7 +156,7 @@ def mcserver_app_api_file_api_get(id, type, solution_indices=None): # noqa: E50 :param solution_indices: Indices for the solutions that should be included in the download. :type solution_indices: List[int] - :rtype: object + :rtype: Union[object, Tuple[object, int], Tuple[object, int, Dict[str, str]] """ if connexion.request.is_json: type = FileType.from_dict(connexion.request.get_json()) # noqa: E501 @@ -151,7 +177,7 @@ def mcserver_app_api_file_api_post(file_type=None, html_content=None, learning_r :param urn: CTS URN for the text passage from which the HTML content was created. :type urn: str - :rtype: str + :rtype: Union[str, Tuple[str, int], Tuple[str, int, Dict[str, str]] """ if connexion.request.is_json: file_type = FileType.from_dict(connexion.request.get_json()) # noqa: E501 @@ -166,7 +192,7 @@ def mcserver_app_api_frequency_api_get(urn): # noqa: E501 :param urn: CTS URN for referencing the corpus. :type urn: str - :rtype: List[FrequencyItem] + :rtype: Union[List[FrequencyItem], Tuple[List[FrequencyItem], int], Tuple[List[FrequencyItem], int, Dict[str, str]] """ return 'do some magic!' @@ -183,7 +209,7 @@ def mcserver_app_api_h5p_api_get(eid, lang, solution_indices=None): # noqa: E50 :param solution_indices: Indices for the solutions that should be included in the download. :type solution_indices: List[int] - :rtype: object + :rtype: Union[object, Tuple[object, int], Tuple[object, int, Dict[str, str]] """ return 'do some magic!' @@ -202,7 +228,7 @@ def mcserver_app_api_h5p_api_post(eid=None, exercise_type_path=None, lang=None, :param solution_indices: Indices for the solutions that should be included in the download. :type solution_indices: List[int] - :rtype: object + :rtype: Union[object, Tuple[object, int], Tuple[object, int, Dict[str, str]] """ if connexion.request.is_json: exercise_type_path = ExerciseTypePath.from_dict(connexion.request.get_json()) # noqa: E501 @@ -223,7 +249,7 @@ def mcserver_app_api_kwic_api_post(search_values, urn, ctx_left, ctx_right): # :param ctx_right: Number of tokens that should be given as context on the right side of a target. :type ctx_right: int - :rtype: str + :rtype: Union[str, Tuple[str, int], Tuple[str, int, Dict[str, str]] """ return 'do some magic!' @@ -236,7 +262,7 @@ def mcserver_app_api_raw_text_api_get(urn): # noqa: E501 :param urn: CTS URN for referencing the corpus. :type urn: str - :rtype: AnnisResponse + :rtype: Union[AnnisResponse, Tuple[AnnisResponse, int], Tuple[AnnisResponse, int, Dict[str, str]] """ return 'do some magic!' @@ -247,7 +273,7 @@ def mcserver_app_api_static_exercises_api_get(): # noqa: E501 # noqa: E501 - :rtype: Dict[str, StaticExercise] + :rtype: Union[Dict[str, StaticExercise], Tuple[Dict[str, StaticExercise], int], Tuple[Dict[str, StaticExercise], int, Dict[str, str]] """ return 'do some magic!' @@ -262,7 +288,7 @@ def mcserver_app_api_textcomplexity_api_get(measure, urn): # noqa: E501 :param urn: CTS URN for referencing the corpus. :type urn: str - :rtype: TextComplexity + :rtype: Union[TextComplexity, Tuple[TextComplexity, int], Tuple[TextComplexity, int, Dict[str, str]] """ return 'do some magic!' @@ -275,7 +301,7 @@ def mcserver_app_api_valid_reff_api_get(urn): # noqa: E501 :param urn: CTS URN for referencing the corpus. :type urn: str - :rtype: List[str] + :rtype: Union[List[str], Tuple[List[str], int], Tuple[List[str], int, Dict[str, str]] """ return 'do some magic!' @@ -294,7 +320,7 @@ def mcserver_app_api_vector_network_api_get(search_regex, highlight_regex=None, :param nearest_neighbor_count: Number of nearest neighbors that should be considered for each relevant word. :type nearest_neighbor_count: int - :rtype: str + :rtype: Union[str, Tuple[str, int], Tuple[str, int, Dict[str, str]] """ return 'do some magic!' @@ -309,7 +335,7 @@ def mcserver_app_api_vector_network_api_post(search_regex, nearest_neighbor_coun :param nearest_neighbor_count: Number of nearest neighbors that should be considered for each target node in a graph analysis. :type nearest_neighbor_count: int - :rtype: List[List[str]] + :rtype: Union[List[List[str]], Tuple[List[List[str]], int], Tuple[List[List[str]], int, Dict[str, str]] """ return 'do some magic!' @@ -326,7 +352,7 @@ def mcserver_app_api_vocabulary_api_get(frequency_upper_bound, query_urn, vocabu :param vocabulary: Identifier for a reference vocabulary. :type vocabulary: dict | bytes - :rtype: List[Sentence] + :rtype: Union[List[Sentence], Tuple[List[Sentence], int], Tuple[List[Sentence], int, Dict[str, str]] """ if connexion.request.is_json: vocabulary = VocabularyMC.from_dict(connexion.request.get_json()) # noqa: E501 @@ -345,7 +371,7 @@ def mcserver_app_api_vocabulary_api_post(frequency_upper_bound, query_urn, vocab :param vocabulary: :type vocabulary: dict | bytes - :rtype: AnnisResponse + :rtype: Union[AnnisResponse, Tuple[AnnisResponse, int], Tuple[AnnisResponse, int, Dict[str, str]] """ if connexion.request.is_json: vocabulary = VocabularyMC.from_dict(connexion.request.get_json()) # noqa: E501 @@ -358,7 +384,7 @@ def mcserver_app_api_zenodo_api_get(): # noqa: E501 # noqa: E501 - :rtype: List[ZenodoRecord] + :rtype: Union[List[ZenodoRecord], Tuple[List[ZenodoRecord], int], Tuple[List[ZenodoRecord], int, Dict[str, str]] """ return 'do some magic!' @@ -371,6 +397,6 @@ def mcserver_app_api_zenodo_api_post(record_id): # noqa: E501 :param record_id: Unique identifier of the record for which file URIs shall be retrieved. :type record_id: int - :rtype: List[str] + :rtype: Union[List[str], Tuple[List[str], int], Tuple[List[str], int, Dict[str, str]] """ return 'do some magic!' diff --git a/mc_backend/openapi/openapi_server/controllers/security_controller.py b/mc_backend/openapi/openapi_server/controllers/security_controller.py new file mode 100644 index 0000000..6d294ff --- /dev/null +++ b/mc_backend/openapi/openapi_server/controllers/security_controller.py @@ -0,0 +1,2 @@ +from typing import List + diff --git a/mc_backend/openapi/openapi_server/encoder.py b/mc_backend/openapi/openapi_server/encoder.py index b2a9e8e..880f4db 100644 --- a/mc_backend/openapi/openapi_server/encoder.py +++ b/mc_backend/openapi/openapi_server/encoder.py @@ -1,7 +1,6 @@ from connexion.apps.flask_app import FlaskJSONEncoder -import six -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model class JSONEncoder(FlaskJSONEncoder): @@ -10,7 +9,7 @@ class JSONEncoder(FlaskJSONEncoder): def default(self, o): if isinstance(o, Model): dikt = {} - for attr, _ in six.iteritems(o.openapi_types): + for attr in o.openapi_types: value = getattr(o, attr) if value is None and not self.include_nulls: continue diff --git a/mc_backend/openapi/openapi_server/models/__init__.py b/mc_backend/openapi/openapi_server/models/__init__.py index f1c5a95..e68207b 100644 --- a/mc_backend/openapi/openapi_server/models/__init__.py +++ b/mc_backend/openapi/openapi_server/models/__init__.py @@ -1,7 +1,4 @@ -# coding: utf-8 - # flake8: noqa -from __future__ import absolute_import # import models into model package from openapi.openapi_server.models.annis_response import AnnisResponse from openapi.openapi_server.models.corpus import Corpus @@ -9,18 +6,12 @@ from openapi.openapi_server.models.exercise_author import ExerciseAuthor from openapi.openapi_server.models.exercise_author_extension import ExerciseAuthorExtension from openapi.openapi_server.models.exercise_base import ExerciseBase from openapi.openapi_server.models.exercise_extension import ExerciseExtension -from openapi.openapi_server.models.exercise_form import ExerciseForm -from openapi.openapi_server.models.exercise_form_all_of import ExerciseFormAllOf from openapi.openapi_server.models.exercise_type_path import ExerciseTypePath -from openapi.openapi_server.models.file_form import FileForm from openapi.openapi_server.models.file_type import FileType from openapi.openapi_server.models.frequency_item import FrequencyItem from openapi.openapi_server.models.graph_data import GraphData -from openapi.openapi_server.models.h5_p_form import H5PForm -from openapi.openapi_server.models.kwic_form import KwicForm from openapi.openapi_server.models.link import Link from openapi.openapi_server.models.matching_exercise import MatchingExercise -from openapi.openapi_server.models.matching_exercise_all_of import MatchingExerciseAllOf from openapi.openapi_server.models.node_mc import NodeMC from openapi.openapi_server.models.phenomenon import Phenomenon from openapi.openapi_server.models.sentence import Sentence @@ -28,10 +19,7 @@ from openapi.openapi_server.models.solution import Solution from openapi.openapi_server.models.solution_element import SolutionElement from openapi.openapi_server.models.static_exercise import StaticExercise from openapi.openapi_server.models.text_complexity import TextComplexity -from openapi.openapi_server.models.vector_network_form import VectorNetworkForm -from openapi.openapi_server.models.vocabulary_form import VocabularyForm from openapi.openapi_server.models.vocabulary_mc import VocabularyMC -from openapi.openapi_server.models.zenodo_form import ZenodoForm from openapi.openapi_server.models.zenodo_metadata_prefix import ZenodoMetadataPrefix from openapi.openapi_server.models.zenodo_metadata_prefix_extension import ZenodoMetadataPrefixExtension from openapi.openapi_server.models.zenodo_record import ZenodoRecord diff --git a/mc_backend/openapi/openapi_server/models/annis_response.py b/mc_backend/openapi/openapi_server/models/annis_response.py index 8bd53fa..ad7f7f8 100644 --- a/mc_backend/openapi/openapi_server/models/annis_response.py +++ b/mc_backend/openapi/openapi_server/models/annis_response.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server.models.frequency_item import FrequencyItem from openapi.openapi_server.models.graph_data import GraphData from openapi.openapi_server.models.solution import Solution @@ -23,7 +20,7 @@ class AnnisResponse(Model): Do not edit the class manually. """ - def __init__(self, exercise_id='', exercise_type='', frequency_analysis=None, graph_data=None, solutions=None, text_complexity=None, uri=''): # noqa: E501 + def __init__(self, exercise_id='', exercise_type='', frequency_analysis=[], graph_data=None, solutions=[], text_complexity=None, uri=''): # noqa: E501 """AnnisResponse - a model defined in OpenAPI :param exercise_id: The exercise_id of this AnnisResponse. # noqa: E501 @@ -81,7 +78,7 @@ class AnnisResponse(Model): return util.deserialize_model(dikt, cls) @property - def exercise_id(self): + def exercise_id(self) -> str: """Gets the exercise_id of this AnnisResponse. Unique identifier (UUID) for the exercise. # noqa: E501 @@ -92,7 +89,7 @@ class AnnisResponse(Model): return self._exercise_id @exercise_id.setter - def exercise_id(self, exercise_id): + def exercise_id(self, exercise_id: str): """Sets the exercise_id of this AnnisResponse. Unique identifier (UUID) for the exercise. # noqa: E501 @@ -104,7 +101,7 @@ class AnnisResponse(Model): self._exercise_id = exercise_id @property - def exercise_type(self): + def exercise_type(self) -> str: """Gets the exercise_type of this AnnisResponse. Type of exercise, concerning interaction and layout. # noqa: E501 @@ -115,7 +112,7 @@ class AnnisResponse(Model): return self._exercise_type @exercise_type.setter - def exercise_type(self, exercise_type): + def exercise_type(self, exercise_type: str): """Sets the exercise_type of this AnnisResponse. Type of exercise, concerning interaction and layout. # noqa: E501 @@ -127,7 +124,7 @@ class AnnisResponse(Model): self._exercise_type = exercise_type @property - def frequency_analysis(self): + def frequency_analysis(self) -> List[FrequencyItem]: """Gets the frequency_analysis of this AnnisResponse. List of items with frequency data for linguistic phenomena. # noqa: E501 @@ -138,7 +135,7 @@ class AnnisResponse(Model): return self._frequency_analysis @frequency_analysis.setter - def frequency_analysis(self, frequency_analysis): + def frequency_analysis(self, frequency_analysis: List[FrequencyItem]): """Sets the frequency_analysis of this AnnisResponse. List of items with frequency data for linguistic phenomena. # noqa: E501 @@ -150,7 +147,7 @@ class AnnisResponse(Model): self._frequency_analysis = frequency_analysis @property - def graph_data(self): + def graph_data(self) -> GraphData: """Gets the graph_data of this AnnisResponse. @@ -160,7 +157,7 @@ class AnnisResponse(Model): return self._graph_data @graph_data.setter - def graph_data(self, graph_data): + def graph_data(self, graph_data: GraphData): """Sets the graph_data of this AnnisResponse. @@ -171,7 +168,7 @@ class AnnisResponse(Model): self._graph_data = graph_data @property - def solutions(self): + def solutions(self) -> List[Solution]: """Gets the solutions of this AnnisResponse. Correct solutions for this exercise. # noqa: E501 @@ -182,7 +179,7 @@ class AnnisResponse(Model): return self._solutions @solutions.setter - def solutions(self, solutions): + def solutions(self, solutions: List[Solution]): """Sets the solutions of this AnnisResponse. Correct solutions for this exercise. # noqa: E501 @@ -194,7 +191,7 @@ class AnnisResponse(Model): self._solutions = solutions @property - def text_complexity(self): + def text_complexity(self) -> TextComplexity: """Gets the text_complexity of this AnnisResponse. @@ -204,7 +201,7 @@ class AnnisResponse(Model): return self._text_complexity @text_complexity.setter - def text_complexity(self, text_complexity): + def text_complexity(self, text_complexity: TextComplexity): """Sets the text_complexity of this AnnisResponse. @@ -215,7 +212,7 @@ class AnnisResponse(Model): self._text_complexity = text_complexity @property - def uri(self): + def uri(self) -> str: """Gets the uri of this AnnisResponse. URI for accessing the exercise in this API. # noqa: E501 @@ -226,7 +223,7 @@ class AnnisResponse(Model): return self._uri @uri.setter - def uri(self, uri): + def uri(self, uri: str): """Sets the uri of this AnnisResponse. URI for accessing the exercise in this API. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/base_model.py b/mc_backend/openapi/openapi_server/models/base_model.py new file mode 100644 index 0000000..5a55576 --- /dev/null +++ b/mc_backend/openapi/openapi_server/models/base_model.py @@ -0,0 +1,68 @@ +import pprint + +import typing + +from openapi.openapi_server import util + +T = typing.TypeVar('T') + + +class Model: + # openapiTypes: The key is attribute name and the + # value is attribute type. + openapi_types: typing.Dict[str, type] = {} + + # attributeMap: The key is attribute name and the + # value is json key in definition. + attribute_map: typing.Dict[str, str] = {} + + @classmethod + def from_dict(cls: typing.Type[T], dikt) -> T: + """Returns the dict as a model""" + return util.deserialize_model(dikt, cls) + + def to_dict(self): + """Returns the model properties as a dict + + :rtype: dict + """ + result = {} + + for attr in self.openapi_types: + value = getattr(self, attr) + if isinstance(value, list): + result[attr] = list(map( + lambda x: x.to_dict() if hasattr(x, "to_dict") else x, + value + )) + elif hasattr(value, "to_dict"): + result[attr] = value.to_dict() + elif isinstance(value, dict): + result[attr] = dict(map( + lambda item: (item[0], item[1].to_dict()) + if hasattr(item[1], "to_dict") else item, + value.items() + )) + else: + result[attr] = value + + return result + + def to_str(self): + """Returns the string representation of the model + + :rtype: str + """ + return pprint.pformat(self.to_dict()) + + def __repr__(self): + """For `print` and `pprint`""" + return self.to_str() + + def __eq__(self, other): + """Returns true if both objects are equal""" + return self.__dict__ == other.__dict__ + + def __ne__(self, other): + """Returns true if both objects are not equal""" + return not self == other diff --git a/mc_backend/openapi/openapi_server/models/corpus.py b/mc_backend/openapi/openapi_server/models/corpus.py index 8c1d794..b9a8470 100644 --- a/mc_backend/openapi/openapi_server/models/corpus.py +++ b/mc_backend/openapi/openapi_server/models/corpus.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -73,7 +70,7 @@ class Corpus(Model): return util.deserialize_model(dikt, cls) @property - def author(self): + def author(self) -> str: """Gets the author of this Corpus. Author of the texts in the corpus. # noqa: E501 @@ -84,7 +81,7 @@ class Corpus(Model): return self._author @author.setter - def author(self, author): + def author(self, author: str): """Sets the author of this Corpus. Author of the texts in the corpus. # noqa: E501 @@ -96,7 +93,7 @@ class Corpus(Model): self._author = author @property - def cid(self): + def cid(self) -> int: """Gets the cid of this Corpus. Unique identifier for the corpus. # noqa: E501 @@ -107,7 +104,7 @@ class Corpus(Model): return self._cid @cid.setter - def cid(self, cid): + def cid(self, cid: int): """Sets the cid of this Corpus. Unique identifier for the corpus. # noqa: E501 @@ -119,7 +116,7 @@ class Corpus(Model): self._cid = cid @property - def citation_level_1(self): + def citation_level_1(self) -> str: """Gets the citation_level_1 of this Corpus. First level for citing the corpus. # noqa: E501 @@ -130,7 +127,7 @@ class Corpus(Model): return self._citation_level_1 @citation_level_1.setter - def citation_level_1(self, citation_level_1): + def citation_level_1(self, citation_level_1: str): """Sets the citation_level_1 of this Corpus. First level for citing the corpus. # noqa: E501 @@ -142,7 +139,7 @@ class Corpus(Model): self._citation_level_1 = citation_level_1 @property - def citation_level_2(self): + def citation_level_2(self) -> str: """Gets the citation_level_2 of this Corpus. Second level for citing the corpus. # noqa: E501 @@ -153,7 +150,7 @@ class Corpus(Model): return self._citation_level_2 @citation_level_2.setter - def citation_level_2(self, citation_level_2): + def citation_level_2(self, citation_level_2: str): """Sets the citation_level_2 of this Corpus. Second level for citing the corpus. # noqa: E501 @@ -165,7 +162,7 @@ class Corpus(Model): self._citation_level_2 = citation_level_2 @property - def citation_level_3(self): + def citation_level_3(self) -> str: """Gets the citation_level_3 of this Corpus. Third level for citing the corpus. # noqa: E501 @@ -176,7 +173,7 @@ class Corpus(Model): return self._citation_level_3 @citation_level_3.setter - def citation_level_3(self, citation_level_3): + def citation_level_3(self, citation_level_3: str): """Sets the citation_level_3 of this Corpus. Third level for citing the corpus. # noqa: E501 @@ -188,7 +185,7 @@ class Corpus(Model): self._citation_level_3 = citation_level_3 @property - def source_urn(self): + def source_urn(self) -> str: """Gets the source_urn of this Corpus. CTS base URN for referencing the corpus. # noqa: E501 @@ -199,7 +196,7 @@ class Corpus(Model): return self._source_urn @source_urn.setter - def source_urn(self, source_urn): + def source_urn(self, source_urn: str): """Sets the source_urn of this Corpus. CTS base URN for referencing the corpus. # noqa: E501 @@ -213,7 +210,7 @@ class Corpus(Model): self._source_urn = source_urn @property - def title(self): + def title(self) -> str: """Gets the title of this Corpus. Corpus title. # noqa: E501 @@ -224,7 +221,7 @@ class Corpus(Model): return self._title @title.setter - def title(self, title): + def title(self, title: str): """Sets the title of this Corpus. Corpus title. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/exercise_author.py b/mc_backend/openapi/openapi_server/models/exercise_author.py index b0d1562..0e9d7a1 100644 --- a/mc_backend/openapi/openapi_server/models/exercise_author.py +++ b/mc_backend/openapi/openapi_server/models/exercise_author.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,8 +15,8 @@ class ExerciseAuthor(Model): """ allowed enum values """ - CALLIDUS = "callidus" - POTSDAM = "potsdam" + CALLIDUS = 'callidus' + POTSDAM = 'potsdam' def __init__(self): # noqa: E501 """ExerciseAuthor - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/exercise_author_extension.py b/mc_backend/openapi/openapi_server/models/exercise_author_extension.py index 2e42be4..c94b6b5 100644 --- a/mc_backend/openapi/openapi_server/models/exercise_author_extension.py +++ b/mc_backend/openapi/openapi_server/models/exercise_author_extension.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,8 +15,8 @@ class ExerciseAuthorExtension(Model): """ allowed enum values """ - CALLIDUS = "callidus" - POTSDAM = "potsdam" + CALLIDUS = 'callidus' + POTSDAM = 'potsdam' def __init__(self): # noqa: E501 """ExerciseAuthorExtension - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/exercise_base.py b/mc_backend/openapi/openapi_server/models/exercise_base.py index 509d802..97a03a8 100644 --- a/mc_backend/openapi/openapi_server/models/exercise_base.py +++ b/mc_backend/openapi/openapi_server/models/exercise_base.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -83,7 +80,7 @@ class ExerciseBase(Model): return util.deserialize_model(dikt, cls) @property - def correct_feedback(self): + def correct_feedback(self) -> str: """Gets the correct_feedback of this ExerciseBase. Feedback for successful completion of the exercise. # noqa: E501 @@ -94,7 +91,7 @@ class ExerciseBase(Model): return self._correct_feedback @correct_feedback.setter - def correct_feedback(self, correct_feedback): + def correct_feedback(self, correct_feedback: str): """Sets the correct_feedback of this ExerciseBase. Feedback for successful completion of the exercise. # noqa: E501 @@ -106,7 +103,7 @@ class ExerciseBase(Model): self._correct_feedback = correct_feedback @property - def general_feedback(self): + def general_feedback(self) -> str: """Gets the general_feedback of this ExerciseBase. Feedback for finishing the exercise. # noqa: E501 @@ -117,7 +114,7 @@ class ExerciseBase(Model): return self._general_feedback @general_feedback.setter - def general_feedback(self, general_feedback): + def general_feedback(self, general_feedback: str): """Sets the general_feedback of this ExerciseBase. Feedback for finishing the exercise. # noqa: E501 @@ -129,7 +126,7 @@ class ExerciseBase(Model): self._general_feedback = general_feedback @property - def incorrect_feedback(self): + def incorrect_feedback(self) -> str: """Gets the incorrect_feedback of this ExerciseBase. Feedback for failing to complete the exercise successfully. # noqa: E501 @@ -140,7 +137,7 @@ class ExerciseBase(Model): return self._incorrect_feedback @incorrect_feedback.setter - def incorrect_feedback(self, incorrect_feedback): + def incorrect_feedback(self, incorrect_feedback: str): """Sets the incorrect_feedback of this ExerciseBase. Feedback for failing to complete the exercise successfully. # noqa: E501 @@ -152,7 +149,7 @@ class ExerciseBase(Model): self._incorrect_feedback = incorrect_feedback @property - def instructions(self): + def instructions(self) -> str: """Gets the instructions of this ExerciseBase. Hints for how to complete the exercise. # noqa: E501 @@ -163,7 +160,7 @@ class ExerciseBase(Model): return self._instructions @instructions.setter - def instructions(self, instructions): + def instructions(self, instructions: str): """Sets the instructions of this ExerciseBase. Hints for how to complete the exercise. # noqa: E501 @@ -177,7 +174,7 @@ class ExerciseBase(Model): self._instructions = instructions @property - def language(self): + def language(self) -> str: """Gets the language of this ExerciseBase. ISO 639-1 Language Code for the localization of exercise content. # noqa: E501 @@ -188,7 +185,7 @@ class ExerciseBase(Model): return self._language @language.setter - def language(self, language): + def language(self, language: str): """Sets the language of this ExerciseBase. ISO 639-1 Language Code for the localization of exercise content. # noqa: E501 @@ -200,7 +197,7 @@ class ExerciseBase(Model): self._language = language @property - def partially_correct_feedback(self): + def partially_correct_feedback(self) -> str: """Gets the partially_correct_feedback of this ExerciseBase. Feedback for successfully completing certain parts of the exercise. # noqa: E501 @@ -211,7 +208,7 @@ class ExerciseBase(Model): return self._partially_correct_feedback @partially_correct_feedback.setter - def partially_correct_feedback(self, partially_correct_feedback): + def partially_correct_feedback(self, partially_correct_feedback: str): """Sets the partially_correct_feedback of this ExerciseBase. Feedback for successfully completing certain parts of the exercise. # noqa: E501 @@ -223,7 +220,7 @@ class ExerciseBase(Model): self._partially_correct_feedback = partially_correct_feedback @property - def search_values(self): + def search_values(self) -> str: """Gets the search_values of this ExerciseBase. Search queries that were used to build the exercise. # noqa: E501 @@ -234,7 +231,7 @@ class ExerciseBase(Model): return self._search_values @search_values.setter - def search_values(self, search_values): + def search_values(self, search_values: str): """Sets the search_values of this ExerciseBase. Search queries that were used to build the exercise. # noqa: E501 @@ -248,7 +245,7 @@ class ExerciseBase(Model): self._search_values = search_values @property - def work_author(self): + def work_author(self) -> str: """Gets the work_author of this ExerciseBase. Name of the person who wrote the base text for the exercise. # noqa: E501 @@ -259,7 +256,7 @@ class ExerciseBase(Model): return self._work_author @work_author.setter - def work_author(self, work_author): + def work_author(self, work_author: str): """Sets the work_author of this ExerciseBase. Name of the person who wrote the base text for the exercise. # noqa: E501 @@ -271,7 +268,7 @@ class ExerciseBase(Model): self._work_author = work_author @property - def work_title(self): + def work_title(self) -> str: """Gets the work_title of this ExerciseBase. Title of the base text for the exercise. # noqa: E501 @@ -282,7 +279,7 @@ class ExerciseBase(Model): return self._work_title @work_title.setter - def work_title(self, work_title): + def work_title(self, work_title: str): """Sets the work_title of this ExerciseBase. Title of the base text for the exercise. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/exercise_extension.py b/mc_backend/openapi/openapi_server/models/exercise_extension.py index 1ed9bf2..a3e3473 100644 --- a/mc_backend/openapi/openapi_server/models/exercise_extension.py +++ b/mc_backend/openapi/openapi_server/models/exercise_extension.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -73,7 +70,7 @@ class ExerciseExtension(Model): return util.deserialize_model(dikt, cls) @property - def conll(self): + def conll(self) -> str: """Gets the conll of this ExerciseExtension. CONLL-formatted linguistic annotations represented as a single string. # noqa: E501 @@ -84,7 +81,7 @@ class ExerciseExtension(Model): return self._conll @conll.setter - def conll(self, conll): + def conll(self, conll: str): """Sets the conll of this ExerciseExtension. CONLL-formatted linguistic annotations represented as a single string. # noqa: E501 @@ -96,7 +93,7 @@ class ExerciseExtension(Model): self._conll = conll @property - def eid(self): + def eid(self) -> str: """Gets the eid of this ExerciseExtension. Unique identifier (UUID) for the exercise. # noqa: E501 @@ -107,7 +104,7 @@ class ExerciseExtension(Model): return self._eid @eid.setter - def eid(self, eid): + def eid(self, eid: str): """Sets the eid of this ExerciseExtension. Unique identifier (UUID) for the exercise. # noqa: E501 @@ -121,7 +118,7 @@ class ExerciseExtension(Model): self._eid = eid @property - def exercise_type(self): + def exercise_type(self) -> str: """Gets the exercise_type of this ExerciseExtension. Type of exercise, concerning interaction and layout. # noqa: E501 @@ -132,7 +129,7 @@ class ExerciseExtension(Model): return self._exercise_type @exercise_type.setter - def exercise_type(self, exercise_type): + def exercise_type(self, exercise_type: str): """Sets the exercise_type of this ExerciseExtension. Type of exercise, concerning interaction and layout. # noqa: E501 @@ -144,7 +141,7 @@ class ExerciseExtension(Model): self._exercise_type = exercise_type @property - def last_access_time(self): + def last_access_time(self) -> float: """Gets the last_access_time of this ExerciseExtension. When the exercise was last accessed (as POSIX timestamp). # noqa: E501 @@ -155,7 +152,7 @@ class ExerciseExtension(Model): return self._last_access_time @last_access_time.setter - def last_access_time(self, last_access_time): + def last_access_time(self, last_access_time: float): """Sets the last_access_time of this ExerciseExtension. When the exercise was last accessed (as POSIX timestamp). # noqa: E501 @@ -169,7 +166,7 @@ class ExerciseExtension(Model): self._last_access_time = last_access_time @property - def solutions(self): + def solutions(self) -> str: """Gets the solutions of this ExerciseExtension. Correct solutions for the exercise. # noqa: E501 @@ -180,7 +177,7 @@ class ExerciseExtension(Model): return self._solutions @solutions.setter - def solutions(self, solutions): + def solutions(self, solutions: str): """Sets the solutions of this ExerciseExtension. Correct solutions for the exercise. # noqa: E501 @@ -192,7 +189,7 @@ class ExerciseExtension(Model): self._solutions = solutions @property - def text_complexity(self): + def text_complexity(self) -> float: """Gets the text_complexity of this ExerciseExtension. Overall text complexity as measured by the software's internal language analysis. # noqa: E501 @@ -203,7 +200,7 @@ class ExerciseExtension(Model): return self._text_complexity @text_complexity.setter - def text_complexity(self, text_complexity): + def text_complexity(self, text_complexity: float): """Sets the text_complexity of this ExerciseExtension. Overall text complexity as measured by the software's internal language analysis. # noqa: E501 @@ -215,7 +212,7 @@ class ExerciseExtension(Model): self._text_complexity = text_complexity @property - def urn(self): + def urn(self) -> str: """Gets the urn of this ExerciseExtension. CTS URN for the text passage from which the exercise was created. # noqa: E501 @@ -226,7 +223,7 @@ class ExerciseExtension(Model): return self._urn @urn.setter - def urn(self, urn): + def urn(self, urn: str): """Sets the urn of this ExerciseExtension. CTS URN for the text passage from which the exercise was created. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/exercise_type_path.py b/mc_backend/openapi/openapi_server/models/exercise_type_path.py index f9e3651..051d001 100644 --- a/mc_backend/openapi/openapi_server/models/exercise_type_path.py +++ b/mc_backend/openapi/openapi_server/models/exercise_type_path.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,12 +15,13 @@ class ExerciseTypePath(Model): """ allowed enum values """ - DIALOG_CARDS = "dialog_cards" - DRAG_TEXT = "drag_text" - FILL_BLANKS = "fill_blanks" - MARK_WORDS = "mark_words" - MULTI_CHOICE = "multi_choice" - VOC_LIST = "voc_list" + DIALOG_CARDS = 'dialog_cards' + DRAG_TEXT = 'drag_text' + FILL_BLANKS = 'fill_blanks' + FIND_WORDS = 'find_words' + MARK_WORDS = 'mark_words' + MULTI_CHOICE = 'multi_choice' + VOC_LIST = 'voc_list' def __init__(self): # noqa: E501 """ExerciseTypePath - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/file_type.py b/mc_backend/openapi/openapi_server/models/file_type.py index 0a01030..af204a1 100644 --- a/mc_backend/openapi/openapi_server/models/file_type.py +++ b/mc_backend/openapi/openapi_server/models/file_type.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,12 +15,12 @@ class FileType(Model): """ allowed enum values """ - DOCX = "docx" - H5P = "h5p" - JSON = "json" - PDF = "pdf" - XML = "xml" - ZIP = "zip" + DOCX = 'docx' + H5P = 'h5p' + JSON = 'json' + PDF = 'pdf' + XML = 'xml' + ZIP = 'zip' def __init__(self): # noqa: E501 """FileType - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/frequency_item.py b/mc_backend/openapi/openapi_server/models/frequency_item.py index 3b3f052..6266a4a 100644 --- a/mc_backend/openapi/openapi_server/models/frequency_item.py +++ b/mc_backend/openapi/openapi_server/models/frequency_item.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server.models.phenomenon import Phenomenon from openapi.openapi_server import util @@ -17,7 +14,7 @@ class FrequencyItem(Model): Do not edit the class manually. """ - def __init__(self, count=0, phenomena=None, values=None): # noqa: E501 + def __init__(self, count=0, phenomena=[], values=[]): # noqa: E501 """FrequencyItem - a model defined in OpenAPI :param count: The count of this FrequencyItem. # noqa: E501 @@ -55,7 +52,7 @@ class FrequencyItem(Model): return util.deserialize_model(dikt, cls) @property - def count(self): + def count(self) -> int: """Gets the count of this FrequencyItem. How often the given combination of values occurred. # noqa: E501 @@ -66,7 +63,7 @@ class FrequencyItem(Model): return self._count @count.setter - def count(self, count): + def count(self, count: int): """Sets the count of this FrequencyItem. How often the given combination of values occurred. # noqa: E501 @@ -78,7 +75,7 @@ class FrequencyItem(Model): self._count = count @property - def phenomena(self): + def phenomena(self) -> List[Phenomenon]: """Gets the phenomena of this FrequencyItem. Labels for the linguistic phenomena described in this frequency entry. # noqa: E501 @@ -89,7 +86,7 @@ class FrequencyItem(Model): return self._phenomena @phenomena.setter - def phenomena(self, phenomena): + def phenomena(self, phenomena: List[Phenomenon]): """Sets the phenomena of this FrequencyItem. Labels for the linguistic phenomena described in this frequency entry. # noqa: E501 @@ -101,7 +98,7 @@ class FrequencyItem(Model): self._phenomena = phenomena @property - def values(self): + def values(self) -> List[str]: """Gets the values of this FrequencyItem. Values for the phenomena described in this frequency entry. # noqa: E501 @@ -112,7 +109,7 @@ class FrequencyItem(Model): return self._values @values.setter - def values(self, values): + def values(self, values: List[str]): """Sets the values of this FrequencyItem. Values for the phenomena described in this frequency entry. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/graph_data.py b/mc_backend/openapi/openapi_server/models/graph_data.py index 0c49b40..78138b4 100644 --- a/mc_backend/openapi/openapi_server/models/graph_data.py +++ b/mc_backend/openapi/openapi_server/models/graph_data.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server.models.link import Link from openapi.openapi_server.models.node_mc import NodeMC from openapi.openapi_server import util @@ -67,7 +64,7 @@ class GraphData(Model): return util.deserialize_model(dikt, cls) @property - def directed(self): + def directed(self) -> bool: """Gets the directed of this GraphData. Whether edges in the returned graph are directed. # noqa: E501 @@ -78,7 +75,7 @@ class GraphData(Model): return self._directed @directed.setter - def directed(self, directed): + def directed(self, directed: bool): """Sets the directed of this GraphData. Whether edges in the returned graph are directed. # noqa: E501 @@ -90,7 +87,7 @@ class GraphData(Model): self._directed = directed @property - def graph(self): + def graph(self) -> object: """Gets the graph of this GraphData. Additional graph data. # noqa: E501 @@ -101,7 +98,7 @@ class GraphData(Model): return self._graph @graph.setter - def graph(self, graph): + def graph(self, graph: object): """Sets the graph of this GraphData. Additional graph data. # noqa: E501 @@ -113,7 +110,7 @@ class GraphData(Model): self._graph = graph @property - def links(self): + def links(self) -> List[Link]: """Gets the links of this GraphData. List of edges for the graph. # noqa: E501 @@ -124,7 +121,7 @@ class GraphData(Model): return self._links @links.setter - def links(self, links): + def links(self, links: List[Link]): """Sets the links of this GraphData. List of edges for the graph. # noqa: E501 @@ -138,7 +135,7 @@ class GraphData(Model): self._links = links @property - def multigraph(self): + def multigraph(self) -> bool: """Gets the multigraph of this GraphData. Whether the graph consists of multiple subgraphs. # noqa: E501 @@ -149,7 +146,7 @@ class GraphData(Model): return self._multigraph @multigraph.setter - def multigraph(self, multigraph): + def multigraph(self, multigraph: bool): """Sets the multigraph of this GraphData. Whether the graph consists of multiple subgraphs. # noqa: E501 @@ -161,7 +158,7 @@ class GraphData(Model): self._multigraph = multigraph @property - def nodes(self): + def nodes(self) -> List[NodeMC]: """Gets the nodes of this GraphData. List of nodes for the graph. # noqa: E501 @@ -172,7 +169,7 @@ class GraphData(Model): return self._nodes @nodes.setter - def nodes(self, nodes): + def nodes(self, nodes: List[NodeMC]): """Sets the nodes of this GraphData. List of nodes for the graph. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/link.py b/mc_backend/openapi/openapi_server/models/link.py index 5658339..0acf850 100644 --- a/mc_backend/openapi/openapi_server/models/link.py +++ b/mc_backend/openapi/openapi_server/models/link.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -63,7 +60,7 @@ class Link(Model): return util.deserialize_model(dikt, cls) @property - def annis_component_name(self): + def annis_component_name(self) -> str: """Gets the annis_component_name of this Link. Component name as given by ANNIS. # noqa: E501 @@ -74,7 +71,7 @@ class Link(Model): return self._annis_component_name @annis_component_name.setter - def annis_component_name(self, annis_component_name): + def annis_component_name(self, annis_component_name: str): """Sets the annis_component_name of this Link. Component name as given by ANNIS. # noqa: E501 @@ -86,7 +83,7 @@ class Link(Model): self._annis_component_name = annis_component_name @property - def annis_component_type(self): + def annis_component_type(self) -> str: """Gets the annis_component_type of this Link. Component type as given by ANNIS. # noqa: E501 @@ -97,7 +94,7 @@ class Link(Model): return self._annis_component_type @annis_component_type.setter - def annis_component_type(self, annis_component_type): + def annis_component_type(self, annis_component_type: str): """Sets the annis_component_type of this Link. Component type as given by ANNIS. # noqa: E501 @@ -109,7 +106,7 @@ class Link(Model): self._annis_component_type = annis_component_type @property - def source(self): + def source(self) -> str: """Gets the source of this Link. ID of the source node for the edge. # noqa: E501 @@ -120,7 +117,7 @@ class Link(Model): return self._source @source.setter - def source(self, source): + def source(self, source: str): """Sets the source of this Link. ID of the source node for the edge. # noqa: E501 @@ -132,7 +129,7 @@ class Link(Model): self._source = source @property - def target(self): + def target(self) -> str: """Gets the target of this Link. ID of the target node for the edge. # noqa: E501 @@ -143,7 +140,7 @@ class Link(Model): return self._target @target.setter - def target(self, target): + def target(self, target: str): """Sets the target of this Link. ID of the target node for the edge. # noqa: E501 @@ -155,7 +152,7 @@ class Link(Model): self._target = target @property - def udep_deprel(self): + def udep_deprel(self) -> str: """Gets the udep_deprel of this Link. Dependency relation described by the edge. # noqa: E501 @@ -166,7 +163,7 @@ class Link(Model): return self._udep_deprel @udep_deprel.setter - def udep_deprel(self, udep_deprel): + def udep_deprel(self, udep_deprel: str): """Sets the udep_deprel of this Link. Dependency relation described by the edge. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/matching_exercise.py b/mc_backend/openapi/openapi_server/models/matching_exercise.py index 8447bf8..7b6e5c1 100644 --- a/mc_backend/openapi/openapi_server/models/matching_exercise.py +++ b/mc_backend/openapi/openapi_server/models/matching_exercise.py @@ -1,19 +1,10 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model -from openapi.openapi_server.models.exercise_base import ExerciseBase -from openapi.openapi_server.models.exercise_extension import ExerciseExtension -from openapi.openapi_server.models.matching_exercise_all_of import MatchingExerciseAllOf +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util -from openapi.openapi_server.models.exercise_base import ExerciseBase # noqa: E501 -from openapi.openapi_server.models.exercise_extension import ExerciseExtension # noqa: E501 -from openapi.openapi_server.models.matching_exercise_all_of import MatchingExerciseAllOf # noqa: E501 class MatchingExercise(Model): """NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -134,7 +125,7 @@ class MatchingExercise(Model): return util.deserialize_model(dikt, cls) @property - def correct_feedback(self): + def correct_feedback(self) -> str: """Gets the correct_feedback of this MatchingExercise. Feedback for successful completion of the exercise. # noqa: E501 @@ -145,7 +136,7 @@ class MatchingExercise(Model): return self._correct_feedback @correct_feedback.setter - def correct_feedback(self, correct_feedback): + def correct_feedback(self, correct_feedback: str): """Sets the correct_feedback of this MatchingExercise. Feedback for successful completion of the exercise. # noqa: E501 @@ -157,7 +148,7 @@ class MatchingExercise(Model): self._correct_feedback = correct_feedback @property - def general_feedback(self): + def general_feedback(self) -> str: """Gets the general_feedback of this MatchingExercise. Feedback for finishing the exercise. # noqa: E501 @@ -168,7 +159,7 @@ class MatchingExercise(Model): return self._general_feedback @general_feedback.setter - def general_feedback(self, general_feedback): + def general_feedback(self, general_feedback: str): """Sets the general_feedback of this MatchingExercise. Feedback for finishing the exercise. # noqa: E501 @@ -180,7 +171,7 @@ class MatchingExercise(Model): self._general_feedback = general_feedback @property - def incorrect_feedback(self): + def incorrect_feedback(self) -> str: """Gets the incorrect_feedback of this MatchingExercise. Feedback for failing to complete the exercise successfully. # noqa: E501 @@ -191,7 +182,7 @@ class MatchingExercise(Model): return self._incorrect_feedback @incorrect_feedback.setter - def incorrect_feedback(self, incorrect_feedback): + def incorrect_feedback(self, incorrect_feedback: str): """Sets the incorrect_feedback of this MatchingExercise. Feedback for failing to complete the exercise successfully. # noqa: E501 @@ -203,7 +194,7 @@ class MatchingExercise(Model): self._incorrect_feedback = incorrect_feedback @property - def instructions(self): + def instructions(self) -> str: """Gets the instructions of this MatchingExercise. Hints for how to complete the exercise. # noqa: E501 @@ -214,7 +205,7 @@ class MatchingExercise(Model): return self._instructions @instructions.setter - def instructions(self, instructions): + def instructions(self, instructions: str): """Sets the instructions of this MatchingExercise. Hints for how to complete the exercise. # noqa: E501 @@ -228,7 +219,7 @@ class MatchingExercise(Model): self._instructions = instructions @property - def language(self): + def language(self) -> str: """Gets the language of this MatchingExercise. ISO 639-1 Language Code for the localization of exercise content. # noqa: E501 @@ -239,7 +230,7 @@ class MatchingExercise(Model): return self._language @language.setter - def language(self, language): + def language(self, language: str): """Sets the language of this MatchingExercise. ISO 639-1 Language Code for the localization of exercise content. # noqa: E501 @@ -251,7 +242,7 @@ class MatchingExercise(Model): self._language = language @property - def partially_correct_feedback(self): + def partially_correct_feedback(self) -> str: """Gets the partially_correct_feedback of this MatchingExercise. Feedback for successfully completing certain parts of the exercise. # noqa: E501 @@ -262,7 +253,7 @@ class MatchingExercise(Model): return self._partially_correct_feedback @partially_correct_feedback.setter - def partially_correct_feedback(self, partially_correct_feedback): + def partially_correct_feedback(self, partially_correct_feedback: str): """Sets the partially_correct_feedback of this MatchingExercise. Feedback for successfully completing certain parts of the exercise. # noqa: E501 @@ -274,7 +265,7 @@ class MatchingExercise(Model): self._partially_correct_feedback = partially_correct_feedback @property - def search_values(self): + def search_values(self) -> str: """Gets the search_values of this MatchingExercise. Search queries that were used to build the exercise. # noqa: E501 @@ -285,7 +276,7 @@ class MatchingExercise(Model): return self._search_values @search_values.setter - def search_values(self, search_values): + def search_values(self, search_values: str): """Sets the search_values of this MatchingExercise. Search queries that were used to build the exercise. # noqa: E501 @@ -299,7 +290,7 @@ class MatchingExercise(Model): self._search_values = search_values @property - def work_author(self): + def work_author(self) -> str: """Gets the work_author of this MatchingExercise. Name of the person who wrote the base text for the exercise. # noqa: E501 @@ -310,7 +301,7 @@ class MatchingExercise(Model): return self._work_author @work_author.setter - def work_author(self, work_author): + def work_author(self, work_author: str): """Sets the work_author of this MatchingExercise. Name of the person who wrote the base text for the exercise. # noqa: E501 @@ -322,7 +313,7 @@ class MatchingExercise(Model): self._work_author = work_author @property - def work_title(self): + def work_title(self) -> str: """Gets the work_title of this MatchingExercise. Title of the base text for the exercise. # noqa: E501 @@ -333,7 +324,7 @@ class MatchingExercise(Model): return self._work_title @work_title.setter - def work_title(self, work_title): + def work_title(self, work_title: str): """Sets the work_title of this MatchingExercise. Title of the base text for the exercise. # noqa: E501 @@ -345,7 +336,7 @@ class MatchingExercise(Model): self._work_title = work_title @property - def conll(self): + def conll(self) -> str: """Gets the conll of this MatchingExercise. CONLL-formatted linguistic annotations represented as a single string. # noqa: E501 @@ -356,7 +347,7 @@ class MatchingExercise(Model): return self._conll @conll.setter - def conll(self, conll): + def conll(self, conll: str): """Sets the conll of this MatchingExercise. CONLL-formatted linguistic annotations represented as a single string. # noqa: E501 @@ -368,7 +359,7 @@ class MatchingExercise(Model): self._conll = conll @property - def eid(self): + def eid(self) -> str: """Gets the eid of this MatchingExercise. Unique identifier (UUID) for the exercise. # noqa: E501 @@ -379,7 +370,7 @@ class MatchingExercise(Model): return self._eid @eid.setter - def eid(self, eid): + def eid(self, eid: str): """Sets the eid of this MatchingExercise. Unique identifier (UUID) for the exercise. # noqa: E501 @@ -393,7 +384,7 @@ class MatchingExercise(Model): self._eid = eid @property - def exercise_type(self): + def exercise_type(self) -> str: """Gets the exercise_type of this MatchingExercise. Type of exercise, concerning interaction and layout. # noqa: E501 @@ -404,7 +395,7 @@ class MatchingExercise(Model): return self._exercise_type @exercise_type.setter - def exercise_type(self, exercise_type): + def exercise_type(self, exercise_type: str): """Sets the exercise_type of this MatchingExercise. Type of exercise, concerning interaction and layout. # noqa: E501 @@ -416,7 +407,7 @@ class MatchingExercise(Model): self._exercise_type = exercise_type @property - def last_access_time(self): + def last_access_time(self) -> float: """Gets the last_access_time of this MatchingExercise. When the exercise was last accessed (as POSIX timestamp). # noqa: E501 @@ -427,7 +418,7 @@ class MatchingExercise(Model): return self._last_access_time @last_access_time.setter - def last_access_time(self, last_access_time): + def last_access_time(self, last_access_time: float): """Sets the last_access_time of this MatchingExercise. When the exercise was last accessed (as POSIX timestamp). # noqa: E501 @@ -441,7 +432,7 @@ class MatchingExercise(Model): self._last_access_time = last_access_time @property - def solutions(self): + def solutions(self) -> str: """Gets the solutions of this MatchingExercise. Correct solutions for the exercise. # noqa: E501 @@ -452,7 +443,7 @@ class MatchingExercise(Model): return self._solutions @solutions.setter - def solutions(self, solutions): + def solutions(self, solutions: str): """Sets the solutions of this MatchingExercise. Correct solutions for the exercise. # noqa: E501 @@ -464,7 +455,7 @@ class MatchingExercise(Model): self._solutions = solutions @property - def text_complexity(self): + def text_complexity(self) -> float: """Gets the text_complexity of this MatchingExercise. Overall text complexity as measured by the software's internal language analysis. # noqa: E501 @@ -475,7 +466,7 @@ class MatchingExercise(Model): return self._text_complexity @text_complexity.setter - def text_complexity(self, text_complexity): + def text_complexity(self, text_complexity: float): """Sets the text_complexity of this MatchingExercise. Overall text complexity as measured by the software's internal language analysis. # noqa: E501 @@ -487,7 +478,7 @@ class MatchingExercise(Model): self._text_complexity = text_complexity @property - def urn(self): + def urn(self) -> str: """Gets the urn of this MatchingExercise. CTS URN for the text passage from which the exercise was created. # noqa: E501 @@ -498,7 +489,7 @@ class MatchingExercise(Model): return self._urn @urn.setter - def urn(self, urn): + def urn(self, urn: str): """Sets the urn of this MatchingExercise. CTS URN for the text passage from which the exercise was created. # noqa: E501 @@ -510,7 +501,7 @@ class MatchingExercise(Model): self._urn = urn @property - def exercise_type_translation(self): + def exercise_type_translation(self) -> str: """Gets the exercise_type_translation of this MatchingExercise. Localized expression of the exercise type. # noqa: E501 @@ -521,7 +512,7 @@ class MatchingExercise(Model): return self._exercise_type_translation @exercise_type_translation.setter - def exercise_type_translation(self, exercise_type_translation): + def exercise_type_translation(self, exercise_type_translation: str): """Sets the exercise_type_translation of this MatchingExercise. Localized expression of the exercise type. # noqa: E501 @@ -533,7 +524,7 @@ class MatchingExercise(Model): self._exercise_type_translation = exercise_type_translation @property - def matching_degree(self): + def matching_degree(self) -> float: """Gets the matching_degree of this MatchingExercise. Percentage of words in the exercise that match a reference vocabulary. # noqa: E501 @@ -544,7 +535,7 @@ class MatchingExercise(Model): return self._matching_degree @matching_degree.setter - def matching_degree(self, matching_degree): + def matching_degree(self, matching_degree: float): """Sets the matching_degree of this MatchingExercise. Percentage of words in the exercise that match a reference vocabulary. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/node_mc.py b/mc_backend/openapi/openapi_server/models/node_mc.py index aa28998..d2572be 100644 --- a/mc_backend/openapi/openapi_server/models/node_mc.py +++ b/mc_backend/openapi/openapi_server/models/node_mc.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -93,7 +90,7 @@ class NodeMC(Model): return util.deserialize_model(dikt, cls) @property - def annis_node_name(self): + def annis_node_name(self) -> str: """Gets the annis_node_name of this NodeMC. Node name as given by ANNIS. # noqa: E501 @@ -104,7 +101,7 @@ class NodeMC(Model): return self._annis_node_name @annis_node_name.setter - def annis_node_name(self, annis_node_name): + def annis_node_name(self, annis_node_name: str): """Sets the annis_node_name of this NodeMC. Node name as given by ANNIS. # noqa: E501 @@ -116,7 +113,7 @@ class NodeMC(Model): self._annis_node_name = annis_node_name @property - def annis_node_type(self): + def annis_node_type(self) -> str: """Gets the annis_node_type of this NodeMC. Node type as given by ANNIS. # noqa: E501 @@ -127,7 +124,7 @@ class NodeMC(Model): return self._annis_node_type @annis_node_type.setter - def annis_node_type(self, annis_node_type): + def annis_node_type(self, annis_node_type: str): """Sets the annis_node_type of this NodeMC. Node type as given by ANNIS. # noqa: E501 @@ -139,7 +136,7 @@ class NodeMC(Model): self._annis_node_type = annis_node_type @property - def annis_tok(self): + def annis_tok(self) -> str: """Gets the annis_tok of this NodeMC. Raw word form as given by ANNIS. # noqa: E501 @@ -150,7 +147,7 @@ class NodeMC(Model): return self._annis_tok @annis_tok.setter - def annis_tok(self, annis_tok): + def annis_tok(self, annis_tok: str): """Sets the annis_tok of this NodeMC. Raw word form as given by ANNIS. # noqa: E501 @@ -162,7 +159,7 @@ class NodeMC(Model): self._annis_tok = annis_tok @property - def annis_type(self): + def annis_type(self) -> str: """Gets the annis_type of this NodeMC. Node type as given by ANNIS (?). # noqa: E501 @@ -173,7 +170,7 @@ class NodeMC(Model): return self._annis_type @annis_type.setter - def annis_type(self, annis_type): + def annis_type(self, annis_type: str): """Sets the annis_type of this NodeMC. Node type as given by ANNIS (?). # noqa: E501 @@ -185,7 +182,7 @@ class NodeMC(Model): self._annis_type = annis_type @property - def id(self): + def id(self) -> str: """Gets the id of this NodeMC. Unique identifier for the node in the SALT model. # noqa: E501 @@ -196,7 +193,7 @@ class NodeMC(Model): return self._id @id.setter - def id(self, id): + def id(self, id: str): """Sets the id of this NodeMC. Unique identifier for the node in the SALT model. # noqa: E501 @@ -208,7 +205,7 @@ class NodeMC(Model): self._id = id @property - def is_oov(self): + def is_oov(self) -> bool: """Gets the is_oov of this NodeMC. Whether the raw word form is missing in a given vocabulary. # noqa: E501 @@ -219,7 +216,7 @@ class NodeMC(Model): return self._is_oov @is_oov.setter - def is_oov(self, is_oov): + def is_oov(self, is_oov: bool): """Sets the is_oov of this NodeMC. Whether the raw word form is missing in a given vocabulary. # noqa: E501 @@ -231,7 +228,7 @@ class NodeMC(Model): self._is_oov = is_oov @property - def udep_lemma(self): + def udep_lemma(self) -> str: """Gets the udep_lemma of this NodeMC. Lemmatized word form. # noqa: E501 @@ -242,7 +239,7 @@ class NodeMC(Model): return self._udep_lemma @udep_lemma.setter - def udep_lemma(self, udep_lemma): + def udep_lemma(self, udep_lemma: str): """Sets the udep_lemma of this NodeMC. Lemmatized word form. # noqa: E501 @@ -254,7 +251,7 @@ class NodeMC(Model): self._udep_lemma = udep_lemma @property - def udep_upostag(self): + def udep_upostag(self) -> str: """Gets the udep_upostag of this NodeMC. Universal part of speech tag for the word form. # noqa: E501 @@ -265,7 +262,7 @@ class NodeMC(Model): return self._udep_upostag @udep_upostag.setter - def udep_upostag(self, udep_upostag): + def udep_upostag(self, udep_upostag: str): """Sets the udep_upostag of this NodeMC. Universal part of speech tag for the word form. # noqa: E501 @@ -277,7 +274,7 @@ class NodeMC(Model): self._udep_upostag = udep_upostag @property - def udep_xpostag(self): + def udep_xpostag(self) -> str: """Gets the udep_xpostag of this NodeMC. Language-specific part of speech tag for the word form. # noqa: E501 @@ -288,7 +285,7 @@ class NodeMC(Model): return self._udep_xpostag @udep_xpostag.setter - def udep_xpostag(self, udep_xpostag): + def udep_xpostag(self, udep_xpostag: str): """Sets the udep_xpostag of this NodeMC. Language-specific part of speech tag for the word form. # noqa: E501 @@ -300,7 +297,7 @@ class NodeMC(Model): self._udep_xpostag = udep_xpostag @property - def udep_feats(self): + def udep_feats(self) -> str: """Gets the udep_feats of this NodeMC. Additional morphological information. # noqa: E501 @@ -311,7 +308,7 @@ class NodeMC(Model): return self._udep_feats @udep_feats.setter - def udep_feats(self, udep_feats): + def udep_feats(self, udep_feats: str): """Sets the udep_feats of this NodeMC. Additional morphological information. # noqa: E501 @@ -323,7 +320,7 @@ class NodeMC(Model): self._udep_feats = udep_feats @property - def solution(self): + def solution(self) -> str: """Gets the solution of this NodeMC. Solution value for this node in an exercise. # noqa: E501 @@ -334,7 +331,7 @@ class NodeMC(Model): return self._solution @solution.setter - def solution(self, solution): + def solution(self, solution: str): """Sets the solution of this NodeMC. Solution value for this node in an exercise. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/phenomenon.py b/mc_backend/openapi/openapi_server/models/phenomenon.py index 0fad63b..7bc2d83 100644 --- a/mc_backend/openapi/openapi_server/models/phenomenon.py +++ b/mc_backend/openapi/openapi_server/models/phenomenon.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,10 +15,10 @@ class Phenomenon(Model): """ allowed enum values """ - DEPENDENCY = "dependency" - FEATS = "feats" - LEMMA = "lemma" - UPOSTAG = "upostag" + DEPENDENCY = 'dependency' + FEATS = 'feats' + LEMMA = 'lemma' + UPOSTAG = 'upostag' def __init__(self): # noqa: E501 """Phenomenon - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/sentence.py b/mc_backend/openapi/openapi_server/models/sentence.py index 157999a..52a7e4e 100644 --- a/mc_backend/openapi/openapi_server/models/sentence.py +++ b/mc_backend/openapi/openapi_server/models/sentence.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -48,7 +45,7 @@ class Sentence(Model): return util.deserialize_model(dikt, cls) @property - def id(self): + def id(self) -> int: """Gets the id of this Sentence. Unique identifier (in the corpus). # noqa: E501 @@ -59,7 +56,7 @@ class Sentence(Model): return self._id @id.setter - def id(self, id): + def id(self, id: int): """Sets the id of this Sentence. Unique identifier (in the corpus). # noqa: E501 @@ -71,7 +68,7 @@ class Sentence(Model): self._id = id @property - def matching_degree(self): + def matching_degree(self) -> float: """Gets the matching_degree of this Sentence. Percentage of words in the sentence that match a reference vocabulary. # noqa: E501 @@ -82,7 +79,7 @@ class Sentence(Model): return self._matching_degree @matching_degree.setter - def matching_degree(self, matching_degree): + def matching_degree(self, matching_degree: float): """Sets the matching_degree of this Sentence. Percentage of words in the sentence that match a reference vocabulary. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/solution.py b/mc_backend/openapi/openapi_server/models/solution.py index 238f1cf..e5e4b6f 100644 --- a/mc_backend/openapi/openapi_server/models/solution.py +++ b/mc_backend/openapi/openapi_server/models/solution.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server.models.solution_element import SolutionElement from openapi.openapi_server import util @@ -50,7 +47,7 @@ class Solution(Model): return util.deserialize_model(dikt, cls) @property - def target(self): + def target(self) -> SolutionElement: """Gets the target of this Solution. @@ -60,7 +57,7 @@ class Solution(Model): return self._target @target.setter - def target(self, target): + def target(self, target: SolutionElement): """Sets the target of this Solution. @@ -71,7 +68,7 @@ class Solution(Model): self._target = target @property - def value(self): + def value(self) -> SolutionElement: """Gets the value of this Solution. @@ -81,7 +78,7 @@ class Solution(Model): return self._value @value.setter - def value(self, value): + def value(self, value: SolutionElement): """Sets the value of this Solution. diff --git a/mc_backend/openapi/openapi_server/models/solution_element.py b/mc_backend/openapi/openapi_server/models/solution_element.py index b64194b..a529423 100644 --- a/mc_backend/openapi/openapi_server/models/solution_element.py +++ b/mc_backend/openapi/openapi_server/models/solution_element.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -58,7 +55,7 @@ class SolutionElement(Model): return util.deserialize_model(dikt, cls) @property - def content(self): + def content(self) -> str: """Gets the content of this SolutionElement. Content of the solution element. # noqa: E501 @@ -69,7 +66,7 @@ class SolutionElement(Model): return self._content @content.setter - def content(self, content): + def content(self, content: str): """Sets the content of this SolutionElement. Content of the solution element. # noqa: E501 @@ -81,7 +78,7 @@ class SolutionElement(Model): self._content = content @property - def salt_id(self): + def salt_id(self) -> str: """Gets the salt_id of this SolutionElement. Unique identifier for the node in the SALT model. # noqa: E501 @@ -92,7 +89,7 @@ class SolutionElement(Model): return self._salt_id @salt_id.setter - def salt_id(self, salt_id): + def salt_id(self, salt_id: str): """Sets the salt_id of this SolutionElement. Unique identifier for the node in the SALT model. # noqa: E501 @@ -104,7 +101,7 @@ class SolutionElement(Model): self._salt_id = salt_id @property - def sentence_id(self): + def sentence_id(self) -> int: """Gets the sentence_id of this SolutionElement. Unique identifier for the sentence in a corpus. # noqa: E501 @@ -115,7 +112,7 @@ class SolutionElement(Model): return self._sentence_id @sentence_id.setter - def sentence_id(self, sentence_id): + def sentence_id(self, sentence_id: int): """Sets the sentence_id of this SolutionElement. Unique identifier for the sentence in a corpus. # noqa: E501 @@ -129,7 +126,7 @@ class SolutionElement(Model): self._sentence_id = sentence_id @property - def token_id(self): + def token_id(self) -> int: """Gets the token_id of this SolutionElement. Unique identifier for the token in a sentence. # noqa: E501 @@ -140,7 +137,7 @@ class SolutionElement(Model): return self._token_id @token_id.setter - def token_id(self, token_id): + def token_id(self, token_id: int): """Sets the token_id of this SolutionElement. Unique identifier for the token in a sentence. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/static_exercise.py b/mc_backend/openapi/openapi_server/models/static_exercise.py index 6e1687f..adfb940 100644 --- a/mc_backend/openapi/openapi_server/models/static_exercise.py +++ b/mc_backend/openapi/openapi_server/models/static_exercise.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -48,7 +45,7 @@ class StaticExercise(Model): return util.deserialize_model(dikt, cls) @property - def solutions(self): + def solutions(self) -> List[List[str]]: """Gets the solutions of this StaticExercise. Solutions for the exercise. # noqa: E501 @@ -59,7 +56,7 @@ class StaticExercise(Model): return self._solutions @solutions.setter - def solutions(self, solutions): + def solutions(self, solutions: List[List[str]]): """Sets the solutions of this StaticExercise. Solutions for the exercise. # noqa: E501 @@ -71,7 +68,7 @@ class StaticExercise(Model): self._solutions = solutions @property - def urn(self): + def urn(self) -> str: """Gets the urn of this StaticExercise. CTS URN for the text passage from which the exercise was created. # noqa: E501 @@ -82,7 +79,7 @@ class StaticExercise(Model): return self._urn @urn.setter - def urn(self, urn): + def urn(self, urn: str): """Sets the urn of this StaticExercise. CTS URN for the text passage from which the exercise was created. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/text_complexity.py b/mc_backend/openapi/openapi_server/models/text_complexity.py index 37dee5d..d795286 100644 --- a/mc_backend/openapi/openapi_server/models/text_complexity.py +++ b/mc_backend/openapi/openapi_server/models/text_complexity.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -113,7 +110,7 @@ class TextComplexity(Model): return util.deserialize_model(dikt, cls) @property - def all(self): + def all(self) -> float: """Gets the all of this TextComplexity. Overall text complexity of the given corpus. # noqa: E501 @@ -124,7 +121,7 @@ class TextComplexity(Model): return self._all @all.setter - def all(self, all): + def all(self, all: float): """Sets the all of this TextComplexity. Overall text complexity of the given corpus. # noqa: E501 @@ -136,7 +133,7 @@ class TextComplexity(Model): self._all = all @property - def avg_w_len(self): + def avg_w_len(self) -> float: """Gets the avg_w_len of this TextComplexity. Average length of a word in the given corpus. # noqa: E501 @@ -147,7 +144,7 @@ class TextComplexity(Model): return self._avg_w_len @avg_w_len.setter - def avg_w_len(self, avg_w_len): + def avg_w_len(self, avg_w_len: float): """Sets the avg_w_len of this TextComplexity. Average length of a word in the given corpus. # noqa: E501 @@ -159,7 +156,7 @@ class TextComplexity(Model): self._avg_w_len = avg_w_len @property - def avg_w_per_sent(self): + def avg_w_per_sent(self) -> float: """Gets the avg_w_per_sent of this TextComplexity. Average number of words per sentence. # noqa: E501 @@ -170,7 +167,7 @@ class TextComplexity(Model): return self._avg_w_per_sent @avg_w_per_sent.setter - def avg_w_per_sent(self, avg_w_per_sent): + def avg_w_per_sent(self, avg_w_per_sent: float): """Sets the avg_w_per_sent of this TextComplexity. Average number of words per sentence. # noqa: E501 @@ -182,7 +179,7 @@ class TextComplexity(Model): self._avg_w_per_sent = avg_w_per_sent @property - def lex_den(self): + def lex_den(self) -> float: """Gets the lex_den of this TextComplexity. Lexical density of the given corpus. # noqa: E501 @@ -193,7 +190,7 @@ class TextComplexity(Model): return self._lex_den @lex_den.setter - def lex_den(self, lex_den): + def lex_den(self, lex_den: float): """Sets the lex_den of this TextComplexity. Lexical density of the given corpus. # noqa: E501 @@ -209,7 +206,7 @@ class TextComplexity(Model): self._lex_den = lex_den @property - def n_abl_abs(self): + def n_abl_abs(self) -> int: """Gets the n_abl_abs of this TextComplexity. Number of ablativi absoluti in the given corpus. # noqa: E501 @@ -220,7 +217,7 @@ class TextComplexity(Model): return self._n_abl_abs @n_abl_abs.setter - def n_abl_abs(self, n_abl_abs): + def n_abl_abs(self, n_abl_abs: int): """Sets the n_abl_abs of this TextComplexity. Number of ablativi absoluti in the given corpus. # noqa: E501 @@ -232,7 +229,7 @@ class TextComplexity(Model): self._n_abl_abs = n_abl_abs @property - def n_clause(self): + def n_clause(self) -> int: """Gets the n_clause of this TextComplexity. Number of clauses in the given corpus. # noqa: E501 @@ -243,7 +240,7 @@ class TextComplexity(Model): return self._n_clause @n_clause.setter - def n_clause(self, n_clause): + def n_clause(self, n_clause: int): """Sets the n_clause of this TextComplexity. Number of clauses in the given corpus. # noqa: E501 @@ -255,7 +252,7 @@ class TextComplexity(Model): self._n_clause = n_clause @property - def n_gerund(self): + def n_gerund(self) -> int: """Gets the n_gerund of this TextComplexity. Number of gerunds in the given corpus. # noqa: E501 @@ -266,7 +263,7 @@ class TextComplexity(Model): return self._n_gerund @n_gerund.setter - def n_gerund(self, n_gerund): + def n_gerund(self, n_gerund: int): """Sets the n_gerund of this TextComplexity. Number of gerunds in the given corpus. # noqa: E501 @@ -278,7 +275,7 @@ class TextComplexity(Model): self._n_gerund = n_gerund @property - def n_inf(self): + def n_inf(self) -> int: """Gets the n_inf of this TextComplexity. Number of infinitives in the given corpus. # noqa: E501 @@ -289,7 +286,7 @@ class TextComplexity(Model): return self._n_inf @n_inf.setter - def n_inf(self, n_inf): + def n_inf(self, n_inf: int): """Sets the n_inf of this TextComplexity. Number of infinitives in the given corpus. # noqa: E501 @@ -301,7 +298,7 @@ class TextComplexity(Model): self._n_inf = n_inf @property - def n_part(self): + def n_part(self) -> int: """Gets the n_part of this TextComplexity. Number of participles in the given corpus. # noqa: E501 @@ -312,7 +309,7 @@ class TextComplexity(Model): return self._n_part @n_part.setter - def n_part(self, n_part): + def n_part(self, n_part: int): """Sets the n_part of this TextComplexity. Number of participles in the given corpus. # noqa: E501 @@ -324,7 +321,7 @@ class TextComplexity(Model): self._n_part = n_part @property - def n_punct(self): + def n_punct(self) -> int: """Gets the n_punct of this TextComplexity. Number of punctuation signs in the given corpus. # noqa: E501 @@ -335,7 +332,7 @@ class TextComplexity(Model): return self._n_punct @n_punct.setter - def n_punct(self, n_punct): + def n_punct(self, n_punct: int): """Sets the n_punct of this TextComplexity. Number of punctuation signs in the given corpus. # noqa: E501 @@ -347,7 +344,7 @@ class TextComplexity(Model): self._n_punct = n_punct @property - def n_sent(self): + def n_sent(self) -> int: """Gets the n_sent of this TextComplexity. Number of sentences in the given corpus. # noqa: E501 @@ -358,7 +355,7 @@ class TextComplexity(Model): return self._n_sent @n_sent.setter - def n_sent(self, n_sent): + def n_sent(self, n_sent: int): """Sets the n_sent of this TextComplexity. Number of sentences in the given corpus. # noqa: E501 @@ -370,7 +367,7 @@ class TextComplexity(Model): self._n_sent = n_sent @property - def n_subclause(self): + def n_subclause(self) -> int: """Gets the n_subclause of this TextComplexity. Number of subclauses in the given corpus. # noqa: E501 @@ -381,7 +378,7 @@ class TextComplexity(Model): return self._n_subclause @n_subclause.setter - def n_subclause(self, n_subclause): + def n_subclause(self, n_subclause: int): """Sets the n_subclause of this TextComplexity. Number of subclauses in the given corpus. # noqa: E501 @@ -393,7 +390,7 @@ class TextComplexity(Model): self._n_subclause = n_subclause @property - def n_types(self): + def n_types(self) -> int: """Gets the n_types of this TextComplexity. Number of distinct word forms in the given corpus. # noqa: E501 @@ -404,7 +401,7 @@ class TextComplexity(Model): return self._n_types @n_types.setter - def n_types(self, n_types): + def n_types(self, n_types: int): """Sets the n_types of this TextComplexity. Number of distinct word forms in the given corpus. # noqa: E501 @@ -416,7 +413,7 @@ class TextComplexity(Model): self._n_types = n_types @property - def n_w(self): + def n_w(self) -> int: """Gets the n_w of this TextComplexity. Number of words in the given corpus. # noqa: E501 @@ -427,7 +424,7 @@ class TextComplexity(Model): return self._n_w @n_w.setter - def n_w(self, n_w): + def n_w(self, n_w: int): """Sets the n_w of this TextComplexity. Number of words in the given corpus. # noqa: E501 @@ -439,7 +436,7 @@ class TextComplexity(Model): self._n_w = n_w @property - def pos(self): + def pos(self) -> int: """Gets the pos of this TextComplexity. Number of distinct part of speech tags in the given corpus. # noqa: E501 @@ -450,7 +447,7 @@ class TextComplexity(Model): return self._pos @pos.setter - def pos(self, pos): + def pos(self, pos: int): """Sets the pos of this TextComplexity. Number of distinct part of speech tags in the given corpus. # noqa: E501 diff --git a/mc_backend/openapi/openapi_server/models/vocabulary_mc.py b/mc_backend/openapi/openapi_server/models/vocabulary_mc.py index 66787dc..4d6885b 100644 --- a/mc_backend/openapi/openapi_server/models/vocabulary_mc.py +++ b/mc_backend/openapi/openapi_server/models/vocabulary_mc.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,10 +15,11 @@ class VocabularyMC(Model): """ allowed enum values """ - AGLDT = "agldt" - BWS = "bws" - PROIEL = "proiel" - VIVA = "viva" + AGLDT = 'agldt' + BWS = 'bws' + PROIEL = 'proiel' + VISCHER = 'vischer' + VIVA = 'viva' def __init__(self): # noqa: E501 """VocabularyMC - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix.py b/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix.py index 2b7d643..9e2cbce 100644 --- a/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix.py +++ b/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,8 +15,8 @@ class ZenodoMetadataPrefix(Model): """ allowed enum values """ - MARC21 = "marc21" - OAI_DATACITE = "oai_datacite" + MARC21 = 'marc21' + OAI_DATACITE = 'oai_datacite' def __init__(self): # noqa: E501 """ZenodoMetadataPrefix - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix_extension.py b/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix_extension.py index 013745e..4ee0384 100644 --- a/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix_extension.py +++ b/mc_backend/openapi/openapi_server/models/zenodo_metadata_prefix_extension.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -18,8 +15,8 @@ class ZenodoMetadataPrefixExtension(Model): """ allowed enum values """ - MARC21 = "marc21" - OAI_DATACITE = "oai_datacite" + MARC21 = 'marc21' + OAI_DATACITE = 'oai_datacite' def __init__(self): # noqa: E501 """ZenodoMetadataPrefixExtension - a model defined in OpenAPI diff --git a/mc_backend/openapi/openapi_server/models/zenodo_record.py b/mc_backend/openapi/openapi_server/models/zenodo_record.py index 8570f8c..c9afe91 100644 --- a/mc_backend/openapi/openapi_server/models/zenodo_record.py +++ b/mc_backend/openapi/openapi_server/models/zenodo_record.py @@ -1,11 +1,8 @@ -# coding: utf-8 - -from __future__ import absolute_import from datetime import date, datetime # noqa: F401 from typing import List, Dict # noqa: F401 -from openapi.openapi_server.models.base_model_ import Model +from openapi.openapi_server.models.base_model import Model from openapi.openapi_server import util @@ -88,7 +85,7 @@ class ZenodoRecord(Model): return util.deserialize_model(dikt, cls) @property - def author(self): + def author(self) -> str: """Gets the author of this ZenodoRecord. Author of the text that serves as a basis or target for this record. # noqa: E501 @@ -99,7 +96,7 @@ class ZenodoRecord(Model): return self._author @author.setter - def author(self, author): + def author(self, author: str): """Sets the author of this ZenodoRecord. Author of the text that serves as a basis or target for this record. # noqa: E501 @@ -111,7 +108,7 @@ class ZenodoRecord(Model): self._author = author @property - def contributor(self): + def contributor(self) -> List[str]: """Gets the contributor of this ZenodoRecord. @@ -121,7 +118,7 @@ class ZenodoRecord(Model): return self._contributor @contributor.setter - def contributor(self, contributor): + def contributor(self, contributor: List[str]): """Sets the contributor of this ZenodoRecord. @@ -132,7 +129,7 @@ class ZenodoRecord(Model): self._contributor = contributor @property - def creator_name(self): + def creator_name(self) -> List[str]: """Gets the creator_name of this ZenodoRecord. @@ -142,7 +139,7 @@ class ZenodoRecord(Model): return self._creator_name @creator_name.setter - def creator_name(self, creator_name): + def creator_name(self, creator_name: List[str]): """Sets the creator_name of this ZenodoRecord. @@ -153,7 +150,7 @@ class ZenodoRecord(Model): self._creator_name = creator_name @property - def description(self): + def description(self) -> List[str]: """Gets the description of this ZenodoRecord. @@ -163,7 +160,7 @@ class ZenodoRecord(Model): return self._description @description.setter - def description(self, description): + def description(self, description: List[str]): """Sets the description of this ZenodoRecord. @@ -174,7 +171,7 @@ class ZenodoRecord(Model): self._description = description @property - def identifier(self): + def identifier(self) -> List[str]: """Gets the identifier of this ZenodoRecord. @@ -184,7 +181,7 @@ class ZenodoRecord(Model): return self._identifier @identifier.setter - def identifier(self, identifier): + def identifier(self, identifier: List[str]): """Sets the identifier of this ZenodoRecord. @@ -195,7 +192,7 @@ class ZenodoRecord(Model): self._identifier = identifier @property - def language(self): + def language(self) -> List[str]: """Gets the language of this ZenodoRecord. @@ -205,7 +202,7 @@ class ZenodoRecord(Model): return self._language @language.setter - def language(self, language): + def language(self, language: List[str]): """Sets the language of this ZenodoRecord. @@ -216,7 +213,7 @@ class ZenodoRecord(Model): self._language = language @property - def subject(self): + def subject(self) -> List[str]: """Gets the subject of this ZenodoRecord. @@ -226,7 +223,7 @@ class ZenodoRecord(Model): return self._subject @subject.setter - def subject(self, subject): + def subject(self, subject: List[str]): """Sets the subject of this ZenodoRecord. @@ -237,7 +234,7 @@ class ZenodoRecord(Model): self._subject = subject @property - def title(self): + def title(self) -> List[str]: """Gets the title of this ZenodoRecord. @@ -247,7 +244,7 @@ class ZenodoRecord(Model): return self._title @title.setter - def title(self, title): + def title(self, title: List[str]): """Sets the title of this ZenodoRecord. @@ -258,7 +255,7 @@ class ZenodoRecord(Model): self._title = title @property - def version(self): + def version(self) -> List[str]: """Gets the version of this ZenodoRecord. @@ -268,7 +265,7 @@ class ZenodoRecord(Model): return self._version @version.setter - def version(self, version): + def version(self, version: List[str]): """Sets the version of this ZenodoRecord. @@ -279,7 +276,7 @@ class ZenodoRecord(Model): self._version = version @property - def work(self): + def work(self) -> List[str]: """Gets the work of this ZenodoRecord. @@ -289,7 +286,7 @@ class ZenodoRecord(Model): return self._work @work.setter - def work(self, work): + def work(self, work: List[str]): """Sets the work of this ZenodoRecord. diff --git a/mc_backend/openapi/openapi_server/openapi/openapi.yaml b/mc_backend/openapi/openapi_server/openapi/openapi.yaml index 1b7bb01..e3fd273 100644 --- a/mc_backend/openapi/openapi_server/openapi/openapi.yaml +++ b/mc_backend/openapi/openapi_server/openapi/openapi.yaml @@ -134,8 +134,8 @@ paths: application/json: schema: $ref: '#/components/schemas/AnnisResponse' - description: Exercise data object, including a graph model for linguistic - annotations. + description: "Exercise data object, including a graph model for linguistic\ + \ annotations." summary: Returns exercise data by ID. x-openapi-router-controller: openapi_server.controllers.default_controller post: @@ -202,7 +202,7 @@ paths: items: $ref: '#/components/schemas/MatchingExercise' type: array - description: Data for interactive exercises, excluding the linguistic details. + description: "Data for interactive exercises, excluding the linguistic details." summary: Provides metadata for all available exercises. x-openapi-router-controller: openapi_server.controllers.default_controller /file: @@ -248,7 +248,7 @@ paths: application/xml: schema: type: object - description: Data for interactive exercises, excluding the linguistic details. + description: "Data for interactive exercises, excluding the linguistic details." summary: Provides the URL to download a specific file. x-openapi-router-controller: openapi_server.controllers.default_controller post: @@ -264,11 +264,12 @@ paths: content: application/json: schema: - description: Indication of success, or name of the file that was generated. + description: "Indication of success, or name of the file that was\ + \ generated." example: 12345678-1234-5678-1234-567812345678.pdf type: string - description: Indication of success, possibly a reference to the resulting - file. + description: "Indication of success, possibly a reference to the resulting\ + \ file." summary: Serializes and persists learning results or HTML content for later access. x-openapi-router-controller: openapi_server.controllers.default_controller @@ -292,7 +293,7 @@ paths: items: $ref: '#/components/schemas/FrequencyItem' type: array - description: Frequency analysis, i.e. a list of frequency items. + description: "Frequency analysis, i.e. a list of frequency items." summary: Returns results for a frequency query from ANNIS for a given CTS URN. x-openapi-router-controller: openapi_server.controllers.default_controller /h5p: @@ -388,7 +389,7 @@ paths: application/json: schema: $ref: '#/components/schemas/AnnisResponse' - description: Graph data for the text passage, including raw text and annotations. + description: "Graph data for the text passage, including raw text and annotations." summary: Provides the raw text for a requested text passage. x-openapi-router-controller: openapi_server.controllers.default_controller /staticExercises: @@ -402,8 +403,8 @@ paths: additionalProperties: $ref: '#/components/schemas/StaticExercise' type: object - description: Metadata for static exercises, mapped to their respective URIs - in the frontend. + description: "Metadata for static exercises, mapped to their respective\ + \ URIs in the frontend." summary: Returns metadata for static exercises. x-openapi-router-controller: openapi_server.controllers.default_controller /textcomplexity: @@ -478,7 +479,7 @@ paths: required: false schema: default: "" - example: ver[aoe] + example: "ver[aoe]" type: string style: form - description: Minimum number of occurrences that a word needs to be included @@ -637,6 +638,50 @@ paths: record on Zenodo. x-openapi-router-controller: openapi_server.controllers.default_controller components: + parameters: + LastUpdateTimeParam: + description: Time (in milliseconds) of the last update. + in: query + name: last_update_time + required: true + schema: + example: 123456789 + type: integer + EidParam: + description: Unique identifier (UUID) for the exercise. + in: query + name: eid + required: true + schema: + example: 12345678-1234-5678-1234-567812345678 + type: string + LangParam: + description: ISO 639-1 Language Code for the localization of exercise content. + in: query + name: lang + required: true + schema: + example: en + type: string + SolutionIndicesParam: + description: Indices for the solutions that should be included in the download. + in: query + name: solution_indices + required: false + schema: + default: [] + items: + example: 0 + type: integer + type: array + UrnParam: + description: CTS URN for referencing the corpus. + in: query + name: urn + required: true + schema: + example: urn:cts:latinLit:phi1254.phi001.perseus-lat2:5.6.21-5.6.21 + type: string schemas: ExerciseAuthorExtension: description: Authors of curated exercises in the Machina Callida. @@ -646,8 +691,8 @@ components: example: callidus type: string ZenodoMetadataPrefixExtension: - description: Prefix for requests to the Zenodo API, indicating the desired metadata - scheme. + description: "Prefix for requests to the Zenodo API, indicating the desired\ + \ metadata scheme." enum: - marc21 - oai_datacite @@ -669,10 +714,12 @@ components: description: Author of the texts in the corpus. example: Aulus Gellius nullable: false + title: author type: string cid: description: Unique identifier for the corpus. example: 1 + title: cid type: integer x-primary-key: true x-autoincrement: true @@ -680,20 +727,24 @@ components: default: default description: First level for citing the corpus. example: Book + title: citation_level_1 type: string citation_level_2: default: default description: Second level for citing the corpus. example: Chapter + title: citation_level_2 type: string citation_level_3: default: default description: Third level for citing the corpus. example: Section + title: citation_level_3 type: string source_urn: description: CTS base URN for referencing the corpus. example: urn:cts:latinLit:phi1254.phi001.perseus-lat2 + title: source_urn type: string x-unique: true title: @@ -701,26 +752,28 @@ components: description: Corpus title. example: Noctes Atticae nullable: false + title: title type: string required: - source_urn + title: Corpus type: object x-tablename: Corpus AnnisResponse: - description: A response with graph data from ANNIS, possibly with additional - data for exercises. + description: "A response with graph data from ANNIS, possibly with additional\ + \ data for exercises." example: frequency_analysis: - values: - - values - - values + - "" + - "" count: 1 phenomena: - upostag - upostag - values: - - values - - values + - "" + - "" count: 1 phenomena: - upostag @@ -768,7 +821,7 @@ components: nodes: - annis_node_name: urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 udep_xpostag: Ne - solution: solution + solution: "" annis_tok: Galliae annis_type: node annis_node_type: node @@ -779,7 +832,7 @@ components: is_oov: true - annis_node_name: urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 udep_xpostag: Ne - solution: solution + solution: "" annis_tok: Galliae annis_type: node annis_node_type: node @@ -808,17 +861,20 @@ components: default: "" description: Unique identifier (UUID) for the exercise. example: 12345678-1234-5678-1234-567812345678 + title: exercise_id type: string exercise_type: default: "" - description: Type of exercise, concerning interaction and layout. + description: "Type of exercise, concerning interaction and layout." example: ddwtos + title: exercise_type type: string frequency_analysis: default: [] description: List of items with frequency data for linguistic phenomena. items: $ref: '#/components/schemas/FrequencyItem' + title: frequency_analysis type: array graph_data: $ref: '#/components/schemas/GraphData' @@ -827,6 +883,7 @@ components: description: Correct solutions for this exercise. items: $ref: '#/components/schemas/Solution' + title: solutions type: array text_complexity: $ref: '#/components/schemas/TextComplexity' @@ -834,13 +891,15 @@ components: default: "" description: URI for accessing the exercise in this API. example: /mc/api/v1.0/file/fd97630c-1f5a-4102-af56-20eb0babdfee + title: uri type: string + title: AnnisResponse type: object FrequencyItem: example: values: - - values - - values + - "" + - "" count: 1 phenomena: - upostag @@ -850,6 +909,7 @@ components: default: 0 description: How often the given combination of values occurred. example: 1 + title: count type: integer phenomena: default: [] @@ -857,32 +917,37 @@ components: entry. items: $ref: '#/components/schemas/Phenomenon' + title: phenomena type: array values: default: [] description: Values for the phenomena described in this frequency entry. items: + example: "" type: string + title: values type: array + title: FrequencyItem type: object Phenomenon: - description: 'Linguistic phenomena: syntactic dependencies, morphological features, - lemmata, parts of speech.' + description: "Linguistic phenomena: syntactic dependencies, morphological features,\ + \ lemmata, parts of speech." enum: - dependency - feats - lemma - upostag example: upostag + title: Phenomenon type: string GraphData: - description: Nodes, edges and metadata for a graph. + description: "Nodes, edges and metadata for a graph." example: directed: true nodes: - annis_node_name: urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 udep_xpostag: Ne - solution: solution + solution: "" annis_tok: Galliae annis_type: node annis_node_type: node @@ -893,7 +958,7 @@ components: is_oov: true - annis_node_name: urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 udep_xpostag: Ne - solution: solution + solution: "" annis_tok: Galliae annis_type: node annis_node_type: node @@ -919,28 +984,34 @@ components: directed: description: Whether edges in the returned graph are directed. example: true + title: directed type: boolean graph: description: Additional graph data. example: {} + title: graph type: object links: description: List of edges for the graph. items: $ref: '#/components/schemas/Link' + title: links type: array multigraph: description: Whether the graph consists of multiple subgraphs. example: true + title: multigraph type: boolean nodes: description: List of nodes for the graph. items: $ref: '#/components/schemas/NodeMC' + title: nodes type: array required: - links - nodes + title: GraphData type: object Link: example: @@ -953,29 +1024,35 @@ components: annis_component_name: description: Component name as given by ANNIS. example: dep + title: annis_component_name type: string annis_component_type: description: Component type as given by ANNIS. example: Pointing + title: annis_component_type type: string source: description: ID of the source node for the edge. example: salt:/urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 + title: source type: string target: description: ID of the target node for the edge. example: salt:/urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok3 + title: target type: string udep_deprel: description: Dependency relation described by the edge. example: det + title: udep_deprel type: string + title: Link type: object NodeMC: example: annis_node_name: urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 udep_xpostag: Ne - solution: solution + solution: "" annis_tok: Galliae annis_type: node annis_node_type: node @@ -988,46 +1065,59 @@ components: annis_node_name: description: Node name as given by ANNIS. example: urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 + title: annis_node_name type: string annis_node_type: description: Node type as given by ANNIS. example: node + title: annis_node_type type: string annis_tok: description: Raw word form as given by ANNIS. example: Galliae + title: annis_tok type: string annis_type: description: Node type as given by ANNIS (?). example: node + title: annis_type type: string id: description: Unique identifier for the node in the SALT model. example: salt:/urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok1 + title: id type: string is_oov: description: Whether the raw word form is missing in a given vocabulary. example: true + title: is_oov type: boolean udep_lemma: description: Lemmatized word form. example: Gallia + title: udep_lemma type: string udep_upostag: description: Universal part of speech tag for the word form. example: PROPN + title: udep_upostag type: string udep_xpostag: description: Language-specific part of speech tag for the word form. example: Ne + title: udep_xpostag type: string udep_feats: description: Additional morphological information. example: Case=Nom|Gender=Fem|Number=Sing + title: udep_feats type: string solution: description: Solution value for this node in an exercise. + example: "" + title: solution type: string + title: NodeMC type: object Solution: description: Correct solution for an exercise. @@ -1047,6 +1137,7 @@ components: $ref: '#/components/schemas/SolutionElement' value: $ref: '#/components/schemas/SolutionElement' + title: Solution type: object SolutionElement: description: Target or value of a correct solution for an exercise. @@ -1059,22 +1150,27 @@ components: content: description: Content of the solution element. example: unam + title: content type: string salt_id: description: Unique identifier for the node in the SALT model. example: salt:/urn:custom:latinLit:proiel.caes-gal.lat:1.1.1/doc1#sent52548tok9 + title: salt_id type: string sentence_id: description: Unique identifier for the sentence in a corpus. example: 52548 + title: sentence_id type: integer token_id: description: Unique identifier for the token in a sentence. example: 9 + title: token_id type: integer required: - sentence_id - token_id + title: SolutionElement type: object TextComplexity: description: Mapping of various elements of text complexity to their corresponding @@ -1100,16 +1196,19 @@ components: description: Overall text complexity of the given corpus. example: 42.31 format: float + title: all type: number avg_w_len: description: Average length of a word in the given corpus. example: 5.4 format: float + title: avg_w_len type: number avg_w_per_sent: description: Average number of words per sentence. example: 5.4 format: float + title: avg_w_per_sent type: number lex_den: description: Lexical density of the given corpus. @@ -1117,56 +1216,88 @@ components: format: float maximum: 1 minimum: 0 + title: lex_den type: number n_abl_abs: description: Number of ablativi absoluti in the given corpus. example: 1 + title: n_abl_abs type: integer n_clause: description: Number of clauses in the given corpus. example: 1 + title: n_clause type: integer n_gerund: description: Number of gerunds in the given corpus. example: 1 + title: n_gerund type: integer n_inf: description: Number of infinitives in the given corpus. example: 1 + title: n_inf type: integer n_part: description: Number of participles in the given corpus. example: 1 + title: n_part type: integer n_punct: description: Number of punctuation signs in the given corpus. example: 1 + title: n_punct type: integer n_sent: description: Number of sentences in the given corpus. example: 1 + title: n_sent type: integer n_subclause: description: Number of subclauses in the given corpus. example: 1 + title: n_subclause type: integer n_types: description: Number of distinct word forms in the given corpus. example: 1 + title: n_types type: integer n_w: description: Number of words in the given corpus. example: 1 + title: n_w type: integer pos: description: Number of distinct part of speech tags in the given corpus. example: 1 + title: pos type: integer + title: TextComplexity type: object ExerciseForm: allOf: - $ref: '#/components/schemas/ExerciseBase' - - $ref: '#/components/schemas/ExerciseForm_allOf' + - description: Additional exercise data. + properties: + type: + description: "Type of exercise, concerning interaction and layout." + example: markWords + type: string + type_translation: + default: "" + description: Localized expression of the exercise type. + example: Cloze + type: string + urn: + description: CTS URN for the text passage from which the exercise was + created. + example: urn:cts:latinLit:phi0448.phi001.perseus-lat2:1.1.1-1.1.1 + type: string + required: + - type + - urn + type: object type: object x-body-name: exercise_data ExerciseBase: @@ -1176,66 +1307,91 @@ components: default: "" description: Feedback for successful completion of the exercise. example: Well done! + title: correct_feedback type: string general_feedback: default: "" description: Feedback for finishing the exercise. example: You have finished the exercise. + title: general_feedback type: string incorrect_feedback: default: "" description: Feedback for failing to complete the exercise successfully. - example: Unfortunately, that answer is wrong. + example: "Unfortunately, that answer is wrong." + title: incorrect_feedback type: string instructions: default: "" description: Hints for how to complete the exercise. example: Fill in the gaps! + title: instructions type: string language: default: de description: ISO 639-1 Language Code for the localization of exercise content. example: en + title: language type: string partially_correct_feedback: default: "" description: Feedback for successfully completing certain parts of the exercise. example: Some parts of this answer are correct. + title: partially_correct_feedback type: string search_values: - default: '[]' + default: "[]" description: Search queries that were used to build the exercise. - example: '[''upostag=noun'', ''dependency=object'']' + example: "['upostag=noun', 'dependency=object']" + title: search_values type: string work_author: default: "" description: Name of the person who wrote the base text for the exercise. example: C. Iulius Caesar + title: work_author type: string work_title: default: "" description: Title of the base text for the exercise. example: Noctes Atticae + title: work_title type: string required: - instructions - search_values + title: ExerciseBase type: object VocabularyMC: - description: 'Reference vocabularies: Ancient Greek and Latin Dependency Treebank, - Bamberger Wortschatz, PROIEL treebank, VIVA textbook' + description: "Reference vocabularies: Ancient Greek and Latin Dependency Treebank,\ + \ Bamberger Wortschatz, PROIEL treebank, Vischer Wortkunde, VIVA textbook" enum: - agldt - bws - proiel + - vischer - viva example: agldt + title: VocabularyMC type: string MatchingExercise: allOf: - $ref: '#/components/schemas/ExerciseBase' - $ref: '#/components/schemas/ExerciseExtension' - - $ref: '#/components/schemas/MatchingExercise_allOf' + - description: Extra data for comparison with a reference vocabulary. + properties: + exercise_type_translation: + description: Localized expression of the exercise type. + example: Cloze + type: string + matching_degree: + description: Percentage of words in the exercise that match a reference + vocabulary. + example: 76.34 + format: float + type: number + type: object + title: MatchingExercise ExerciseExtension: description: Additional data for creating and evaluating interactive exercises. properties: @@ -1246,31 +1402,36 @@ components: example: \# newdoc id = ...\n# sent_id = 1\n# text = Caesar fortis est.\n1\tCaesar\tCaeso\tVERB ... nullable: false + title: conll type: string eid: description: Unique identifier (UUID) for the exercise. example: 12345678-1234-5678-1234-567812345678 + title: eid type: string x-primary-key: true exercise_type: default: "" - description: Type of exercise, concerning interaction and layout. + description: "Type of exercise, concerning interaction and layout." example: markWords nullable: false + title: exercise_type type: string last_access_time: description: When the exercise was last accessed (as POSIX timestamp). example: 1234567.789 format: float + title: last_access_time type: number x-index: true solutions: - default: '[]' + default: "[]" description: Correct solutions for the exercise. - example: '[{''target'': {''sentence_id'': 1, ''token_id'': 7, ''salt_id'': - ''salt:/urn:...'', ''content'': ''eo''}, ''value'': {''sentence_id'': - 0, ''token_id'': 0, ''content'': None, ''salt_id'': ''salt:/urn:...''}}]' + example: "[{'target': {'sentence_id': 1, 'token_id': 7, 'salt_id': 'salt:/urn:...',\ + \ 'content': 'eo'}, 'value': {'sentence_id': 0, 'token_id': 0, 'content':\ + \ None, 'salt_id': 'salt:/urn:...'}}]" nullable: false + title: solutions type: string text_complexity: default: 0.0 @@ -1278,16 +1439,19 @@ components: language analysis. example: 54.53 format: float + title: text_complexity type: number urn: default: "" description: CTS URN for the text passage from which the exercise was created. example: urn:cts:latinLit:phi0448.phi001.perseus-lat2:1.1.1-1.1.1 nullable: false + title: urn type: string required: - eid - last_access_time + title: ExerciseExtension type: object FileType: description: File format for the requested serialization. @@ -1299,6 +1463,7 @@ components: - xml - zip example: pdf + title: FileType type: string FileForm: description: Metadata for file content to be saved for later access. @@ -1311,7 +1476,7 @@ components: type: string learning_result: description: Serialized XAPI results for an interactive exercise. - example: '{''0'': {}}' + example: "{'0': {}}" type: string urn: description: CTS URN for the text passage from which the HTML content was @@ -1347,18 +1512,20 @@ components: - dialog_cards - drag_text - fill_blanks + - find_words - mark_words - multi_choice - voc_list example: drag_text + title: ExerciseTypePath type: string KwicForm: description: Relevant parameters for creating a Keyword In Context view. properties: search_values: - default: '[]' + default: "[]" description: Search queries that were used to build the exercise. - example: '[''upostag=noun'', ''dependency=object'']' + example: "['upostag=noun', 'dependency=object']" type: string urn: description: CTS URN for the text passage from which the KWIC view should @@ -1388,22 +1555,25 @@ components: solutions: description: Solutions for the exercise. items: - description: Single solution, given as tuple of correct response and its - lemma. + description: "Single solution, given as tuple of correct response and\ + \ its lemma." items: description: Correct response or corresponding lemma. example: gaudeas type: string type: array + title: solutions type: array urn: description: CTS URN for the text passage from which the exercise was created. example: urn:cts:latinLit:phi0448.phi001.perseus-lat2:1.1.1-1.1.1 + title: urn type: string + title: StaticExercise type: object SearchRegex: description: Regular expression for a textual search. - example: ver[aoe] + example: "ver[aoe]" type: string NearestNeighborCount: default: 0 @@ -1416,15 +1586,9 @@ components: target word. properties: search_regex: - description: Regular expression for a textual search. - example: ver[aoe] - type: string + $ref: '#/components/schemas/SearchRegex' nearest_neighbor_count: - default: 0 - description: Number of nearest neighbors that should be considered for each - target node in a graph analysis. - example: 50 - type: integer + $ref: '#/components/schemas/NearestNeighborCount' required: - search_regex type: object @@ -1438,13 +1602,16 @@ components: id: description: Unique identifier (in the corpus). example: 1 + title: id type: integer matching_degree: description: Percentage of words in the sentence that match a reference vocabulary. example: 76.34 format: float + title: matching_degree type: number + title: Sentence type: object VocabularyForm: description: Relevant parameters for comparing a corpus to a reference vocabulary. @@ -1472,29 +1639,29 @@ components: - https://zenodo.org/record/4515301 - https://zenodo.org/record/4515301 contributor: - - Forst, Alexandra - - Forst, Alexandra + - "Forst, Alexandra" + - "Forst, Alexandra" author: Caesar subject: - Latein - Latein work: - - Bellum civile II, 43-44 - - Bellum civile II, 43-44 + - "Bellum civile II, 43-44" + - "Bellum civile II, 43-44" description: - Die Materialien dieser Lerneinheit sollen Lateinstudierende bei der Wortschatzarbeit unterstützen. - Die Materialien dieser Lerneinheit sollen Lateinstudierende bei der Wortschatzarbeit unterstützen. creator_name: - - Glockemann, Brunhild - - Glockemann, Brunhild + - "Glockemann, Brunhild" + - "Glockemann, Brunhild" language: - deu - deu title: - - Wortschatztraining zu Caesar, Bellum civile II, 43 bis 44 - - Wortschatztraining zu Caesar, Bellum civile II, 43 bis 44 + - "Wortschatztraining zu Caesar, Bellum civile II, 43 bis 44" + - "Wortschatztraining zu Caesar, Bellum civile II, 43 bis 44" version: - "2.0" - "2.0" @@ -1503,18 +1670,21 @@ components: description: Author of the text that serves as a basis or target for this record. example: Caesar + title: author type: string contributor: items: description: People that contributed something to the record. - example: Forst, Alexandra + example: "Forst, Alexandra" type: string + title: contributor type: array creator_name: items: description: People that created the record. - example: Glockemann, Brunhild + example: "Glockemann, Brunhild" type: string + title: creator_name type: array description: items: @@ -1522,44 +1692,52 @@ components: example: Die Materialien dieser Lerneinheit sollen Lateinstudierende bei der Wortschatzarbeit unterstützen. type: string + title: description type: array identifier: items: description: Identifier for easy access to the record. example: https://zenodo.org/record/4515301 type: string + title: identifier type: array language: items: description: Language of the materials in the record. example: deu type: string + title: language type: array subject: items: description: Tag that classifies the record. example: Latein type: string + title: subject type: array title: items: description: Title of the record. - example: Wortschatztraining zu Caesar, Bellum civile II, 43 bis 44 + example: "Wortschatztraining zu Caesar, Bellum civile II, 43 bis 44" type: string + title: title type: array version: items: description: Version of the record. example: "2.0" type: string + title: version type: array work: items: description: Name of the work that serves as a basis or target for this record. - example: Bellum civile II, 43-44 + example: "Bellum civile II, 43-44" type: string + title: work type: array + title: ZenodoRecord type: object ZenodoForm: description: Relevant parameters for accessing file URIs in a Zenodo record. @@ -1581,42 +1759,10 @@ components: example: callidus type: string ZenodoMetadataPrefix: - description: Prefix for requests to the Zenodo API, indicating the desired metadata - scheme. + description: "Prefix for requests to the Zenodo API, indicating the desired\ + \ metadata scheme." enum: - marc21 - oai_datacite example: oai_datacite type: string - ExerciseForm_allOf: - description: Additional exercise data. - properties: - type: - description: Type of exercise, concerning interaction and layout. - example: markWords - type: string - type_translation: - default: "" - description: Localized expression of the exercise type. - example: Cloze - type: string - urn: - description: CTS URN for the text passage from which the exercise was created. - example: urn:cts:latinLit:phi0448.phi001.perseus-lat2:1.1.1-1.1.1 - type: string - required: - - type - - urn - MatchingExercise_allOf: - description: Extra data for comparison with a reference vocabulary. - properties: - exercise_type_translation: - description: Localized expression of the exercise type. - example: Cloze - type: string - matching_degree: - description: Percentage of words in the exercise that match a reference - vocabulary. - example: 76.34 - format: float - type: number diff --git a/mc_backend/openapi/openapi_server/typing_utils.py b/mc_backend/openapi/openapi_server/typing_utils.py index 0563f81..74e3c91 100644 --- a/mc_backend/openapi/openapi_server/typing_utils.py +++ b/mc_backend/openapi/openapi_server/typing_utils.py @@ -1,5 +1,3 @@ -# coding: utf-8 - import sys if sys.version_info < (3, 7): diff --git a/mc_backend/openapi/openapi_server/util.py b/mc_backend/openapi/openapi_server/util.py index 8ce9198..1479b03 100644 --- a/mc_backend/openapi/openapi_server/util.py +++ b/mc_backend/openapi/openapi_server/util.py @@ -1,6 +1,5 @@ import datetime -import six import typing from openapi.openapi_server import typing_utils @@ -16,7 +15,7 @@ def _deserialize(data, klass): if data is None: return None - if klass in six.integer_types or klass in (float, str, bool, bytearray): + if klass in (int, float, str, bool, bytearray): return _deserialize_primitive(data, klass) elif klass == object: return _deserialize_object(data) @@ -45,7 +44,7 @@ def _deserialize_primitive(data, klass): try: value = klass(data) except UnicodeEncodeError: - value = six.u(data) + value = data except TypeError: value = data return value @@ -67,6 +66,9 @@ def deserialize_date(string): :return: date. :rtype: date """ + if string is None: + return None + try: from dateutil.parser import parse return parse(string).date() @@ -84,6 +86,9 @@ def deserialize_datetime(string): :return: datetime. :rtype: datetime """ + if string is None: + return None + try: from dateutil.parser import parse return parse(string) @@ -104,7 +109,7 @@ def deserialize_model(data, klass): if not instance.openapi_types: return data - for attr, attr_type in six.iteritems(instance.openapi_types): + for attr, attr_type in instance.openapi_types.items(): if data is not None \ and instance.attribute_map[attr] in data \ and isinstance(data, (list, dict)): @@ -139,4 +144,4 @@ def _deserialize_dict(data, boxed_type): :rtype: dict """ return {k: _deserialize(v, boxed_type) - for k, v in six.iteritems(data)} + for k, v in data.items() } diff --git a/mc_backend/openapi/requirements.txt b/mc_backend/openapi/requirements.txt index 72ed547..be4c8a3 100644 --- a/mc_backend/openapi/requirements.txt +++ b/mc_backend/openapi/requirements.txt @@ -8,3 +8,4 @@ werkzeug == 0.16.1; python_version=="3.5" or python_version=="3.4" swagger-ui-bundle >= 0.0.2 python_dateutil >= 2.6.0 setuptools >= 21.0.0 +Flask == 2.1.1 diff --git a/mc_backend/openapi/setup.py b/mc_backend/openapi/setup.py index acb8346..168902b 100644 --- a/mc_backend/openapi/setup.py +++ b/mc_backend/openapi/setup.py @@ -1,5 +1,3 @@ -# coding: utf-8 - import sys from setuptools import setup, find_packages diff --git a/mc_backend/openapi/test-requirements.txt b/mc_backend/openapi/test-requirements.txt index 0970f28..58f51d6 100644 --- a/mc_backend/openapi/test-requirements.txt +++ b/mc_backend/openapi/test-requirements.txt @@ -1,4 +1,4 @@ -pytest~=4.6.7 # needed for python 2.7+3.4 +pytest~=7.1.0 pytest-cov>=2.8.1 -pytest-randomly==1.2.3 # needed for python 2.7+3.4 -Flask-Testing==0.8.0 +pytest-randomly>=1.2.3 +Flask-Testing==0.8.1 diff --git a/mc_backend/openapi_models.yaml b/mc_backend/openapi_models.yaml index 8255ea8..b9ebeff 100644 --- a/mc_backend/openapi_models.yaml +++ b/mc_backend/openapi_models.yaml @@ -268,7 +268,7 @@ components: - urn ExerciseTypePath: type: string - enum: [dialog_cards, drag_text, fill_blanks, mark_words, multi_choice, voc_list] + enum: [dialog_cards, drag_text, fill_blanks, find_words, mark_words, multi_choice, voc_list] description: Paths to the data directories for various H5P exercise types. example: drag_text FileForm: @@ -785,9 +785,9 @@ components: - search_regex VocabularyMC: type: string - enum: [agldt, bws, proiel, viva] + enum: [agldt, bws, proiel, vischer, viva] description: "Reference vocabularies: Ancient Greek and Latin Dependency Treebank, Bamberger Wortschatz, - PROIEL treebank, VIVA textbook" + PROIEL treebank, Vischer Wortkunde, VIVA textbook" example: agldt VocabularyForm: x-body-name: vocabulary_data diff --git a/mc_backend/tests.py b/mc_backend/tests.py index b903d5f..af5c7ea 100644 --- a/mc_backend/tests.py +++ b/mc_backend/tests.py @@ -48,8 +48,13 @@ from mcserver.app.services import AnnotationService, CorpusService, FileService, from mcserver.config import TestingConfig, Config, DevelopmentConfig from mcserver.models_auto import Corpus, Exercise, UpdateInfo, LearningResult from mocks import Mocks, MockResponse, MockW2V, MockQuery, TestHelper -from openapi.openapi_server.models import VocabularyForm, VocabularyMC, ExerciseForm, \ - KwicForm, VectorNetworkForm, MatchingExercise, ExerciseTypePath, H5PForm, TextComplexity, ZenodoRecord, ZenodoForm +from openapi.openapi_server.models import VocabularyMC, MatchingExercise, ExerciseTypePath, TextComplexity, ZenodoRecord +from openapi.openapi_server.models.exercise_form import ExerciseForm +from openapi.openapi_server.models.h5_p_form import H5PForm +from openapi.openapi_server.models.kwic_form import KwicForm +from openapi.openapi_server.models.vector_network_form import VectorNetworkForm +from openapi.openapi_server.models.vocabulary_form import VocabularyForm +from openapi.openapi_server.models.zenodo_form import ZenodoForm class APItestCase(unittest.TestCase): diff --git a/mc_frontend/.gitignore b/mc_frontend/.gitignore index 15dc7a6..1c3c7ac 100644 --- a/mc_frontend/.gitignore +++ b/mc_frontend/.gitignore @@ -11,6 +11,7 @@ log.txt *.sublime-workspace .vscode/ npm-debug.log* +openapitools.json .idea/ .sourcemaps/ diff --git a/mc_frontend/openapi/.openapi-generator/FILES b/mc_frontend/openapi/.openapi-generator/FILES new file mode 100644 index 0000000..dbb26fd --- /dev/null +++ b/mc_frontend/openapi/.openapi-generator/FILES @@ -0,0 +1,35 @@ +.gitignore +README.md +api.module.ts +api/api.ts +api/default.service.ts +configuration.ts +encoder.ts +git_push.sh +index.ts +model/annisResponse.ts +model/corpus.ts +model/exerciseAuthor.ts +model/exerciseAuthorExtension.ts +model/exerciseBase.ts +model/exerciseExtension.ts +model/exerciseTypePath.ts +model/fileType.ts +model/frequencyItem.ts +model/graphData.ts +model/link.ts +model/matchingExercise.ts +model/models.ts +model/nodeMC.ts +model/phenomenon.ts +model/sentence.ts +model/solution.ts +model/solutionElement.ts +model/staticExercise.ts +model/textComplexity.ts +model/vocabularyMC.ts +model/zenodoMetadataPrefix.ts +model/zenodoMetadataPrefixExtension.ts +model/zenodoRecord.ts +param.ts +variables.ts diff --git a/mc_frontend/openapi/.openapi-generator/VERSION b/mc_frontend/openapi/.openapi-generator/VERSION index ecedc98..73a86b1 100644 --- a/mc_frontend/openapi/.openapi-generator/VERSION +++ b/mc_frontend/openapi/.openapi-generator/VERSION @@ -1 +1 @@ -4.3.1 \ No newline at end of file +7.0.1 \ No newline at end of file diff --git a/mc_frontend/openapi/README.md b/mc_frontend/openapi/README.md index e0c9192..de16f95 100644 --- a/mc_frontend/openapi/README.md +++ b/mc_frontend/openapi/README.md @@ -10,7 +10,7 @@ npm run build ### publishing -First build the package then run ```npm publish``` +First build the package then run ```npm publish dist``` (don't forget to specify the `dist` folder!) ### consuming @@ -25,14 +25,14 @@ npm install @ --save _without publishing (not recommended):_ ``` -npm install PATH_TO_GENERATED_PACKAGE/-.tgz --save +npm install PATH_TO_GENERATED_PACKAGE/dist.tgz --save ``` _It's important to take the tgz file, otherwise you'll get trouble with links on windows_ _using `npm link`:_ -In PATH_TO_GENERATED_PACKAGE: +In PATH_TO_GENERATED_PACKAGE/dist: ``` npm link ``` @@ -57,7 +57,6 @@ In your Angular project: import { ApiModule } from ''; import { HttpClientModule } from '@angular/common/http'; - @NgModule({ imports: [ ApiModule, @@ -76,7 +75,7 @@ export class AppModule {} // configuring providers import { ApiModule, Configuration, ConfigurationParameters } from ''; -export function apiConfigFactory (): Configuration => { +export function apiConfigFactory (): Configuration { const params: ConfigurationParameters = { // set configuration parameters here. } @@ -121,7 +120,7 @@ export class AppModule {} import { DefaultApi } from ''; export class AppComponent { - constructor(private apiGateway: DefaultApi) { } + constructor(private apiGateway: DefaultApi) { } } ``` @@ -137,7 +136,6 @@ import { ApiModule } from 'my-api-path'; import { ApiModule as OtherApiModule } from 'my-other-api-path'; import { HttpClientModule } from '@angular/common/http'; - @NgModule({ imports: [ ApiModule, @@ -154,7 +152,7 @@ export class AppModule { ### Set service base path -If different than the generated base path, during app bootstrap, you can provide the base path to your service. +If different than the generated base path, during app bootstrap, you can provide the base path to your service. ``` import { BASE_PATH } from ''; @@ -202,4 +200,27 @@ import { environment } from '../environments/environment'; bootstrap: [ AppComponent ] }) export class AppModule { } -``` +``` + +### Customizing path parameter encoding + +Without further customization, only [path-parameters][parameter-locations-url] of [style][style-values-url] 'simple' +and Dates for format 'date-time' are encoded correctly. + +Other styles (e.g. "matrix") are not that easy to encode +and thus are best delegated to other libraries (e.g.: [@honoluluhenk/http-param-expander]). + +To implement your own parameter encoding (or call another library), +pass an arrow-function or method-reference to the `encodeParam` property of the Configuration-object +(see [General Usage](#general-usage) above). + +Example value for use in your Configuration-Provider: +```typescript +new Configuration({ + encodeParam: (param: Param) => myFancyParamEncoder(param), +}) +``` + +[parameter-locations-url]: https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#parameter-locations +[style-values-url]: https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#style-values +[@honoluluhenk/http-param-expander]: https://www.npmjs.com/package/@honoluluhenk/http-param-expander diff --git a/mc_frontend/openapi/api.module.ts b/mc_frontend/openapi/api.module.ts index 6cdacac..58d341f 100644 --- a/mc_frontend/openapi/api.module.ts +++ b/mc_frontend/openapi/api.module.ts @@ -3,8 +3,6 @@ import { Configuration } from './configuration'; import { HttpClient } from '@angular/common/http'; -import { DefaultService } from './api/default.service'; - @NgModule({ imports: [], declarations: [], diff --git a/mc_frontend/openapi/api/default.service.ts b/mc_frontend/openapi/api/default.service.ts index b60722e..6319b7b 100644 --- a/mc_frontend/openapi/api/default.service.ts +++ b/mc_frontend/openapi/api/default.service.ts @@ -13,22 +13,35 @@ import { Inject, Injectable, Optional } from '@angular/core'; import { HttpClient, HttpHeaders, HttpParams, - HttpResponse, HttpEvent, HttpParameterCodec } from '@angular/common/http'; + HttpResponse, HttpEvent, HttpParameterCodec, HttpContext + } from '@angular/common/http'; import { CustomHttpParameterCodec } from '../encoder'; import { Observable } from 'rxjs'; -import { AnnisResponse } from '../model/models'; -import { Corpus } from '../model/models'; -import { ExerciseTypePath } from '../model/models'; -import { FileType } from '../model/models'; -import { FrequencyItem } from '../model/models'; -import { MatchingExercise } from '../model/models'; -import { Sentence } from '../model/models'; -import { StaticExercise } from '../model/models'; -import { TextComplexity } from '../model/models'; -import { VocabularyMC } from '../model/models'; -import { ZenodoRecord } from '../model/models'; - +// @ts-ignore +import { AnnisResponse } from '../model/annisResponse'; +// @ts-ignore +import { Corpus } from '../model/corpus'; +// @ts-ignore +import { ExerciseTypePath } from '../model/exerciseTypePath'; +// @ts-ignore +import { FileType } from '../model/fileType'; +// @ts-ignore +import { FrequencyItem } from '../model/frequencyItem'; +// @ts-ignore +import { MatchingExercise } from '../model/matchingExercise'; +// @ts-ignore +import { Sentence } from '../model/sentence'; +// @ts-ignore +import { StaticExercise } from '../model/staticExercise'; +// @ts-ignore +import { TextComplexity } from '../model/textComplexity'; +// @ts-ignore +import { VocabularyMC } from '../model/vocabularyMC'; +// @ts-ignore +import { ZenodoRecord } from '../model/zenodoRecord'; + +// @ts-ignore import { BASE_PATH, COLLECTION_FORMATS } from '../variables'; import { Configuration } from '../configuration'; @@ -44,11 +57,15 @@ export class DefaultService { public configuration = new Configuration(); public encoder: HttpParameterCodec; - constructor(protected httpClient: HttpClient, @Optional()@Inject(BASE_PATH) basePath: string, @Optional() configuration: Configuration) { + constructor(protected httpClient: HttpClient, @Optional()@Inject(BASE_PATH) basePath: string|string[], @Optional() configuration: Configuration) { if (configuration) { this.configuration = configuration; } if (typeof this.configuration.basePath !== 'string') { + if (Array.isArray(basePath) && basePath.length > 0) { + basePath = basePath[0]; + } + if (typeof basePath !== 'string') { basePath = this.basePath; } @@ -71,7 +88,7 @@ export class DefaultService { return false; } - + // @ts-ignore private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams { if (typeof value === "object" && value instanceof Date === false) { httpParams = this.addToHttpParamsRecursive(httpParams, value); @@ -91,8 +108,7 @@ export class DefaultService { (value as any[]).forEach( elem => httpParams = this.addToHttpParamsRecursive(httpParams, elem, key)); } else if (value instanceof Date) { if (key != null) { - httpParams = httpParams.append(key, - (value as Date).toISOString().substr(0, 10)); + httpParams = httpParams.append(key, (value as Date).toISOString().substring(0, 10)); } else { throw Error("key may not be null if value is Date"); } @@ -114,39 +130,52 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiCorpusAPIDelete(cid: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<boolean>; - public mcserverAppApiCorpusAPIDelete(cid: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<boolean>>; - public mcserverAppApiCorpusAPIDelete(cid: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<boolean>>; - public mcserverAppApiCorpusAPIDelete(cid: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiCorpusAPIDelete(cid: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<boolean>; + public mcserverAppApiCorpusAPIDelete(cid: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<boolean>>; + public mcserverAppApiCorpusAPIDelete(cid: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<boolean>>; + public mcserverAppApiCorpusAPIDelete(cid: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (cid === null || cid === undefined) { throw new Error('Required parameter cid was null or undefined when calling mcserverAppApiCorpusAPIDelete.'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.delete<boolean>(`${this.configuration.basePath}/corpora/${encodeURIComponent(String(cid))}`, + let localVarPath = `/corpora/${this.configuration.encodeParam({name: "cid", value: cid, in: "path", style: "simple", explode: false, dataType: "number", dataFormat: undefined})}`; + return this.httpClient.request<boolean>('delete', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -159,39 +188,52 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiCorpusAPIGet(cid: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Corpus>; - public mcserverAppApiCorpusAPIGet(cid: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Corpus>>; - public mcserverAppApiCorpusAPIGet(cid: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Corpus>>; - public mcserverAppApiCorpusAPIGet(cid: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiCorpusAPIGet(cid: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Corpus>; + public mcserverAppApiCorpusAPIGet(cid: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Corpus>>; + public mcserverAppApiCorpusAPIGet(cid: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Corpus>>; + public mcserverAppApiCorpusAPIGet(cid: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (cid === null || cid === undefined) { throw new Error('Required parameter cid was null or undefined when calling mcserverAppApiCorpusAPIGet.'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<Corpus>(`${this.configuration.basePath}/corpora/${encodeURIComponent(String(cid))}`, + let localVarPath = `/corpora/${this.configuration.encodeParam({name: "cid", value: cid, in: "path", style: "simple", explode: false, dataType: "number", dataFormat: undefined})}`; + return this.httpClient.request<Corpus>('get', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -207,55 +249,67 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Corpus>; - public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Corpus>>; - public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Corpus>>; - public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Corpus>; + public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Corpus>>; + public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Corpus>>; + public mcserverAppApiCorpusAPIPatch(cid: number, author?: string, sourceUrn?: string, title?: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (cid === null || cid === undefined) { throw new Error('Required parameter cid was null or undefined when calling mcserverAppApiCorpusAPIPatch.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (author !== undefined && author !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>author, 'author'); } if (sourceUrn !== undefined && sourceUrn !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>sourceUrn, 'source_urn'); } if (title !== undefined && title !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>title, 'title'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.patch<Corpus>(`${this.configuration.basePath}/corpora/${encodeURIComponent(String(cid))}`, - null, + let localVarPath = `/corpora/${this.configuration.encodeParam({name: "cid", value: cid, in: "path", style: "simple", explode: false, dataType: "number", dataFormat: undefined})}`; + return this.httpClient.request<Corpus>('patch', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -268,46 +322,59 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Corpus>; - public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Corpus>>; - public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Corpus>>; - public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Corpus>; + public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Corpus>>; + public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Corpus>>; + public mcserverAppApiCorpusListAPIGet(lastUpdateTime: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (lastUpdateTime === null || lastUpdateTime === undefined) { throw new Error('Required parameter lastUpdateTime was null or undefined when calling mcserverAppApiCorpusListAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (lastUpdateTime !== undefined && lastUpdateTime !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>lastUpdateTime, 'last_update_time'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<Corpus>(`${this.configuration.basePath}/corpora`, + let localVarPath = `/corpora`; + return this.httpClient.request<Corpus>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -320,46 +387,59 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiExerciseAPIGet(eid: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<AnnisResponse>; - public mcserverAppApiExerciseAPIGet(eid: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<AnnisResponse>>; - public mcserverAppApiExerciseAPIGet(eid: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<AnnisResponse>>; - public mcserverAppApiExerciseAPIGet(eid: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiExerciseAPIGet(eid: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<AnnisResponse>; + public mcserverAppApiExerciseAPIGet(eid: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<AnnisResponse>>; + public mcserverAppApiExerciseAPIGet(eid: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<AnnisResponse>>; + public mcserverAppApiExerciseAPIGet(eid: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (eid === null || eid === undefined) { throw new Error('Required parameter eid was null or undefined when calling mcserverAppApiExerciseAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (eid !== undefined && eid !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>eid, 'eid'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<AnnisResponse>(`${this.configuration.basePath}/exercise`, + let localVarPath = `/exercise`; + return this.httpClient.request<AnnisResponse>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -368,40 +448,126 @@ export class DefaultService { /** * Creates a new exercise. + * @param instructions Hints for how to complete the exercise. + * @param type Type of exercise, concerning interaction and layout. + * @param urn CTS URN for the text passage from which the exercise was created. + * @param correctFeedback Feedback for successful completion of the exercise. + * @param generalFeedback Feedback for finishing the exercise. + * @param incorrectFeedback Feedback for failing to complete the exercise successfully. + * @param language ISO 639-1 Language Code for the localization of exercise content. + * @param partiallyCorrectFeedback Feedback for successfully completing certain parts of the exercise. + * @param searchValues Search queries that were used to build the exercise. + * @param workAuthor Name of the person who wrote the base text for the exercise. + * @param workTitle Title of the base text for the exercise. + * @param typeTranslation Localized expression of the exercise type. * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiExerciseAPIPost(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<AnnisResponse>; - public mcserverAppApiExerciseAPIPost(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<AnnisResponse>>; - public mcserverAppApiExerciseAPIPost(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<AnnisResponse>>; - public mcserverAppApiExerciseAPIPost(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiExerciseAPIPost(instructions: string, type: string, urn: string, correctFeedback?: string, generalFeedback?: string, incorrectFeedback?: string, language?: string, partiallyCorrectFeedback?: string, searchValues?: string, workAuthor?: string, workTitle?: string, typeTranslation?: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<AnnisResponse>; + public mcserverAppApiExerciseAPIPost(instructions: string, type: string, urn: string, correctFeedback?: string, generalFeedback?: string, incorrectFeedback?: string, language?: string, partiallyCorrectFeedback?: string, searchValues?: string, workAuthor?: string, workTitle?: string, typeTranslation?: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<AnnisResponse>>; + public mcserverAppApiExerciseAPIPost(instructions: string, type: string, urn: string, correctFeedback?: string, generalFeedback?: string, incorrectFeedback?: string, language?: string, partiallyCorrectFeedback?: string, searchValues?: string, workAuthor?: string, workTitle?: string, typeTranslation?: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<AnnisResponse>>; + public mcserverAppApiExerciseAPIPost(instructions: string, type: string, urn: string, correctFeedback?: string, generalFeedback?: string, incorrectFeedback?: string, language?: string, partiallyCorrectFeedback?: string, searchValues?: string, workAuthor?: string, workTitle?: string, typeTranslation?: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { + if (instructions === null || instructions === undefined) { + throw new Error('Required parameter instructions was null or undefined when calling mcserverAppApiExerciseAPIPost.'); + } + if (type === null || type === undefined) { + throw new Error('Required parameter type was null or undefined when calling mcserverAppApiExerciseAPIPost.'); + } + if (urn === null || urn === undefined) { + throw new Error('Required parameter urn was null or undefined when calling mcserverAppApiExerciseAPIPost.'); + } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + // to determine the Content-Type header + const consumes: string[] = [ + 'application/x-www-form-urlencoded' + ]; + + const canConsumeForm = this.canConsumeForm(consumes); + + let localVarFormParams: { append(param: string, value: any): any; }; + let localVarUseForm = false; + let localVarConvertFormParamsToString = false; + if (localVarUseForm) { + localVarFormParams = new FormData(); + } else { + localVarFormParams = new HttpParams({encoder: this.encoder}); } - return this.httpClient.post<AnnisResponse>(`${this.configuration.basePath}/exercise`, - null, + if (correctFeedback !== undefined) { + localVarFormParams = localVarFormParams.append('correct_feedback', <any>correctFeedback) as any || localVarFormParams; + } + if (generalFeedback !== undefined) { + localVarFormParams = localVarFormParams.append('general_feedback', <any>generalFeedback) as any || localVarFormParams; + } + if (incorrectFeedback !== undefined) { + localVarFormParams = localVarFormParams.append('incorrect_feedback', <any>incorrectFeedback) as any || localVarFormParams; + } + if (instructions !== undefined) { + localVarFormParams = localVarFormParams.append('instructions', <any>instructions) as any || localVarFormParams; + } + if (language !== undefined) { + localVarFormParams = localVarFormParams.append('language', <any>language) as any || localVarFormParams; + } + if (partiallyCorrectFeedback !== undefined) { + localVarFormParams = localVarFormParams.append('partially_correct_feedback', <any>partiallyCorrectFeedback) as any || localVarFormParams; + } + if (searchValues !== undefined) { + localVarFormParams = localVarFormParams.append('search_values', <any>searchValues) as any || localVarFormParams; + } + if (workAuthor !== undefined) { + localVarFormParams = localVarFormParams.append('work_author', <any>workAuthor) as any || localVarFormParams; + } + if (workTitle !== undefined) { + localVarFormParams = localVarFormParams.append('work_title', <any>workTitle) as any || localVarFormParams; + } + if (type !== undefined) { + localVarFormParams = localVarFormParams.append('type', <any>type) as any || localVarFormParams; + } + if (typeTranslation !== undefined) { + localVarFormParams = localVarFormParams.append('type_translation', <any>typeTranslation) as any || localVarFormParams; + } + if (urn !== undefined) { + localVarFormParams = localVarFormParams.append('urn', <any>urn) as any || localVarFormParams; + } + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } + } + + let localVarPath = `/exercise`; + return this.httpClient.request<AnnisResponse>('post', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -417,58 +583,71 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<MatchingExercise>>; - public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<MatchingExercise>>>; - public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<MatchingExercise>>>; - public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Array<MatchingExercise>>; + public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Array<MatchingExercise>>>; + public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Array<MatchingExercise>>>; + public mcserverAppApiExerciseListAPIGet(lang: string, frequencyUpperBound?: number, lastUpdateTime?: number, vocabulary?: VocabularyMC, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (lang === null || lang === undefined) { throw new Error('Required parameter lang was null or undefined when calling mcserverAppApiExerciseListAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (lang !== undefined && lang !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>lang, 'lang'); } if (frequencyUpperBound !== undefined && frequencyUpperBound !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>frequencyUpperBound, 'frequency_upper_bound'); } if (lastUpdateTime !== undefined && lastUpdateTime !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>lastUpdateTime, 'last_update_time'); } if (vocabulary !== undefined && vocabulary !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>vocabulary, 'vocabulary'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<Array<MatchingExercise>>(`${this.configuration.basePath}/exerciseList`, + let localVarPath = `/exerciseList`; + return this.httpClient.request<Array<MatchingExercise>>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -483,10 +662,10 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml'}): Observable<object>; - public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml'}): Observable<HttpResponse<object>>; - public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml'}): Observable<HttpEvent<object>>; - public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml'}): Observable<any> { + public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml', context?: HttpContext}): Observable<object>; + public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml', context?: HttpContext}): Observable<HttpResponse<object>>; + public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml', context?: HttpContext}): Observable<HttpEvent<object>>; + public mcserverAppApiFileAPIGet(id: string, type: FileType, solutionIndices?: Array<number>, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/pdf' | 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' | 'application/xml', context?: HttpContext}): Observable<any> { if (id === null || id === undefined) { throw new Error('Required parameter id was null or undefined when calling mcserverAppApiFileAPIGet.'); } @@ -494,48 +673,61 @@ export class DefaultService { throw new Error('Required parameter type was null or undefined when calling mcserverAppApiFileAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (id !== undefined && id !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>id, 'id'); } if (type !== undefined && type !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>type, 'type'); } if (solutionIndices) { - queryParameters = this.addToHttpParams(queryParameters, - solutionIndices.join(COLLECTION_FORMATS['csv']), 'solution_indices'); + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, + [...solutionIndices].join(COLLECTION_FORMATS['csv']), 'solution_indices'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/pdf', 'application/vnd.openxmlformats-officedocument.wordprocessingml.document', 'application/xml' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<object>(`${this.configuration.basePath}/file`, + let localVarPath = `/file`; + return this.httpClient.request<object>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -551,23 +743,28 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<string>; - public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<string>>; - public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<string>>; - public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<string>; + public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<string>>; + public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<string>>; + public mcserverAppApiFileAPIPost(fileType?: FileType, htmlContent?: string, learningResult?: string, urn?: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } // to determine the Content-Type header @@ -577,39 +774,47 @@ export class DefaultService { const canConsumeForm = this.canConsumeForm(consumes); - let formParams: { append(param: string, value: any): any; }; - let useForm = false; - let convertFormParamsToString = false; - if (useForm) { - formParams = new FormData(); + let localVarFormParams: { append(param: string, value: any): any; }; + let localVarUseForm = false; + let localVarConvertFormParamsToString = false; + if (localVarUseForm) { + localVarFormParams = new FormData(); } else { - formParams = new HttpParams({encoder: this.encoder}); + localVarFormParams = new HttpParams({encoder: this.encoder}); } if (fileType !== undefined) { - formParams = formParams.append('file_type', <any>fileType) as any || formParams; + localVarFormParams = localVarFormParams.append('file_type', <any>fileType) as any || localVarFormParams; } if (htmlContent !== undefined) { - formParams = formParams.append('html_content', <any>htmlContent) as any || formParams; + localVarFormParams = localVarFormParams.append('html_content', <any>htmlContent) as any || localVarFormParams; } if (learningResult !== undefined) { - formParams = formParams.append('learning_result', <any>learningResult) as any || formParams; + localVarFormParams = localVarFormParams.append('learning_result', <any>learningResult) as any || localVarFormParams; } if (urn !== undefined) { - formParams = formParams.append('urn', <any>urn) as any || formParams; + localVarFormParams = localVarFormParams.append('urn', <any>urn) as any || localVarFormParams; } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.post<string>(`${this.configuration.basePath}/file`, - convertFormParamsToString ? formParams.toString() : formParams, + let localVarPath = `/file`; + return this.httpClient.request<string>('post', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -622,46 +827,59 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiFrequencyAPIGet(urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<FrequencyItem>>; - public mcserverAppApiFrequencyAPIGet(urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<FrequencyItem>>>; - public mcserverAppApiFrequencyAPIGet(urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<FrequencyItem>>>; - public mcserverAppApiFrequencyAPIGet(urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiFrequencyAPIGet(urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Array<FrequencyItem>>; + public mcserverAppApiFrequencyAPIGet(urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Array<FrequencyItem>>>; + public mcserverAppApiFrequencyAPIGet(urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Array<FrequencyItem>>>; + public mcserverAppApiFrequencyAPIGet(urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (urn === null || urn === undefined) { throw new Error('Required parameter urn was null or undefined when calling mcserverAppApiFrequencyAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (urn !== undefined && urn !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>urn, 'urn'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<Array<FrequencyItem>>(`${this.configuration.basePath}/frequency`, + let localVarPath = `/frequency`; + return this.httpClient.request<Array<FrequencyItem>>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -676,10 +894,10 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<object>; - public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<object>>; - public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<object>>; - public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<object>; + public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<object>>; + public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<object>>; + public mcserverAppApiH5pAPIGet(eid: string, lang: string, solutionIndices?: Array<number>, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (eid === null || eid === undefined) { throw new Error('Required parameter eid was null or undefined when calling mcserverAppApiH5pAPIGet.'); } @@ -687,46 +905,59 @@ export class DefaultService { throw new Error('Required parameter lang was null or undefined when calling mcserverAppApiH5pAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (eid !== undefined && eid !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>eid, 'eid'); } if (lang !== undefined && lang !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>lang, 'lang'); } if (solutionIndices) { - queryParameters = this.addToHttpParams(queryParameters, - solutionIndices.join(COLLECTION_FORMATS['csv']), 'solution_indices'); + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, + [...solutionIndices].join(COLLECTION_FORMATS['csv']), 'solution_indices'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<object>(`${this.configuration.basePath}/h5p`, + let localVarPath = `/h5p`; + return this.httpClient.request<object>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -742,23 +973,28 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/zip'}): Observable<object>; - public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/zip'}): Observable<HttpResponse<object>>; - public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/zip'}): Observable<HttpEvent<object>>; - public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/zip'}): Observable<any> { + public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/zip', context?: HttpContext}): Observable<object>; + public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/zip', context?: HttpContext}): Observable<HttpResponse<object>>; + public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/zip', context?: HttpContext}): Observable<HttpEvent<object>>; + public mcserverAppApiH5pAPIPost(eid?: string, exerciseTypePath?: ExerciseTypePath, lang?: string, solutionIndices?: Array<number>, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/zip', context?: HttpContext}): Observable<any> { - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/zip' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } // to determine the Content-Type header @@ -768,45 +1004,53 @@ export class DefaultService { const canConsumeForm = this.canConsumeForm(consumes); - let formParams: { append(param: string, value: any): any; }; - let useForm = false; - let convertFormParamsToString = false; - if (useForm) { - formParams = new FormData(); + let localVarFormParams: { append(param: string, value: any): any; }; + let localVarUseForm = false; + let localVarConvertFormParamsToString = false; + if (localVarUseForm) { + localVarFormParams = new FormData(); } else { - formParams = new HttpParams({encoder: this.encoder}); + localVarFormParams = new HttpParams({encoder: this.encoder}); } if (eid !== undefined) { - formParams = formParams.append('eid', <any>eid) as any || formParams; + localVarFormParams = localVarFormParams.append('eid', <any>eid) as any || localVarFormParams; } if (exerciseTypePath !== undefined) { - formParams = formParams.append('exercise_type_path', <any>exerciseTypePath) as any || formParams; + localVarFormParams = localVarFormParams.append('exercise_type_path', <any>exerciseTypePath) as any || localVarFormParams; } if (lang !== undefined) { - formParams = formParams.append('lang', <any>lang) as any || formParams; + localVarFormParams = localVarFormParams.append('lang', <any>lang) as any || localVarFormParams; } if (solutionIndices) { - if (useForm) { + if (localVarUseForm) { solutionIndices.forEach((element) => { - formParams = formParams.append('solution_indices', <any>element) as any || formParams; + localVarFormParams = localVarFormParams.append('solution_indices', <any>element) as any || localVarFormParams; }) } else { - formParams = formParams.append('solution_indices', solutionIndices.join(COLLECTION_FORMATS['csv'])) as any || formParams; + localVarFormParams = localVarFormParams.append('solution_indices', [...solutionIndices].join(COLLECTION_FORMATS['csv'])) as any || localVarFormParams; } } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.post<object>(`${this.configuration.basePath}/h5p`, - convertFormParamsToString ? formParams.toString() : formParams, + let localVarPath = `/h5p`; + return this.httpClient.request<object>('post', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -822,10 +1066,10 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<string>; - public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<string>>; - public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<string>>; - public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<string>; + public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<string>>; + public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<string>>; + public mcserverAppApiKwicAPIPost(searchValues: string, urn: string, ctxLeft: number, ctxRight: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (searchValues === null || searchValues === undefined) { throw new Error('Required parameter searchValues was null or undefined when calling mcserverAppApiKwicAPIPost.'); } @@ -839,18 +1083,23 @@ export class DefaultService { throw new Error('Required parameter ctxRight was null or undefined when calling mcserverAppApiKwicAPIPost.'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } // to determine the Content-Type header @@ -860,39 +1109,47 @@ export class DefaultService { const canConsumeForm = this.canConsumeForm(consumes); - let formParams: { append(param: string, value: any): any; }; - let useForm = false; - let convertFormParamsToString = false; - if (useForm) { - formParams = new FormData(); + let localVarFormParams: { append(param: string, value: any): any; }; + let localVarUseForm = false; + let localVarConvertFormParamsToString = false; + if (localVarUseForm) { + localVarFormParams = new FormData(); } else { - formParams = new HttpParams({encoder: this.encoder}); + localVarFormParams = new HttpParams({encoder: this.encoder}); } if (searchValues !== undefined) { - formParams = formParams.append('search_values', <any>searchValues) as any || formParams; + localVarFormParams = localVarFormParams.append('search_values', <any>searchValues) as any || localVarFormParams; } if (urn !== undefined) { - formParams = formParams.append('urn', <any>urn) as any || formParams; + localVarFormParams = localVarFormParams.append('urn', <any>urn) as any || localVarFormParams; } if (ctxLeft !== undefined) { - formParams = formParams.append('ctx_left', <any>ctxLeft) as any || formParams; + localVarFormParams = localVarFormParams.append('ctx_left', <any>ctxLeft) as any || localVarFormParams; } if (ctxRight !== undefined) { - formParams = formParams.append('ctx_right', <any>ctxRight) as any || formParams; + localVarFormParams = localVarFormParams.append('ctx_right', <any>ctxRight) as any || localVarFormParams; } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.post<string>(`${this.configuration.basePath}/kwic`, - convertFormParamsToString ? formParams.toString() : formParams, + let localVarPath = `/kwic`; + return this.httpClient.request<string>('post', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -905,46 +1162,59 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiRawTextAPIGet(urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<AnnisResponse>; - public mcserverAppApiRawTextAPIGet(urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<AnnisResponse>>; - public mcserverAppApiRawTextAPIGet(urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<AnnisResponse>>; - public mcserverAppApiRawTextAPIGet(urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiRawTextAPIGet(urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<AnnisResponse>; + public mcserverAppApiRawTextAPIGet(urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<AnnisResponse>>; + public mcserverAppApiRawTextAPIGet(urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<AnnisResponse>>; + public mcserverAppApiRawTextAPIGet(urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (urn === null || urn === undefined) { throw new Error('Required parameter urn was null or undefined when calling mcserverAppApiRawTextAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (urn !== undefined && urn !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>urn, 'urn'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<AnnisResponse>(`${this.configuration.basePath}/rawtext`, + let localVarPath = `/rawtext`; + return this.httpClient.request<AnnisResponse>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -956,36 +1226,49 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiStaticExercisesAPIGet(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<{ [key: string]: StaticExercise; }>; - public mcserverAppApiStaticExercisesAPIGet(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<{ [key: string]: StaticExercise; }>>; - public mcserverAppApiStaticExercisesAPIGet(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<{ [key: string]: StaticExercise; }>>; - public mcserverAppApiStaticExercisesAPIGet(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiStaticExercisesAPIGet(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<{ [key: string]: StaticExercise; }>; + public mcserverAppApiStaticExercisesAPIGet(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<{ [key: string]: StaticExercise; }>>; + public mcserverAppApiStaticExercisesAPIGet(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<{ [key: string]: StaticExercise; }>>; + public mcserverAppApiStaticExercisesAPIGet(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<{ [key: string]: StaticExercise; }>(`${this.configuration.basePath}/staticExercises`, + let localVarPath = `/staticExercises`; + return this.httpClient.request<{ [key: string]: StaticExercise; }>('get', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -999,10 +1282,10 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<TextComplexity>; - public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<TextComplexity>>; - public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<TextComplexity>>; - public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<TextComplexity>; + public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<TextComplexity>>; + public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<TextComplexity>>; + public mcserverAppApiTextcomplexityAPIGet(measure: string, urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (measure === null || measure === undefined) { throw new Error('Required parameter measure was null or undefined when calling mcserverAppApiTextcomplexityAPIGet.'); } @@ -1010,42 +1293,55 @@ export class DefaultService { throw new Error('Required parameter urn was null or undefined when calling mcserverAppApiTextcomplexityAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (measure !== undefined && measure !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>measure, 'measure'); } if (urn !== undefined && urn !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>urn, 'urn'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<TextComplexity>(`${this.configuration.basePath}/textcomplexity`, + let localVarPath = `/textcomplexity`; + return this.httpClient.request<TextComplexity>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -1058,46 +1354,59 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiValidReffAPIGet(urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<string>>; - public mcserverAppApiValidReffAPIGet(urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<string>>>; - public mcserverAppApiValidReffAPIGet(urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<string>>>; - public mcserverAppApiValidReffAPIGet(urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiValidReffAPIGet(urn: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Array<string>>; + public mcserverAppApiValidReffAPIGet(urn: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Array<string>>>; + public mcserverAppApiValidReffAPIGet(urn: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Array<string>>>; + public mcserverAppApiValidReffAPIGet(urn: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (urn === null || urn === undefined) { throw new Error('Required parameter urn was null or undefined when calling mcserverAppApiValidReffAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (urn !== undefined && urn !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>urn, 'urn'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<Array<string>>(`${this.configuration.basePath}/validReff`, + let localVarPath = `/validReff`; + return this.httpClient.request<Array<string>>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -1113,58 +1422,71 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<string>; - public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<string>>; - public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<string>>; - public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<string>; + public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<string>>; + public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<string>>; + public mcserverAppApiVectorNetworkAPIGet(searchRegex: string, highlightRegex?: string, minCount?: number, nearestNeighborCount?: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (searchRegex === null || searchRegex === undefined) { throw new Error('Required parameter searchRegex was null or undefined when calling mcserverAppApiVectorNetworkAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (searchRegex !== undefined && searchRegex !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>searchRegex, 'search_regex'); } if (highlightRegex !== undefined && highlightRegex !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>highlightRegex, 'highlight_regex'); } if (minCount !== undefined && minCount !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>minCount, 'min_count'); } if (nearestNeighborCount !== undefined && nearestNeighborCount !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>nearestNeighborCount, 'nearest_neighbor_count'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<string>(`${this.configuration.basePath}/vectorNetwork`, + let localVarPath = `/vectorNetwork`; + return this.httpClient.request<string>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -1178,26 +1500,31 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<Array<string>>>; - public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<Array<string>>>>; - public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<Array<string>>>>; - public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Array<Array<string>>>; + public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Array<Array<string>>>>; + public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Array<Array<string>>>>; + public mcserverAppApiVectorNetworkAPIPost(searchRegex: string, nearestNeighborCount?: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (searchRegex === null || searchRegex === undefined) { throw new Error('Required parameter searchRegex was null or undefined when calling mcserverAppApiVectorNetworkAPIPost.'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } // to determine the Content-Type header @@ -1207,33 +1534,41 @@ export class DefaultService { const canConsumeForm = this.canConsumeForm(consumes); - let formParams: { append(param: string, value: any): any; }; - let useForm = false; - let convertFormParamsToString = false; - if (useForm) { - formParams = new FormData(); + let localVarFormParams: { append(param: string, value: any): any; }; + let localVarUseForm = false; + let localVarConvertFormParamsToString = false; + if (localVarUseForm) { + localVarFormParams = new FormData(); } else { - formParams = new HttpParams({encoder: this.encoder}); + localVarFormParams = new HttpParams({encoder: this.encoder}); } if (searchRegex !== undefined) { - formParams = formParams.append('search_regex', <any>searchRegex) as any || formParams; + localVarFormParams = localVarFormParams.append('search_regex', <any>searchRegex) as any || localVarFormParams; } if (nearestNeighborCount !== undefined) { - formParams = formParams.append('nearest_neighbor_count', <any>nearestNeighborCount) as any || formParams; + localVarFormParams = localVarFormParams.append('nearest_neighbor_count', <any>nearestNeighborCount) as any || localVarFormParams; } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.post<Array<Array<string>>>(`${this.configuration.basePath}/vectorNetwork`, - convertFormParamsToString ? formParams.toString() : formParams, + let localVarPath = `/vectorNetwork`; + return this.httpClient.request<Array<Array<string>>>('post', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -1248,10 +1583,10 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<Sentence>>; - public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<Sentence>>>; - public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<Sentence>>>; - public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Array<Sentence>>; + public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Array<Sentence>>>; + public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Array<Sentence>>>; + public mcserverAppApiVocabularyAPIGet(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (frequencyUpperBound === null || frequencyUpperBound === undefined) { throw new Error('Required parameter frequencyUpperBound was null or undefined when calling mcserverAppApiVocabularyAPIGet.'); } @@ -1262,46 +1597,59 @@ export class DefaultService { throw new Error('Required parameter vocabulary was null or undefined when calling mcserverAppApiVocabularyAPIGet.'); } - let queryParameters = new HttpParams({encoder: this.encoder}); + let localVarQueryParameters = new HttpParams({encoder: this.encoder}); if (frequencyUpperBound !== undefined && frequencyUpperBound !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>frequencyUpperBound, 'frequency_upper_bound'); } if (queryUrn !== undefined && queryUrn !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>queryUrn, 'query_urn'); } if (vocabulary !== undefined && vocabulary !== null) { - queryParameters = this.addToHttpParams(queryParameters, + localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>vocabulary, 'vocabulary'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<Array<Sentence>>(`${this.configuration.basePath}/vocabulary`, + let localVarPath = `/vocabulary`; + return this.httpClient.request<Array<Sentence>>('get', `${this.configuration.basePath}${localVarPath}`, { - params: queryParameters, - responseType: <any>responseType, + context: localVarHttpContext, + params: localVarQueryParameters, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -1316,10 +1664,10 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<AnnisResponse>; - public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<AnnisResponse>>; - public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<AnnisResponse>>; - public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<AnnisResponse>; + public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<AnnisResponse>>; + public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<AnnisResponse>>; + public mcserverAppApiVocabularyAPIPost(frequencyUpperBound: number, queryUrn: string, vocabulary: VocabularyMC, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (frequencyUpperBound === null || frequencyUpperBound === undefined) { throw new Error('Required parameter frequencyUpperBound was null or undefined when calling mcserverAppApiVocabularyAPIPost.'); } @@ -1330,18 +1678,23 @@ export class DefaultService { throw new Error('Required parameter vocabulary was null or undefined when calling mcserverAppApiVocabularyAPIPost.'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + } + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } // to determine the Content-Type header @@ -1351,36 +1704,44 @@ export class DefaultService { const canConsumeForm = this.canConsumeForm(consumes); - let formParams: { append(param: string, value: any): any; }; - let useForm = false; - let convertFormParamsToString = false; - if (useForm) { - formParams = new FormData(); + let localVarFormParams: { append(param: string, value: any): any; }; + let localVarUseForm = false; + let localVarConvertFormParamsToString = false; + if (localVarUseForm) { + localVarFormParams = new FormData(); } else { - formParams = new HttpParams({encoder: this.encoder}); + localVarFormParams = new HttpParams({encoder: this.encoder}); } if (frequencyUpperBound !== undefined) { - formParams = formParams.append('frequency_upper_bound', <any>frequencyUpperBound) as any || formParams; + localVarFormParams = localVarFormParams.append('frequency_upper_bound', <any>frequencyUpperBound) as any || localVarFormParams; } if (queryUrn !== undefined) { - formParams = formParams.append('query_urn', <any>queryUrn) as any || formParams; + localVarFormParams = localVarFormParams.append('query_urn', <any>queryUrn) as any || localVarFormParams; } if (vocabulary !== undefined) { - formParams = formParams.append('vocabulary', <any>vocabulary) as any || formParams; + localVarFormParams = localVarFormParams.append('vocabulary', <any>vocabulary) as any || localVarFormParams; } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.post<AnnisResponse>(`${this.configuration.basePath}/vocabulary`, - convertFormParamsToString ? formParams.toString() : formParams, + let localVarPath = `/vocabulary`; + return this.httpClient.request<AnnisResponse>('post', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -1392,36 +1753,49 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiZenodoAPIGet(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<ZenodoRecord>>; - public mcserverAppApiZenodoAPIGet(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<ZenodoRecord>>>; - public mcserverAppApiZenodoAPIGet(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<ZenodoRecord>>>; - public mcserverAppApiZenodoAPIGet(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiZenodoAPIGet(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Array<ZenodoRecord>>; + public mcserverAppApiZenodoAPIGet(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Array<ZenodoRecord>>>; + public mcserverAppApiZenodoAPIGet(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Array<ZenodoRecord>>>; + public mcserverAppApiZenodoAPIGet(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); } + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); + } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.get<Array<ZenodoRecord>>(`${this.configuration.basePath}/zenodo`, + let localVarPath = `/zenodo`; + return this.httpClient.request<Array<ZenodoRecord>>('get', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } @@ -1434,26 +1808,31 @@ export class DefaultService { * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body. * @param reportProgress flag to report request and response progress. */ - public mcserverAppApiZenodoAPIPost(recordId: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<string>>; - public mcserverAppApiZenodoAPIPost(recordId: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<string>>>; - public mcserverAppApiZenodoAPIPost(recordId: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<string>>>; - public mcserverAppApiZenodoAPIPost(recordId: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> { + public mcserverAppApiZenodoAPIPost(recordId: number, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<Array<string>>; + public mcserverAppApiZenodoAPIPost(recordId: number, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpResponse<Array<string>>>; + public mcserverAppApiZenodoAPIPost(recordId: number, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<HttpEvent<Array<string>>>; + public mcserverAppApiZenodoAPIPost(recordId: number, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json', context?: HttpContext}): Observable<any> { if (recordId === null || recordId === undefined) { throw new Error('Required parameter recordId was null or undefined when calling mcserverAppApiZenodoAPIPost.'); } - let headers = this.defaultHeaders; + let localVarHeaders = this.defaultHeaders; - let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; - if (httpHeaderAcceptSelected === undefined) { + let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept; + if (localVarHttpHeaderAcceptSelected === undefined) { // to determine the Accept header const httpHeaderAccepts: string[] = [ 'application/json' ]; - httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); + localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts); } - if (httpHeaderAcceptSelected !== undefined) { - headers = headers.set('Accept', httpHeaderAcceptSelected); + if (localVarHttpHeaderAcceptSelected !== undefined) { + localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected); + } + + let localVarHttpContext: HttpContext | undefined = options && options.context; + if (localVarHttpContext === undefined) { + localVarHttpContext = new HttpContext(); } // to determine the Content-Type header @@ -1463,30 +1842,38 @@ export class DefaultService { const canConsumeForm = this.canConsumeForm(consumes); - let formParams: { append(param: string, value: any): any; }; - let useForm = false; - let convertFormParamsToString = false; - if (useForm) { - formParams = new FormData(); + let localVarFormParams: { append(param: string, value: any): any; }; + let localVarUseForm = false; + let localVarConvertFormParamsToString = false; + if (localVarUseForm) { + localVarFormParams = new FormData(); } else { - formParams = new HttpParams({encoder: this.encoder}); + localVarFormParams = new HttpParams({encoder: this.encoder}); } if (recordId !== undefined) { - formParams = formParams.append('record_id', <any>recordId) as any || formParams; + localVarFormParams = localVarFormParams.append('record_id', <any>recordId) as any || localVarFormParams; } - let responseType: 'text' | 'json' = 'json'; - if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) { - responseType = 'text'; + let responseType_: 'text' | 'json' | 'blob' = 'json'; + if (localVarHttpHeaderAcceptSelected) { + if (localVarHttpHeaderAcceptSelected.startsWith('text')) { + responseType_ = 'text'; + } else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) { + responseType_ = 'json'; + } else { + responseType_ = 'blob'; + } } - return this.httpClient.post<Array<string>>(`${this.configuration.basePath}/zenodo`, - convertFormParamsToString ? formParams.toString() : formParams, + let localVarPath = `/zenodo`; + return this.httpClient.request<Array<string>>('post', `${this.configuration.basePath}${localVarPath}`, { - responseType: <any>responseType, + context: localVarHttpContext, + body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams, + responseType: <any>responseType_, withCredentials: this.configuration.withCredentials, - headers: headers, + headers: localVarHeaders, observe: observe, reportProgress: reportProgress } diff --git a/mc_frontend/openapi/configuration.ts b/mc_frontend/openapi/configuration.ts index c038bbc..526b454 100644 --- a/mc_frontend/openapi/configuration.ts +++ b/mc_frontend/openapi/configuration.ts @@ -1,23 +1,70 @@ import { HttpParameterCodec } from '@angular/common/http'; +import { Param } from './param'; export interface ConfigurationParameters { + /** + * @deprecated Since 5.0. Use credentials instead + */ apiKeys?: {[ key: string ]: string}; username?: string; password?: string; + /** + * @deprecated Since 5.0. Use credentials instead + */ accessToken?: string | (() => string); basePath?: string; withCredentials?: boolean; + /** + * Takes care of encoding query- and form-parameters. + */ encoder?: HttpParameterCodec; + /** + * Override the default method for encoding path parameters in various + * <a href="https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#style-values">styles</a>. + * <p> + * See {@link README.md} for more details + * </p> + */ + encodeParam?: (param: Param) => string; + /** + * The keys are the names in the securitySchemes section of the OpenAPI + * document. They should map to the value used for authentication + * minus any standard prefixes such as 'Basic' or 'Bearer'. + */ + credentials?: {[ key: string ]: string | (() => string | undefined)}; } export class Configuration { + /** + * @deprecated Since 5.0. Use credentials instead + */ apiKeys?: {[ key: string ]: string}; username?: string; password?: string; + /** + * @deprecated Since 5.0. Use credentials instead + */ accessToken?: string | (() => string); basePath?: string; withCredentials?: boolean; + /** + * Takes care of encoding query- and form-parameters. + */ encoder?: HttpParameterCodec; + /** + * Encoding of various path parameter + * <a href="https://github.com/OAI/OpenAPI-Specification/blob/main/versions/3.1.0.md#style-values">styles</a>. + * <p> + * See {@link README.md} for more details + * </p> + */ + encodeParam: (param: Param) => string; + /** + * The keys are the names in the securitySchemes section of the OpenAPI + * document. They should map to the value used for authentication + * minus any standard prefixes such as 'Basic' or 'Bearer'. + */ + credentials: {[ key: string ]: string | (() => string | undefined)}; constructor(configurationParameters: ConfigurationParameters = {}) { this.apiKeys = configurationParameters.apiKeys; @@ -27,6 +74,18 @@ export class Configuration { this.basePath = configurationParameters.basePath; this.withCredentials = configurationParameters.withCredentials; this.encoder = configurationParameters.encoder; + if (configurationParameters.encodeParam) { + this.encodeParam = configurationParameters.encodeParam; + } + else { + this.encodeParam = param => this.defaultEncodeParam(param); + } + if (configurationParameters.credentials) { + this.credentials = configurationParameters.credentials; + } + else { + this.credentials = {}; + } } /** @@ -81,4 +140,27 @@ export class Configuration { const jsonMime: RegExp = new RegExp('^(application\/json|[^;/ \t]+\/[^;/ \t]+[+]json)[ \t]*(;.*)?$', 'i'); return mime !== null && (jsonMime.test(mime) || mime.toLowerCase() === 'application/json-patch+json'); } + + public lookupCredential(key: string): string | undefined { + const value = this.credentials[key]; + return typeof value === 'function' + ? value() + : value; + } + + private defaultEncodeParam(param: Param): string { + // This implementation exists as fallback for missing configuration + // and for backwards compatibility to older typescript-angular generator versions. + // It only works for the 'simple' parameter style. + // Date-handling only works for the 'date-time' format. + // All other styles and Date-formats are probably handled incorrectly. + // + // But: if that's all you need (i.e.: the most common use-case): no need for customization! + + const value = param.dataFormat === 'date-time' && param.value instanceof Date + ? (param.value as Date).toISOString() + : param.value; + + return encodeURIComponent(String(value)); + } } diff --git a/mc_frontend/openapi/encoder.ts b/mc_frontend/openapi/encoder.ts index cbefb4a..138c4d5 100644 --- a/mc_frontend/openapi/encoder.ts +++ b/mc_frontend/openapi/encoder.ts @@ -18,4 +18,3 @@ export class CustomHttpParameterCodec implements HttpParameterCodec { return decodeURIComponent(v); } } - diff --git a/mc_frontend/openapi/git_push.sh b/mc_frontend/openapi/git_push.sh index ced3be2..f53a75d 100644 --- a/mc_frontend/openapi/git_push.sh +++ b/mc_frontend/openapi/git_push.sh @@ -1,7 +1,7 @@ #!/bin/sh # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ # -# Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" "gitlab.com" +# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com" git_user_id=$1 git_repo_id=$2 @@ -38,14 +38,14 @@ git add . git commit -m "$release_note" # Sets the new remote -git_remote=`git remote` +git_remote=$(git remote) if [ "$git_remote" = "" ]; then # git remote not defined if [ "$GIT_TOKEN" = "" ]; then echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git else - git remote add origin https://${git_user_id}:${GIT_TOKEN}@${git_host}/${git_user_id}/${git_repo_id}.git + git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git fi fi @@ -55,4 +55,3 @@ git pull origin master # Pushes (Forces) the changes in the local repository up to the remote repository echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git" git push origin master 2>&1 | grep -v 'To https' - diff --git a/mc_frontend/openapi/index.ts b/mc_frontend/openapi/index.ts index c312b70..104dd3d 100644 --- a/mc_frontend/openapi/index.ts +++ b/mc_frontend/openapi/index.ts @@ -2,4 +2,5 @@ export * from './api/api'; export * from './model/models'; export * from './variables'; export * from './configuration'; -export * from './api.module'; \ No newline at end of file +export * from './api.module'; +export * from './param'; diff --git a/mc_frontend/openapi/model/exerciseTypePath.ts b/mc_frontend/openapi/model/exerciseTypePath.ts index 949337a..4e3eb13 100644 --- a/mc_frontend/openapi/model/exerciseTypePath.ts +++ b/mc_frontend/openapi/model/exerciseTypePath.ts @@ -3,7 +3,7 @@ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator) * * The version of the OpenAPI document: 1.0 - * + * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech @@ -14,7 +14,7 @@ /** * Paths to the data directories for various H5P exercise types. */ -export type ExerciseTypePath = 'dialog_cards' | 'drag_text' | 'fill_blanks' | 'mark_words' | 'multi_choice' | 'voc_list'; +export type ExerciseTypePath = 'dialog_cards' | 'drag_text' | 'fill_blanks' | 'find_words' | 'mark_words' | 'multi_choice' | 'voc_list'; export const ExerciseTypePath = { DialogCards: 'dialog_cards' as ExerciseTypePath, diff --git a/mc_frontend/openapi/model/matchingExercise.ts b/mc_frontend/openapi/model/matchingExercise.ts index 3d82616..c6885c3 100644 --- a/mc_frontend/openapi/model/matchingExercise.ts +++ b/mc_frontend/openapi/model/matchingExercise.ts @@ -9,9 +9,6 @@ * https://openapi-generator.tech * Do not edit the class manually. */ -import { MatchingExerciseAllOf } from './matchingExerciseAllOf'; -import { ExerciseExtension } from './exerciseExtension'; -import { ExerciseBase } from './exerciseBase'; export interface MatchingExercise { diff --git a/mc_frontend/openapi/model/models.ts b/mc_frontend/openapi/model/models.ts index e64d9aa..1e90858 100644 --- a/mc_frontend/openapi/model/models.ts +++ b/mc_frontend/openapi/model/models.ts @@ -4,18 +4,12 @@ export * from './exerciseAuthor'; export * from './exerciseAuthorExtension'; export * from './exerciseBase'; export * from './exerciseExtension'; -export * from './exerciseForm'; -export * from './exerciseFormAllOf'; export * from './exerciseTypePath'; -export * from './fileForm'; export * from './fileType'; export * from './frequencyItem'; export * from './graphData'; -export * from './h5PForm'; -export * from './kwicForm'; export * from './link'; export * from './matchingExercise'; -export * from './matchingExerciseAllOf'; export * from './nodeMC'; export * from './phenomenon'; export * from './sentence'; @@ -23,10 +17,7 @@ export * from './solution'; export * from './solutionElement'; export * from './staticExercise'; export * from './textComplexity'; -export * from './vectorNetworkForm'; -export * from './vocabularyForm'; export * from './vocabularyMC'; -export * from './zenodoForm'; export * from './zenodoMetadataPrefix'; export * from './zenodoMetadataPrefixExtension'; export * from './zenodoRecord'; diff --git a/mc_frontend/openapi/model/vocabularyMC.ts b/mc_frontend/openapi/model/vocabularyMC.ts index 529c75f..ffb1175 100644 --- a/mc_frontend/openapi/model/vocabularyMC.ts +++ b/mc_frontend/openapi/model/vocabularyMC.ts @@ -12,14 +12,15 @@ /** - * Reference vocabularies: Ancient Greek and Latin Dependency Treebank, Bamberger Wortschatz, PROIEL treebank, Vischer vocabulary, VIVA textbook + * Reference vocabularies: Ancient Greek and Latin Dependency Treebank, Bamberger Wortschatz, PROIEL treebank, Vischer Wortkunde, VIVA textbook */ -export type VocabularyMC = 'agldt' | 'bws' | 'proiel' | 'viva'; +export type VocabularyMC = 'agldt' | 'bws' | 'proiel' | 'vischer' | 'viva'; export const VocabularyMC = { Agldt: 'agldt' as VocabularyMC, Bws: 'bws' as VocabularyMC, Proiel: 'proiel' as VocabularyMC, + Vischer: 'vischer' as VocabularyMC, Viva: 'viva' as VocabularyMC }; diff --git a/mc_frontend/openapi/param.ts b/mc_frontend/openapi/param.ts new file mode 100644 index 0000000..78a2d20 --- /dev/null +++ b/mc_frontend/openapi/param.ts @@ -0,0 +1,69 @@ +/** + * Standard parameter styles defined by OpenAPI spec + */ +export type StandardParamStyle = + | 'matrix' + | 'label' + | 'form' + | 'simple' + | 'spaceDelimited' + | 'pipeDelimited' + | 'deepObject' + ; + +/** + * The OpenAPI standard {@link StandardParamStyle}s may be extended by custom styles by the user. + */ +export type ParamStyle = StandardParamStyle | string; + +/** + * Standard parameter locations defined by OpenAPI spec + */ +export type ParamLocation = 'query' | 'header' | 'path' | 'cookie'; + +/** + * Standard types as defined in <a href="https://swagger.io/specification/#data-types">OpenAPI Specification: Data Types</a> + */ +export type StandardDataType = + | "integer" + | "number" + | "boolean" + | "string" + | "object" + | "array" + ; + +/** + * Standard {@link DataType}s plus your own types/classes. + */ +export type DataType = StandardDataType | string; + +/** + * Standard formats as defined in <a href="https://swagger.io/specification/#data-types">OpenAPI Specification: Data Types</a> + */ +export type StandardDataFormat = + | "int32" + | "int64" + | "float" + | "double" + | "byte" + | "binary" + | "date" + | "date-time" + | "password" + ; + +export type DataFormat = StandardDataFormat | string; + +/** + * The parameter to encode. + */ +export interface Param { + name: string; + value: unknown; + in: ParamLocation; + style: ParamStyle, + explode: boolean; + dataType: DataType; + dataFormat: DataFormat | undefined; +} diff --git a/mc_frontend/src/app/doc-software/doc-software.page.ts b/mc_frontend/src/app/doc-software/doc-software.page.ts index e762bfd..0417867 100644 --- a/mc_frontend/src/app/doc-software/doc-software.page.ts +++ b/mc_frontend/src/app/doc-software/doc-software.page.ts @@ -1,4 +1,4 @@ -import {Component, OnInit} from '@angular/core'; +import {Component} from '@angular/core'; import {HelperService} from 'src/app/helper.service'; import {NavController} from '@ionic/angular'; import {HttpClient} from '@angular/common/http'; diff --git a/mc_frontend/src/app/doc-voc-unit/doc-voc-unit.page.ts b/mc_frontend/src/app/doc-voc-unit/doc-voc-unit.page.ts index 532e2b4..a407680 100644 --- a/mc_frontend/src/app/doc-voc-unit/doc-voc-unit.page.ts +++ b/mc_frontend/src/app/doc-voc-unit/doc-voc-unit.page.ts @@ -1,4 +1,4 @@ -import {Component, OnInit} from '@angular/core'; +import {Component} from '@angular/core'; import {HelperService} from 'src/app/helper.service'; import {NavController} from '@ionic/angular'; import {HttpClient} from '@angular/common/http'; diff --git a/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.spec.ts b/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.spec.ts index 592f36b..6e00b08 100644 --- a/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.spec.ts +++ b/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.spec.ts @@ -17,7 +17,8 @@ import {QueryMC} from '../models/queryMC'; import {PhenomenonMapContent} from '../models/phenomenonMap'; import Spy = jasmine.Spy; import MockMC from '../models/mockMC'; -import {ExerciseForm, Phenomenon} from '../../../openapi'; +import {Phenomenon} from '../../../openapi'; +import {ExerciseForm} from "../../../openapi/model/exerciseForm"; describe('ExerciseParametersPage', () => { let exerciseParametersPage: ExerciseParametersPage; diff --git a/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.ts b/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.ts index 86ea7bb..df90bae 100644 --- a/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.ts +++ b/mc_frontend/src/app/exercise-parameters/exercise-parameters.page.ts @@ -19,8 +19,9 @@ import {ApplicationState} from '../models/applicationState'; import {take} from 'rxjs/operators'; import {TextRange} from '../models/textRange'; import configMC from '../../configMC'; -import {AnnisResponse, ExerciseForm, FrequencyItem, Phenomenon} from '../../../openapi'; -import {KwicForm} from '../../../openapi'; +import {AnnisResponse, FrequencyItem, Phenomenon} from '../../../openapi'; +import {ExerciseForm} from "../../../openapi/model/exerciseForm"; +import {KwicForm} from "../../../openapi/model/kwicForm"; @Component({ selector: 'app-exercise-parameters', diff --git a/mc_frontend/src/app/exercise.service.ts b/mc_frontend/src/app/exercise.service.ts index 8183d58..4a944e1 100644 --- a/mc_frontend/src/app/exercise.service.ts +++ b/mc_frontend/src/app/exercise.service.ts @@ -5,7 +5,7 @@ import {HelperService} from './helper.service'; import {ExercisePart} from './models/exercisePart'; import {EventMC, ExerciseType, H5PexerciseType, MoodleExerciseType} from './models/enum'; import {HttpClient, HttpParams} from '@angular/common/http'; -import {AnnisResponse, ExerciseTypePath, H5PForm, Solution, SolutionElement} from '../../openapi'; +import {AnnisResponse, ExerciseTypePath, Solution, SolutionElement} from '../../openapi'; import {take} from 'rxjs/operators'; import {ApplicationState} from './models/applicationState'; import {ToastController} from '@ionic/angular'; @@ -18,6 +18,7 @@ import {ActivatedRoute} from '@angular/router'; import {XAPIevent} from './models/xAPIevent'; import {TestResultMC} from './models/testResultMC'; import * as JSZip from 'jszip'; +import {H5PForm} from "../../openapi/model/h5PForm"; declare var H5PStandalone: any; diff --git a/mc_frontend/src/app/imprint/imprint.page.ts b/mc_frontend/src/app/imprint/imprint.page.ts index ca0de2e..d3ccf8f 100644 --- a/mc_frontend/src/app/imprint/imprint.page.ts +++ b/mc_frontend/src/app/imprint/imprint.page.ts @@ -1,4 +1,4 @@ -import {Component, OnInit} from '@angular/core'; +import {Component} from '@angular/core'; import {HelperService} from 'src/app/helper.service'; import {NavController} from '@ionic/angular'; import {HttpClient} from '@angular/common/http'; diff --git a/mc_frontend/src/app/models/enum.ts b/mc_frontend/src/app/models/enum.ts index 273cd23..44dffff 100644 --- a/mc_frontend/src/app/models/enum.ts +++ b/mc_frontend/src/app/models/enum.ts @@ -209,5 +209,6 @@ export enum VocabularyCorpusTranslation { agldt = 'VOCABULARY_REFERENCE_CORPUS_AGLDT' as any, bws = 'VOCABULARY_REFERENCE_CORPUS_BWS' as any, proiel = 'VOCABULARY_REFERENCE_CORPUS_PROIEL' as any, + vischer = 'VOCABULARY_REFERENCE_CORPUS_VISCHER' as any, viva = 'VOCABULARY_REFERENCE_CORPUS_VIVA' as any, } diff --git a/mc_frontend/src/app/semantics/semantics.page.ts b/mc_frontend/src/app/semantics/semantics.page.ts index 7e9bed6..98f13e3 100644 --- a/mc_frontend/src/app/semantics/semantics.page.ts +++ b/mc_frontend/src/app/semantics/semantics.page.ts @@ -5,7 +5,7 @@ import configMC from '../../configMC'; import {HttpClient, HttpErrorResponse, HttpParams} from '@angular/common/http'; import {ActivatedRoute} from '@angular/router'; import {CorpusService} from '../corpus.service'; -import {VectorNetworkForm} from '../../../openapi'; +import {VectorNetworkForm} from "../../../openapi/model/vectorNetworkForm"; @Component({ selector: 'app-semantics', diff --git a/mc_frontend/src/app/sequences/sequences.page.ts b/mc_frontend/src/app/sequences/sequences.page.ts index c777b56..e283b72 100644 --- a/mc_frontend/src/app/sequences/sequences.page.ts +++ b/mc_frontend/src/app/sequences/sequences.page.ts @@ -2,13 +2,13 @@ import {Component, OnInit} from '@angular/core'; import {HelperService} from '../helper.service'; import {NavController, ToastController} from '@ionic/angular'; import configMC from '../../configMC'; -import {ExerciseTypePath, H5PForm, ZenodoForm, ZenodoRecord} from '../../../openapi'; +import {ExerciseTypePath, ZenodoRecord} from '../../../openapi'; import {ExerciseService} from '../exercise.service'; import {HttpClient} from '@angular/common/http'; import {ZenodoRecordMC} from '../models/zenodoRecordMC'; -import * as JSZip from 'jszip'; import {ExerciseParams} from '../models/exerciseParams'; import {TranslateService} from '@ngx-translate/core'; +import {ZenodoForm} from "../../../openapi/model/zenodoForm"; @Component({ selector: 'app-sequences', diff --git a/mc_frontend/src/app/show-text/show-text.page.ts b/mc_frontend/src/app/show-text/show-text.page.ts index a486c18..12f4da3 100644 --- a/mc_frontend/src/app/show-text/show-text.page.ts +++ b/mc_frontend/src/app/show-text/show-text.page.ts @@ -11,7 +11,7 @@ import {CorpusMC} from '../models/corpusMC'; import {take} from 'rxjs/operators'; import configMC from '../../configMC'; import {FileType, VocabularyMC} from 'openapi'; -import {FileForm} from '../../../openapi'; +import {FileForm} from "../../../openapi/model/fileForm"; @Component({ selector: 'app-show-text', diff --git a/mc_frontend/src/app/vocabulary-check/vocabulary-check.page.spec.ts b/mc_frontend/src/app/vocabulary-check/vocabulary-check.page.spec.ts index 4443d8a..a425d0e 100644 --- a/mc_frontend/src/app/vocabulary-check/vocabulary-check.page.spec.ts +++ b/mc_frontend/src/app/vocabulary-check/vocabulary-check.page.spec.ts @@ -8,9 +8,7 @@ import {RouterModule} from '@angular/router'; import {TranslateTestingModule} from '../translate-testing/translate-testing.module'; import {FormsModule} from '@angular/forms'; import {APP_BASE_HREF} from '@angular/common'; -import MockMC from '../models/mockMC'; import Spy = jasmine.Spy; -import {Sentence} from '../../../openapi'; describe('VocabularyCheckPage', () => { let vocabularyCheckPage: VocabularyCheckPage; diff --git a/mc_frontend/src/app/vocabulary.service.spec.ts b/mc_frontend/src/app/vocabulary.service.spec.ts index 231929d..0dc39ae 100644 --- a/mc_frontend/src/app/vocabulary.service.spec.ts +++ b/mc_frontend/src/app/vocabulary.service.spec.ts @@ -5,9 +5,10 @@ import {HttpClientTestingModule} from '@angular/common/http/testing'; import {IonicStorageModule} from '@ionic/storage'; import {TranslateTestingModule} from './translate-testing/translate-testing.module'; import {HttpErrorResponse, HttpParams} from '@angular/common/http'; -import {AnnisResponse, Sentence, VocabularyForm, VocabularyMC} from '../../openapi'; +import {AnnisResponse, Sentence, VocabularyMC} from '../../openapi'; import Spy = jasmine.Spy; import MockMC from './models/mockMC'; +import {VocabularyForm} from "../../openapi/model/vocabularyForm"; describe('VocabularyService', () => { let vocabularyService: VocabularyService; @@ -81,7 +82,7 @@ describe('VocabularyService', () => { it('should be initialized', () => { vocabularyService.ngOnInit(); - expect(Object.keys(vocabularyService.refVocMap).length).toBe(4); + expect(Object.keys(vocabularyService.refVocMap).length).toBe(5); expect(vocabularyService.getCurrentReferenceVocabulary().totalCount).toBe(1276); expect(vocabularyService.getPossibleSubCount()).toBe(500); }); diff --git a/mc_frontend/src/app/vocabulary.service.ts b/mc_frontend/src/app/vocabulary.service.ts index 587951f..aaf0f71 100644 --- a/mc_frontend/src/app/vocabulary.service.ts +++ b/mc_frontend/src/app/vocabulary.service.ts @@ -6,12 +6,13 @@ import {HelperService} from 'src/app/helper.service'; import {TestResultMC} from 'src/app/models/testResultMC'; import {NavController, ToastController} from '@ionic/angular'; import configMC from '../configMC'; -import {AnnisResponse, Sentence, VocabularyForm} from '../../openapi'; +import {AnnisResponse, Sentence} from '../../openapi'; import {VocabularyMC} from '../../openapi'; import {take} from 'rxjs/operators'; import {CorpusMC} from './models/corpusMC'; import {TextRange} from './models/textRange'; import {CorpusService} from './corpus.service'; +import {VocabularyForm} from "../../openapi/model/vocabularyForm"; @Injectable({ providedIn: 'root' @@ -130,6 +131,11 @@ export class VocabularyService implements OnInit { totalCount: 16402, possibleSubcounts: [] }); + this.refVocMap[VocabularyMC.Vischer] = new Vocabulary({ + hasFrequencyOrder: false, + totalCount: 5885, + possibleSubcounts: [5885] + }); this.refVocMap[VocabularyMC.Viva] = new Vocabulary({ hasFrequencyOrder: false, totalCount: 1164, diff --git a/mc_frontend/src/assets/i18n/de.json b/mc_frontend/src/assets/i18n/de.json index d9ed357..9b82caf 100644 --- a/mc_frontend/src/assets/i18n/de.json +++ b/mc_frontend/src/assets/i18n/de.json @@ -418,6 +418,7 @@ "VOCABULARY_REFERENCE_CORPUS_AGLDT": "Ancient Greek and Latin Dependency Treebank", "VOCABULARY_REFERENCE_CORPUS_BWS": "Bamberger Wortschatz", "VOCABULARY_REFERENCE_CORPUS_PROIEL": "PROIEL Treebank", + "VOCABULARY_REFERENCE_CORPUS_VISCHER": "Vischer Wortkunde", "VOCABULARY_REFERENCE_CORPUS_VIVA": "VIVA 1 + 2 Wortschatz", "VOCABULARY_REFERENCE_RANGE_END": " Wörter aus dem Referenzvokabular verwenden", "VOCABULARY_REFERENCE_RANGE_START": "Nur die häufigsten ", diff --git a/mc_frontend/src/assets/i18n/en.json b/mc_frontend/src/assets/i18n/en.json index 8677621..f81f693 100644 --- a/mc_frontend/src/assets/i18n/en.json +++ b/mc_frontend/src/assets/i18n/en.json @@ -418,6 +418,7 @@ "VOCABULARY_REFERENCE_CORPUS_AGLDT": "Ancient Greek and Latin Dependency Treebank", "VOCABULARY_REFERENCE_CORPUS_BWS": "Bamberg Core Vocabulary", "VOCABULARY_REFERENCE_CORPUS_PROIEL": "PROIEL Treebank", + "VOCABULARY_REFERENCE_CORPUS_VISCHER": "Vischer's Vocabulary", "VOCABULARY_REFERENCE_CORPUS_VIVA": "VIVA textbook 1 + 2 Vocabulary", "VOCABULARY_REFERENCE_RANGE_END": " most frequent words in the reference vocabulary", "VOCABULARY_REFERENCE_RANGE_START": "Take only the ", -- GitLab