com.independentsoft.exchange

## Class Subscription

- java.lang.Object
- - com.independentsoft.exchange.Subscription

- Direct Known Subclasses:
    PullSubscription, PushSubscription, StreamingSubscription

      public abstract class Subscription
      extends java.lang.Object

  Represents a subscription.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Subscription()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `java.util.List<EventType>` | `getEventTypes()` Gets a list of event notifications that are used to create a subscription.
    `java.util.List<FolderId>` | `getFolders()` Gets a list of folder identifiers that are used to identify folders to monitor for event notifications.
    `java.lang.String` | `getWatermark()` Gets an event bookmark in the mailbox events table.
    `boolean` | `isSubscribeToAllFolders()` Checks if is subscribe to all folders.
    `void` | `setSubscribeToAllFolders(boolean subscribeToAllFolders)` Sets the subscribe to all folders.
    `void` | `setWatermark(java.lang.String watermark)` Sets an event bookmark in the mailbox events table.

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

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

- - ### Constructor Detail

    - #### Subscription

          public Subscription()

  - ### Method Detail

    - #### getFolders

          public java.util.List<FolderId> getFolders()

      Gets a list of folder identifiers that are used to identify folders to monitor for event notifications.
      Returns:
        the folders

    - #### getEventTypes

          public java.util.List<EventType> getEventTypes()

      Gets a list of event notifications that are used to create a subscription.
      Returns:
        the event types

    - #### getWatermark

          public java.lang.String getWatermark()

      Gets an event bookmark in the mailbox events table.
      Returns:
        the watermark

    - #### setWatermark

          public void setWatermark(java.lang.String watermark)

      Sets an event bookmark in the mailbox events table.
      Parameters:
        `watermark` - the new watermark

    - #### isSubscribeToAllFolders

          public boolean isSubscribeToAllFolders()

      Checks if is subscribe to all folders.
      Returns:
        true, if is subscribe to all folders

    - #### setSubscribeToAllFolders

          public void setSubscribeToAllFolders(boolean subscribeToAllFolders)

      Sets the subscribe to all folders.
      Parameters:
        `subscribeToAllFolders` - the new subscribe to all folders