use of com.taobao.weex.ui.ComponentCreator in project incubator-weex by apache.
the class ConfigComponentHolder method createInstance.
@Override
public synchronized WXComponent createInstance(WXSDKInstance instance, WXDomObject node, WXVContainer parent) throws IllegalAccessException, InvocationTargetException, InstantiationException {
if (mClass == null || mClassLoader != instance.getContext().getClassLoader()) {
mClass = WXSDKManager.getInstance().getClassLoaderAdapter().getComponentClass(mType, mClassName, instance);
mClassLoader = instance.getContext().getClassLoader();
}
ComponentCreator creator = new SimpleComponentHolder.ClazzComponentCreator(mClass);
WXComponent component = creator.createInstance(instance, node, parent);
component.bindHolder(this);
return component;
}
Aggregations