Ejemplo n.º 1
0
 void onUpdateConfig(TL_config *config) {
     NativeByteBuffer *buffer = BuffersStorage::getInstance().getFreeBuffer(config->getObjectSize());
     config->serializeToStream(buffer);
     buffer->position(0);
     jniEnv->CallStaticVoidMethod(jclass_ConnectionsManager, jclass_ConnectionsManager_onUpdateConfig, buffer);
     buffer->reuse();
 }
Ejemplo n.º 2
0
jint position(JNIEnv *env, jclass c, jint address) {
    NativeByteBuffer *buffer = (NativeByteBuffer *) address;
    return buffer->position();
}