epoxy-adapter / com.airbnb.epoxy.preload / EpoxyModelPreloader / viewSignature

viewSignature

open fun viewSignature(epoxyModel: T): Any?

An optional signature to differentiate views within the same model. This is useful if your EpoxyModel can contain varying amounts of preloadable views, or preloadable views of varying sizes.

By default the model's class, span size, and layout resource, are used to differentiate views. This signature allows additional differentiation. For example, if your EpoxyModel shows an preloadable view that varies between portrait or landscape, this orientation will affect the view dimensions. In this case you could return a boolean here to differentiate the two cases so that the preloaded data has the correct orientation.

The returned object can be anything, but it must implement Object.hashCode