mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Summary: In this diff I'm introducing IViewGroupManager to extract methods required to add/remove views from a viewGroup This will be used by ViewManagers that require to add views but don't depend on ViewGroupmanager changelog: [internal] internal Reviewed By: javache Differential Revision: D41386920 fbshipit-source-id: a7d893d92d0f12766dcc71dfd1b22539c3b9687d
27 lines
943 B
Java
27 lines
943 B
Java
/*
|
|
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
*
|
|
* This source code is licensed under the MIT license found in the
|
|
* LICENSE file in the root directory of this source tree.
|
|
*/
|
|
|
|
package com.facebook.react.uimanager;
|
|
|
|
import android.view.View;
|
|
|
|
/** Interface providing children management API for view managers of classes extending ViewGroup. */
|
|
public interface IViewGroupManager<T extends View> extends IViewManagerWithChildren {
|
|
|
|
/** Adds a child view into the parent at the index specified as a parameter */
|
|
void addView(T parent, View child, int index);
|
|
|
|
/** @return child of the parent view at the index specified as a parameter. */
|
|
View getChildAt(T parent, int index);
|
|
|
|
/** Removes View from the parent View at the index specified as a parameter. */
|
|
void removeViewAt(T parent, int index);
|
|
|
|
/** Return the amount of children contained by the view specified as a parameter. */
|
|
int getChildCount(T parent);
|
|
}
|