Introduce cloning mechanism for React Shadow Node

Reviewed By: achen1

Differential Revision: D7018869

fbshipit-source-id: beca45b1df9602ebbc9172091b24a2bf44e103f4
This commit is contained in:
David Vacca
2018-02-20 19:09:52 -08:00
committed by Facebook Github Bot
parent 9dd7608c97
commit ad06403c3e
3 changed files with 66 additions and 11 deletions
@@ -67,6 +67,11 @@ public interface ReactShadowNode<T extends ReactShadowNode> {
*/
boolean isYogaLeafNode();
/**
* @return a mutable copy of the {@link ReactShadowNode}
*/
T mutableCopy();
String getViewClass();
boolean hasUpdates();
@@ -127,8 +132,11 @@ public interface ReactShadowNode<T extends ReactShadowNode> {
T getRootNode();
@Deprecated() //Replaced by setRootTag method.
void setRootNode(T rootNode);
void setRootTag(int rootTag);
void setViewClassName(String viewClassName);
@Nullable
@@ -159,6 +167,8 @@ public interface ReactShadowNode<T extends ReactShadowNode> {
T removeNativeChildAt(int i);
void removeAllChildren();
void removeAllNativeChildren();
int getNativeChildCount();