RCP: x.x, add concordance context cut
See #943
Currently “text” is the only structure used to cut concordance contexts.
- We must be able to cut several structures (for example “text” or “plu” & “deplu” or “p”)
- The import parameters defines which structures to cut in the
concordance
- Step 1: add “context_limit” parameter to “import.xml” file.
- default text value is “text”
- default
type value is "list" *** can contain multiple values (ex: "text,plu,deplu") *** if
type=“list”, the context limit query will be []|[]|…|[] - if @type=“query”, text value must be a CQL query
- document how to patch “import.xml” for this parameter
- test with Apocalypse corpus
- Step 2: replace patch by complete import parameter interface
- build an import UI for this parameter with a new section “Commands/Commandes” and the “Concordance context structure limits/Structures de limite de contextes de concordance”
- save the field in “import.xml”
- Step 1: add “context_limit” parameter to “import.xml” file.
Add in admin documentation the new import parameter element : uis/ui@command=concordance/context_limit, @type attribute and text value
Validation test - Step 1
* Call concordance on DISCOURS corpus with query "
[]"
* exit TXM
* add the new import configuration in the DISCOURS corpus “import.xml” file (in ~/TXM/corpora/discours)
...
<uis>
<ui command="concordance">
<context_limits type="list">text,p</context_limits>
</ui>
</uis>
...
* re-start TXM
* Call concordance on DISCOURS corpus with query "
[]", ensure left contexts are empty
Validation test - Step 2 (using UI)
* Call concordance on DISCOURS corpus with query "
[]"
* open the import parameters
* select the DISCOURS corpus source folders
* in the “Commands preferences” section, set the “concordance context structure limits to ”p" (list of structure separated by comma)
* start the import
* Call concordance on DISCOURS corpus with query "
[]", ensure left contexts are empty
(from redmine: issue id 1124, created on 2014/11/14 by Alexey Lavrentev)
- Relations:
- relates #1093 (closed)