类 WorkbookReference

java.lang.Object
com.grapecity.documents.excel.expressions.WorkbookReference

public final class WorkbookReference extends Object
Represents a reference to an external workbook. This class is immutable.
  • 字段详细资料

    • SupportsReferenceId

      public static final boolean SupportsReferenceId
      另请参阅:
  • 构造器详细资料

    • WorkbookReference

      public WorkbookReference()
  • 方法详细资料

    • getBaseDirectory

      public String getBaseDirectory()
      The base directory that contains workbook. If the value is not null ,Name is the file name of workbook. If the value is empty, the path isthe root directory.
    • getBaseUri

      public String getBaseUri()
      The base uri that contains workbook.
      If the value is not null, Name is the file name ofworkbook.
      For example, the base uri of https://www.grapecity.com/file/example.xlsx is https://www.grapecity.com/file . The file name is example.xlsx .
    • getName

      public String getName()
      The name of the workbook. If the BaseDirectory is not null, represents the file name of the workbook.
    • getId

      public int getId()
      Gets or sets the workbook id if the reference came from low-level storage of formulas. The default value is 0, which means the current workbook.
    • FromFilePath

      public static WorkbookReference FromFilePath(String workbookFullPath)
      Creates a workbook reference from file path.
      参数:
      workbookFullPath - The full path of workbook. It must be a valid filepath.
      返回:
      Workbook reference
    • FromUri

      public static WorkbookReference FromUri(String uri)
      Creates a workbook reference from a URI link to workbook.
      参数:
      uri - A URI link to the workbook.
      返回:
    • FromName

      public static WorkbookReference FromName(String name)
      Creates a workbook reference from workbook name.
      参数:
      name - The name of the workbook. It can be different from file name.
      返回:
      Workbook reference
    • equals

      public boolean equals(Object obj)
      Check if the workbook reference equals to another.
      覆盖:
      equals 在类中 Object
      参数:
      obj - Another workbook reference
      返回:
      equality
    • equals

      public boolean equals(WorkbookReference other)
      Check if the workbook reference equals to another.
      参数:
      other - Another workbook reference
      返回:
      equality
    • hashCode

      public int hashCode()
      Gets hash code of the workbook reference.
      覆盖:
      hashCode 在类中 Object
      返回:
      hash code
    • toString

      public String toString()
      Converts workbook reference to string.
      覆盖:
      toString 在类中 Object
      返回:
      string value