[]
        
首页
开发者学堂
文档
论坛
市场
生态机会
活动
立即试用
(Showing Draft Content)

SheetType

Enum Class SheetType

java.lang.Object
java.lang.Enum<SheetType>
com.grapecity.documents.excel.SheetType
All Implemented Interfaces:
Serializable, Comparable<SheetType>, Constable

public enum SheetType extends Enum<SheetType>
表示工作表的类型。

将此枚举与 IWorksheets.add(SheetType) 一起使用可创建特定类型的工作表,或与 IWorksheet.getType() 一起使用可识别现有工作表是普通工作表还是图表工作表。


 IWorksheet chartSheet = workbook.getWorksheets().add(SheetType.Chart);
 SheetType type = chartSheet.getType();
 
  • Enum Constant Details

    • Worksheet

      public static final SheetType Worksheet
      代表一个工作表。
    • Chart

      public static final SheetType Chart
      代表一个图表工作表。
  • Method Details

    • values

      public static SheetType[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static SheetType valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null