Package org.zkoss.stateless.action.data

## Class SelectionData

- java.lang.Object
- - org.zkoss.stateless.action.data.SelectionData

- All Implemented Interfaces:
    `java.io.Serializable`, `ActionData`

      public class SelectionData
      extends java.lang.Object
      implements ActionData

  Represents an action cause by user's the active selection which is a highlighted block of text.
  Author:
    jumperchen
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `SelectionData()` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `int` | `getEnd()` | Returns the selected text's end position.
    `java.lang.String` | `getSelectedText()` | Returns the selected text contained in this text.
    `int` | `getStart()` | Returns the selected text's start position.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### SelectionData

          public SelectionData()

  - ### Method Detail

    - #### getEnd

          public int getEnd()

      Returns the selected text's end position.
      Returns:
        the end position `>`= 0

    - #### getStart

          public int getStart()

      Returns the selected text's start position.
      Returns:
        the start position `>`= 0

    - #### getSelectedText

          public java.lang.String getSelectedText()

      Returns the selected text contained in this text. If the selection is null or the document empty, returns empty string.