@Beta public class CellCopyPolicy extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
CellCopyPolicy.Builder |
Modifier and Type | Field and Description |
---|---|
static boolean |
DEFAULT_CONDENSE_ROWS_POLICY |
static boolean |
DEFAULT_COPY_CELL_FORMULA_POLICY |
static boolean |
DEFAULT_COPY_CELL_STYLE_POLICY |
static boolean |
DEFAULT_COPY_CELL_VALUE_POLICY |
static boolean |
DEFAULT_COPY_HYPERLINK_POLICY |
static boolean |
DEFAULT_COPY_MERGED_REGIONS_POLICY |
static boolean |
DEFAULT_COPY_ROW_HEIGHT_POLICY |
static boolean |
DEFAULT_MERGE_HYPERLINK_POLICY |
Constructor and Description |
---|
CellCopyPolicy()
Default CellCopyPolicy, uses default policy
For custom CellCopyPolicy, use
CellCopyPolicy.Builder class |
CellCopyPolicy(CellCopyPolicy other)
Copy constructor
|
Modifier and Type | Method and Description |
---|---|
CellCopyPolicy.Builder |
createBuilder() |
boolean |
isCondenseRows()
If condenseRows is true, a discontinuity in srcRows will be removed when copied to destination
|
boolean |
isCopyCellFormula() |
boolean |
isCopyCellStyle() |
boolean |
isCopyCellValue() |
boolean |
isCopyHyperlink() |
boolean |
isCopyMergedRegions() |
boolean |
isCopyRowHeight() |
boolean |
isMergeHyperlink() |
void |
setCondenseRows(boolean condenseRows)
If condenseRows is true, a discontinuity in srcRows will be removed when copied to destination
|
void |
setCopyCellFormula(boolean copyCellFormula) |
void |
setCopyCellStyle(boolean copyCellStyle) |
void |
setCopyCellValue(boolean copyCellValue) |
void |
setCopyHyperlink(boolean copyHyperlink) |
void |
setCopyMergedRegions(boolean copyMergedRegions) |
void |
setCopyRowHeight(boolean copyRowHeight) |
void |
setMergeHyperlink(boolean mergeHyperlink) |
public static final boolean DEFAULT_COPY_CELL_VALUE_POLICY
public static final boolean DEFAULT_COPY_CELL_STYLE_POLICY
public static final boolean DEFAULT_COPY_CELL_FORMULA_POLICY
public static final boolean DEFAULT_COPY_HYPERLINK_POLICY
public static final boolean DEFAULT_MERGE_HYPERLINK_POLICY
public static final boolean DEFAULT_COPY_ROW_HEIGHT_POLICY
public static final boolean DEFAULT_CONDENSE_ROWS_POLICY
public static final boolean DEFAULT_COPY_MERGED_REGIONS_POLICY
public CellCopyPolicy()
CellCopyPolicy.Builder
classpublic CellCopyPolicy(CellCopyPolicy other)
other
- policy to copypublic CellCopyPolicy.Builder createBuilder()
public boolean isCopyCellValue()
public void setCopyCellValue(boolean copyCellValue)
copyCellValue
- the copyCellValue to setpublic boolean isCopyCellStyle()
public void setCopyCellStyle(boolean copyCellStyle)
copyCellStyle
- the copyCellStyle to setpublic boolean isCopyCellFormula()
public void setCopyCellFormula(boolean copyCellFormula)
copyCellFormula
- the copyCellFormula to setpublic boolean isCopyHyperlink()
public void setCopyHyperlink(boolean copyHyperlink)
copyHyperlink
- the copyHyperlink to setpublic boolean isMergeHyperlink()
public void setMergeHyperlink(boolean mergeHyperlink)
mergeHyperlink
- the mergeHyperlink to setpublic boolean isCopyRowHeight()
public void setCopyRowHeight(boolean copyRowHeight)
copyRowHeight
- the copyRowHeight to setpublic boolean isCondenseRows()
For example:
Sheet.copyRows({Row(1), Row(2), Row(5)}, 11, policy) results in rows 1, 2, and 5 being copied to rows 11, 12, and 13 if condenseRows is True, or rows 11, 11, 15 if condenseRows is false
public void setCondenseRows(boolean condenseRows)
For example:
Sheet.copyRows({Row(1), Row(2), Row(5)}, 11, policy) results in rows 1, 2, and 5 being copied to rows 11, 12, and 13 if condenseRows is True, or rows 11, 11, 15 if condenseRows is false
condenseRows
- the condenseRows to setpublic boolean isCopyMergedRegions()
public void setCopyMergedRegions(boolean copyMergedRegions)
copyMergedRegions
- the copyMergedRegions to setCopyright 2022 The Apache Software Foundation or its licensors, as applicable.