本文整理汇总了C++中ThreadLocalJNIEnvHolder类的典型用法代码示例。如果您正苦于以下问题:C++ ThreadLocalJNIEnvHolder类的具体用法?C++ ThreadLocalJNIEnvHolder怎么用?C++ ThreadLocalJNIEnvHolder使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了ThreadLocalJNIEnvHolder类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: getEnv
JNIEnv* getEnv() noexcept
{
#if JUCE_DEBUG
if (! systemInitialised)
{
DBG ("*** Call to getEnv() when system not initialised");
jassertfalse;
std::exit (EXIT_FAILURE);
}
#endif
return threadLocalJNIEnvHolder.getOrAttach();
}
示例2: getEnv
JNIEnv* getEnv() noexcept
{
#if BEAST_DEBUG
if (! systemInitialised)
{
DBG ("*** Call to getEnv() when system not initialised");
bassertfalse;
exit (0);
}
#endif
return threadLocalJNIEnvHolder.getOrAttach();
}
示例3: initialise
void AndroidSystem::initialise (JNIEnv* env, jobject act, jstring file, jstring dataDir)
{
screenWidth = screenHeight = 0;
dpi = 160;
JNIClassBase::initialiseAllClasses (env);
threadLocalJNIEnvHolder.initialise (env);
#if JUCE_DEBUG
systemInitialised = true;
#endif
activity = GlobalRef (act);
appFile = juceString (env, file);
appDataDir = juceString (env, dataDir);
}
示例4: initialise
void AndroidSystem::initialise (JNIEnv* env, jobject activity_,
jstring appFile_, jstring appDataDir_)
{
screenWidth = screenHeight = 0;
JNIClassBase::initialiseAllClasses (env);
threadLocalJNIEnvHolder.initialise (env);
#if BEAST_DEBUG
systemInitialised = true;
#endif
activity = GlobalRef (activity_);
appFile = beastString (env, appFile_);
appDataDir = beastString (env, appDataDir_);
}