Package com.google.refine.model

Examples of com.google.refine.model.Row.dup()


                Map<String, Recon> reconMap = new HashMap<String, Recon>();
               
                for (int r = 0; r < _oldRows.size(); r++) {
                    Row oldRow = _oldRows.get(r);
                    if (r < rowIndex) {
                        _newRows.add(oldRow.dup());
                        continue;
                    }
                   
                    if (dataExtension == null || dataExtension.data.length == 0) {
                        _newRows.add(oldRow);
View Full Code Here


        int oldRowCount = project.rows.size();
        for (int r = 0; r < oldRowCount; r++) {
            Row oldRow = project.rows.get(r);
           
            if (oldRow.isCellBlank(keyCellIndex)) {
                newRows.add(oldRow.dup());
                continue;
            }
           
            int r2 = r + 1;
            while (r2 < oldRowCount && project.rows.get(r2).isCellBlank(keyCellIndex)) {
View Full Code Here

            while (r2 < oldRowCount && project.rows.get(r2).isCellBlank(keyCellIndex)) {
                r2++;
            }
           
            if (r2 == r + 1) {
                newRows.add(oldRow.dup());
                continue;
            }
           
            StringBuffer sb = new StringBuffer();
            for (int r3 = r; r3 < r2; r3++) {
View Full Code Here

       
        int oldRowCount = project.rows.size();
        for (int r = 0; r < oldRowCount; r++) {
            Row oldRow = project.rows.get(r);
            if (oldRow.isCellBlank(cellIndex)) {
                newRows.add(oldRow.dup());
                continue;
            }
           
            Object value = oldRow.getCellValue(cellIndex);
            String s = value instanceof String ? ((String) value) : value.toString();
View Full Code Here

            } else {
                values = StringUtils.splitByWholeSeparatorPreserveAllTokens(s, _separator);
            }
           
            if (values.length < 2) {
                newRows.add(oldRow.dup());
                continue;
            }
           
            // First value goes into the same row
            {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.