当前位置: 首页>>代码示例>>Java>>正文


Java ReactPackage类代码示例

本文整理汇总了Java中com.facebook.react.ReactPackage的典型用法代码示例。如果您正苦于以下问题:Java ReactPackage类的具体用法?Java ReactPackage怎么用?Java ReactPackage使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


ReactPackage类属于com.facebook.react包,在下文中一共展示了ReactPackage类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: createReactInstanceManager

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected ReactInstanceManager createReactInstanceManager() {
    ReactInstanceManagerBuilder builder = ReactInstanceManager.builder()
            .setApplication(getApplication())
            .setJSMainModuleName(getJSMainModuleName())
            .setUseDeveloperSupport(getUseDeveloperSupport())
            .setRedBoxHandler(getRedBoxHandler())
            .setUIImplementationProvider(getUIImplementationProvider())
            .setInitialLifecycleState(LifecycleState.BEFORE_CREATE)
            .setNativeModuleCallExceptionHandler(
                    new ReadingNativeModuleCallExceptionHandler());

    for (ReactPackage reactPackage : getPackages()) {
        builder.addPackage(reactPackage);
    }

    String jsBundleFile = getJSBundleFile();
    if (jsBundleFile != null) {
        builder.setJSBundleFile(jsBundleFile);
    } else {
        builder.setBundleAssetName(Assertions.assertNotNull(getBundleAssetName()));
    }
    return builder.build();
}
 
开发者ID:qq565999484,项目名称:RNLearn_Project1,代码行数:25,代码来源:MainApplication.java

示例2: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
	List<ReactPackage> result = new ArrayList<>();

	List<ReactPackage> additionalReactPackages = NavigationApplication.instance.createAdditionalReactPackages();
	if (additionalReactPackages != null)
		result.addAll(additionalReactPackages);

	if (!containsInstanceOfClass(result, MainReactPackage.class)) {
		result.add(new MainReactPackage());
	}
	if (!containsInstanceOfClass(result, NavigationReactPackage.class)) {
		result.add(new NavigationReactPackage());
	}

	return result;
}
 
开发者ID:wix,项目名称:react-native-navigation,代码行数:18,代码来源:NavigationReactGateway.java

示例3: getReactInstanceManager

import com.facebook.react.ReactPackage; //导入依赖的package包/类
public static synchronized ReactInstanceManager getReactInstanceManager(
        Application application) {
    if (sSingletonManager == null) {
        ReactInstanceManager.Builder builder = ReactInstanceManager.builder()
                .setApplication(application)
                .setJSMainModuleName("index.android")
                .setUseDeveloperSupport(BuildConfig.DEBUG)
                        // TODO figure out the right thing to put here.
                .setInitialLifecycleState(LifecycleState.BEFORE_RESUME);

        for (ReactPackage reactPackage : getPackages()) {
            builder.addPackage(reactPackage);
        }

        builder.setBundleAssetName("index.android.bundle");
        sSingletonManager = builder.build();
    }
    return sSingletonManager;
}
 
开发者ID:alangpierce,项目名称:react-native-android-audio-demo,代码行数:20,代码来源:ReactInstanceSingleton.java

示例4: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
        new NearbyPackage()
  );
}
 
开发者ID:miguelespinoza,项目名称:react-native-nearby,代码行数:8,代码来源:MainApplication.java

示例5: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
        new CameraPackage()
  );
}
 
开发者ID:cuonghuynhvan,项目名称:react-native-camera-android-simple,代码行数:8,代码来源:MainApplication.java

示例6: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
    return Arrays.<ReactPackage>asList(
            new MainReactPackage(),
            new ReactTwitterKitPackage(CONSUMER_KEY, CONSUMER_SECRET)
    );
}
 
开发者ID:netceteragroup,项目名称:react-native-twitterkit,代码行数:8,代码来源:MainApplication.java

示例7: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
      new VectorIconsPackage(),
      new RNCollapsingToolbarPackage(),
      new RNNestedScrollViewPackage()
  );
}
 
开发者ID:cesardeazevedo,项目名称:react-native-collapsing-toolbar,代码行数:10,代码来源:MainApplication.java

示例8: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
        new SystemSettingPackage()
  );
}
 
开发者ID:c19354837,项目名称:react-native-system-setting,代码行数:8,代码来源:MainApplication.java

示例9: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
        new RNMessageComposePackage()
  );
}
 
开发者ID:joonhocho,项目名称:react-native-message-compose,代码行数:8,代码来源:MainApplication.java

示例10: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
          new RNReactNativeAndoridShadowPackage()
  );
}
 
开发者ID:wix,项目名称:react-native-andorid-shadow,代码行数:8,代码来源:MainApplication.java

示例11: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
        new RNGLModelViewPackage()
  );
}
 
开发者ID:rastapasta,项目名称:react-native-gl-model-view,代码行数:8,代码来源:MainApplication.java

示例12: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
      new RNGLModelViewPackage()
  );
}
 
开发者ID:rastapasta,项目名称:react-native-gl-model-view,代码行数:8,代码来源:MainApplication.java

示例13: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
      new ReactNativeAndroidAudioConverterPackage() // <---- add this line
  );
}
 
开发者ID:SovTech,项目名称:ReactNativeAndroidAudioConverter,代码行数:8,代码来源:MainApplication.java

示例14: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
new RNRecyclerviewListPackage()
  );
}
 
开发者ID:godness84,项目名称:react-native-recyclerview-list,代码行数:8,代码来源:MainApplication.java

示例15: getPackages

import com.facebook.react.ReactPackage; //导入依赖的package包/类
@Override
protected List<ReactPackage> getPackages() {
  return Arrays.<ReactPackage>asList(
      new MainReactPackage(),
      new TestPackage()
  );
}
 
开发者ID:zupzup,项目名称:react-native-ethereum,代码行数:8,代码来源:MainApplication.java


注:本文中的com.facebook.react.ReactPackage类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。