Canceler
Date: 2017-02-10

javax.jmdns.impl.tasks.state

## Class Canceler

- java.lang.Object
- - java.util.TimerTask
  - - javax.jmdns.impl.tasks.DNSTask
    - - javax.jmdns.impl.tasks.state.DNSStateTask
      - - javax.jmdns.impl.tasks.state.Canceler

- All Implemented Interfaces:
    java.lang.Runnable

      public class Canceler
      extends DNSStateTask

  The Canceler sends two announces with TTL=0 for the specified services.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `Canceler(JmDNSImpl jmDNSImpl)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected void` | `advanceTask()`
    `protected DNSOutgoing` | `buildOutgoingForDNS(DNSOutgoing out)`
    `protected DNSOutgoing` | `buildOutgoingForInfo(ServiceInfoImpl info, DNSOutgoing out)`
    `boolean` | `cancel()`
    `protected boolean` | `checkRunCondition()`
    `protected DNSOutgoing` | `createOugoing()`
    `java.lang.String` | `getName()` Return this task name.
    `java.lang.String` | `getTaskDescription()`
    `protected void` | `recoverTask(java.lang.Throwable e)`
    `void` | `start(java.util.Timer timer)` Start this task.
    `java.lang.String` | `toString()`

    - ### Methods inherited from class javax.jmdns.impl.tasks.state.DNSStateTask

      `advanceObjectsState, associate, defaultTTL, getTaskState, getTTL, removeAssociation, run, setDefaultTTL, setTaskState`

    - ### Methods inherited from class javax.jmdns.impl.tasks.DNSTask

      `addAdditionalAnswer, addAnswer, addAnswer, addAuthoritativeAnswer, addQuestion, getDns`

    - ### Methods inherited from class java.util.TimerTask

      `scheduledExecutionTime`

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

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

- - ### Constructor Detail

    - #### Canceler

          public Canceler(JmDNSImpl jmDNSImpl)

  - ### Method Detail

    - #### getName

          public java.lang.String getName()

      Description copied from class: `DNSTask`
      Return this task name.
      Specified by:
        `getName` in class `DNSTask`
      Returns:
        task name

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `DNSTask`

    - #### start

          public void start(java.util.Timer timer)

      Description copied from class: `DNSTask`
      Start this task.
      Specified by:
        `start` in class `DNSTask`
      Parameters:
        `timer` - task timer.

    - #### cancel

          public boolean cancel()

      Overrides:
        `cancel` in class `java.util.TimerTask`

    - #### getTaskDescription

          public java.lang.String getTaskDescription()

      Specified by:
        `getTaskDescription` in class `DNSStateTask`

    - #### checkRunCondition

          protected boolean checkRunCondition()

      Specified by:
        `checkRunCondition` in class `DNSStateTask`

    - #### createOugoing

          protected DNSOutgoing createOugoing()

      Specified by:
        `createOugoing` in class `DNSStateTask`

    - #### buildOutgoingForDNS

          protected DNSOutgoing buildOutgoingForDNS(DNSOutgoing out)
                                             throws java.io.IOException

      Specified by:
        `buildOutgoingForDNS` in class `DNSStateTask`
      Throws:
        `java.io.IOException`

    - #### buildOutgoingForInfo

          protected DNSOutgoing buildOutgoingForInfo(ServiceInfoImpl info,
                                         DNSOutgoing out)
                                              throws java.io.IOException

      Specified by:
        `buildOutgoingForInfo` in class `DNSStateTask`
      Throws:
        `java.io.IOException`

    - #### recoverTask

          protected void recoverTask(java.lang.Throwable e)

      Specified by:
        `recoverTask` in class `DNSStateTask`

    - #### advanceTask

          protected void advanceTask()

      Specified by:
        `advanceTask` in class `DNSStateTask`