# BrowseSupportFragment.FragmentFactory

# BrowseSupportFragment.FragmentFactory

Artifact:[androidx.leanback:leanback](https://developer.android.com/jetpack/androidx/releases/leanback)  
[View Source](https://cs.android.com/search?q=file:androidx/leanback/app/BrowseSupportFragment.java+class:androidx.leanback.app.BrowseSupportFragment.FragmentFactory)  
Added in[1.1.0](https://developer.android.com/jetpack/androidx/releases/leanback#1.1.0)

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/androidx/leanback/app/BrowseSupportFragment.FragmentFactory "View this page in Java")

<br />

```
abstract class BrowseSupportFragment.FragmentFactory<T : Fragment?>
```

<br />

Known direct subclasses  
[BrowseSupportFragment.ListRowFragmentFactory](https://developer.android.com/reference/kotlin/androidx/leanback/app/BrowseSupportFragment.ListRowFragmentFactory)  

|-------------------------------------------------------------------------------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------|
| [BrowseSupportFragment.ListRowFragmentFactory](https://developer.android.com/reference/kotlin/androidx/leanback/app/BrowseSupportFragment.ListRowFragmentFactory) | FragmentFactory implementation for[ListRow](https://developer.android.com/reference/kotlin/androidx/leanback/widget/ListRow). |

*** ** * ** ***

Factory class responsible for creating fragment given the current item.[ListRow](https://developer.android.com/reference/kotlin/androidx/leanback/widget/ListRow)should return[RowsSupportFragment](https://developer.android.com/reference/kotlin/androidx/leanback/app/RowsSupportFragment)or its subclass whereas[PageRow](https://developer.android.com/reference/kotlin/androidx/leanback/widget/PageRow)can return any fragment class.

## Summary

|                                                               ### Public constructors                                                               |
|-----------------------------------------------------------------------------------------------------------------------------------------------------|
| [FragmentFactory](https://developer.android.com/reference/kotlin/androidx/leanback/app/BrowseSupportFragment.FragmentFactory#FragmentFactory())`()` |

| ### Public functions |
|----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `abstract T!`        | [createFragment](https://developer.android.com/reference/kotlin/androidx/leanback/app/BrowseSupportFragment.FragmentFactory#createFragment(java.lang.Object))`(row: `[Any](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html)`!)` |

## Public constructors

### FragmentFactory

Added in 1.1.0  

```
FragmentFactory()
```  

## Public functions

### createFragment

Added in[1.1.0](https://developer.android.com/jetpack/androidx/releases/leanback#1.1.0)  

```
abstract fun createFragment(row: Any!): T!
```