Grammalecte  Diff

Differences From Artifact [d4be1a8610]:

To Artifact [57cce4f9d0]:


356
357
358
359
360
361
362
363
364
365
366
367

368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391

392
393
394
395
396
397
398

    getListOfTokensReduc (sText, bInfo = true) {
        let aTokenList = this.getListOfTokens(sText.replace("'", "’").trim(), false);
        let iKey = 0;
        let aElem = [];
        do {
            let oToken = aTokenList[iKey];
            let bLocFound = false;
            let iKeyTree = iKey + 1;
            let sTokenTmpKey = '';
            let aTokenTempList = [oToken];
            if (oToken.sType == "WORD" || oToken.sType == "ELPFX"){

                let oLocNode = this.oLocGraph[this._unifyStr(oToken.sValue)];
                while (typeof(oLocNode) !== "undefined") {
                    let oTokenNext = aTokenList[iKeyTree];
                    iKeyTree++;

                    if (typeof(oTokenNext) !== "undefined") {
                        oLocNode = oLocNode[this._unifyStr(oTokenNext.sValue)];
                    } else {
                        oLocNode = "undefined";
                    }

                    if (typeof(oLocNode) !== "undefined" && iKeyTree <= aTokenList.length) {
                        sTokenTmpKey = Object.keys(oLocNode)[0];
                        aTokenTempList.push(oTokenNext);
                    } else {
                        if (sTokenTmpKey.substring(0, 1) == ':') {
                            bLocFound = true;
                        }
                        break;
                    }
                };
            }

            if (bLocFound) {

                let sWord = '';
                for (let oTokenWord of aTokenTempList) {
                    sWord += oTokenWord.sValue+' ';
                }
                iKey = iKey + aTokenTempList.length-1;
                let oTokenLocution = {
                    'nEnd': aTokenTempList[aTokenTempList.length-1].nEnd,







<
<



>

|


<
|

<
<

<
|



<
<
<


<
|
|
|
>







356
357
358
359
360
361
362


363
364
365
366
367
368
369
370

371
372


373

374
375
376
377



378
379

380
381
382
383
384
385
386
387
388
389
390

    getListOfTokensReduc (sText, bInfo = true) {
        let aTokenList = this.getListOfTokens(sText.replace("'", "’").trim(), false);
        let iKey = 0;
        let aElem = [];
        do {
            let oToken = aTokenList[iKey];


            let sTokenTmpKey = '';
            let aTokenTempList = [oToken];
            if (oToken.sType == "WORD" || oToken.sType == "ELPFX"){
                let iKeyTree = iKey + 1;
                let oLocNode = this.oLocGraph[this._unifyStr(oToken.sValue)];
                while (oLocNode) {
                    let oTokenNext = aTokenList[iKeyTree];
                    iKeyTree++;

                    if (oTokenNext) {
                        oLocNode = oLocNode[this._unifyStr(oTokenNext.sValue)];


                    }

                    if (oLocNode && iKeyTree <= aTokenList.length) {
                        sTokenTmpKey = Object.keys(oLocNode)[0];
                        aTokenTempList.push(oTokenNext);
                    } else {



                        break;
                    }

                }
            }

            if (sTokenTmpKey.substring(0, 1) == ':') {
                let sWord = '';
                for (let oTokenWord of aTokenTempList) {
                    sWord += oTokenWord.sValue+' ';
                }
                iKey = iKey + aTokenTempList.length-1;
                let oTokenLocution = {
                    'nEnd': aTokenTempList[aTokenTempList.length-1].nEnd,