[]
Serializable, Comparable<PasteType>, Constable与 IRange.copy(IRange,PasteOption) 或 PasteOption.setPasteType(java.util.EnumSet) 配合使用,可以控制源区域的哪些方面被粘贴到目标位置。可以使用 EnumSet 组合多个值。
worksheet.getRange("A1:B2").setValue(new Object[][] {
{"Name", "Price"},
{"Apple", 1.99}
});
worksheet.getRange("A1:B1").getFont().setBold(true);
// Copy only values (without formatting) to another range
PasteOption option = new PasteOption();
option.setPasteType(EnumSet.of(PasteType.Values));
worksheet.getRange("A1:B2").copy(worksheet.getRange("D1"), option);
Enum.EnumDesc<E extends Enum<E>>name - the name of the enum constant to be returned.IllegalArgumentException - if this enum class has no constant with the specified nameNullPointerException - if the argument is null