com.dlsc.flexgantt.policy

## Class PolicyProviderEvent

- java.lang.Object
- - java.util.EventObject
  - - com.dlsc.flexgantt.policy.PolicyProviderEvent

- All Implemented Interfaces:
    Serializable

      public class PolicyProviderEvent
      extends EventObject

  An event object which wraps information about an event / a change that occured inside a policy provider. The event will be sent to those policy provider listeners that are attached to the provider that changed.
  Since:
    1.0
  Version:
    $Revision: 1.8 $
  Author:
    Dirk Lemmermann
  See Also:
    `IPolicyProvider.addPolicyProviderListener(IPolicyProviderListener)`, Serialized Form

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `PolicyProviderEvent.ID` An event identifier used to distinguish between different types of events that can take place inside a policy provider.

  - ### Field Summary

    - ### Fields inherited from class java.util.EventObject

      `source`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `PolicyProviderEvent(IPolicyProvider pp, PolicyProviderEvent.ID id, Class<? extends IPolicy> policyType, IPolicy policyImpl)` Constructs a new policy provider event.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `PolicyProviderEvent.ID` | `getId()` Returns the event identifier that can be used to distinguish between different types of events.
    `IPolicy` | `getPolicyImpl()` Returns the new policy implementation.
    `IPolicyProvider` | `getPolicyProvider()` Returns the source of the event (the modified policy provider).
    `Class<? extends IPolicy>` | `getPolicyType()` Returns the type of the changed policy.

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

      `getSource, toString`

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

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

- - ### Constructor Detail

    - #### PolicyProviderEvent

          public PolicyProviderEvent(IPolicyProvider pp,
                                     PolicyProviderEvent.ID id,
                                     Class<? extends IPolicy> policyType,
                                     IPolicy policyImpl)

      Constructs a new policy provider event.
      Parameters:
        `pp` - the changed policy provider
        `id` - the event identifier used to distinguish between different types of events
        `policyType` - the type of the policy that was changed
        `policyImpl` - the new implementation of the changed policy
      Since:
        1.0

  - ### Method Detail

    - #### getPolicyProvider

          public IPolicyProvider getPolicyProvider()

      Returns the source of the event (the modified policy provider).
      Returns:
        the modified policy provider
      Since:
        1.0

    - #### getId

          public PolicyProviderEvent.ID getId()

      Returns the event identifier that can be used to distinguish between different types of events.
      Returns:
        the event identifier
      Since:
        1.0

    - #### getPolicyImpl

          public IPolicy getPolicyImpl()

      Returns the new policy implementation.
      Returns:
        the new policy implementation
      Since:
        1.0

    - #### getPolicyType

          public Class<? extends IPolicy> getPolicyType()

      Returns the type of the changed policy.
      Returns:
        the policy type that was changed
      Since:
        1.0

Copyright © 2006–2020 Dirk Lemmermann Software & Consulting. All rights reserved.