Save the date! Android Dev Summit is coming to Mountain View, CA on November 7-8, 2018.
Android 0.0.0 Developer Preview
belongs to Maven artifact androidx.leanback:leanback:1.1.0-alpha01

FacetProvider

public interface FacetProvider

androidx.leanback.widget.FacetProvider


This is the query interface to supply optional features(aka facets) on an object without the need of letting the object to subclass or implement java interfaces.

Summary

Public methods

abstract Object getFacet(Class<?> facetClass)

Queries optional implemented facet.

Public methods

getFacet

public abstract Object getFacet (Class<?> facetClass)

Queries optional implemented facet.

Parameters
facetClass Class: Facet classes to query, examples are: class of ItemAlignmentFacet.

Returns
Object Facet implementation for the facetClass or null if feature not implemented.