org.eclipse.emf.cdo.view

## Interface CDOAdapterPolicy

- All Known Implementing Classes:
    AbstractObjectConflictResolver.MergeLocalChangesPerFeature, AbstractObjectConflictResolver.ThreeWayMerge

      public interface CDOAdapterPolicy

  A policy that allows to specify valid `Adapter` / `EObject` combinations.
  Since:
    2.0
  Author:
    Simon McDuff
  See Also:
    `CDOView.Options.addChangeSubscriptionPolicy(CDOAdapterPolicy)`, `CDOView.Options.setStrongReferencePolicy(CDOAdapterPolicy)`

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static CDOAdapterPolicy` | `ALL` A default adapter policy that always triggers special behavior.
    `static CDOAdapterPolicy` | `CDO` A default adapter policy that only triggers special behavior if the adapter under test implements `CDOAdapter`.
    `static CDOAdapterPolicy` | `NONE` A default adapter policy that never triggers any special behavior.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `isValid(EObject eObject, Adapter adapter)` Returns `true` if the given adapter on the given object should trigger a certain operation or behavior, `false` otherwise.

- - ### Field Detail

    - #### NONE

          static final CDOAdapterPolicy NONE

      A default adapter policy that never triggers any special behavior.

    - #### CDO

          static final CDOAdapterPolicy CDO

      A default adapter policy that only triggers special behavior if the adapter under test implements `CDOAdapter`.

    - #### ALL

          static final CDOAdapterPolicy ALL

      A default adapter policy that always triggers special behavior.

  - ### Method Detail

    - #### isValid

          boolean isValid(EObject eObject,
                          Adapter adapter)

      Returns `true` if the given adapter on the given object should trigger a certain operation or behavior, `false` otherwise.
      See Also:
        `CDOView.Options.addChangeSubscriptionPolicy(CDOAdapterPolicy)`, `CDOView.Options.setStrongReferencePolicy(CDOAdapterPolicy)`

Copyright (c) 2014 Eike Stepper (Berlin, Germany) and others.
All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html