/* 4all.h */
+
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
/*
typedef struct
{
//#define TEST_STAGE
+#include <jni.h>
+
#ifdef __ANDROID__
#include <android/log.h>
*
*/
-/*
#ifndef _JORTE_H
#define _JORTE_H
-*/
#ifdef __cplusplus
extern "C" {
#endif
-#include "orte.h"
+#include "orte_all.h"
// switch program behaviour (test stage,....)
#include "4all.h"
-// NtpTime
-#include "getNtpTime.h"
-
// new type definitions
-#include "typedefs_defines_jorte.h"
+#include "jorte_typedefs_defines.h"
+
+// JORTE API
+#include "jorte_protos_api.h"
// auto-generated headers by JNI
#include "org_ocera_orte_tools_Conversions.h"
#include "org_ocera_orte_Domain.h"
-#include "org_ocera_orte_DomainEvents.h"
-#include "org_ocera_orte_DomainProp.h"
+#include "org_ocera_orte_DomainApp.h"
+#include "org_ocera_orte_DomainMgr.h"
+#include "org_ocera_orte_types_DomainEvents.h"
+#include "org_ocera_orte_types_DomainProp.h"
+#include "org_ocera_orte_types_NtpTime.h"
#include "org_ocera_orte_tools_GetORTEConstant.h"
#include "org_ocera_orte_JOrte.h"
-#include "org_ocera_orte_Manager.h"
#include "org_ocera_orte_Publication.h"
#include "org_ocera_orte_Subscription.h"
} /* extern "C"*/
#endif
-/*
-#endif // _JORTE_H
-*/
+#endif // _JORTE_H
\ No newline at end of file
/* jorte_typedefs_api.h */
-#include <jni.h>
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#ifndef _JORTE_PROTOS_API_H
+#define _JORTE_PROTOS_API_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+#include <jni.h>
#include "orte.h"
extern int
extern jclass
findClass(JNIEnv *env, const char* name);
+
+#ifdef __cplusplus
+} /* extern "C"*/
+#endif
+
+#endif // _JORTE_PROTOS_API_H
\ No newline at end of file
/* typedefs_defines_jorte.h */
/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
+#include <jni.h>
typedef struct
{
#ifdef _MSC_VER
#include <orte/ew_types.h>
+#elif defined(__ANDROID__) && !defined(OMK_FOR_USER) && !defined(OMK_FOR_KERNEL)
+ #include "orte/orte_config_android.h"
#else
#include <orte/orte_config.h>
#endif
#if defined _MSC_VER
#include "orte/ew_types.h"
+#elif defined(__ANDROID__)
+ #include "orte/orte_config_android.h"
#elif defined(HAVE_CONFIG_H) || defined(OMK_FOR_USER) || defined(OMK_FOR_KERNEL)
#include "orte/orte_config.h"
#else
/* JGetORTEConstant.c */
+
/**
* This code provides conversion between JAVA a C environments.
* The C functions are calling here and results are send to JAVA
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-/* pregenerated header */
-#include "jorte/org_ocera_orte_tools_GetORTEConstant.h"
-/* library header file's path */
-#include "orte.h"
+#include "jorte/jorte.h"
/* macro for comparing 2 strings */
/* if(a==b) -> strcmp = 0 */
/* IPAdressToString.c */
+
/**
* This code provides conversion between JAVA a C environments.
- * The C functions are calling here and results are send to JAVA
- * native functions. It uses the header pregenerated by JAVA
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_tools_Conversions.h"
-
-
+#include "jorte/jorte.h"
/* native function - prototype declared in pregenerated header */
JNIEXPORT jstring JNICALL
/* JNtpTimeToStringMs.c */
+
/**
* This code provides conversion between JAVA a C environments.
* The C functions are calling here and results are send to JAVA
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_types_NtpTime.h"
-
-
+#include "jorte/jorte.h"
/* native function - prototype declared in pregenerated header */
JNIEXPORT jstring JNICALL
/* JNtpTimeToStringUs.c */
+
/**
* This code provides conversion between JAVA a C environments.
* The C functions are calling here and results are send to JAVA
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_types_NtpTime.h"
-
-
+#include "jorte/jorte.h"
/* native function - prototype declared in pregenerated header */
JNIEXPORT jstring JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_DomainApp.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// new data types
-#include "jorte/jorte_typedefs_defines.h"
-#include "jorte/jorte_protos_api.h"
-#include <inttypes.h>
-
+#include "jorte/jorte.h"
// /////////////////////////////////////////////////////////////////////
// create default application domain
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
- * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz
-)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
* @version 0.1
*
*/
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_DomainApp.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_typedefs_defines.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_DomainApp_jORTEDomainAppDestroy
-#include <stdlib.h>
-#include <stdio.h>
-#include <jni.h>
-#include "orte.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_typedefs_defines.h"
-#include "jorte/jorte_protos_api.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
// /////////////////////////////////////////////////////////////////////
// public void onRegFail()
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_types_DomainEvents.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_typedefs_defines.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_types_DomainEvents_jORTEDomainEventsDestroy
(JNIEnv *env, jobject obj, jlong handle)
{
- free((void*)handle);
+ FREE((void*)handle);
#ifdef TEST_STAGE
printf(":c: events destroyed.. \n");
/* JORTEDomainInitEvents.c */
-
/**
* This code provides conversion between JAVA a C environments.
* The C functions are calling here and results are send to JAVA
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
- * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz
-)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
* @version 0.1
*
*/
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_types_DomainEvents.h"
-#include "jorte/4all.h"
+#include "jorte/jorte.h"
JNIEXPORT jlong JNICALL
Java_org_ocera_orte_types_DomainEvents_jORTEDomainInitEvents
ORTEDomainAppEvents *evs;
// memory allocation
- evs = (ORTEDomainAppEvents *) malloc(sizeof(ORTEDomainAppEvents));
+ evs = (ORTEDomainAppEvents *) MALLOC(sizeof(ORTEDomainAppEvents));
if(evs == 0)
{
printf(":!c: evs = NULL [not enough memory] \n");
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_DomainMgr.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_typedefs_defines.h"
-#include "jorte/jorte_protos_api.h"
+#include "jorte/jorte.h"
/* ****************************** *
* create default manager domain *
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
- * @author CTU FEE Prague - Department of Control Engineering (dce.felk
-.cvut.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
* @version 0.1
*
*/
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_DomainMgr.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_typedefs_defines.h"
-
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_DomainMgr_jORTEDomainMgrDestroy
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
- * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz
-)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
* @version 0.1
*/
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_types_DomainProp.h"
-#include "jorte/4all.h"
+#include "jorte/jorte.h"
JNIEXPORT jlong JNICALL
Java_org_ocera_orte_types_DomainProp_jORTEDomainPropDefaultGet
-#include <string.h>
-#include <stdlib.h>
-#include "orte.h"
-#include "jorte/4all.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
-#include "jorte/org_ocera_orte_types_DomainProp.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_types_DomainProp_jORTEDomainPropDestroy
(
-#include <string.h>
-#include <stdlib.h>
-#include "orte.h"
-#include "jorte/4all.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
-#include "jorte/org_ocera_orte_types_DomainProp.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL Java_org_ocera_orte_types_DomainProp_jORTEDomainPropSet
(
/* JORTEDomainStart.c */
-
/**
* This code provides conversion between JAVA a C environments.
* The C functions are calling here and results are send to JAVA
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Domain.h"
-#include "jorte/4all.h"
+#include "jorte/jorte.h"
// ve fci chybi 2 Multicast argumenty - maji se dodat???
JNIEXPORT void JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_JOrte.h"
-#include "jorte/4all.h"
-
+#include "jorte/jorte.h"
JNIEXPORT void JNICALL
Java_org_ocera_orte_JOrte_jORTEInit
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#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"
-#include "jorte/4all.h"
+#include "jorte/jorte.h"
// ### DOCASNE ##################################################################
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <stdlib.h>
-// origin orte headers
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Publication.h"
-#include "jorte/4all.h"
-
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationDestroy
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-// library header file's path
-#include "orte.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Publication.h"
-#include "jorte/jorte_protos_api.h"
-
+#include "jorte/jorte.h"
JNIEXPORT jobject JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationGetStatus
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-// library header file's path
-#include "orte.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-#include "jorte/jorte_protos_api.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Publication.h"
-
+#include "jorte/jorte.h"
JNIEXPORT jobject JNICALL
Java_org_ocera_orte_Publication_jORTEPublicationPropertiesGet
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-#include <inttypes.h>
-// library header file's path
-#include "orte.h"
-// getNtpTime function
-#include "jorte/jorte_protos_api.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Publication.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-#include <stdlib.h>
-// library header file's path
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Publication.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-#include <inttypes.h>
-// library header file's path
-#include "orte.h"
-// getNtpTime function
-#include "jorte/jorte_protos_api.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Publication.h"
+
+#include "jorte/jorte.h"
JNIEXPORT jint JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// origin orte headers
-#include "orte.h"
-/* pregenerated header */
-#include "jorte/org_ocera_orte_JOrte.h"
-#include "jorte/4all.h"
+#include "jorte/jorte.h"
JNIEXPORT void JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-
-#include <stdlib.h>
-#include <inttypes.h>
-
-// library header file's path
-#include "orte_all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Subscription.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// new data types
-#include "jorte/jorte_typedefs_defines.h"
-#include "jorte/jorte_protos_api.h"
+#include "jorte/jorte.h"
/* ****************************************************************** *
* CallBack function *
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-#include <stdlib.h>
-// library header file's path
-#include "orte.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Subscription.h"
-//
-#include "jorte/jorte_typedefs_defines.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionDestroy
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-// library header file's path
-#include "orte.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Subscription.h"
-#include "jorte/jorte_protos_api.h"
+#include "jorte/jorte.h"
JNIEXPORT jobject JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-// library header file's path
-#include "orte.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Subscription.h"
-#include "jorte/jorte_protos_api.h"
+#include "jorte/jorte.h"
JNIEXPORT jobject JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionPropertiesGet
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-#include <inttypes.h>
-// library header file's path
-#include "orte.h"
-// getNtpTime function
-#include "jorte/jorte_protos_api.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Subscription.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
-#include "orte.h"
-#include "jorte/4all.h"
-#include "jorte/org_ocera_orte_Subscription.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
JNIEXPORT jint JNICALL
Java_org_ocera_orte_Subscription_jORTESubscriptionPull
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include <string.h>
-#include <stdlib.h>
-#include <inttypes.h>
-// library header file's path
-#include "orte.h"
-// getNtpTime function
-#include "jorte/jorte_protos_api.h"
-// enable TEST_STAGE run level
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_Subscription.h"
+#include "jorte/jorte.h"
JNIEXPORT jint JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// library header file's path
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_DomainApp.h"
-#include "jorte/4all.h"
+#include "jorte/jorte.h"
JNIEXPORT jint JNICALL
Java_org_ocera_orte_DomainApp_jORTETypeRegisterAdd
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// library header file's path
-#include "orte.h"
-#include "jorte/4all.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_DomainApp.h"
+#include "jorte/jorte.h"
JNIEXPORT jboolean JNICALL
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// library header file's path
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_JOrte.h"
+#include "jorte/jorte.h"
/* native function - prototype declared in pregenerated header */
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*/
-// library header file's path
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_JOrte.h"
+#include "jorte/jorte.h"
/* native function - prototype declared in pregenerated header */
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-
-// library header file's path
-#include "orte.h"
-// pregenerated header
-#include "jorte/org_ocera_orte_tools_Conversions.h"
+#include "jorte/jorte.h"
/* native function - prototype declared in pregenerated header */
/* createAppInfo.c */
-#include <jni.h>
-#include "orte.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_protos_api.h"
-#include <inttypes.h>
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
jobject createAppInfo(JNIEnv *env, const ORTEAppInfo *ainfo)
{
/* createPubInfo.c */
-#include <jni.h>
-#include "orte.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_protos_api.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
jobject createPubInfo(JNIEnv *env, const ORTEPubInfo *pinfo)
{
/* createSubInfo.c */
-#include <jni.h>
-#include "orte.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_protos_api.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
jobject createSubInfo(JNIEnv *env, const ORTESubInfo *sinfo)
{
* (by command 'javah -jni class_with_native_function')
*
* @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
* @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
* @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
* @author dedication to Kj
*
*/
-#include "jorte/jorte_protos_api.h"
-
+#include "jorte/jorte.h"
NtpTime getNtpTime(JNIEnv *env, jobject obj)
{
-#include <stdlib.h>
-#include <jni.h>
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
static jmethodID findClassM;
static jmethodID findLoadedClassM;
/* setRecvInfo.c */
-#include <jni.h>
-#include <inttypes.h>
-#include "orte.h"
-#include "jorte/4all.h"
-#include "jorte/jorte_protos_api.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
int setRecvInfo(JNIEnv *env, const ORTERecvInfo *rinfo, jobject obj)
{
/* setTopic.c */
-#include <jni.h>
-#include "jorte/4all.h"
-#include "jorte/jorte_protos_api.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
int setTopic(JNIEnv *env, jclass cls, jobject obj, const char *topic)
{
/* setType.c */
-#include <jni.h>
-#include "jorte/4all.h"
-#include "jorte/jorte_protos_api.h"
+/**
+ * This code provides conversion between JAVA a C environments.
+ * The C functions are calling here and results are send to JAVA
+ * native functions. It uses the header pregenerated by JAVA
+ * (by command 'javah -jni class_with_native_function')
+ *
+ * @author Lukas Pokorny (lukas_pokorny@centrum.cz)
+ * @author Martin Vajnar (martin.vajnar@gmail.com)
+ * @author CTU FEE Prague - Department of Control Engineering (dce.felk.cvut.cz)
+ * @author Project ORTE - OCERA Real Time Ethernet (www.ocera.org)
+ * @author dedication to Kj
+ * @version 0.1
+ *
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ */
+
+#include "jorte/jorte.h"
int setType(JNIEnv *env, jclass cls, jobject obj, const char *typeName)
{