Assembly: EPiServer.Data (in EPiServer.Data.dll) Version: 9.7.2
Extracts the identity from the object if it has one.
public static Identity GetIdentity( this Object value )
The algorith used to extract identity is as follows: 1. The object is checked to see if it implements the IDynamicData interface and if so its Id property is called. 2. The object is reflected to search for a property named Id with a getter whose type is either Identity or Guid 3. The object is checked to see if it implements the interface and if so its ID and UniqueId properties are called