Package org.eclipse.handly.model.adapter

# Class NullContentAdapter

java.lang.Object
org.eclipse.handly.model.adapter.NullContentAdapter

All Implemented Interfaces:
  `IContentAdapter`

public class NullContentAdapter extends Object implements IContentAdapter
A content adapter that does nothing in terms of actual adaptation: it merely defines identity transformation between all `IElement`s.

- ## Field Summary

  Fields
  Modifier and Type
  Field
  Description
  `static final IContentAdapter`
  `INSTANCE`
  The sole instance of the null content adapter.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `IElement`
  `adapt(Object element)`
  Returns the `IElement` that corresponds to the given element.
  `Object`
  `getCorrespondingElement(IElement element)`
  Returns the element that corresponds to the given `IElement`.

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

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

- ## Field Details

  - ### INSTANCE

    public static final IContentAdapter INSTANCE
    The sole instance of the null content adapter.

- ## Method Details

  - ### adapt

    public IElement adapt(Object element)
    Description copied from interface: `IContentAdapter`
    Returns the `IElement` that corresponds to the given element.
    Specified by:
      `adapt` in interface `IContentAdapter`
    Parameters:
      `element` - may be `null`
    Returns:
      the corresponding `IElement`, or `null` if none

  - ### getCorrespondingElement

    public Object getCorrespondingElement(IElement element)
    Description copied from interface: `IContentAdapter`
    Returns the element that corresponds to the given `IElement`.
    Specified by:
      `getCorrespondingElement` in interface `IContentAdapter`
    Parameters:
      `element` - an `IElement` (may be `null`)
    Returns:
      the corresponding element, or `null` if none