Revision 2039

tmp/org.txm.cooccurrence.core/src/org/txm/cooccurrence/core/functions/Cooccurrence.java (revision 2039)
1491 1491
		
1492 1492
		String maxempanstr = "within " + maxempan + " "; //$NON-NLS-1$ //$NON-NLS-2$
1493 1493
		if (this.getStructuralUnitLimit() != null) maxempanstr += this.getStructuralUnitLimit().getName(); 
1494
		
1495
		
1496
		String pquery = CQLQuery.fixQuery(this.getQuery().getQueryString());
1494 1497
		if (this.getMaxLeft() == 0) {
1495
			query = ""+this.getQuery()+" []* "+query+" "+maxempanstr; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
1498
			query = ""+pquery+" []* "+query+" "+maxempanstr; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
1496 1499
		} else if (this.getMaxRight() == 0) {
1497
			query = ""+query+" []* "+this.getQuery()+" "+maxempanstr; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
1500
			query = ""+query+" []* "+pquery+" "+maxempanstr; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
1498 1501
		} else {
1499
			query = "("+this.getQuery()+" []* "+query+") | ("+query+" []* "+this.getQuery()+") "+maxempanstr; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
1502
			query = "("+pquery+" []* "+query+") | ("+query+" []* "+pquery+") "+maxempanstr; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$ //$NON-NLS-5$
1500 1503
		}
1501 1504
		
1502 1505
		return query;

Also available in: Unified diff