public CellRangeAddress[] getCellRanges() { return field_4_cell_ranges.getCellRangeAddresses(); }
public String prettyPrint() { StringBuilder builder = new StringBuilder(); for(CellRangeAddress address : regions.getCellRangeAddresses()) { builder.append(address.formatAsString()); } builder.append(" => "); builder.append(this.validationConstraint.prettyPrint()); return builder.toString(); }
/** * Finds and returns the {@link DataValidationContext} for the cell, if there is * one. Lookup is based on the first match from * {@link DataValidation#getRegions()} for the cell's sheet. DataValidation * regions must be in the same sheet as the DataValidation. Allowed values * expressions may reference other sheets, however. * * @param cell reference to check * @return the DataValidationContext applicable to the given cell, or null if no * validation applies */ public DataValidationContext getValidationContextForCell(CellReference cell) { final Sheet sheet = workbook.getSheet(cell.getSheetName()); if (sheet == null) return null; final List<? extends DataValidation> dataValidations = getValidations(sheet); if (dataValidations == null) return null; for (DataValidation dv : dataValidations) { final CellRangeAddressList regions = dv.getRegions(); if (regions == null) return null; // current implementation can't return null for (CellRangeAddressBase range : regions.getCellRangeAddresses()) { if (range.isInRange(cell)) { return new DataValidationContext(dv, this, range, cell); } } } return null; }
CellRangeAddress[] cellRangeAddresses = cellRangeAddressList.getCellRangeAddresses(); List<String> sqref = new ArrayList<>(); for (int i = 0; i < cellRangeAddresses.length; i++) {
public CellRangeAddress[] getCellRanges() { return field_4_cell_ranges.getCellRangeAddresses(); }
public CellRangeAddress[] getCellRanges() { return field_4_cell_ranges.getCellRangeAddresses(); }
public CellRangeAddress[] getCellRanges() { return field_4_cell_ranges.getCellRangeAddresses(); }
public String prettyPrint() { StringBuilder builder = new StringBuilder(); for(CellRangeAddress address : regions.getCellRangeAddresses()) { builder.append(address.formatAsString()); } builder.append(" => "); builder.append(this.validationConstraint.prettyPrint()); return builder.toString(); }
public String prettyPrint() { StringBuilder builder = new StringBuilder(); for(CellRangeAddress address : regions.getCellRangeAddresses()) { builder.append(address.formatAsString()); } builder.append(" => "); builder.append(this.validationConstraint.prettyPrint()); return builder.toString(); }
/** * Finds and returns the {@link DataValidationContext} for the cell, if there is * one. Lookup is based on the first match from * {@link DataValidation#getRegions()} for the cell's sheet. DataValidation * regions must be in the same sheet as the DataValidation. Allowed values * expressions may reference other sheets, however. * * @param cell reference to check * @return the DataValidationContext applicable to the given cell, or null if no * validation applies */ public DataValidationContext getValidationContextForCell(CellReference cell) { final Sheet sheet = workbook.getSheet(cell.getSheetName()); if (sheet == null) return null; final List<? extends DataValidation> dataValidations = getValidations(sheet); if (dataValidations == null) return null; for (DataValidation dv : dataValidations) { final CellRangeAddressList regions = dv.getRegions(); if (regions == null) return null; // current implementation can't return null for (CellRangeAddressBase range : regions.getCellRangeAddresses()) { if (range.isInRange(cell)) { return new DataValidationContext(dv, this, range, cell); } } } return null; }
CellRangeAddress[] cellRangeAddresses = cellRangeAddressList.getCellRangeAddresses(); if (cellRangeAddresses == null || cellRangeAddresses.length == 0) { continue;
CellRangeAddress[] cellRangeAddresses = cellRangeAddressList.getCellRangeAddresses(); List<String> sqref = new ArrayList<String>(); for (int i = 0; i < cellRangeAddresses.length; i++) {
CellRangeAddress[] cellRangeAddresses = cellRangeAddressList.getCellRangeAddresses(); List<String> sqref = new ArrayList<>(); for (int i = 0; i < cellRangeAddresses.length; i++) {