Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.poi.hssf.record
Class HyperlinkRecord

    java.lang.Object
      org.apache.poi.hssf.record.RecordBase
          org.apache.poi.hssf.record.Record
              org.apache.poi.hssf.record.StandardRecord
                  org.apache.poi.hssf.record.HyperlinkRecord

    public final class HyperlinkRecord

extends StandardRecord

The `HyperlinkRecord` (0x01B8) wraps an HLINK-record from the Excel-97 format. Supports only external links for now (eg http://)

Author:
  Mark Hissink Muller

  Field Summary
  `static short` | `sid`

  Constructor Summary
  `HyperlinkRecord()` Create a new hyperlink
  `HyperlinkRecord(RecordInputStream in)`

  Method Summary
  `java.lang.Object` | `clone()`
  `java.lang.String` | `getAddress()` Hyperlink address.
  `protected int` | `getDataSize()`
  `int` | `getFileOptions()` Options for a file link
  `int` | `getFirstColumn()`
  `int` | `getFirstRow()`
  `java.lang.String` | `getLabel()` Return text label for this hyperlink
  `int` | `getLabelOptions()` Label options
  `int` | `getLastColumn()`
  `int` | `getLastRow()`
  `java.lang.String` | `getShortFilename()`
  `short` | `getSid()` return the non static version of the id for this record.
  `java.lang.String` | `getTargetFrame()`
  `java.lang.String` | `getTextMark()`
  `boolean` | `isDocumentLink()` Based on the link options, is this a document?
  `boolean` | `isFileLink()` Based on the link options, is this a file?
  `boolean` | `isUrlLink()` Based on the link options, is this a url?
  `void` | `newDocumentLink()` Initialize a new document link
  `void` | `newFileLink()` Initialize a new file link
  `void` | `newUrlLink()` Initialize a new url link
  `void` | `serialize(LittleEndianOutput out)` Write the data content of this BIFF record.
  `void` | `setAddress(java.lang.String address)` Hyperlink address.
  `void` | `setFirstColumn(int col)` Set the first column (zero-based)of the range that contains this hyperlink
  `void` | `setFirstRow(int col)` Set the first row (zero-based)of the range that contains this hyperlink
  `void` | `setLabel(java.lang.String label)` Sets text label for this hyperlink
  `void` | `setLastColumn(int col)` Set the last column (zero-based)of the range that contains this hyperlink
  `void` | `setLastRow(int col)` Set the last row (zero-based)of the range that contains this hyperlink
  `void` | `setShortFilename(java.lang.String shortFilename)`
  `void` | `setTextMark(java.lang.String textMark)`
  `java.lang.String` | `toString()` get a string representation of the record (for biffview/debugging)

  Methods inherited from class org.apache.poi.hssf.record.StandardRecord
  `getRecordSize, serialize`

  Methods inherited from class org.apache.poi.hssf.record.Record
  `cloneViaReserialise, serialize`

  Methods inherited from class java.lang.Object
  `equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

  Field Detail

  ### sid

      public static final short sid

  See Also:
    Constant Field Values

  Constructor Detail

  ### HyperlinkRecord

      public HyperlinkRecord()

    Create a new hyperlink

  ### HyperlinkRecord

      public HyperlinkRecord(RecordInputStream in)

  Method Detail

  ### getFirstColumn

      public int getFirstColumn()

    Returns:
      the 0-based column of the first cell that contains this hyperlink

  ### setFirstColumn

      public void setFirstColumn(int col)

    Set the first column (zero-based)of the range that contains this hyperlink

  ### getLastColumn

      public int getLastColumn()

    Returns:
      the 0-based column of the last cell that contains this hyperlink

  ### setLastColumn

      public void setLastColumn(int col)

    Set the last column (zero-based)of the range that contains this hyperlink

  ### getFirstRow

      public int getFirstRow()

    Returns:
      the 0-based row of the first cell that contains this hyperlink

  ### setFirstRow

      public void setFirstRow(int col)

    Set the first row (zero-based)of the range that contains this hyperlink

  ### getLastRow

      public int getLastRow()

    Returns:
      the 0-based row of the last cell that contains this hyperlink

  ### setLastRow

      public void setLastRow(int col)

    Set the last row (zero-based)of the range that contains this hyperlink

  ### getLabel

      public java.lang.String getLabel()

    Return text label for this hyperlink

    Returns:
      text to display

  ### setLabel

      public void setLabel(java.lang.String label)

    Sets text label for this hyperlink

    Parameters:
      `label` - text label for this hyperlink

  ### getTargetFrame

      public java.lang.String getTargetFrame()

  ### getAddress

      public java.lang.String getAddress()

    Hyperlink address. Depending on the hyperlink type it can be URL, e-mail, path to a file, etc.

    Returns:
      the address of this hyperlink

  ### setAddress

      public void setAddress(java.lang.String address)

    Hyperlink address. Depending on the hyperlink type it can be URL, e-mail, path to a file, etc.

    Parameters:
      `address` - the address of this hyperlink

  ### getShortFilename

      public java.lang.String getShortFilename()

  ### setShortFilename

      public void setShortFilename(java.lang.String shortFilename)

  ### getTextMark

      public java.lang.String getTextMark()

  ### setTextMark

      public void setTextMark(java.lang.String textMark)

  ### getLabelOptions

      public int getLabelOptions()

    Label options

  ### getFileOptions

      public int getFileOptions()

    Options for a file link

  ### serialize

      public void serialize(LittleEndianOutput out)

    Description copied from class: `StandardRecord`
    Write the data content of this BIFF record. The 'ushort sid' and 'ushort size' header fields have already been written by the superclass.
    The subclass must write the exact number of bytes as reported by `RecordBase.getRecordSize()`}

    Specified by:
      `serialize` in class `StandardRecord`

  ### getDataSize

      protected int getDataSize()

    Specified by:
      `getDataSize` in class `StandardRecord`

  ### getSid

      public short getSid()

    Description copied from class: `Record`
    return the non static version of the id for this record.

    Specified by:
      `getSid` in class `Record`

  ### toString

      public java.lang.String toString()

    Description copied from class: `Record`
    get a string representation of the record (for biffview/debugging)

    Overrides:
      `toString` in class `Record`

  ### isUrlLink

      public boolean isUrlLink()

    Based on the link options, is this a url?

  ### isFileLink

      public boolean isFileLink()

    Based on the link options, is this a file?

  ### isDocumentLink

      public boolean isDocumentLink()

    Based on the link options, is this a document?

  ### newUrlLink

      public void newUrlLink()

    Initialize a new url link

  ### newFileLink

      public void newFileLink()

    Initialize a new file link

  ### newDocumentLink

      public void newDocumentLink()

    Initialize a new document link

  ### clone

      public java.lang.Object clone()

    Overrides:
      `clone` in class `Record`

  Overview | Package | Class | Use | Tree | Deprecated | Index | Help
  PREV CLASS NEXT CLASS | FRAMES NO FRAMES
  SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

  Copyright 2010 The Apache Software Foundation or its licensors, as applicable.