/*
* Class: org_ocera_orte_Domain
* Method: jORTEDomainStart
- * Signature: (IZZZ)V
+ * Signature: (JZZZ)V
*/
JNIEXPORT void JNICALL Java_org_ocera_orte_Domain_jORTEDomainStart
- (JNIEnv *, jclass, jint, jboolean, jboolean, jboolean);
+ (JNIEnv *, jclass, jlong, jboolean, jboolean, jboolean);
#ifdef __cplusplus
}
/*
* Class: org_ocera_orte_DomainApp
* Method: jORTEDomainDefaultAppCreate
- * Signature: (IZ)I
+ * Signature: (IZ)J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_DomainApp_jORTEDomainDefaultAppCreate
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_DomainApp_jORTEDomainDefaultAppCreate
(JNIEnv *, jclass, jint, jboolean);
/*
* Class: org_ocera_orte_DomainApp
* Method: jORTEDomainAppCreate
- * Signature: (IIILorg/ocera/orte/types/DomainEvents;Z)I
+ * Signature: (IJJLorg/ocera/orte/types/DomainEvents;Z)J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_DomainApp_jORTEDomainAppCreate
- (JNIEnv *, jclass, jint, jint, jint, jobject, jboolean);
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_DomainApp_jORTEDomainAppCreate
+ (JNIEnv *, jclass, jint, jlong, jlong, jobject, jboolean);
/*
* Class: org_ocera_orte_DomainApp
* Method: jORTEDomainAppDestroy
- * Signature: (I)Z
+ * Signature: (J)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_DomainApp_jORTEDomainAppDestroy
- (JNIEnv *, jclass, jint);
+ (JNIEnv *, jclass, jlong);
/*
* Class: org_ocera_orte_DomainApp
* Method: jORTETypeRegisterAdd
- * Signature: (ILjava/lang/String;J)I
+ * Signature: (JLjava/lang/String;J)I
*/
JNIEXPORT jint JNICALL Java_org_ocera_orte_DomainApp_jORTETypeRegisterAdd
- (JNIEnv *, jclass, jint, jstring, jlong);
+ (JNIEnv *, jclass, jlong, jstring, jlong);
/*
* Class: org_ocera_orte_DomainApp
* Method: jORTETypeRegisterDestroyAll
- * Signature: (I)Z
+ * Signature: (J)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_DomainApp_jORTETypeRegisterDestroyAll
- (JNIEnv *, jclass, jint);
+ (JNIEnv *, jclass, jlong);
#ifdef __cplusplus
}
/*
* Class: org_ocera_orte_DomainMgr
* Method: jORTEDomainDefaultMgrCreate
- * Signature: (IZ)I
+ * Signature: (IZ)J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_DomainMgr_jORTEDomainDefaultMgrCreate
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_DomainMgr_jORTEDomainDefaultMgrCreate
(JNIEnv *, jclass, jint, jboolean);
/*
* Class: org_ocera_orte_DomainMgr
* Method: jORTEDomainMgrCreate
- * Signature: (IIIZ)I
+ * Signature: (IJJZ)J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_DomainMgr_jORTEDomainMgrCreate
- (JNIEnv *, jclass, jint, jint, jint, jboolean);
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_DomainMgr_jORTEDomainMgrCreate
+ (JNIEnv *, jclass, jint, jlong, jlong, jboolean);
/*
* Class: org_ocera_orte_DomainMgr
* Method: jORTEDomainMgrDestroy
- * Signature: (I)Z
+ * Signature: (J)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_DomainMgr_jORTEDomainMgrDestroy
- (JNIEnv *, jclass, jint);
+ (JNIEnv *, jclass, jlong);
#ifdef __cplusplus
}
/*
* Class: org_ocera_orte_JOrte
* Method: jORTEAppSendThread
- * Signature: (I)V
+ * Signature: (J)V
*/
JNIEXPORT void JNICALL Java_org_ocera_orte_JOrte_jORTEAppSendThread
- (JNIEnv *, jclass, jint);
+ (JNIEnv *, jclass, jlong);
#ifdef __cplusplus
}
/*
* Class: org_ocera_orte_Publication
* Method: jORTEPublicationCreate
- * Signature: (ILjava/lang/String;Ljava/lang/String;ILjava/nio/ByteBuffer;Lorg/ocera/orte/types/NtpTime;I)I
+ * Signature: (JLjava/lang/String;Ljava/lang/String;ILjava/nio/ByteBuffer;Lorg/ocera/orte/types/NtpTime;I)J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_Publication_jORTEPublicationCreate
- (JNIEnv *, jobject, jint, jstring, jstring, jint, jobject, jobject, jint);
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_Publication_jORTEPublicationCreate
+ (JNIEnv *, jobject, jlong, jstring, jstring, jint, jobject, jobject, jint);
/*
* Class: org_ocera_orte_Publication
* Method: jORTEPublicationDestroy
- * Signature: (I)Z
+ * Signature: (J)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_Publication_jORTEPublicationDestroy
- (JNIEnv *, jobject, jint);
+ (JNIEnv *, jobject, jlong);
/*
* Class: org_ocera_orte_Publication
* Method: jORTEPublicationSend
- * Signature: (ILorg/ocera/orte/types/MessageData;)Z
+ * Signature: (JLorg/ocera/orte/types/MessageData;)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_Publication_jORTEPublicationSend
- (JNIEnv *, jobject, jint, jobject);
+ (JNIEnv *, jobject, jlong, jobject);
/*
* Class: org_ocera_orte_Publication
* Method: jORTEPublicationPropertiesGet
- * Signature: (I)Lorg/ocera/orte/types/PublProp;
+ * Signature: (J)Lorg/ocera/orte/types/PublProp;
*/
JNIEXPORT jobject JNICALL Java_org_ocera_orte_Publication_jORTEPublicationPropertiesGet
- (JNIEnv *, jobject, jint);
+ (JNIEnv *, jobject, jlong);
/*
* Class: org_ocera_orte_Publication
* Method: jORTEPublicationPropertiesSet
- * Signature: (ILorg/ocera/orte/types/PublProp;)Z
+ * Signature: (JLorg/ocera/orte/types/PublProp;)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_Publication_jORTEPublicationPropertiesSet
- (JNIEnv *, jobject, jint, jobject);
+ (JNIEnv *, jobject, jlong, jobject);
/*
* Class: org_ocera_orte_Publication
* Method: jORTEPublicationGetStatus
- * Signature: (I)Lorg/ocera/orte/types/Status;
+ * Signature: (J)Lorg/ocera/orte/types/Status;
*/
JNIEXPORT jobject JNICALL Java_org_ocera_orte_Publication_jORTEPublicationGetStatus
- (JNIEnv *, jobject, jint);
+ (JNIEnv *, jobject, jlong);
/*
* Class: org_ocera_orte_Publication
* Method: jORTEPublicationWaitForSubscriptions
- * Signature: (ILorg/ocera/orte/types/NtpTime;JJ)I
+ * Signature: (JLorg/ocera/orte/types/NtpTime;JJ)I
*/
JNIEXPORT jint JNICALL Java_org_ocera_orte_Publication_jORTEPublicationWaitForSubscriptions
- (JNIEnv *, jobject, jint, jobject, jlong, jlong);
+ (JNIEnv *, jobject, jlong, jobject, jlong, jlong);
#ifdef __cplusplus
}
/*
* Class: org_ocera_orte_Subscription
* Method: jORTESubscriptionCreate
- * Signature: (IIILjava/lang/String;Ljava/lang/String;ILorg/ocera/orte/types/MessageData;Lorg/ocera/orte/types/NtpTime;Lorg/ocera/orte/types/NtpTime;Lorg/ocera/orte/SubscriptionCallback;J)I
+ * Signature: (JIILjava/lang/String;Ljava/lang/String;ILorg/ocera/orte/types/MessageData;Lorg/ocera/orte/types/NtpTime;Lorg/ocera/orte/types/NtpTime;Lorg/ocera/orte/SubscriptionCallback;J)J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionCreate
- (JNIEnv *, jobject, jint, jint, jint, jstring, jstring, jint, jobject, jobject, jobject, jobject, jlong);
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionCreate
+ (JNIEnv *, jobject, jlong, jint, jint, jstring, jstring, jint, jobject, jobject, jobject, jobject, jlong);
/*
* Class: org_ocera_orte_Subscription
* Method: jORTESubscriptionDestroy
- * Signature: (I)Z
+ * Signature: (J)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionDestroy
- (JNIEnv *, jobject, jint);
+ (JNIEnv *, jobject, jlong);
/*
* Class: org_ocera_orte_Subscription
* Method: jORTESubscriptionPropertiesGet
- * Signature: (I)Lorg/ocera/orte/types/SubsProp;
+ * Signature: (J)Lorg/ocera/orte/types/SubsProp;
*/
JNIEXPORT jobject JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionPropertiesGet
- (JNIEnv *, jobject, jint);
+ (JNIEnv *, jobject, jlong);
/*
* Class: org_ocera_orte_Subscription
* Method: jORTESubscriptionPropertiesSet
- * Signature: (ILorg/ocera/orte/types/SubsProp;)Z
+ * Signature: (JLorg/ocera/orte/types/SubsProp;)Z
*/
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionPropertiesSet
- (JNIEnv *, jobject, jint, jobject);
+ (JNIEnv *, jobject, jlong, jobject);
/*
* Class: org_ocera_orte_Subscription
* Method: jORTESubscriptionGetStatus
- * Signature: (I)Lorg/ocera/orte/types/Status;
+ * Signature: (J)Lorg/ocera/orte/types/Status;
*/
JNIEXPORT jobject JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionGetStatus
- (JNIEnv *, jobject, jint);
+ (JNIEnv *, jobject, jlong);
/*
* Class: org_ocera_orte_Subscription
* Method: jORTESubscriptionWaitForPublications
- * Signature: (ILorg/ocera/orte/types/NtpTime;JJ)I
+ * Signature: (JLorg/ocera/orte/types/NtpTime;JJ)I
*/
JNIEXPORT jint JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionWaitForPublications
- (JNIEnv *, jobject, jint, jobject, jlong, jlong);
+ (JNIEnv *, jobject, jlong, jobject, jlong, jlong);
/*
* Class: org_ocera_orte_Subscription
* Method: jORTESubscriptionPull
- * Signature: (I)I
+ * Signature: (J)I
*/
JNIEXPORT jint JNICALL Java_org_ocera_orte_Subscription_jORTESubscriptionPull
- (JNIEnv *, jobject, jint);
+ (JNIEnv *, jobject, jlong);
#ifdef __cplusplus
}
/*
* Class: org_ocera_orte_types_DomainEvents
* Method: jORTEDomainInitEvents
- * Signature: ()I
+ * Signature: ()J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_types_DomainEvents_jORTEDomainInitEvents
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_types_DomainEvents_jORTEDomainInitEvents
(JNIEnv *, jclass);
#ifdef __cplusplus
/*
* Class: org_ocera_orte_types_DomainProp
* Method: jORTEDomainPropDefaultGet
- * Signature: ()I
+ * Signature: ()J
*/
-JNIEXPORT jint JNICALL Java_org_ocera_orte_types_DomainProp_jORTEDomainPropDefaultGet
+JNIEXPORT jlong JNICALL Java_org_ocera_orte_types_DomainProp_jORTEDomainPropDefaultGet
(JNIEnv *, jclass);
#ifdef __cplusplus
}
/* domain fields */
- protected int handle;
+ protected long handle;
public DomainProp props;
public DomainEvents events;
* Get handle of the Application Domain.
* @return Handle of the Application Domain.
*/
- public int getHandle()
+ public long getHandle()
{
return this.handle;
}
* @return
*/
private static native
- void jORTEDomainStart(int dhandle,
+ void jORTEDomainStart(long dhandle,
boolean recvMetatrafficThread,
boolean recvUserDataThread,
boolean sendThread);
* @param domain given domain
* @return addres value (from C environment) of the created domain
*/
- private static native int jORTEDomainDefaultAppCreate(int domain,boolean suspend);
+ private static native long jORTEDomainDefaultAppCreate(int domain,boolean suspend);
/**
*/
private static native
- int jORTEDomainAppCreate(int domain,
- int propHandle,
- int eventsHandle,
+ long jORTEDomainAppCreate(int domain,
+ long propHandle,
+ long eventsHandle,
DomainEvents ev,
boolean suspend);
* @return boolean value, False when some error occures, otherwise True
*/
private static native
- boolean jORTEDomainAppDestroy(int dhandle);
+ boolean jORTEDomainAppDestroy(long dhandle);
/**
* @return
*/
private static native
- int jORTETypeRegisterAdd(int dhandle,
- String typeName,
- long maxlenght);
+ int jORTETypeRegisterAdd(long dhandle,
+ String typeName,
+ long maxlenght);
/**
* @return boolean value, False when some error occures, otherwise True
*/
private static native
- boolean jORTETypeRegisterDestroyAll(int dhandle);
+ boolean jORTETypeRegisterDestroyAll(long dhandle);
-}
-
\ No newline at end of file
+}
\ No newline at end of file
* @return handle of the Manager
**/
private static native
- int jORTEDomainDefaultMgrCreate(int dhandle,boolean suspend);
+ long jORTEDomainDefaultMgrCreate(int dhandle,boolean suspend);
/**
* @return handle of the Manager
**/
private static native
- int jORTEDomainMgrCreate(int dhandle,
- int propsHandle,
- int eventsHandle,
- boolean suspend);
+ long jORTEDomainMgrCreate(int dhandle,
+ long propsHandle,
+ long eventsHandle,
+ boolean suspend);
/**
* jORTEDomainMgrDestroy - destroy manager object
* @return if some error occures return False, otherwise True
**/
private static native
- boolean jORTEDomainMgrDestroy(int dhandle);
+ boolean jORTEDomainMgrDestroy(long dhandle);
}
}
public static
- void appSendThread(int dhandle)
+ void appSendThread(long dhandle)
{
jORTEAppSendThread(dhandle);
}
* @return void
*/
private static native
- void jORTEAppSendThread(int dhandle);
+ void jORTEAppSendThread(long dhandle);
}
public class Publication {
- private int handle;
+ private long handle;
private org.ocera.orte.types.MessageData msgData;
private boolean b;
*
* @return handler of the publication
*/
- public int getHandle()
+ public long getHandle()
{
return this.handle;
}
* ****************************************************************** */
private native
- int jORTEPublicationCreate(int appDomainHandle,
+ long jORTEPublicationCreate(long appDomainHandle,
String topic,
String typeName,
int bufflen,
// NtpTime sendCallBackDelay
private native
- boolean jORTEPublicationDestroy(int publHandle);
+ boolean jORTEPublicationDestroy(long publHandle);
private native
- boolean jORTEPublicationSend(int publHandle,
+ boolean jORTEPublicationSend(long publHandle,
MessageData instance);
private native
- PublProp jORTEPublicationPropertiesGet(int publHandle);
+ PublProp jORTEPublicationPropertiesGet(long publHandle);
private native
- boolean jORTEPublicationPropertiesSet(int publHandle,
+ boolean jORTEPublicationPropertiesSet(long publHandle,
PublProp publProps);
private native
- Status jORTEPublicationGetStatus(int publHandle);
+ Status jORTEPublicationGetStatus(long publHandle);
private native
- int jORTEPublicationWaitForSubscriptions(int publHandle,
+ int jORTEPublicationWaitForSubscriptions(long publHandle,
NtpTime wait,
long retries,
long noSubscription);
public class Subscription {
- private int handle;
- private int callbackContextHandle = 0;
+ private long handle;
+ private long callbackContextHandle = 0;
+
private Domain appDomain;
/**
* Get Subscription's handle.
* @return Handle of the subscription.
*/
- public int getHandle()
+ public long getHandle()
{
return this.handle;
}
* @return ORTE_OK if succesful, ORTE_BAD_HANDLE if bad subscription handle,
* ORTE_TIMEOUT if number of retries has been exhausted.
*/
- public boolean pull(int subsHandle)
+ public boolean pull(long subsHandle)
{
int b = jORTESubscriptionPull(subsHandle);
if (b == ORTEConstant.ORTE_BAD_HANDLE)
* ****************************************************************** */
private native
- int jORTESubscriptionCreate(int appDomainHandle,
- int subsmode, /*! union */
- int substype, /*! union */
- String topic,
- String typeName,
- int bufflength,
- MessageData message,
- NtpTime deadline,
- NtpTime minSeparation,
- SubscriptionCallback cb,
- // recvCallBackParam
- long multicastIPAddress);
+ long jORTESubscriptionCreate(long appDomainHandle,
+ int subsmode, /*! union */
+ int substype, /*! union */
+ String topic,
+ String typeName,
+ int bufflength,
+ MessageData message,
+ NtpTime deadline,
+ NtpTime minSeparation,
+ SubscriptionCallback cb,
+ // recvCallBackParam
+ long multicastIPAddress);
private native
- boolean jORTESubscriptionDestroy(int subsHandle);
+ boolean jORTESubscriptionDestroy(long subsHandle);
private native
- SubsProp jORTESubscriptionPropertiesGet(int subsHandle);
+ SubsProp jORTESubscriptionPropertiesGet(long subsHandle);
private native
- boolean jORTESubscriptionPropertiesSet(int subsHandle, SubsProp subProps);
+ boolean jORTESubscriptionPropertiesSet(long subsHandle, SubsProp subProps);
private native
- Status jORTESubscriptionGetStatus(int subsHandle);
+ Status jORTESubscriptionGetStatus(long subsHandle);
private native
- int jORTESubscriptionWaitForPublications(int subsHandle,
+ int jORTESubscriptionWaitForPublications(long subsHandle,
NtpTime wait,
long retries,
long noPublications);
private native
- int jORTESubscriptionPull(int subsHandle);
+ int jORTESubscriptionPull(long subsHandle);
public class DomainEvents {
/* handler to C struct with default domain properties */
- private int handle = 0;
+ private long handle = 0;
/* load native library 'libjorte.so' */
}
- public int getHandle()
+ public long getHandle()
{
return this.handle;
}
* @return handler to default properties of a domain, NULL if error
*/
private static native
- int jORTEDomainInitEvents();
+ long jORTEDomainInitEvents();
/* handler to C struct with default domain properties */
- public int handle = 0;
+ public long handle = 0;
/**
public static
DomainProp defaultPropsCreate() {
DomainProp prop = new DomainProp();
- int handle = jORTEDomainPropDefaultGet();
+ long handle = jORTEDomainPropDefaultGet();
prop.handle = handle;
return prop;
}
* @return handler to default properties of a domain, NULL if error
*/
private static native
- int jORTEDomainPropDefaultGet();
+ long jORTEDomainPropDefaultGet();
}
// /////////////////////////////////////////////////////////////////////
// create default application domain
// /////////////////////////////////////////////////////////////////////
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_DomainApp_jORTEDomainDefaultAppCreate
(JNIEnv *env, jclass class, jint jdomain, jboolean jsusp)
{
- jint d;
+ jlong d;
#ifdef TEST_STAGE
printf(":c: jsem pred ORTEDomainDefaultAppCreate() \n");
#endif
// call ORTE function
- d = (jint) ORTEDomainAppCreate((int)jdomain,
+ d = (jlong) ORTEDomainAppCreate((int)jdomain,
NULL,
NULL,
(Boolean) jsusp);
// //////////////////////////////////////////////////////////////////////
// create user application domain
// //////////////////////////////////////////////////////////////////////
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_DomainApp_jORTEDomainAppCreate
(JNIEnv *env, jclass cls,
jint jdomain,
- jint propHandle,
- jint eventsHandle,
+ jlong propHandle,
+ jlong eventsHandle,
jobject obj_de,
jboolean jsusp)
{
// jni varibles
JavaVM *jvm;
- jint d;
+ jlong d;
//
ORTEDomainAppEvents *dom_events;
JORTEDomainEventsContext_t *domain_events_cont;
dom_events->onSubDeleteParam = (void *) domain_events_cont;
////////////////////////////////////////////////
// call ORTE function
- d = (jint) ORTEDomainAppCreate((int)jdomain,
+ d = (jlong) ORTEDomainAppCreate((int)jdomain,
(ORTEDomainProp *) propHandle,
(ORTEDomainAppEvents *) eventsHandle,
(Boolean) jsusp);
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_DomainApp_jORTEDomainAppDestroy
-(JNIEnv *env, jclass cls, jint dhandle)
+(JNIEnv *env, jclass cls, jlong dhandle)
{
// check domain handle
if (dhandle == 0)
#include "jorte/org_ocera_orte_types_DomainEvents.h"
#include "jorte/4all.h"
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_types_DomainEvents_jORTEDomainInitEvents
(JNIEnv *env, jclass cls)
{
printf(":c: events initialized.. \n");
#endif
- return ((jint) evs);
+ return ((jlong) evs);
}
/* ****************************** *
* create default manager domain *
* ****************************** */
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_DomainMgr_jORTEDomainDefaultMgrCreate
(JNIEnv *env, jclass cls, jint jdomain, jboolean susp)
{
- jint d;
+ jlong d;
// call ORTE function
- d = (jint) ORTEDomainMgrCreate((int)jdomain,
+ d = (jlong) ORTEDomainMgrCreate((int)jdomain,
NULL,
NULL,
(Boolean) susp);
/* *************************** *
* create user manager domain *
* *************************** */
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_DomainMg_jORTEDomainMgrCreate
-(JNIEnv *env, jclass cls, jint jdomain, jint propHandle,
- jint eventsHandle, jboolean susp)
+(JNIEnv *env, jclass cls, jint jdomain, jlong propHandle,
+ jlong eventsHandle, jboolean susp)
{
- jint d;
+ jlong d;
// call ORTE function
- d = (jint) ORTEDomainMgrCreate((int)jdomain,
- (ORTEDomainProp *) propHandle,
- (ORTEDomainAppEvents *) eventsHandle,
- (Boolean) susp);
+ d = (jlong) ORTEDomainMgrCreate((int)jdomain,
+ (ORTEDomainProp *) propHandle,
+ (ORTEDomainAppEvents *) eventsHandle,
+ (Boolean) susp);
if(d == 0)
{
printf(":!c: creating mgrDomain failed! \n");
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_DomainMgr_jORTEDomainMgrDestroy
-(JNIEnv *env, jclass cls, jint dhandle)
+(JNIEnv *env, jclass cls, jlong dhandle)
{
int8_t b;
#include "jorte/org_ocera_orte_types_DomainProp.h"
#include "jorte/4all.h"
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_types_DomainProp_jORTEDomainPropDefaultGet
(JNIEnv *env, jclass cls)
{
#ifdef TEST_STAGE
printf(":c: default domain properties created.. \n");
#endif
- return ((jint) dprop);
+ return ((jlong) dprop);
}
// ve fci chybi 2 Multicast argumenty - maji se dodat???
JNIEXPORT void JNICALL
Java_org_ocera_orte_Domain_jORTEDomainStart
-(JNIEnv *env, jclass cls, jint dom_handle,
+(JNIEnv *env, jclass cls, jlong dom_handle,
jboolean recvUnicastMetatrafficThread,
jboolean recvUnicastUserDataThread,
jboolean sendThread)
#include <stdlib.h>
// origin orte headers
#include "orte.h"
+#include "orte_all.h"
// pregenerated header
#include "jorte/org_ocera_orte_Publication.h"
#include "jorte/jorte_protos_api.h"
// native method
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationCreate
(JNIEnv *env ,
jobject obj,
- jint dom_handle,
+ jlong dom_handle,
jstring j_topic,
jstring j_type_name,
jint jbufflen,
if(buffer != 0) free(buffer);
return 0;
}
- return ((jint) p);
+ return ((jlong) p);
}
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationDestroy
-(JNIEnv *env, jclass cls, jint pub_handle)
+(JNIEnv *env, jclass cls, jlong pub_handle)
{
int8_t b;
JNIEXPORT jobject JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationGetStatus
-(JNIEnv *env, jobject obj, jint j_appDomain_handle)
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle)
{
// jni types
jclass cls_ps = NULL; // class of PubStatus
JNIEXPORT jobject JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationPropertiesGet
-(JNIEnv *env, jobject obj, jint j_appDomain_handle)
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle)
{
// jni types
jclass cls_pp = NULL; // PublProp class
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationPropertiesSet
-(JNIEnv *env, jobject obj, jint j_appDomain_handle, jobject obj_pp)
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle, jobject obj_pp)
{
// jni types
jclass cls_pp = NULL;
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationSend
-(JNIEnv *env, jobject obj, jint pub_handle, jobject obj_msg)
+(JNIEnv *env, jobject obj, jlong pub_handle, jobject obj_msg)
{
jclass cls;
jobject obj_bb;
JNIEXPORT jint JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationWaitForSubscriptions
-(JNIEnv *env, jobject obj, jint j_appDomain_handle,
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle,
jobject obj_ntpT, jlong jretries, jlong jnoSubscriptions)
{
int i;
/* ****************************************************************** *
* native method *
* ****************************************************************** */
-JNIEXPORT jint JNICALL
+JNIEXPORT jlong JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionCreate
(JNIEnv *env,
jobject obj,
- jint dhandle, // appDomain handle
+ jlong dhandle, // appDomain handle
jint jsmode, // subs mode
jint jstype, // subs type
jstring jtopic, // subs topic
fid = (*env)->GetFieldID(env,
cls,
"callbackContextHandle",
- "I");
+ "J");
if(fid == 0)
{
#ifdef TEST_STAGE
#endif
break;
}
- (*env)->SetIntField(env,
+ (*env)->SetLongField(env,
obj,
fid,
- (int) callback_cont);
+ (jlong) callback_cont);
#ifdef TEST_STAGE
printf(":c: ORTESubscriptionCreate() calling..\n");
#endif
(*env)->ReleaseStringUTFChars(env, jtname, typename);
// returns handle of new created Subscription
if(flag_ok == 0) return 0;
- return ((jint) s);
+ return ((jlong) s);
}
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionDestroy
-(JNIEnv *env, jobject obj, jint subs_handle)
+(JNIEnv *env, jobject obj, jlong subs_handle)
{
int8_t b;
- jint h;
+ jlong h;
jclass cls;
jfieldID fid;
int flag_ok = 0;
fid = (*env)->GetFieldID(env,
cls,
"callbackContextHandle",
- "I");
+ "J");
if(fid == 0)
{
#ifdef TEST_STAGE
break;
}
// get value
- h = (*env)->GetIntField(env, obj, fid);
+ h = (*env)->GetLongField(env, obj, fid);
if(h)
{
//JavaVM *jvm;
JNIEXPORT jobject JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionGetStatus
-(JNIEnv *env, jobject obj, jint j_appDomain_handle)
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle)
{
// jni types
jclass cls_ss = NULL; // class of SubsStatus
JNIEXPORT jobject JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionPropertiesGet
-(JNIEnv *env, jobject obj, jint j_appDomain_handle)
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle)
{
// jni types
jclass cls_sp = NULL; // SubsProp class
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionPropertiesSet
-(JNIEnv *env, jobject obj, jint j_appDomain_handle, jobject obj_sp)
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle, jobject obj_sp)
{
// jni types
jclass cls_sp = NULL;
JNIEXPORT jint JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionWaitForPublications
-(JNIEnv *env, jobject obj, jint j_appDomain_handle,
+(JNIEnv *env, jobject obj, jlong j_appDomain_handle,
jobject obj_ntpT, jlong jretries, jlong jnoPublications)
{
int i;
JNIEXPORT jint JNICALL
Java_org_ocera_orte_DomainApp_jORTETypeRegisterAdd
-(JNIEnv *env, jclass cls, jint handle, jstring jname, jlong jlength)
+(JNIEnv *env, jclass cls, jlong handle, jstring jname, jlong jlength)
{
const char *name;
int b;
// library header file's path
#include "orte.h"
+#include "jorte/4all.h"
// pregenerated header
#include "jorte/org_ocera_orte_DomainApp.h"
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_DomainApp_jORTETypeRegisterDestroyAll
-(JNIEnv *env, jclass cls, jint j_app_domain_handle)
+(JNIEnv *env, jclass cls, jlong j_app_domain_handle)
{
int b;
fieldID = (*env)->GetFieldID(env,ntpTimeClass,"fraction","J");
// if(fieldID == NULL) return(NTPTIME_ZERO(time)); // NEFUNGUJE
/* get object's value */
- time.fraction = (uint32_t) (*env)->GetIntField(env,obj,fieldID);
+ time.fraction = (uint32_t) (*env)->GetLongField(env,obj,fieldID);
return(time);