org.apache.poi.xssf.usermodel.XSSFTable.getStartCellReference()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(6.9k)|赞(0)|评价(0)|浏览(162)

本文整理了Java中org.apache.poi.xssf.usermodel.XSSFTable.getStartCellReference()方法的一些代码示例,展示了XSSFTable.getStartCellReference()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XSSFTable.getStartCellReference()方法的具体详情如下:
包路径:org.apache.poi.xssf.usermodel.XSSFTable
类名称:XSSFTable
方法名:getStartCellReference

XSSFTable.getStartCellReference介绍

暂无

代码示例

代码示例来源:origin: org.apache.poi/poi-ooxml

/**
 * @since 3.15 beta 2
 */
public int getStartColIndex() {
  return getStartCellReference().getCol();
}

代码示例来源:origin: org.apache.poi/poi-ooxml

/**
 * @since 3.15 beta 2
 */
public int getStartRowIndex() {
  return getStartCellReference().getRow();
}

代码示例来源:origin: org.apache.poi/poi-ooxml

/**
 * Get the area reference for the cells which this table covers. The area
 * includes header rows and totals rows.
 *
 * Does not track updates to underlying changes to CTTable To synchronize
 * with changes to the underlying CTTable, call {@link #updateReferences()}.
 * 
 * @return the area of the table
 * @see "Open Office XML Part 4: chapter 3.5.1.2, attribute ref"
 * @since 3.17 beta 1
 */
public AreaReference getCellReferences() {
  return new AreaReference(
      getStartCellReference(),
      getEndCellReference(),
      SpreadsheetVersion.EXCEL2007
  );
}

代码示例来源:origin: org.apache.poi/poi-ooxml

/**
 * Get the total number of rows in this table, including all
 * {@linkplain #getHeaderRowCount() header rows} and all
 * {@linkplain #getTotalsRowCount() totals rows}. (Note: in this version
 * autofiltering is ignored)
 * 
 * Returns <code>0</code> if the start or end cell references are not set.
 * 
 * Does not track updates to underlying changes to CTTable To synchronize
 * with changes to the underlying CTTable, call {@link #updateReferences()}.
 * 
 * @return the total number of rows
 */
public int getRowCount() {
  CellReference from = getStartCellReference();
  CellReference to = getEndCellReference();
  
  int rowCount = 0;
  if (from!=null && to!=null) {
    rowCount = to.getRow() - from.getRow() + 1;
  }
  return rowCount;
}

代码示例来源:origin: org.apache.poi/poi-ooxml

int startRow = table.getStartCellReference().getRow() + table.getHeaderRowCount();
int endRow = table.getEndCellReference().getRow();
  short startColumnIndex = table.getStartCellReference().getCol();
  for (XSSFTableColumn tableColumn : tableColumns) {
    XSSFCell cell = row.getCell(startColumnIndex + tableColumn.getColumnIndex());

代码示例来源:origin: org.apache.poi/poi-ooxml

/**
 * Get the number of data rows in this table. This does not include any
 * header rows or totals rows.
 * 
 * Returns <code>0</code> if the start or end cell references are not set.
 * 
 * Does not track updates to underlying changes to CTTable To synchronize
 * with changes to the underlying CTTable, call {@link #updateReferences()}.
 * 
 * @return the number of data rows
 * @since 4.0.0
 */
public int getDataRowCount() {
  CellReference from = getStartCellReference();
  CellReference to = getEndCellReference();
  int rowCount = 0;
  if (from != null && to != null) {
    rowCount = (to.getRow() - from.getRow() + 1) - getHeaderRowCount()
        - getTotalsRowCount();
  }
  return rowCount;
}

代码示例来源:origin: org.apache.poi/poi-ooxml

int rowOffset = table.getStartCellReference().getRow() + table.getHeaderRowCount();
int columnOffset = table.getStartCellReference().getCol();

代码示例来源:origin: org.apache.poi/poi-ooxml

return new AreaReference(table.getStartCellReference(), table.getEndCellReference(),
    SpreadsheetVersion.EXCEL2007);

代码示例来源:origin: org.apache.poi/poi-ooxml

CellReference tableStart = getStartCellReference();
CellReference tableEnd = getEndCellReference();
SpreadsheetVersion version = getXSSFSheet().getWorkbook().getSpreadsheetVersion();

代码示例来源:origin: org.apache.poi/poi-ooxml

CellReference ref = getStartCellReference();
if (ref == null) return;

代码示例来源:origin: org.apache.poi/poi-ooxml

CellReference tableStart = getStartCellReference();
CellReference tableEnd = getEndCellReference();
SpreadsheetVersion version = getXSSFSheet().getWorkbook().getSpreadsheetVersion();

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

/**
 * @since 3.15 beta 2
 */
public int getStartColIndex() {
  return getStartCellReference().getCol();
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

/**
 * @since 3.15 beta 2
 */
public int getStartRowIndex() {
  return getStartCellReference().getRow();
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

/**
 * Get the area reference for the cells which this table covers. The area
 * includes header rows and totals rows.
 *
 * Does not track updates to underlying changes to CTTable To synchronize
 * with changes to the underlying CTTable, call {@link #updateReferences()}.
 * 
 * @return the area of the table
 * @see "Open Office XML Part 4: chapter 3.5.1.2, attribute ref"
 * @since 3.17 beta 1
 */
public AreaReference getCellReferences() {
  return new AreaReference(
      getStartCellReference(),
      getEndCellReference(),
      SpreadsheetVersion.EXCEL2007
  );
}

代码示例来源:origin: org.openl.rules/org.openl.lib.poi.dev

/**
   *  @return the total number of rows in the selection. (Note: in this version autofiltering is ignored)
   *
   */
  public int getRowCount(){
    
    
    CellReference from = getStartCellReference();
    CellReference to = getEndCellReference();
    
    int rowCount = -1;
    if (from!=null && to!=null){
     rowCount = to.getRow()-from.getRow();
    }
    return rowCount;
  }
}

代码示例来源:origin: stackoverflow.com

System.out.println(t.getNumerOfMappedColumns());
int startRow = t.getStartCellReference().getRow();
int endRow = t.getEndCellReference().getRow();
System.out.println("startRow = " + startRow);
System.out.println("endRow = " + endRow);
int startColumn = t.getStartCellReference().getCol();
int endColumn = t.getEndCellReference().getCol();

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

/**
 * Get the total number of rows in this table, including all
 * {@linkplain #getHeaderRowCount() header rows} and all
 * {@linkplain #getTotalsRowCount() totals rows}. (Note: in this version
 * autofiltering is ignored)
 * 
 * Returns <code>0</code> if the start or end cell references are not set.
 * 
 * Does not track updates to underlying changes to CTTable To synchronize
 * with changes to the underlying CTTable, call {@link #updateReferences()}.
 * 
 * @return the total number of rows
 */
public int getRowCount() {
  CellReference from = getStartCellReference();
  CellReference to = getEndCellReference();
  
  int rowCount = 0;
  if (from!=null && to!=null) {
    rowCount = to.getRow() - from.getRow() + 1;
  }
  return rowCount;
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

/**
 * Get the number of data rows in this table. This does not include any
 * header rows or totals rows.
 * 
 * Returns <code>0</code> if the start or end cell references are not set.
 * 
 * Does not track updates to underlying changes to CTTable To synchronize
 * with changes to the underlying CTTable, call {@link #updateReferences()}.
 * 
 * @return the number of data rows
 * @since 4.0.0
 */
public int getDataRowCount() {
  CellReference from = getStartCellReference();
  CellReference to = getEndCellReference();
  int rowCount = 0;
  if (from != null && to != null) {
    rowCount = (to.getRow() - from.getRow() + 1) - getHeaderRowCount()
        - getTotalsRowCount();
  }
  return rowCount;
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

return new AreaReference(table.getStartCellReference(), table.getEndCellReference(),
    SpreadsheetVersion.EXCEL2007);

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi

CellReference ref = getStartCellReference();
if (ref == null) return;

相关文章