Package reportgen.ren.report.extendedformat.range

Examples of reportgen.ren.report.extendedformat.range.ColRowRange


    }

    public static List<RangeProcessor> getProcessors(ColRowRangeList lst, RangeProcessor parentthrows ReportException {
        List<RangeProcessor> rows = new LinkedList<RangeProcessor>();
        for(int i=0; i<lst.size(); i++) {
            ColRowRange range = lst.get(i);
            rows.add(getProcessor(range, parent, i));
        }

        Collections.sort(rows, new Comparator<RangeProcessor>() {
            @Override
View Full Code Here


                parent, "Название ", "Вставка нового элемента", JOptionPane.QUESTION_MESSAGE);
        if(newName == null) {
            return;
        }

        ColRowRange range = null;
        if(type == GENERIC) {
            range = new ColRowRangeGeneric(newName, list.getContext());
        } else if(type == GROUP) {
            range = new ColRowRangeGroup(newName, list.getContext());
        } else if(type == CROSS) {
View Full Code Here

    }// </editor-fold>//GEN-END:initComponents

    private void addBtnActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_addBtnActionPerformed
        List<ColRowRange> opts = new LinkedList<ColRowRange>();
        for(int i=0;i<available.size(); i++) {
            ColRowRange iRange = available.get(i);
            if(iRange == range
                    || lst.contains(iRange)) {
                continue;
            }
            opts.add(iRange);
        }
        Iterator<ColRowRange> it = opts.iterator();
        while(it.hasNext()) {
            if(isLinked(it.next(), range)) {
                it.remove();
            }
        }
        if(opts.size() == 0) {
            Message.warning(this, "Нет доступных диапазонов");
            return;
        }
        ColRowRange sel = (ColRowRange) JOptionPane.showInputDialog(this, "Выберите диапазон",
            "Вставка связанного диапазона", JOptionPane.QUESTION_MESSAGE, null, opts.toArray(), null);
        if(sel != null) {
            lst.add(sel);
            updatePanel();
        }
View Full Code Here

    protected boolean checkExternalLinks(Set<RangeProcessor> fit) {
        Set<ColRowRange> set = range.getExcluded();
        if(set.size() != 0) {
            for(RangeProcessor f: fit) {
                ColRowRange iRange = f.getRange();
                if(set.contains(iRange)) {
                    System.out.println("This range (" + range.getTitle() + ") "
                            + "failed becase of " + iRange.getTitle());
                    return false;
                }
            }
        }

        set = range.getIncluded();
        if(set.size() != 0) {
            for(RangeProcessor f: fit) {
                ColRowRange iRange = f.getRange();
                if(set.contains(iRange)) {
                    return true;
                }
            }
            return false;
View Full Code Here

    }

    @Override
    protected void onRemove(CellValue cell) throws ReportException {
        super.onRemove(cell);
        ColRowRange col = cell.getColReference();
        ColRowRange row = cell.getRowReference();
        Key key = new Key(col, row);
        map.remove(key);

    }
View Full Code Here

    protected void onAdd(CellValue cell) {
        super.onAdd(cell);
        if(map == null) {
            map = new HashMap<Key, CellValue>();
        }
        ColRowRange col = cell.getColReference();
        ColRowRange row = cell.getRowReference();
        map.put(new Key(col, row), cell);
    }
View Full Code Here

TOP

Related Classes of reportgen.ren.report.extendedformat.range.ColRowRange

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.