Skip to content

Commit

Permalink
Make FragmentDelegate functions open. (#322)
Browse files Browse the repository at this point in the history
  • Loading branch information
Laimiux authored Dec 12, 2023
1 parent d5b7ffe commit 877827f
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ data class FragmentEnvironment(
/**
* Instantiates the feature.
*/
fun <DependenciesT, KeyT: FragmentKey> initializeFeature(
open fun <DependenciesT, KeyT: FragmentKey> initializeFeature(
fragmentId: FragmentId,
factory: FeatureFactory<DependenciesT, KeyT>,
dependencies: DependenciesT,
Expand All @@ -29,7 +29,7 @@ data class FragmentEnvironment(
/**
* Called from [FormulaFragment.onCreateView] to instantiate the view.
*/
fun createView(
open fun createView(
fragmentId: FragmentId,
viewFactory: ViewFactory<Any>,
inflater: LayoutInflater,
Expand All @@ -41,14 +41,14 @@ data class FragmentEnvironment(
/**
* Called when we are ready to apply [output] to the view.
*/
fun setOutput(fragmentId: FragmentId, output: Any, applyOutputToView: (Any) -> Unit) {
open fun setOutput(fragmentId: FragmentId, output: Any, applyOutputToView: (Any) -> Unit) {
applyOutputToView(output)
}

/**
* Called after first render model is rendered. The [durationInMillis] starts
* when formula fragment is initialized and ends after first render model is applied.
*/
fun onFirstModelRendered(fragmentId: FragmentId, durationInMillis: Long) = Unit
open fun onFirstModelRendered(fragmentId: FragmentId, durationInMillis: Long) = Unit
}
}

0 comments on commit 877827f

Please sign in to comment.