Package org.eclipse.emf.compare.match.eobject

# Class IdentifierEObjectMatcher.DefaultIDFunction

java.lang.Object
org.eclipse.emf.compare.match.eobject.IdentifierEObjectMatcher.DefaultIDFunction

All Implemented Interfaces:
  `com.google.common.base.Function<EObject,String>`, `Function<EObject,String>`

Enclosing class:
  IdentifierEObjectMatcher

public static class IdentifierEObjectMatcher.DefaultIDFunction extends Object implements com.google.common.base.Function<EObject,String>
The default function used to retrieve IDs from EObject. You might want to extend or compose with it if you want to reuse its behavior.

## Constructor Summary

Constructors
Constructor
Description
`DefaultIDFunction()`

## Method Summary

Modifier and Type
Method
Description
`String`
`apply(EObject eObject)`
Return an ID for an EObject, null if not found.

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

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

### Methods inherited from interface com.google.common.base.Function

`equals`

### Methods inherited from interface java.util.function.Function

`andThen, compose`

## Constructor Details

### DefaultIDFunction

public DefaultIDFunction()

## Method Details

### apply

public String apply(EObject eObject)
Return an ID for an EObject, null if not found.

Specified by:
  `apply` in interface `com.google.common.base.Function<EObject,String>`
Specified by:
  `apply` in interface `Function<EObject,String>`
Parameters:
  `eObject` - The EObject for which we need an identifier.
Returns:
  The identifier for that EObject if we could determine one. `null` if no condition (see description above) is fulfilled for the given eObject.