@ramcna/capacitor-ephemeris 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Package.swift +28 -0
- package/README.md +127 -0
- package/RamcnaCapacitorEphemeris.podspec +17 -0
- package/android/build.gradle +77 -0
- package/android/src/main/AndroidManifest.xml +2 -0
- package/android/src/main/cpp/CMakeLists.txt +41 -0
- package/android/src/main/cpp/cJSON/cJSON.c +3191 -0
- package/android/src/main/cpp/cJSON/cJSON.h +306 -0
- package/android/src/main/cpp/swe-bridge.cpp +151 -0
- package/android/src/main/cpp/swejni/LICENSE +52 -0
- package/android/src/main/cpp/swejni/LICENSE.TXT +52 -0
- package/android/src/main/cpp/swejni/ephemeris_jni.c +177 -0
- package/android/src/main/cpp/swejni/sefstars.txt +1602 -0
- package/android/src/main/cpp/swejni/seleapsec.txt +6 -0
- package/android/src/main/cpp/swejni/seorbel.txt +97 -0
- package/android/src/main/cpp/swejni/swecl.c +6428 -0
- package/android/src/main/cpp/swejni/swedate.c +588 -0
- package/android/src/main/cpp/swejni/swedate.h +81 -0
- package/android/src/main/cpp/swejni/swehel.c +3511 -0
- package/android/src/main/cpp/swejni/swehouse.c +3143 -0
- package/android/src/main/cpp/swejni/swehouse.h +98 -0
- package/android/src/main/cpp/swejni/swejni.c +2057 -0
- package/android/src/main/cpp/swejni/swejni.h +757 -0
- package/android/src/main/cpp/swejni/swejpl.c +958 -0
- package/android/src/main/cpp/swejni/swejpl.h +103 -0
- package/android/src/main/cpp/swejni/swemmoon.c +1930 -0
- package/android/src/main/cpp/swejni/swemplan.c +967 -0
- package/android/src/main/cpp/swejni/swemptab.h +10640 -0
- package/android/src/main/cpp/swejni/swenut2000a.h +2819 -0
- package/android/src/main/cpp/swejni/sweodef.h +326 -0
- package/android/src/main/cpp/swejni/sweph.c +8614 -0
- package/android/src/main/cpp/swejni/sweph.h +849 -0
- package/android/src/main/cpp/swejni/swephexp.h +1020 -0
- package/android/src/main/cpp/swejni/swephlib.c +4634 -0
- package/android/src/main/cpp/swejni/swephlib.h +189 -0
- package/android/src/main/java/com/vedichoroo/ephemeris/CapacitorEphemerisPlugin.java +182 -0
- package/android/src/main/res/.gitkeep +0 -0
- package/dist/docs.json +147 -0
- package/dist/esm/definitions.d.ts +42 -0
- package/dist/esm/definitions.js +2 -0
- package/dist/esm/definitions.js.map +1 -0
- package/dist/esm/index.d.ts +4 -0
- package/dist/esm/index.js +7 -0
- package/dist/esm/index.js.map +1 -0
- package/dist/esm/web.d.ts +31 -0
- package/dist/esm/web.js +28 -0
- package/dist/esm/web.js.map +1 -0
- package/dist/plugin.cjs.js +42 -0
- package/dist/plugin.cjs.js.map +1 -0
- package/dist/plugin.js +45 -0
- package/dist/plugin.js.map +1 -0
- package/ios/Sources/CapacitorEphemerisPluginPlugin/CapacitorEphemerisPlugin.swift +8 -0
- package/ios/Sources/CapacitorEphemerisPluginPlugin/CapacitorEphemerisPluginImplementation.swift +52 -0
- package/ios/Sources/CapacitorEphemerisPluginPlugin/CapacitorEphemerisPluginPlugin.swift +82 -0
- package/ios/Tests/CapacitorEphemerisPluginPluginTests/CapacitorEphemerisPluginTests.swift +15 -0
- package/package.json +81 -0
|
@@ -0,0 +1,2057 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Author Yura Krymlov
|
|
3
|
+
* Created 2021-02
|
|
4
|
+
* Version 2.10.03
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
#include "swephexp.h"
|
|
8
|
+
#include "swejni.h"
|
|
9
|
+
|
|
10
|
+
#define JNI_RELEASE (ERR >= retc ? JNI_ABORT : JNI_OK)
|
|
11
|
+
|
|
12
|
+
#define DEFINE_CHAR_SERR char serr[AS_MAXCH];
|
|
13
|
+
#define ERR_BUILDER_APPEND_IF_ERR if (ERR >= retc && NULL != errBuilder) appendToBuilder(env, serr, errBuilder);
|
|
14
|
+
#define ERR_BUILDER_APPEND_IF_SERR if (*serr != '\0' && NULL != errBuilder) appendToBuilder(env, serr, errBuilder);
|
|
15
|
+
|
|
16
|
+
#define GET_DOUBLE_ARRAY_ELEMENTS(IS_COPY, JDOUBLE_ARRAY, ELEMENTS)\
|
|
17
|
+
jboolean IS_COPY = JNI_FALSE; \
|
|
18
|
+
jdouble* ELEMENTS = (NULL != JDOUBLE_ARRAY) ? (*env)->GetDoubleArrayElements(env, JDOUBLE_ARRAY, &IS_COPY) : NULL;
|
|
19
|
+
|
|
20
|
+
#define RLZ_DOUBLE_ARRAY_ELEMENTS_OK(IS_COPY, JDOUBLE_ARRAY, ELEMENTS)\
|
|
21
|
+
if (JNI_TRUE == IS_COPY && NULL != JDOUBLE_ARRAY) (*env)->ReleaseDoubleArrayElements(env, JDOUBLE_ARRAY, ELEMENTS, JNI_OK);
|
|
22
|
+
|
|
23
|
+
#define RLZ_DOUBLE_ARRAY_ELEMENTS(IS_COPY, JDOUBLE_ARRAY, ELEMENTS)\
|
|
24
|
+
if (JNI_TRUE == IS_COPY && NULL != JDOUBLE_ARRAY) (*env)->ReleaseDoubleArrayElements(env, JDOUBLE_ARRAY, ELEMENTS, JNI_RELEASE);
|
|
25
|
+
|
|
26
|
+
#define GET_INT_ARRAY_ELEMENTS(IS_COPY, JINT_ARRAY, ELEMENTS) \
|
|
27
|
+
jboolean IS_COPY = JNI_FALSE; \
|
|
28
|
+
jint * ELEMENTS = (NULL != JINT_ARRAY) ? (*env)->GetIntArrayElements(env, JINT_ARRAY, &IS_COPY) : NULL;
|
|
29
|
+
|
|
30
|
+
#define RLZ_INT_ARRAY_ELEMENTS_OK(IS_COPY, JINT_ARRAY, ELEMENTS)\
|
|
31
|
+
if (JNI_TRUE == IS_COPY && NULL != JINT_ARRAY) (*env)->ReleaseIntArrayElements(env, JINT_ARRAY, ELEMENTS, JNI_OK);
|
|
32
|
+
|
|
33
|
+
#define GET_STRING_UTF_CHARS(IS_COPY, JSTRING, CCSTRING)\
|
|
34
|
+
jboolean IS_COPY = JNI_FALSE; \
|
|
35
|
+
const char* CCSTRING = (NULL != JSTRING) ? (*env)->GetStringUTFChars(env, JSTRING, &IS_COPY) : NULL;
|
|
36
|
+
|
|
37
|
+
#define RLZ_STRING_UTF_CHARS(IS_COPY, JSTRING, CCSTRING)\
|
|
38
|
+
if (JNI_TRUE == IS_COPY && NULL != JSTRING) (*env)->ReleaseStringUTFChars(env, JSTRING, CCSTRING);
|
|
39
|
+
|
|
40
|
+
#define CPY_CSTRING_TO_CHARS(CCSTRING, CHARS) \
|
|
41
|
+
char CHARS[AS_MAXCH]; \
|
|
42
|
+
if (NULL == CCSTRING) *CHARS = '\0'; \
|
|
43
|
+
else strcpy(CHARS, CCSTRING);
|
|
44
|
+
|
|
45
|
+
#define BUILDER_APPEND_IF_DIFF(BUILDER, CCSTRING, CHARS) \
|
|
46
|
+
if (NULL != BUILDER && NULL != CCSTRING && 0 != strcmp(CCSTRING, CHARS)) { \
|
|
47
|
+
emptyBuilder(env, BUILDER); \
|
|
48
|
+
appendToBuilder(env, CHARS, BUILDER); \
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/*
|
|
52
|
+
* JNIEXPORT void JNICALL Java_package_class_method
|
|
53
|
+
* (JNIEnv *env, jclass clazz, jdoubleArray dblArray) {
|
|
54
|
+
* // The isArrayCopy variable boolean indicates whether
|
|
55
|
+
* // the copy of the primitive elements was a copy or not.
|
|
56
|
+
* jboolean isArrayCopy;
|
|
57
|
+
*
|
|
58
|
+
* // If it is a copy, one must remember to free it before returning.
|
|
59
|
+
* jdouble* dblElements = (*env)->GetDoubleArrayElements(env, dblArray, &isArrayCopy);
|
|
60
|
+
*
|
|
61
|
+
* // Also, if we made any changes to the array, we must copy it back to
|
|
62
|
+
* // the original one so that the changes are reflected in the original.
|
|
63
|
+
* // This is the purpose of the ReleaseDoubleArrayElements call.
|
|
64
|
+
* if (isArrayCopy == JNI_TRUE) (*env)->ReleaseDoubleArrayElements(env, dblArray, dblElements, JNI_OK);
|
|
65
|
+
*
|
|
66
|
+
* Release Modes:
|
|
67
|
+
* JNI_OK Copy the contents of the buffer back into array and free the buffer
|
|
68
|
+
* JNI_ABORT Free the buffer without copying back any changes
|
|
69
|
+
* JNI_COMMIT Copy the contents of the buffer back into array but do not free buffer
|
|
70
|
+
* }
|
|
71
|
+
*/
|
|
72
|
+
|
|
73
|
+
jstring getBuilderString(JNIEnv *env, jobject builder) {
|
|
74
|
+
if (NULL == builder) return NULL;
|
|
75
|
+
|
|
76
|
+
// Obtain the Java StringBuilder class handle
|
|
77
|
+
jclass clazz = (*env)->GetObjectClass(env, builder);
|
|
78
|
+
|
|
79
|
+
// Obtain the method ID for the StringBuilder toString method
|
|
80
|
+
jmethodID mid = (*env)->GetMethodID(env, clazz, "toString", "()Ljava/lang/String;");
|
|
81
|
+
|
|
82
|
+
// If this method does not exist then return.
|
|
83
|
+
if (mid == 0) return NULL;
|
|
84
|
+
|
|
85
|
+
// Call the StringBuilder object's toString method
|
|
86
|
+
return (*env)->CallObjectMethod(env, builder, mid);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
void emptyBuilder(JNIEnv *env, jobject builder) {
|
|
90
|
+
if (NULL == builder) return;
|
|
91
|
+
|
|
92
|
+
// Obtain the Java StringBuilder class handle
|
|
93
|
+
jclass clazz = (*env)->GetObjectClass(env, builder);
|
|
94
|
+
|
|
95
|
+
// Obtain the method ID for the StringBuilder setLength method
|
|
96
|
+
jmethodID mid = (*env)->GetMethodID(env, clazz, "setLength", "(I)V");
|
|
97
|
+
|
|
98
|
+
// If this method does not exist then return.
|
|
99
|
+
if (mid == 0) return;
|
|
100
|
+
|
|
101
|
+
// Call the StringBuilder object's setLength method
|
|
102
|
+
(*env)->CallVoidMethod(env, builder, mid, 0);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
void appendToBuilder(JNIEnv *env, char *chArray, jobject builder) {
|
|
106
|
+
if (NULL == builder) return;
|
|
107
|
+
|
|
108
|
+
// Obtain the Java StringBuilder class handle
|
|
109
|
+
jclass clazz = (*env)->GetObjectClass(env, builder);
|
|
110
|
+
|
|
111
|
+
// Obtain the method ID for the StringBuilder append method
|
|
112
|
+
jmethodID mid = (*env)->GetMethodID(env, clazz, "append", "(Ljava/lang/String;)Ljava/lang/StringBuilder;");
|
|
113
|
+
|
|
114
|
+
// If this method does not exist then return.
|
|
115
|
+
if (mid == 0) return;
|
|
116
|
+
|
|
117
|
+
// Create a new Java String object for the given char Array
|
|
118
|
+
jstring jArray = (*env)->NewStringUTF(env, chArray);
|
|
119
|
+
|
|
120
|
+
// Call the StringBuilder object's append method
|
|
121
|
+
(*env)->CallObjectMethod(env, builder, mid, jArray);
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
/*
|
|
125
|
+
* int32 swe_heliacal_ut(double tjdstart_ut, double *geopos, double *datm, double *dobs,
|
|
126
|
+
* char *ObjectName, int32 TypeEvent, int32 iflag, double *dret, char *serr)
|
|
127
|
+
*
|
|
128
|
+
* Class: swisseph_SwephExp
|
|
129
|
+
* Method: swe_heliacal_ut
|
|
130
|
+
* Signature: (D[D[D[DLjava/lang/String;II[DLjava/lang/StringBuilder;)I
|
|
131
|
+
*/
|
|
132
|
+
JNIEXPORT jint JNICALL
|
|
133
|
+
Java_swisseph_SwephExp_swe_1heliacal_1ut(JNIEnv *env, jclass swephexp,
|
|
134
|
+
jdouble tjdstart_ut, jdoubleArray geoposArray, jdoubleArray datmArray,
|
|
135
|
+
jdoubleArray dobsArray, jstring objectName, jint typeEvent, jint iflag,
|
|
136
|
+
jdoubleArray dretArray, jobject errBuilder) {
|
|
137
|
+
DEFINE_CHAR_SERR
|
|
138
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
139
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
140
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
141
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
142
|
+
|
|
143
|
+
GET_STRING_UTF_CHARS(isCopy, objectName, objName)
|
|
144
|
+
CPY_CSTRING_TO_CHARS(objName, objectNameIn)
|
|
145
|
+
|
|
146
|
+
int32 retc = swe_heliacal_ut(tjdstart_ut, geopos, datm, dobs, objectNameIn,
|
|
147
|
+
typeEvent, iflag, dret, serr);
|
|
148
|
+
|
|
149
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
150
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
151
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
152
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
153
|
+
RLZ_STRING_UTF_CHARS(isCopy, objectName, objName)
|
|
154
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
155
|
+
return retc;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/*
|
|
159
|
+
* int32 swe_heliacal_pheno_ut(double tjd_ut, double *geopos, double *datm, double *dobs,
|
|
160
|
+
* char *ObjectName, int32 TypeEvent, int32 helflag, double *darr, char *serr)
|
|
161
|
+
*
|
|
162
|
+
* Class: swisseph_SwephExp
|
|
163
|
+
* Method: swe_heliacal_pheno_ut
|
|
164
|
+
* Signature: (D[D[D[DLjava/lang/String;II[DLjava/lang/StringBuilder;)I
|
|
165
|
+
*/
|
|
166
|
+
JNIEXPORT jint JNICALL
|
|
167
|
+
Java_swisseph_SwephExp_swe_1heliacal_1pheno_1ut(JNIEnv *env, jclass swephexp,
|
|
168
|
+
jdouble tjd_ut, jdoubleArray geoposArray,
|
|
169
|
+
jdoubleArray datmArray, jdoubleArray dobsArray,
|
|
170
|
+
jstring objectName, jint typeEvent, jint helflag,
|
|
171
|
+
jdoubleArray darrArray, jobject errBuilder) {
|
|
172
|
+
DEFINE_CHAR_SERR
|
|
173
|
+
|
|
174
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
175
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
176
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
177
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, darrArray, darr)
|
|
178
|
+
|
|
179
|
+
GET_STRING_UTF_CHARS(isCopy, objectName, objName)
|
|
180
|
+
CPY_CSTRING_TO_CHARS(objName, objectNameIn)
|
|
181
|
+
|
|
182
|
+
int32 retc = swe_heliacal_pheno_ut(tjd_ut, geopos, datm, dobs, objectNameIn, typeEvent, helflag, darr, serr);
|
|
183
|
+
|
|
184
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
185
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
186
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
187
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, darrArray, darr)
|
|
188
|
+
RLZ_STRING_UTF_CHARS(isCopy, objectName, objName)
|
|
189
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
190
|
+
return retc;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
/*
|
|
194
|
+
* int32 swe_vis_limit_mag(double tjdut, double *geopos, double *datm, double *dobs,
|
|
195
|
+
* char *ObjectName, int32 helflag, double *dret, char *serr)
|
|
196
|
+
*
|
|
197
|
+
* Class: swisseph_SwephExp
|
|
198
|
+
* Method: swe_vis_limit_mag
|
|
199
|
+
* Signature: (D[D[D[DLjava/lang/StringBuilder;I[DLjava/lang/StringBuilder;)I
|
|
200
|
+
*/
|
|
201
|
+
JNIEXPORT jint JNICALL
|
|
202
|
+
Java_swisseph_SwephExp_swe_1vis_1limit_1mag(JNIEnv *env, jclass swephexp,
|
|
203
|
+
jdouble tjdut, jdoubleArray geoposArray, jdoubleArray datmArray,
|
|
204
|
+
jdoubleArray dobsArray, jobject objectNameBuilder, jint helflag,
|
|
205
|
+
jdoubleArray dretArray, jobject errBuilder) {
|
|
206
|
+
DEFINE_CHAR_SERR
|
|
207
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
208
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
209
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
210
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
211
|
+
|
|
212
|
+
jstring objectName = getBuilderString(env, objectNameBuilder);
|
|
213
|
+
GET_STRING_UTF_CHARS(isCopy, objectName, objectname)
|
|
214
|
+
CPY_CSTRING_TO_CHARS(objectname, object_name)
|
|
215
|
+
|
|
216
|
+
int32 retc = swe_vis_limit_mag(tjdut, geopos, datm, dobs, object_name, helflag, dret, serr);
|
|
217
|
+
|
|
218
|
+
BUILDER_APPEND_IF_DIFF(objectNameBuilder, objectname, object_name)
|
|
219
|
+
|
|
220
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
221
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
222
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
223
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
224
|
+
RLZ_STRING_UTF_CHARS(isCopy, objectName, objectname)
|
|
225
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
226
|
+
return retc;
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
/*
|
|
230
|
+
* int32 swe_heliacal_angle(double tjdut, double *dgeo, double *datm, double *dobs,
|
|
231
|
+
* int32 helflag, double mag, double azi_obj, double azi_sun, double azi_moon,
|
|
232
|
+
* double alt_moon, double *dret, char *serr);
|
|
233
|
+
*
|
|
234
|
+
* Class: swisseph_SwephExp
|
|
235
|
+
* Method: swe_heliacal_angle
|
|
236
|
+
* Signature: (D[D[D[DIDDDDD[DLjava/lang/StringBuilder;)I
|
|
237
|
+
*/
|
|
238
|
+
JNIEXPORT jint JNICALL
|
|
239
|
+
Java_swisseph_SwephExp_swe_1heliacal_1angle(JNIEnv *env, jclass swephexp,
|
|
240
|
+
jdouble tjdut, jdoubleArray dgeoArray,
|
|
241
|
+
jdoubleArray datmArray, jdoubleArray dobsArray, jint helflag,
|
|
242
|
+
jdouble mag, jdouble azi_obj, jdouble azi_sun, jdouble azi_moon,
|
|
243
|
+
jdouble alt_moon, jdoubleArray dretArray, jobject errBuilder) {
|
|
244
|
+
DEFINE_CHAR_SERR
|
|
245
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, dgeoArray, dgeo)
|
|
246
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
247
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
248
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
249
|
+
|
|
250
|
+
int32 retc = swe_heliacal_angle(tjdut, dgeo, datm, dobs,helflag, mag, azi_obj,
|
|
251
|
+
azi_sun, azi_moon,alt_moon, dret, serr);
|
|
252
|
+
|
|
253
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, dgeoArray, dgeo)
|
|
254
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
255
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
256
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
257
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
258
|
+
return retc;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
/*
|
|
262
|
+
* int32 swe_topo_arcus_visionis(double tjdut, double *dgeo, double *datm, double *dobs,
|
|
263
|
+
* int32 helflag, double mag, double azi_obj, double alt_obj, double azi_sun,
|
|
264
|
+
* double azi_moon, double alt_moon, double *dret, char *serr);
|
|
265
|
+
*
|
|
266
|
+
* Class: swisseph_SwephExp
|
|
267
|
+
* Method: swe_topo_arcus_visionis
|
|
268
|
+
* Signature: (D[D[D[DIDDDDDD[DLjava/lang/StringBuilder;)I
|
|
269
|
+
*/
|
|
270
|
+
JNIEXPORT jint JNICALL
|
|
271
|
+
Java_swisseph_SwephExp_swe_1topo_1arcus_1visionis(JNIEnv *env, jclass swephexp,
|
|
272
|
+
jdouble tjdut, jdoubleArray dgeoArray,
|
|
273
|
+
jdoubleArray datmArray, jdoubleArray dobsArray,
|
|
274
|
+
jint helflag, jdouble mag, jdouble azi_obj, jdouble alt_obj,
|
|
275
|
+
jdouble azi_sun, jdouble azi_moon, jdouble alt_moon,
|
|
276
|
+
jdoubleArray dretArray, jobject errBuilder) {
|
|
277
|
+
DEFINE_CHAR_SERR
|
|
278
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, dgeoArray, dgeo)
|
|
279
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
280
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
281
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
282
|
+
|
|
283
|
+
int32 retc = swe_topo_arcus_visionis(tjdut, dgeo, datm, dobs,helflag, mag, azi_obj,
|
|
284
|
+
alt_obj, azi_sun,azi_moon, alt_moon, dret, serr);
|
|
285
|
+
|
|
286
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, dgeoArray, dgeo)
|
|
287
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, datmArray, datm)
|
|
288
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, dobsArray, dobs)
|
|
289
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, dretArray, dret)
|
|
290
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
291
|
+
return retc;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
/*
|
|
295
|
+
* void swe_set_astro_models(char *samod, int32 iflag)
|
|
296
|
+
*
|
|
297
|
+
* Class: swisseph_SwephExp
|
|
298
|
+
* Method: swe_set_astro_models
|
|
299
|
+
* Signature: (Ljava/lang/StringBuilder;I)V
|
|
300
|
+
*/
|
|
301
|
+
JNIEXPORT void JNICALL
|
|
302
|
+
Java_swisseph_SwephExp_swe_1set_1astro_1models(JNIEnv *env, jclass swephexp,
|
|
303
|
+
jobject samodBuilder, jint iflag) {
|
|
304
|
+
jstring samodObject = getBuilderString(env, samodBuilder);
|
|
305
|
+
GET_STRING_UTF_CHARS(isCopy, samodObject, samodobject)
|
|
306
|
+
CPY_CSTRING_TO_CHARS(samodobject, samod_object)
|
|
307
|
+
|
|
308
|
+
swe_set_astro_models(samod_object, iflag);
|
|
309
|
+
|
|
310
|
+
BUILDER_APPEND_IF_DIFF(samodBuilder, samodobject, samod_object)
|
|
311
|
+
RLZ_STRING_UTF_CHARS(isCopy, samodObject, samodobject)
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
/*
|
|
315
|
+
* void swe_get_astro_models(char *samod, char *sdet, int32 iflag)
|
|
316
|
+
*
|
|
317
|
+
* Class: swisseph_SwephExp
|
|
318
|
+
* Method: swe_get_astro_models
|
|
319
|
+
* Signature: (Ljava/lang/StringBuilder;Ljava/lang/StringBuilder;I)V
|
|
320
|
+
*/
|
|
321
|
+
JNIEXPORT void JNICALL
|
|
322
|
+
Java_swisseph_SwephExp_swe_1get_1astro_1models(JNIEnv *env, jclass swephexp,
|
|
323
|
+
jobject samodBuilder, jobject sdetBuilder, jint iflag) {
|
|
324
|
+
jstring samodObject = getBuilderString(env, samodBuilder);
|
|
325
|
+
GET_STRING_UTF_CHARS(isCopy1, samodObject, samodobject)
|
|
326
|
+
CPY_CSTRING_TO_CHARS(samodobject, samod_object)
|
|
327
|
+
|
|
328
|
+
jstring sdetObject = getBuilderString(env, sdetBuilder);
|
|
329
|
+
GET_STRING_UTF_CHARS(isCopy2, sdetObject, sdetobject)
|
|
330
|
+
CPY_CSTRING_TO_CHARS(sdetobject, sdet_object)
|
|
331
|
+
|
|
332
|
+
swe_get_astro_models(samod_object, sdet_object, iflag);
|
|
333
|
+
|
|
334
|
+
BUILDER_APPEND_IF_DIFF(samodBuilder, samodobject, samod_object)
|
|
335
|
+
BUILDER_APPEND_IF_DIFF(sdetBuilder, sdetobject, sdet_object)
|
|
336
|
+
|
|
337
|
+
RLZ_STRING_UTF_CHARS(isCopy1, samodObject, samodobject)
|
|
338
|
+
RLZ_STRING_UTF_CHARS(isCopy2, sdetObject, sdetobject)
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
/*
|
|
342
|
+
* char* swe_version(char *)
|
|
343
|
+
*
|
|
344
|
+
* Class: swisseph_SwephExp
|
|
345
|
+
* Method: swe_version
|
|
346
|
+
* Signature: ()Ljava/lang/String;
|
|
347
|
+
*/
|
|
348
|
+
JNIEXPORT jstring JNICALL
|
|
349
|
+
Java_swisseph_SwephExp_swe_1version(JNIEnv *env, jclass swephexp) {
|
|
350
|
+
char s[AS_MAXCH];
|
|
351
|
+
return (*env)->NewStringUTF(env, swe_version(s));
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
/*
|
|
355
|
+
* char * swe_get_library_path(char *)
|
|
356
|
+
*
|
|
357
|
+
* Class: swisseph_SwephExp
|
|
358
|
+
* Method: swe_get_library_path
|
|
359
|
+
* Signature: ()Ljava/lang/String;
|
|
360
|
+
*/
|
|
361
|
+
JNIEXPORT jstring JNICALL
|
|
362
|
+
Java_swisseph_SwephExp_swe_1get_1library_1path(JNIEnv *env, jclass swephexp) {
|
|
363
|
+
char s[AS_MAXCH];
|
|
364
|
+
return (*env)->NewStringUTF(env, swe_get_library_path(s));
|
|
365
|
+
}
|
|
366
|
+
|
|
367
|
+
/*
|
|
368
|
+
* int swe_calc(double tjd, int ipl, int32 iflag, double *xx, char *serr)
|
|
369
|
+
*
|
|
370
|
+
* Class: swisseph_SwephExp
|
|
371
|
+
* Method: swe_calc
|
|
372
|
+
* Signature: (DII[DLjava/lang/StringBuilder;)I
|
|
373
|
+
*/
|
|
374
|
+
JNIEXPORT jint JNICALL
|
|
375
|
+
Java_swisseph_SwephExp_swe_1calc(JNIEnv *env, jclass swephexp, jdouble tjd, jint ipl,
|
|
376
|
+
jint iflag, jdoubleArray xxArray, jobject errBuilder) {
|
|
377
|
+
DEFINE_CHAR_SERR
|
|
378
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, xxArray, xx)
|
|
379
|
+
|
|
380
|
+
int32 retc = swe_calc(tjd, ipl, iflag, xx, serr);
|
|
381
|
+
|
|
382
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, xxArray, xx)
|
|
383
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
384
|
+
return retc;
|
|
385
|
+
}
|
|
386
|
+
|
|
387
|
+
/*
|
|
388
|
+
* Class: swisseph_SwephExp
|
|
389
|
+
* Method: swe_calc_ut
|
|
390
|
+
* Signature: (DII[DLjava/lang/StringBuilder;)I
|
|
391
|
+
*/
|
|
392
|
+
JNIEXPORT jint JNICALL
|
|
393
|
+
Java_swisseph_SwephExp_swe_1calc_1ut(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint ipl,
|
|
394
|
+
jint iflag, jdoubleArray xxArray, jobject errBuilder) {
|
|
395
|
+
|
|
396
|
+
DEFINE_CHAR_SERR
|
|
397
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, xxArray, xx)
|
|
398
|
+
|
|
399
|
+
int32 retc = swe_calc_ut(tjd_ut, ipl, iflag, xx, serr);
|
|
400
|
+
|
|
401
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, xxArray, xx)
|
|
402
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
403
|
+
return retc;
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
/*
|
|
407
|
+
* int32 swe_calc_pctr(double tjd, int32 ipl, int32 iplctr, int32 iflag, double *xxret, char *serr)
|
|
408
|
+
*
|
|
409
|
+
* Class: swisseph_SwephExp
|
|
410
|
+
* Method: swe_calc_pctr
|
|
411
|
+
* Signature: (DIII[DLjava/lang/StringBuilder;)I
|
|
412
|
+
*/
|
|
413
|
+
JNIEXPORT jint JNICALL
|
|
414
|
+
Java_swisseph_SwephExp_swe_1calc_1pctr(JNIEnv *env, jclass swephexp, jdouble tjd, jint ipl,
|
|
415
|
+
jint iplctr, jint iflag, jdoubleArray xxretArray, jobject errBuilder) {
|
|
416
|
+
DEFINE_CHAR_SERR
|
|
417
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, xxretArray, xxret)
|
|
418
|
+
|
|
419
|
+
int32 retc = swe_calc_pctr(tjd, ipl, iplctr, iflag, xxret, serr);
|
|
420
|
+
|
|
421
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, xxretArray, xxret)
|
|
422
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
423
|
+
return retc;
|
|
424
|
+
}
|
|
425
|
+
|
|
426
|
+
/*
|
|
427
|
+
* int32 swe_fixstar(char *star, double tjd, int32 iflag,double *xx,char *serr)
|
|
428
|
+
*
|
|
429
|
+
* Class: swisseph_SwephExp
|
|
430
|
+
* Method: swe_fixstar
|
|
431
|
+
* Signature: (Ljava/lang/StringBuilder;DI[DLjava/lang/StringBuilder;)I
|
|
432
|
+
*/
|
|
433
|
+
JNIEXPORT jint JNICALL
|
|
434
|
+
Java_swisseph_SwephExp_swe_1fixstar(JNIEnv *env, jclass swephexp, jobject starNameBuilder, jdouble tjd,
|
|
435
|
+
jint iflag, jdoubleArray xxArray, jobject errBuilder) {
|
|
436
|
+
DEFINE_CHAR_SERR
|
|
437
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
438
|
+
|
|
439
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
440
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
441
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
442
|
+
|
|
443
|
+
int32 retc = swe_fixstar(star_name, tjd, iflag, xx, serr);
|
|
444
|
+
|
|
445
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
446
|
+
|
|
447
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
448
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
449
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
450
|
+
return retc;
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
/*
|
|
454
|
+
* int32 swe_fixstar_ut(char *star, double tjd_ut, int32 iflag, double *xx, char *serr)
|
|
455
|
+
*
|
|
456
|
+
* Class: swisseph_SwephExp
|
|
457
|
+
* Method: swe_fixstar_ut
|
|
458
|
+
* Signature: (Ljava/lang/StringBuilder;DI[DLjava/lang/StringBuilder;)I
|
|
459
|
+
*/
|
|
460
|
+
JNIEXPORT jint JNICALL
|
|
461
|
+
Java_swisseph_SwephExp_swe_1fixstar_1ut(JNIEnv *env, jclass swephexp, jobject starNameBuilder, jdouble tjd_ut,
|
|
462
|
+
jint iflag, jdoubleArray xxArray, jobject errBuilder) {
|
|
463
|
+
DEFINE_CHAR_SERR
|
|
464
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
465
|
+
|
|
466
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
467
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
468
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
469
|
+
|
|
470
|
+
int32 retc = swe_fixstar_ut(star_name, tjd_ut, iflag, xx, serr);
|
|
471
|
+
|
|
472
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
473
|
+
|
|
474
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
475
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
476
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
477
|
+
return retc;
|
|
478
|
+
}
|
|
479
|
+
|
|
480
|
+
/*
|
|
481
|
+
* int32 swe_fixstar_mag(char *star, double *mag, char *serr)
|
|
482
|
+
*
|
|
483
|
+
* Class: swisseph_SwephExp
|
|
484
|
+
* Method: swe_fixstar_mag
|
|
485
|
+
* Signature: (Ljava/lang/StringBuilder;[DLjava/lang/StringBuilder;)I
|
|
486
|
+
*/
|
|
487
|
+
JNIEXPORT jint JNICALL
|
|
488
|
+
Java_swisseph_SwephExp_swe_1fixstar_1mag(JNIEnv *env, jclass swephexp, jobject starNameBuilder,
|
|
489
|
+
jdoubleArray magArray, jobject errBuilder) {
|
|
490
|
+
DEFINE_CHAR_SERR
|
|
491
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, magArray, mag)
|
|
492
|
+
|
|
493
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
494
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
495
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
496
|
+
|
|
497
|
+
int32 retc = swe_fixstar_mag(star_name, mag, serr);
|
|
498
|
+
|
|
499
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
500
|
+
|
|
501
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, magArray, mag)
|
|
502
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
503
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
504
|
+
return retc;
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
/*
|
|
508
|
+
* int32 swe_fixstar2(char *star, double tjd, int32 iflag,double *xx,char *serr)
|
|
509
|
+
*
|
|
510
|
+
* Class: swisseph_SwephExp
|
|
511
|
+
* Method: swe_fixstar2
|
|
512
|
+
* Signature: (Ljava/lang/StringBuilder;DI[DLjava/lang/StringBuilder;)I
|
|
513
|
+
*/
|
|
514
|
+
JNIEXPORT jint JNICALL
|
|
515
|
+
Java_swisseph_SwephExp_swe_1fixstar2(JNIEnv *env, jclass swephexp, jobject starNameBuilder, jdouble tjd,
|
|
516
|
+
jint iflag, jdoubleArray xxArray, jobject errBuilder) {
|
|
517
|
+
DEFINE_CHAR_SERR
|
|
518
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
519
|
+
|
|
520
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
521
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
522
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
523
|
+
|
|
524
|
+
int32 retc = swe_fixstar2(star_name, tjd, iflag, xx, serr);
|
|
525
|
+
|
|
526
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
527
|
+
|
|
528
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
529
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
530
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
531
|
+
return retc;
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
/*
|
|
535
|
+
* int32 swe_fixstar2_ut(char *star, double tjd_ut, int32 iflag, double *xx, char *serr)
|
|
536
|
+
*
|
|
537
|
+
* Class: swisseph_SwephExp
|
|
538
|
+
* Method: swe_fixstar2_ut
|
|
539
|
+
* Signature: (Ljava/lang/StringBuilder;DI[DLjava/lang/StringBuilder;)I
|
|
540
|
+
*/
|
|
541
|
+
JNIEXPORT jint JNICALL
|
|
542
|
+
Java_swisseph_SwephExp_swe_1fixstar2_1ut(JNIEnv *env, jclass swephexp, jobject starNameBuilder, jdouble tjd_ut,
|
|
543
|
+
jint iflag, jdoubleArray xxArray, jobject errBuilder) {
|
|
544
|
+
DEFINE_CHAR_SERR
|
|
545
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
546
|
+
|
|
547
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
548
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
549
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
550
|
+
|
|
551
|
+
int32 retc = swe_fixstar2_ut(star_name, tjd_ut, iflag, xx, serr);
|
|
552
|
+
|
|
553
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
554
|
+
|
|
555
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, xxArray, xx)
|
|
556
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
557
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
558
|
+
return retc;
|
|
559
|
+
}
|
|
560
|
+
|
|
561
|
+
/*
|
|
562
|
+
* int32 swe_fixstar2_mag(char *star, double *mag, char *serr)
|
|
563
|
+
*
|
|
564
|
+
* Class: swisseph_SwephExp
|
|
565
|
+
* Method: swe_fixstar2_mag
|
|
566
|
+
* Signature: (Ljava/lang/StringBuilder;[DLjava/lang/StringBuilder;)I
|
|
567
|
+
*/
|
|
568
|
+
JNIEXPORT jint JNICALL
|
|
569
|
+
Java_swisseph_SwephExp_swe_1fixstar2_1mag(JNIEnv *env, jclass swephexp, jobject starNameBuilder,
|
|
570
|
+
jdoubleArray magArray, jobject errBuilder) {
|
|
571
|
+
DEFINE_CHAR_SERR
|
|
572
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, magArray, mag)
|
|
573
|
+
|
|
574
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
575
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
576
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
577
|
+
|
|
578
|
+
int32 retc = swe_fixstar2_mag(star_name, mag, serr);
|
|
579
|
+
|
|
580
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
581
|
+
|
|
582
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, magArray, mag)
|
|
583
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
584
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
585
|
+
return retc;
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
/*
|
|
589
|
+
* Class: swisseph_SwephExp
|
|
590
|
+
* Method: swe_close
|
|
591
|
+
* Signature: ()V
|
|
592
|
+
*/
|
|
593
|
+
JNIEXPORT void JNICALL
|
|
594
|
+
Java_swisseph_SwephExp_swe_1close(JNIEnv *env, jclass swephexp) {
|
|
595
|
+
swe_close();
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
/*
|
|
599
|
+
* Class: swisseph_SwephExp
|
|
600
|
+
* Method: swe_set_ephe_path
|
|
601
|
+
* Signature: (Ljava/lang/String;)V
|
|
602
|
+
*/
|
|
603
|
+
JNIEXPORT void JNICALL
|
|
604
|
+
Java_swisseph_SwephExp_swe_1set_1ephe_1path(JNIEnv *env, jclass swephexp, jstring jEphePath) {
|
|
605
|
+
GET_STRING_UTF_CHARS(isCopy, jEphePath, ephePath)
|
|
606
|
+
//CPY_CSTRING_TO_CHARS(ephePath, ephe_path) SINCE: 2.10.03
|
|
607
|
+
|
|
608
|
+
swe_set_ephe_path(ephePath);
|
|
609
|
+
|
|
610
|
+
RLZ_STRING_UTF_CHARS(isCopy, jEphePath, ephePath)
|
|
611
|
+
}
|
|
612
|
+
|
|
613
|
+
/*
|
|
614
|
+
* Class: swisseph_SwephExp
|
|
615
|
+
* Method: swe_set_jpl_file
|
|
616
|
+
* Signature: (Ljava/lang/String;)V
|
|
617
|
+
*/
|
|
618
|
+
JNIEXPORT void JNICALL
|
|
619
|
+
Java_swisseph_SwephExp_swe_1set_1jpl_1file(JNIEnv *env, jclass swephexp, jstring jplPath) {
|
|
620
|
+
GET_STRING_UTF_CHARS(isCopy, jplPath, jplFile)
|
|
621
|
+
//CPY_CSTRING_TO_CHARS(jplFile, fname) SINCE: 2.10.03
|
|
622
|
+
|
|
623
|
+
swe_set_jpl_file(jplFile);
|
|
624
|
+
|
|
625
|
+
RLZ_STRING_UTF_CHARS(isCopy, jplPath, jplFile)
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
/*
|
|
629
|
+
* Class: swisseph_SwephExp
|
|
630
|
+
* Method: swe_get_planet_name
|
|
631
|
+
* Signature: (I)Ljava/lang/String;
|
|
632
|
+
*/
|
|
633
|
+
JNIEXPORT jstring JNICALL
|
|
634
|
+
Java_swisseph_SwephExp_swe_1get_1planet_1name(JNIEnv *env, jclass swephexp, jint ipl) {
|
|
635
|
+
char s[AS_MAXCH];
|
|
636
|
+
jstring result = NULL;
|
|
637
|
+
const char *pname = swe_get_planet_name(ipl, s);
|
|
638
|
+
if (NULL != pname) result = (*env)->NewStringUTF(env, pname);
|
|
639
|
+
return result;
|
|
640
|
+
}
|
|
641
|
+
|
|
642
|
+
/*
|
|
643
|
+
* Class: swisseph_SwephExp
|
|
644
|
+
* Method: swe_set_topo
|
|
645
|
+
* Signature: (DDD)V
|
|
646
|
+
*/
|
|
647
|
+
JNIEXPORT void JNICALL
|
|
648
|
+
Java_swisseph_SwephExp_swe_1set_1topo(JNIEnv *env, jclass swephexp, jdouble geolon, jdouble geolat, jdouble geoalt) {
|
|
649
|
+
swe_set_topo(geolon, geolat, geoalt);
|
|
650
|
+
}
|
|
651
|
+
|
|
652
|
+
/*
|
|
653
|
+
* void swe_set_sid_mode(int32 sid_mode, double t0, double ayan_t0)
|
|
654
|
+
*
|
|
655
|
+
* Class: swisseph_SwephExp
|
|
656
|
+
* Method: swe_set_sid_mode
|
|
657
|
+
* Signature: (IDD)V
|
|
658
|
+
*/
|
|
659
|
+
JNIEXPORT void JNICALL
|
|
660
|
+
Java_swisseph_SwephExp_swe_1set_1sid_1mode(JNIEnv *env, jclass swephexp, jint sid_mode, jdouble t0, jdouble ayan_t0) {
|
|
661
|
+
swe_set_sid_mode(sid_mode, t0, ayan_t0);
|
|
662
|
+
}
|
|
663
|
+
|
|
664
|
+
/*
|
|
665
|
+
* int32 swe_get_ayanamsa_ex(double tjd_et, int32 iflag, double *daya, char *serr)
|
|
666
|
+
*
|
|
667
|
+
* Class: swisseph_SwephExp
|
|
668
|
+
* Method: swe_get_ayanamsa_ex
|
|
669
|
+
* Signature: (DI[DLjava/lang/StringBuilder;)I
|
|
670
|
+
*/
|
|
671
|
+
JNIEXPORT jint JNICALL
|
|
672
|
+
Java_swisseph_SwephExp_swe_1get_1ayanamsa_1ex(JNIEnv *env, jclass swephexp, jdouble tjd_et, jint iflag,
|
|
673
|
+
jdoubleArray dayaArray, jobject errBuilder) {
|
|
674
|
+
DEFINE_CHAR_SERR
|
|
675
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, dayaArray, daya)
|
|
676
|
+
|
|
677
|
+
int32 retc = swe_get_ayanamsa_ex(tjd_et, iflag, daya, serr);
|
|
678
|
+
|
|
679
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, dayaArray, daya)
|
|
680
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
681
|
+
return retc;
|
|
682
|
+
}
|
|
683
|
+
|
|
684
|
+
/* int32 swe_get_ayanamsa_ex_ut(double tjd_ut, int32 iflag, double *daya, char *serr)
|
|
685
|
+
*
|
|
686
|
+
* Class: swisseph_SwephExp
|
|
687
|
+
* Method: swe_get_ayanamsa_ex_ut
|
|
688
|
+
* Signature: (DI[DLjava/lang/StringBuilder;)I
|
|
689
|
+
*/
|
|
690
|
+
JNIEXPORT jint JNICALL
|
|
691
|
+
Java_swisseph_SwephExp_swe_1get_1ayanamsa_1ex_1ut(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint iflag,
|
|
692
|
+
jdoubleArray dayaArray, jobject errBuilder) {
|
|
693
|
+
DEFINE_CHAR_SERR
|
|
694
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, dayaArray, daya)
|
|
695
|
+
|
|
696
|
+
int32 retc = swe_get_ayanamsa_ex_ut(tjd_ut, iflag, daya, serr);
|
|
697
|
+
|
|
698
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, dayaArray, daya)
|
|
699
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
700
|
+
return retc;
|
|
701
|
+
}
|
|
702
|
+
|
|
703
|
+
/*
|
|
704
|
+
* Class: swisseph_SwephExp
|
|
705
|
+
* Method: swe_get_ayanamsa
|
|
706
|
+
* Signature: (D)D
|
|
707
|
+
*/
|
|
708
|
+
JNIEXPORT jdouble JNICALL
|
|
709
|
+
Java_swisseph_SwephExp_swe_1get_1ayanamsa(JNIEnv *env, jclass swephexp, jdouble tjd_et) {
|
|
710
|
+
return swe_get_ayanamsa(tjd_et);
|
|
711
|
+
}
|
|
712
|
+
|
|
713
|
+
/*
|
|
714
|
+
* Class: swisseph_SwephExp
|
|
715
|
+
* Method: swe_get_ayanamsa_ut
|
|
716
|
+
* Signature: (D)D
|
|
717
|
+
*/
|
|
718
|
+
JNIEXPORT jdouble JNICALL
|
|
719
|
+
Java_swisseph_SwephExp_swe_1get_1ayanamsa_1ut(JNIEnv *env, jclass swephexp, jdouble tjd_ut) {
|
|
720
|
+
return swe_get_ayanamsa_ut(tjd_ut);
|
|
721
|
+
}
|
|
722
|
+
|
|
723
|
+
/*
|
|
724
|
+
* Class: swisseph_SwephExp
|
|
725
|
+
* Method: swe_get_ayanamsa_name
|
|
726
|
+
* Signature: (I)Ljava/lang/String;
|
|
727
|
+
*/
|
|
728
|
+
JNIEXPORT jstring JNICALL
|
|
729
|
+
Java_swisseph_SwephExp_swe_1get_1ayanamsa_1name(JNIEnv *env, jclass swephexp, jint isidmode) {
|
|
730
|
+
jstring result = NULL;
|
|
731
|
+
const char *name = swe_get_ayanamsa_name(isidmode);
|
|
732
|
+
if (NULL != name) result = (*env)->NewStringUTF(env, name);
|
|
733
|
+
return result;
|
|
734
|
+
}
|
|
735
|
+
|
|
736
|
+
/*
|
|
737
|
+
* const char * swe_get_current_file_data(int ifno, double *tfstart, double *tfend, int *denum)
|
|
738
|
+
*
|
|
739
|
+
* Class: swisseph_SwephExp
|
|
740
|
+
* Method: swe_get_current_file_data
|
|
741
|
+
* Signature: (I[D[D[I)Ljava/lang/String;
|
|
742
|
+
*/
|
|
743
|
+
JNIEXPORT jstring JNICALL
|
|
744
|
+
Java_swisseph_SwephExp_swe_1get_1current_1file_1data(JNIEnv *env, jclass swephexp, jint ifno,
|
|
745
|
+
jdoubleArray tfstartArray, jdoubleArray tfendArray,
|
|
746
|
+
jintArray denumArray) {
|
|
747
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, tfstartArray, tfstart)
|
|
748
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, tfendArray, tfend)
|
|
749
|
+
GET_INT_ARRAY_ELEMENTS(isCopy, denumArray, denum)
|
|
750
|
+
|
|
751
|
+
int32 sweph_denum[1];
|
|
752
|
+
jstring result = NULL;
|
|
753
|
+
const char *data = swe_get_current_file_data(ifno, tfstart, tfend, &sweph_denum[0]);
|
|
754
|
+
if (NULL != data) result = (*env)->NewStringUTF(env, data);
|
|
755
|
+
denum[0] = sweph_denum[0];
|
|
756
|
+
|
|
757
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy1, tfstartArray, tfstart)
|
|
758
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy2, tfendArray, tfend)
|
|
759
|
+
RLZ_INT_ARRAY_ELEMENTS_OK(isCopy, denumArray, denum)
|
|
760
|
+
|
|
761
|
+
return result;
|
|
762
|
+
}
|
|
763
|
+
|
|
764
|
+
/*
|
|
765
|
+
* Class: swisseph_SwephExp
|
|
766
|
+
* Method: swe_date_conversion
|
|
767
|
+
* Signature: (IIIDC[D)I
|
|
768
|
+
*/
|
|
769
|
+
JNIEXPORT jint JNICALL
|
|
770
|
+
Java_swisseph_SwephExp_swe_1date_1conversion(JNIEnv *env, jclass swephexp,
|
|
771
|
+
jint y, jint m, jint d, jdouble utime,
|
|
772
|
+
jchar calendarType, jdoubleArray tjdArray) {
|
|
773
|
+
/* calendarType - g[regorian]|j[ulian] */
|
|
774
|
+
/* utime - universal time in hours (decimal) */
|
|
775
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, tjdArray, tjd)
|
|
776
|
+
|
|
777
|
+
int retc = swe_date_conversion(y, m, d, utime, calendarType, tjd);
|
|
778
|
+
|
|
779
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, tjdArray, tjd)
|
|
780
|
+
return retc;
|
|
781
|
+
}
|
|
782
|
+
|
|
783
|
+
/*
|
|
784
|
+
* double swe_julday(int year, int month, int day, double hour, int gregflag)
|
|
785
|
+
*
|
|
786
|
+
* Class: swisseph_SwephExp
|
|
787
|
+
* Method: swe_julday
|
|
788
|
+
* Signature: (IIIDI)D
|
|
789
|
+
*/
|
|
790
|
+
JNIEXPORT jdouble JNICALL
|
|
791
|
+
Java_swisseph_SwephExp_swe_1julday(JNIEnv *env, jclass swephexp,
|
|
792
|
+
jint year, jint month, jint day, jdouble hour, jint gregflag) {
|
|
793
|
+
return swe_julday(year, month, day, hour, gregflag);
|
|
794
|
+
}
|
|
795
|
+
|
|
796
|
+
/*
|
|
797
|
+
* Class: swisseph_SwephExp
|
|
798
|
+
* Method: swe_revjul
|
|
799
|
+
* Signature: (DI[I[D)V
|
|
800
|
+
*/
|
|
801
|
+
JNIEXPORT void JNICALL
|
|
802
|
+
Java_swisseph_SwephExp_swe_1revjul(JNIEnv *env, jclass swephexp, jdouble jd,
|
|
803
|
+
jint gregflag, jintArray ymdArray, jdoubleArray utimeArray) {
|
|
804
|
+
int ymd[3];
|
|
805
|
+
GET_INT_ARRAY_ELEMENTS(isIntCopy, ymdArray, ymdOut)
|
|
806
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, utimeArray, utime)
|
|
807
|
+
|
|
808
|
+
swe_revjul(jd, gregflag, &ymd[0], &ymd[1], &ymd[2], utime);
|
|
809
|
+
|
|
810
|
+
ymdOut[0] = ymd[0];
|
|
811
|
+
ymdOut[1] = ymd[1];
|
|
812
|
+
ymdOut[2] = ymd[2];
|
|
813
|
+
|
|
814
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isDblCopy, utimeArray, utime)
|
|
815
|
+
RLZ_INT_ARRAY_ELEMENTS_OK(isIntCopy, ymdArray, ymdOut)
|
|
816
|
+
}
|
|
817
|
+
|
|
818
|
+
/*
|
|
819
|
+
* Class: swisseph_SwephExp
|
|
820
|
+
* Method: swe_utc_to_jd
|
|
821
|
+
* Signature: (IIIIIDI[DLjava/lang/StringBuilder;)I
|
|
822
|
+
*/
|
|
823
|
+
JNIEXPORT jint JNICALL
|
|
824
|
+
Java_swisseph_SwephExp_swe_1utc_1to_1jd(JNIEnv *env, jclass swephexp, jint iyear, jint imonth,
|
|
825
|
+
jint iday, jint ihour, jint imin, jdouble dsec,
|
|
826
|
+
jint gregflag, jdoubleArray dretArray,
|
|
827
|
+
jobject errBuilder) {
|
|
828
|
+
DEFINE_CHAR_SERR
|
|
829
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, dretArray, dret)
|
|
830
|
+
|
|
831
|
+
int32 retc = swe_utc_to_jd(iyear, imonth, iday, ihour, imin, dsec, gregflag, dret, serr);
|
|
832
|
+
|
|
833
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, dretArray, dret)
|
|
834
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
835
|
+
return retc;
|
|
836
|
+
}
|
|
837
|
+
|
|
838
|
+
/*
|
|
839
|
+
* Class: swisseph_SwephExp
|
|
840
|
+
* Method: swe_jdet_to_utc
|
|
841
|
+
* Signature: (DI[I[D)V
|
|
842
|
+
*/
|
|
843
|
+
JNIEXPORT void JNICALL
|
|
844
|
+
Java_swisseph_SwephExp_swe_1jdet_1to_1utc(JNIEnv *env, jclass swephexp,
|
|
845
|
+
jdouble tjd_et, jint gregflag, jintArray ymdhmArray,
|
|
846
|
+
jdoubleArray dsecArray) {
|
|
847
|
+
GET_INT_ARRAY_ELEMENTS(isIntCopy, ymdhmArray, ymdhmOut)
|
|
848
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, dsecArray, dsecOut)
|
|
849
|
+
|
|
850
|
+
int32 ymdhm[5];
|
|
851
|
+
swe_jdet_to_utc(tjd_et, gregflag, &ymdhm[0], &ymdhm[1],
|
|
852
|
+
&ymdhm[2], &ymdhm[3], &ymdhm[4], dsecOut);
|
|
853
|
+
|
|
854
|
+
ymdhmOut[0] = ymdhm[0];
|
|
855
|
+
ymdhmOut[1] = ymdhm[1];
|
|
856
|
+
ymdhmOut[2] = ymdhm[2];
|
|
857
|
+
ymdhmOut[3] = ymdhm[3];
|
|
858
|
+
ymdhmOut[4] = ymdhm[4];
|
|
859
|
+
|
|
860
|
+
RLZ_INT_ARRAY_ELEMENTS_OK(isIntCopy, ymdhmArray, ymdhmOut)
|
|
861
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isDblCopy, dsecArray, dsecOut)
|
|
862
|
+
}
|
|
863
|
+
|
|
864
|
+
/*
|
|
865
|
+
* Class: swisseph_SwephExp
|
|
866
|
+
* Method: swe_jdut1_to_utc
|
|
867
|
+
* Signature: (DI[I[D)V
|
|
868
|
+
*/
|
|
869
|
+
JNIEXPORT void JNICALL
|
|
870
|
+
Java_swisseph_SwephExp_swe_1jdut1_1to_1utc(JNIEnv *env, jclass swephexp,
|
|
871
|
+
jdouble tjd_ut, jint gregflag, jintArray ymdhmArray,
|
|
872
|
+
jdoubleArray dsecArray) {
|
|
873
|
+
GET_INT_ARRAY_ELEMENTS(isIntCopy, ymdhmArray, ymdhmOut)
|
|
874
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, dsecArray, dsecOut)
|
|
875
|
+
|
|
876
|
+
int32 ymdhm[5];
|
|
877
|
+
swe_jdut1_to_utc(tjd_ut, gregflag, &ymdhm[0], &ymdhm[1],
|
|
878
|
+
&ymdhm[2], &ymdhm[3], &ymdhm[4], dsecOut);
|
|
879
|
+
|
|
880
|
+
ymdhmOut[0] = ymdhm[0];
|
|
881
|
+
ymdhmOut[1] = ymdhm[1];
|
|
882
|
+
ymdhmOut[2] = ymdhm[2];
|
|
883
|
+
ymdhmOut[3] = ymdhm[3];
|
|
884
|
+
ymdhmOut[4] = ymdhm[4];
|
|
885
|
+
|
|
886
|
+
RLZ_INT_ARRAY_ELEMENTS_OK(isIntCopy, ymdhmArray, ymdhmOut)
|
|
887
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isDblCopy, dsecArray, dsecOut)
|
|
888
|
+
}
|
|
889
|
+
|
|
890
|
+
/*
|
|
891
|
+
* Class: swisseph_SwephExp
|
|
892
|
+
* Method: swe_utc_time_zone
|
|
893
|
+
* Signature: (IIIIIDD[I[D)V
|
|
894
|
+
*/
|
|
895
|
+
JNIEXPORT void JNICALL
|
|
896
|
+
Java_swisseph_SwephExp_swe_1utc_1time_1zone(JNIEnv *env, jclass swephexp, jint iyear, jint imonth,
|
|
897
|
+
jint iday, jint ihour, jint imin, jdouble dsec, jdouble d_timezone,
|
|
898
|
+
jintArray ymdhmArray, jdoubleArray dsecArray) {
|
|
899
|
+
GET_INT_ARRAY_ELEMENTS(isIntCopy, ymdhmArray, ymdhmOut)
|
|
900
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, dsecArray, dsecOut)
|
|
901
|
+
|
|
902
|
+
int32 ymdhm[5];
|
|
903
|
+
swe_utc_time_zone(iyear, imonth, iday, ihour, imin, dsec, d_timezone, &ymdhm[0],
|
|
904
|
+
&ymdhm[1], &ymdhm[2], &ymdhm[3], &ymdhm[4], dsecOut);
|
|
905
|
+
|
|
906
|
+
ymdhmOut[0] = ymdhm[0];
|
|
907
|
+
ymdhmOut[1] = ymdhm[1];
|
|
908
|
+
ymdhmOut[2] = ymdhm[2];
|
|
909
|
+
ymdhmOut[3] = ymdhm[3];
|
|
910
|
+
ymdhmOut[4] = ymdhm[4];
|
|
911
|
+
|
|
912
|
+
RLZ_INT_ARRAY_ELEMENTS_OK(isIntCopy, ymdhmArray, ymdhmOut)
|
|
913
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isDblCopy, dsecArray, dsecOut)
|
|
914
|
+
}
|
|
915
|
+
|
|
916
|
+
/*
|
|
917
|
+
* Class: swisseph_SwephExp
|
|
918
|
+
* Method: swe_houses
|
|
919
|
+
* Signature: (DDDI[D[D)I
|
|
920
|
+
*/
|
|
921
|
+
JNIEXPORT jint JNICALL
|
|
922
|
+
Java_swisseph_SwephExp_swe_1houses(JNIEnv *env, jclass swephexp, jdouble tjd_ut,
|
|
923
|
+
jdouble geolat, jdouble geolon, jint hsys,
|
|
924
|
+
jdoubleArray cuspsArray, jdoubleArray ascmcArray) {
|
|
925
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCuspsCopy, cuspsArray, cusps)
|
|
926
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAscmcCopy, ascmcArray, ascmc)
|
|
927
|
+
|
|
928
|
+
int retc = swe_houses(tjd_ut, geolat, geolon, hsys, cusps, ascmc);
|
|
929
|
+
|
|
930
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCuspsCopy, cuspsArray, cusps)
|
|
931
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAscmcCopy, ascmcArray, ascmc)
|
|
932
|
+
return retc;
|
|
933
|
+
}
|
|
934
|
+
|
|
935
|
+
/*
|
|
936
|
+
* Class: swisseph_SwephExp
|
|
937
|
+
* Method: swe_houses_ex
|
|
938
|
+
* Signature: (DIDDI[D[D)I
|
|
939
|
+
*/
|
|
940
|
+
JNIEXPORT jint JNICALL
|
|
941
|
+
Java_swisseph_SwephExp_swe_1houses_1ex(JNIEnv *env, jclass swephexp, jdouble tjd_ut,
|
|
942
|
+
jint iflag, jdouble geolat, jdouble geolon, jint hsys,
|
|
943
|
+
jdoubleArray cuspsArray, jdoubleArray ascmcArray) {
|
|
944
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCuspsCopy, cuspsArray, cusps)
|
|
945
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAscmcCopy, ascmcArray, ascmc)
|
|
946
|
+
|
|
947
|
+
int retc = swe_houses_ex(tjd_ut, iflag, geolat, geolon, hsys, cusps, ascmc);
|
|
948
|
+
|
|
949
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCuspsCopy, cuspsArray, cusps)
|
|
950
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAscmcCopy, ascmcArray, ascmc)
|
|
951
|
+
return retc;
|
|
952
|
+
}
|
|
953
|
+
|
|
954
|
+
/*
|
|
955
|
+
* int swe_houses_ex2(double tjd_ut, int32 iflag, double geolat, double geolon, int hsys,
|
|
956
|
+
* double *cusps, double *ascmc, double *cusp_speed, double *ascmc_speed, char *serr)
|
|
957
|
+
*
|
|
958
|
+
* Class: swisseph_SwephExp
|
|
959
|
+
* Method: swe_houses_ex2
|
|
960
|
+
* Signature: (DIDDI[D[D[D[DLjava/lang/StringBuilder;)I
|
|
961
|
+
*/
|
|
962
|
+
JNIEXPORT jint JNICALL
|
|
963
|
+
Java_swisseph_SwephExp_swe_1houses_1ex2(JNIEnv *env, jclass swephexp,
|
|
964
|
+
jdouble tjd_ut, jint iflag, jdouble geolat, jdouble geolon,
|
|
965
|
+
jint hsys, jdoubleArray cuspsArray,
|
|
966
|
+
jdoubleArray ascmcArray, jdoubleArray cuspSpeedArray,
|
|
967
|
+
jdoubleArray ascmcSpeedArray, jobject errBuilder) {
|
|
968
|
+
DEFINE_CHAR_SERR
|
|
969
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, cuspsArray, cusps)
|
|
970
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, ascmcArray, ascmc)
|
|
971
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, cuspSpeedArray, cusp_speed)
|
|
972
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, ascmcSpeedArray, ascmc_speed)
|
|
973
|
+
|
|
974
|
+
int retc = swe_houses_ex2(tjd_ut, iflag, geolat, geolon, hsys, cusps, ascmc, cusp_speed, ascmc_speed, serr);
|
|
975
|
+
|
|
976
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, cuspsArray, cusps)
|
|
977
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, ascmcArray, ascmc)
|
|
978
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, cuspSpeedArray, cusp_speed)
|
|
979
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, ascmcSpeedArray, ascmc_speed)
|
|
980
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
981
|
+
return retc;
|
|
982
|
+
}
|
|
983
|
+
|
|
984
|
+
/*
|
|
985
|
+
* int swe_houses_armc(double armc,double geolat,double eps,int hsys,double *cusp,double *ascmc)
|
|
986
|
+
*
|
|
987
|
+
* Class: swisseph_SwephExp
|
|
988
|
+
* Method: swe_houses_armc
|
|
989
|
+
* Signature: (DDDI[D[D)I
|
|
990
|
+
*/
|
|
991
|
+
JNIEXPORT jint JNICALL
|
|
992
|
+
Java_swisseph_SwephExp_swe_1houses_1armc(JNIEnv *env, jclass swephexp,
|
|
993
|
+
jdouble armc, jdouble geolat, jdouble eps, jint hsys,
|
|
994
|
+
jdoubleArray cuspArray, jdoubleArray ascmcArray) {
|
|
995
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, cuspArray, cusp)
|
|
996
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, ascmcArray, ascmc)
|
|
997
|
+
|
|
998
|
+
int retc = swe_houses_armc(armc, geolat, eps, hsys, cusp, ascmc);
|
|
999
|
+
|
|
1000
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, cuspArray, cusp)
|
|
1001
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, ascmcArray, ascmc)
|
|
1002
|
+
|
|
1003
|
+
return retc;
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
/*
|
|
1007
|
+
* int swe_houses_armc_ex2(double armc, double geolat, double eps, int hsys, double *cusps,
|
|
1008
|
+
* double *ascmc, double *cusp_speed, double *ascmc_speed, char *serr);
|
|
1009
|
+
*
|
|
1010
|
+
* Class: swisseph_SwephExp
|
|
1011
|
+
* Method: swe_houses_armc_ex2
|
|
1012
|
+
* Signature: (DDDI[D[D[D[DLjava/lang/StringBuilder;)I
|
|
1013
|
+
*/
|
|
1014
|
+
JNIEXPORT jint JNICALL
|
|
1015
|
+
Java_swisseph_SwephExp_swe_1houses_1armc_1ex2(JNIEnv *env, jclass swephexp, jdouble armc, jdouble geolat,
|
|
1016
|
+
jdouble eps, jint hsys, jdoubleArray cuspsArray,
|
|
1017
|
+
jdoubleArray ascmcArray, jdoubleArray cuspSpeedArray,
|
|
1018
|
+
jdoubleArray ascmcSpeedArray, jobject errBuilder) {
|
|
1019
|
+
DEFINE_CHAR_SERR
|
|
1020
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, cuspsArray, cusps)
|
|
1021
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, ascmcArray, ascmc)
|
|
1022
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, cuspSpeedArray, cusp_speed)
|
|
1023
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, ascmcSpeedArray, ascmc_speed)
|
|
1024
|
+
|
|
1025
|
+
int retc = swe_houses_armc_ex2(armc, geolat, eps, hsys, cusps, ascmc, cusp_speed, ascmc_speed, serr);
|
|
1026
|
+
|
|
1027
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, cuspsArray, cusps)
|
|
1028
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, ascmcArray, ascmc)
|
|
1029
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, cuspSpeedArray, cusp_speed)
|
|
1030
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, ascmcSpeedArray, ascmc_speed)
|
|
1031
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1032
|
+
return retc;
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
/*
|
|
1036
|
+
* double swe_house_pos(double armc, double geolat, double eps, int hsys, double *xpin, char *serr)
|
|
1037
|
+
*
|
|
1038
|
+
* Class: swisseph_SwephExp
|
|
1039
|
+
* Method: swe_house_pos
|
|
1040
|
+
* Signature: (DDDI[DLjava/lang/StringBuilder;)D
|
|
1041
|
+
*/
|
|
1042
|
+
JNIEXPORT jdouble JNICALL
|
|
1043
|
+
Java_swisseph_SwephExp_swe_1house_1pos(JNIEnv *env, jclass swephexp, jdouble armc, jdouble geolat,
|
|
1044
|
+
jdouble eps, jint hsys, jdoubleArray xpinArray, jobject errBuilder) {
|
|
1045
|
+
DEFINE_CHAR_SERR
|
|
1046
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, xpinArray, xpin)
|
|
1047
|
+
|
|
1048
|
+
double house_pos = swe_house_pos(armc, geolat, eps, hsys, xpin, serr);
|
|
1049
|
+
|
|
1050
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy, xpinArray, xpin)
|
|
1051
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1052
|
+
return house_pos;
|
|
1053
|
+
}
|
|
1054
|
+
|
|
1055
|
+
/*
|
|
1056
|
+
* Class: swisseph_SwephExp
|
|
1057
|
+
* Method: swe_house_name
|
|
1058
|
+
* Signature: (I)Ljava/lang/String;
|
|
1059
|
+
*/
|
|
1060
|
+
JNIEXPORT jstring JNICALL
|
|
1061
|
+
Java_swisseph_SwephExp_swe_1house_1name(JNIEnv *env, jclass swephexp, jint hsys) {
|
|
1062
|
+
jstring result = NULL;
|
|
1063
|
+
const char *house_name = swe_house_name(hsys);
|
|
1064
|
+
if (NULL != house_name) result = (*env)->NewStringUTF(env, house_name);
|
|
1065
|
+
return result;
|
|
1066
|
+
}
|
|
1067
|
+
|
|
1068
|
+
/*
|
|
1069
|
+
* int32 swe_gauquelin_sector(double t_ut, int32 ipl, char *starname, int32 iflag, int32 imeth,
|
|
1070
|
+
* double *geopos, double atpress, double attemp, double *dgsect, char *serr);
|
|
1071
|
+
*
|
|
1072
|
+
* Class: swisseph_SwephExp
|
|
1073
|
+
* Method: swe_gauquelin_sector
|
|
1074
|
+
* Signature: (DILjava/lang/StringBuilder;II[DDD[DLjava/lang/StringBuilder;)I
|
|
1075
|
+
*/
|
|
1076
|
+
JNIEXPORT jint JNICALL
|
|
1077
|
+
Java_swisseph_SwephExp_swe_1gauquelin_1sector(JNIEnv *env, jclass swephexp, jdouble t_ut, jint ipl,
|
|
1078
|
+
jobject starNameBuilder, jint iflag, jint imeth,
|
|
1079
|
+
jdoubleArray geoposArray, jdouble atpress, jdouble attemp,
|
|
1080
|
+
jdoubleArray dgsectArray, jobject errBuilder) {
|
|
1081
|
+
DEFINE_CHAR_SERR
|
|
1082
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1083
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDgsectCopy, dgsectArray, dgsect)
|
|
1084
|
+
|
|
1085
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
1086
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1087
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
1088
|
+
|
|
1089
|
+
int32 retc = swe_gauquelin_sector(t_ut, ipl, star_name, iflag, imeth, geopos, atpress, attemp, dgsect, serr);
|
|
1090
|
+
|
|
1091
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
1092
|
+
|
|
1093
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1094
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDgsectCopy, dgsectArray, dgsect)
|
|
1095
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1096
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1097
|
+
return retc;
|
|
1098
|
+
}
|
|
1099
|
+
|
|
1100
|
+
/*
|
|
1101
|
+
* int32 swe_sol_eclipse_where(double tjd, int32 ifl, double *geopos, double *attr, char *serr)
|
|
1102
|
+
*
|
|
1103
|
+
* Class: swisseph_SwephExp
|
|
1104
|
+
* Method: swe_sol_eclipse_where
|
|
1105
|
+
* Signature: (DI[D[DLjava/lang/StringBuilder;)I
|
|
1106
|
+
*/
|
|
1107
|
+
JNIEXPORT jint JNICALL
|
|
1108
|
+
Java_swisseph_SwephExp_swe_1sol_1eclipse_1where(JNIEnv *env, jclass swephexp, jdouble tjd, jint ifl,
|
|
1109
|
+
jdoubleArray geoposArray, jdoubleArray attrArray, jobject errBuilder) {
|
|
1110
|
+
DEFINE_CHAR_SERR
|
|
1111
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1112
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1113
|
+
|
|
1114
|
+
int32 retc = swe_sol_eclipse_where(tjd, ifl, geopos, attr, serr);
|
|
1115
|
+
|
|
1116
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1117
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1118
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1119
|
+
return retc;
|
|
1120
|
+
}
|
|
1121
|
+
|
|
1122
|
+
/*
|
|
1123
|
+
* int32 swe_lun_occult_where(double tjd, int32 ipl, char *starname, int32 ifl, double *geopos, double *attr, char *serr)
|
|
1124
|
+
*
|
|
1125
|
+
* Class: swisseph_SwephExp
|
|
1126
|
+
* Method: swe_lun_occult_where
|
|
1127
|
+
* Signature: (DILjava/lang/StringBuilder;I[D[DLjava/lang/StringBuilder;)I
|
|
1128
|
+
*/
|
|
1129
|
+
JNIEXPORT jint JNICALL
|
|
1130
|
+
Java_swisseph_SwephExp_swe_1lun_1occult_1where(JNIEnv *env, jclass swephexp, jdouble tjd, jint ipl,
|
|
1131
|
+
jobject starNameBuilder, jint ifl, jdoubleArray geoposArray,
|
|
1132
|
+
jdoubleArray attrArray, jobject errBuilder) {
|
|
1133
|
+
DEFINE_CHAR_SERR
|
|
1134
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1135
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1136
|
+
|
|
1137
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
1138
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1139
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
1140
|
+
|
|
1141
|
+
int32 retc = swe_lun_occult_where(tjd, ipl, star_name, ifl, geopos, attr, serr);
|
|
1142
|
+
|
|
1143
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
1144
|
+
|
|
1145
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1146
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1147
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1148
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1149
|
+
return retc;
|
|
1150
|
+
}
|
|
1151
|
+
|
|
1152
|
+
/*
|
|
1153
|
+
* int32 swe_sol_eclipse_how(double tjd, int32 ifl, double *geopos, double *attr, char *serr)
|
|
1154
|
+
*
|
|
1155
|
+
* Class: swisseph_SwephExp
|
|
1156
|
+
* Method: swe_sol_eclipse_how
|
|
1157
|
+
* Signature: (DI[D[DLjava/lang/StringBuilder;)I
|
|
1158
|
+
*/
|
|
1159
|
+
JNIEXPORT jint JNICALL
|
|
1160
|
+
Java_swisseph_SwephExp_swe_1sol_1eclipse_1how(JNIEnv *env, jclass swephexp, jdouble tjd, jint ifl,
|
|
1161
|
+
jdoubleArray geoposArray, jdoubleArray attrArray, jobject errBuilder) {
|
|
1162
|
+
DEFINE_CHAR_SERR
|
|
1163
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1164
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1165
|
+
|
|
1166
|
+
int32 retc = swe_sol_eclipse_how(tjd, ifl, geopos, attr, serr);
|
|
1167
|
+
|
|
1168
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1169
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1170
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1171
|
+
return retc;
|
|
1172
|
+
}
|
|
1173
|
+
|
|
1174
|
+
/*
|
|
1175
|
+
* Class: swisseph_SwephExp
|
|
1176
|
+
* Method: swe_sol_eclipse_when_loc
|
|
1177
|
+
* Signature: (DI[D[D[DILjava/lang/StringBuilder;)I
|
|
1178
|
+
*/
|
|
1179
|
+
JNIEXPORT jint JNICALL
|
|
1180
|
+
Java_swisseph_SwephExp_swe_1sol_1eclipse_1when_1loc(JNIEnv *env, jclass swephexp, jdouble tjd_start,
|
|
1181
|
+
jint ifl, jdoubleArray geoposArray, jdoubleArray tretArray,
|
|
1182
|
+
jdoubleArray attrArray, jint backward, jobject errBuilder) {
|
|
1183
|
+
DEFINE_CHAR_SERR
|
|
1184
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1185
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1186
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1187
|
+
|
|
1188
|
+
int32 retc = swe_sol_eclipse_when_loc(tjd_start, ifl, geopos, tret, attr, backward, serr);
|
|
1189
|
+
|
|
1190
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1191
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1192
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1193
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1194
|
+
return retc;
|
|
1195
|
+
}
|
|
1196
|
+
|
|
1197
|
+
/*
|
|
1198
|
+
* int32 swe_lun_occult_when_loc(double tjd_start, int32 ipl, char *starname, int32 ifl,
|
|
1199
|
+
* double *geopos, double *tret, double *attr, int32 backward, char *serr)
|
|
1200
|
+
*
|
|
1201
|
+
* Class: swisseph_SwephExp
|
|
1202
|
+
* Method: swe_lun_occult_when_loc
|
|
1203
|
+
* Signature: (DILjava/lang/StringBuilder;I[D[D[DILjava/lang/StringBuilder;)I
|
|
1204
|
+
*/
|
|
1205
|
+
JNIEXPORT jint JNICALL
|
|
1206
|
+
Java_swisseph_SwephExp_swe_1lun_1occult_1when_1loc(JNIEnv *env, jclass swephexp, jdouble tjd_start, jint ipl,
|
|
1207
|
+
jobject starNameBuilder, jint ifl, jdoubleArray geoposArray,
|
|
1208
|
+
jdoubleArray tretArray, jdoubleArray attrArray,
|
|
1209
|
+
jint backward, jobject errBuilder) {
|
|
1210
|
+
DEFINE_CHAR_SERR
|
|
1211
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1212
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1213
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1214
|
+
|
|
1215
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
1216
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1217
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
1218
|
+
|
|
1219
|
+
int32 retc = swe_lun_occult_when_loc(tjd_start, ipl, star_name, ifl, geopos, tret, attr, backward, serr);
|
|
1220
|
+
|
|
1221
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
1222
|
+
|
|
1223
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1224
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1225
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1226
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1227
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1228
|
+
return retc;
|
|
1229
|
+
}
|
|
1230
|
+
|
|
1231
|
+
/*
|
|
1232
|
+
* Class: swisseph_SwephExp
|
|
1233
|
+
* Method: swe_sol_eclipse_when_glob
|
|
1234
|
+
* Signature: (DII[DILjava/lang/StringBuilder;)I
|
|
1235
|
+
*/
|
|
1236
|
+
JNIEXPORT jint JNICALL
|
|
1237
|
+
Java_swisseph_SwephExp_swe_1sol_1eclipse_1when_1glob(JNIEnv *env, jclass swephexp,
|
|
1238
|
+
jdouble tjd_start, jint ifl, jint ifltype,
|
|
1239
|
+
jdoubleArray tretArray, jint backward,
|
|
1240
|
+
jobject errBuilder) {
|
|
1241
|
+
DEFINE_CHAR_SERR
|
|
1242
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, tretArray, tret)
|
|
1243
|
+
|
|
1244
|
+
int32 retc = swe_sol_eclipse_when_glob(tjd_start, ifl, ifltype, tret, backward, serr);
|
|
1245
|
+
|
|
1246
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, tretArray, tret)
|
|
1247
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1248
|
+
return retc;
|
|
1249
|
+
}
|
|
1250
|
+
|
|
1251
|
+
/*
|
|
1252
|
+
* int32 swe_lun_occult_when_glob(double tjd_start, int32 ipl, char *starname, int32 ifl,
|
|
1253
|
+
* int32 ifltype,double *tret, int32 backward, char *serr)
|
|
1254
|
+
*
|
|
1255
|
+
* Class: swisseph_SwephExp
|
|
1256
|
+
* Method: swe_lun_occult_when_glob
|
|
1257
|
+
* Signature: (DILjava/lang/StringBuilder;II[DILjava/lang/StringBuilder;)I
|
|
1258
|
+
*/
|
|
1259
|
+
JNIEXPORT jint JNICALL
|
|
1260
|
+
Java_swisseph_SwephExp_swe_1lun_1occult_1when_1glob(JNIEnv *env, jclass swephexp, jdouble tjd_start, jint ipl,
|
|
1261
|
+
jobject starNameBuilder, jint ifl, jint ifltype,
|
|
1262
|
+
jdoubleArray tretArray, jint backward, jobject errBuilder) {
|
|
1263
|
+
DEFINE_CHAR_SERR
|
|
1264
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1265
|
+
|
|
1266
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
1267
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1268
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
1269
|
+
|
|
1270
|
+
int32 retc = swe_lun_occult_when_glob(tjd_start, ipl, star_name, ifl, ifltype, tret, backward, serr);
|
|
1271
|
+
|
|
1272
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
1273
|
+
|
|
1274
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1275
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1276
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1277
|
+
return retc;
|
|
1278
|
+
}
|
|
1279
|
+
|
|
1280
|
+
/*
|
|
1281
|
+
* int32 swe_lun_eclipse_how(double tjd_ut,int32 ifl,double *geopos,double *attr,char *serr)
|
|
1282
|
+
*
|
|
1283
|
+
* Class: swisseph_SwephExp
|
|
1284
|
+
* Method: swe_lun_eclipse_how
|
|
1285
|
+
* Signature: (DI[D[DLjava/lang/StringBuilder;)I
|
|
1286
|
+
*/
|
|
1287
|
+
JNIEXPORT jint JNICALL
|
|
1288
|
+
Java_swisseph_SwephExp_swe_1lun_1eclipse_1how(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint ifl,
|
|
1289
|
+
jdoubleArray geoposArray, jdoubleArray attrArray, jobject errBuilder) {
|
|
1290
|
+
DEFINE_CHAR_SERR
|
|
1291
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1292
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1293
|
+
|
|
1294
|
+
int32 retc = swe_lun_eclipse_how(tjd_ut, ifl, geopos, attr, serr);
|
|
1295
|
+
|
|
1296
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1297
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1298
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1299
|
+
return retc;
|
|
1300
|
+
}
|
|
1301
|
+
|
|
1302
|
+
/*
|
|
1303
|
+
* Class: swisseph_SwephExp
|
|
1304
|
+
* Method: swe_lun_eclipse_when
|
|
1305
|
+
* Signature: (DII[DILjava/lang/StringBuilder;)I
|
|
1306
|
+
*/
|
|
1307
|
+
JNIEXPORT jint JNICALL
|
|
1308
|
+
Java_swisseph_SwephExp_swe_1lun_1eclipse_1when(JNIEnv *env, jclass swephexp, jdouble tjd_start,
|
|
1309
|
+
jint ifl, jint ifltype, jdoubleArray tretArray,
|
|
1310
|
+
jint backward, jobject errBuilder) {
|
|
1311
|
+
DEFINE_CHAR_SERR
|
|
1312
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, tretArray, tret)
|
|
1313
|
+
|
|
1314
|
+
int32 retc = swe_lun_eclipse_when(tjd_start, ifl, ifltype, tret, backward, serr);
|
|
1315
|
+
|
|
1316
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, tretArray, tret)
|
|
1317
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1318
|
+
return retc;
|
|
1319
|
+
}
|
|
1320
|
+
|
|
1321
|
+
/*
|
|
1322
|
+
* Class: swisseph_SwephExp
|
|
1323
|
+
* Method: swe_lun_eclipse_when_loc
|
|
1324
|
+
* Signature: (DI[D[D[DILjava/lang/StringBuilder;)I
|
|
1325
|
+
*/
|
|
1326
|
+
JNIEXPORT jint JNICALL
|
|
1327
|
+
Java_swisseph_SwephExp_swe_1lun_1eclipse_1when_1loc(JNIEnv *env, jclass swephexp, jdouble tjd_start,
|
|
1328
|
+
jint ifl, jdoubleArray geoposArray, jdoubleArray tretArray,
|
|
1329
|
+
jdoubleArray attrArray, jint backward, jobject errBuilder) {
|
|
1330
|
+
DEFINE_CHAR_SERR
|
|
1331
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1332
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1333
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1334
|
+
|
|
1335
|
+
int32 retc = swe_lun_eclipse_when_loc(tjd_start, ifl, geopos, tret, attr, backward, serr);
|
|
1336
|
+
|
|
1337
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1338
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1339
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isAttrCopy, attrArray, attr)
|
|
1340
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1341
|
+
return retc;
|
|
1342
|
+
}
|
|
1343
|
+
|
|
1344
|
+
/*
|
|
1345
|
+
* int32 swe_pheno(double tjd, int32 ipl, int32 iflag, double *attr, char *serr)
|
|
1346
|
+
*
|
|
1347
|
+
* Class: swisseph_SwephExp
|
|
1348
|
+
* Method: swe_pheno
|
|
1349
|
+
* Signature: (DII[DLjava/lang/StringBuilder;)I
|
|
1350
|
+
*/
|
|
1351
|
+
JNIEXPORT jint JNICALL
|
|
1352
|
+
Java_swisseph_SwephExp_swe_1pheno(JNIEnv *env, jclass swephexp, jdouble tjd, jint ipl,
|
|
1353
|
+
jint iflag, jdoubleArray attrArray, jobject errBuilder) {
|
|
1354
|
+
DEFINE_CHAR_SERR
|
|
1355
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, attrArray, attr)
|
|
1356
|
+
|
|
1357
|
+
int32 retc = swe_pheno(tjd, ipl, iflag, attr, serr);
|
|
1358
|
+
|
|
1359
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, attrArray, attr)
|
|
1360
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1361
|
+
return retc;
|
|
1362
|
+
}
|
|
1363
|
+
|
|
1364
|
+
/*
|
|
1365
|
+
* int32 swe_pheno_ut(double tjd_ut, int32 ipl, int32 iflag, double *attr, char *serr)
|
|
1366
|
+
*
|
|
1367
|
+
* Class: swisseph_SwephExp
|
|
1368
|
+
* Method: swe_pheno_ut
|
|
1369
|
+
* Signature: (DII[DLjava/lang/StringBuilder;)I
|
|
1370
|
+
*/
|
|
1371
|
+
JNIEXPORT jint JNICALL
|
|
1372
|
+
Java_swisseph_SwephExp_swe_1pheno_1ut(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint ipl,
|
|
1373
|
+
jint iflag, jdoubleArray attrArray, jobject errBuilder) {
|
|
1374
|
+
DEFINE_CHAR_SERR
|
|
1375
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, attrArray, attr)
|
|
1376
|
+
|
|
1377
|
+
int32 retc = swe_pheno_ut(tjd_ut, ipl, iflag, attr, serr);
|
|
1378
|
+
|
|
1379
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy, attrArray, attr)
|
|
1380
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1381
|
+
return retc;
|
|
1382
|
+
}
|
|
1383
|
+
|
|
1384
|
+
/*
|
|
1385
|
+
* double swe_refrac(double inalt, double atpress, double attemp, int calc_flag)
|
|
1386
|
+
*
|
|
1387
|
+
* Class: swisseph_SwephExp
|
|
1388
|
+
* Method: swe_refrac
|
|
1389
|
+
* Signature: (DDDI)D
|
|
1390
|
+
*/
|
|
1391
|
+
JNIEXPORT jdouble JNICALL
|
|
1392
|
+
Java_swisseph_SwephExp_swe_1refrac(JNIEnv *env, jclass swephexp, jdouble inalt,
|
|
1393
|
+
jdouble atpress, jdouble attemp, jint calc_flag) {
|
|
1394
|
+
return swe_refrac(inalt, atpress, attemp, calc_flag);
|
|
1395
|
+
}
|
|
1396
|
+
|
|
1397
|
+
/*
|
|
1398
|
+
* double swe_refrac_extended(double inalt, double geoalt, double atpress,
|
|
1399
|
+
* double attemp, double lapse_rate, int32 calc_flag, double *dret);
|
|
1400
|
+
*
|
|
1401
|
+
* Class: swisseph_SwephExp
|
|
1402
|
+
* Method: swe_refrac_extended
|
|
1403
|
+
* Signature: (DDDDDI[D)D
|
|
1404
|
+
*/
|
|
1405
|
+
JNIEXPORT jdouble JNICALL
|
|
1406
|
+
Java_swisseph_SwephExp_swe_1refrac_1extended(JNIEnv *env, jclass swephexp, jdouble inalt, jdouble geoalt,
|
|
1407
|
+
jdouble atpress, jdouble attemp, jdouble lapse_rate,
|
|
1408
|
+
jint calc_flag, jdoubleArray dretArray) {
|
|
1409
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy, dretArray, dret)
|
|
1410
|
+
|
|
1411
|
+
double rex = swe_refrac_extended(inalt, geoalt, atpress, attemp, lapse_rate, calc_flag, dret);
|
|
1412
|
+
|
|
1413
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy, dretArray, dret)
|
|
1414
|
+
return rex;
|
|
1415
|
+
}
|
|
1416
|
+
|
|
1417
|
+
/*
|
|
1418
|
+
* void swe_set_lapse_rate(double lapse_rate)
|
|
1419
|
+
*
|
|
1420
|
+
* Class: swisseph_SwephExp
|
|
1421
|
+
* Method: swe_set_lapse_rate
|
|
1422
|
+
* Signature: (D)V
|
|
1423
|
+
*/
|
|
1424
|
+
JNIEXPORT void JNICALL
|
|
1425
|
+
Java_swisseph_SwephExp_swe_1set_1lapse_1rate(JNIEnv *env, jclass swephexp, jdouble lapse_rate) {
|
|
1426
|
+
swe_set_lapse_rate(lapse_rate);
|
|
1427
|
+
}
|
|
1428
|
+
|
|
1429
|
+
/*
|
|
1430
|
+
* void swe_azalt(double tjd_ut,int32 calc_flag,double *geopos,double atpress,double attemp,double *xin,double *xaz)
|
|
1431
|
+
*
|
|
1432
|
+
* Class: swisseph_SwephExp
|
|
1433
|
+
* Method: swe_azalt
|
|
1434
|
+
* Signature: (DI[DDD[D[D)V
|
|
1435
|
+
*/
|
|
1436
|
+
JNIEXPORT void JNICALL
|
|
1437
|
+
Java_swisseph_SwephExp_swe_1azalt(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint calc_flag,
|
|
1438
|
+
jdoubleArray geoposArray, jdouble atpress, jdouble attemp,
|
|
1439
|
+
jdoubleArray xinArray, jdoubleArray xazArray) {
|
|
1440
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
1441
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xinArray, xin)
|
|
1442
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, xazArray, xaz)
|
|
1443
|
+
|
|
1444
|
+
swe_azalt(tjd_ut, calc_flag, geopos, atpress, attemp, xin, xaz);
|
|
1445
|
+
|
|
1446
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy1, geoposArray, geopos)
|
|
1447
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy2, xinArray, xin)
|
|
1448
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy3, xazArray, xaz)
|
|
1449
|
+
}
|
|
1450
|
+
|
|
1451
|
+
/*
|
|
1452
|
+
* void swe_azalt_rev(double tjd_ut,int32 calc_flag,double *geopos,double *xin,double *xout);
|
|
1453
|
+
*
|
|
1454
|
+
* Class: swisseph_SwephExp
|
|
1455
|
+
* Method: swe_azalt_rev
|
|
1456
|
+
* Signature: (DI[D[D[D)V
|
|
1457
|
+
*/
|
|
1458
|
+
JNIEXPORT void JNICALL
|
|
1459
|
+
Java_swisseph_SwephExp_swe_1azalt_1rev(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint calc_flag,
|
|
1460
|
+
jdoubleArray geoposArray, jdoubleArray xinArray, jdoubleArray xoutArray) {
|
|
1461
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, geoposArray, geopos)
|
|
1462
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xinArray, xin)
|
|
1463
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, xoutArray, xout)
|
|
1464
|
+
|
|
1465
|
+
swe_azalt_rev(tjd_ut, calc_flag, geopos, xin, xout);
|
|
1466
|
+
|
|
1467
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy1, geoposArray, geopos)
|
|
1468
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy2, xinArray, xin)
|
|
1469
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy3, xoutArray, xout)
|
|
1470
|
+
}
|
|
1471
|
+
|
|
1472
|
+
/*
|
|
1473
|
+
* int32 swe_rise_trans_true_hor(double tjd_ut, int32 ipl, char *starname, int32 epheflag, int32 rsmi,
|
|
1474
|
+
* double *geopos,double atpress, double attemp,double horhgt,double *tret,char *serr);
|
|
1475
|
+
*
|
|
1476
|
+
* Class: swisseph_SwephExp
|
|
1477
|
+
* Method: swe_rise_trans_true_hor
|
|
1478
|
+
* Signature: (DILjava/lang/StringBuilder;II[DDDD[DLjava/lang/StringBuilder;)I
|
|
1479
|
+
*/
|
|
1480
|
+
JNIEXPORT jint JNICALL
|
|
1481
|
+
Java_swisseph_SwephExp_swe_1rise_1trans_1true_1hor(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint ipl,
|
|
1482
|
+
jobject starNameBuilder, jint epheflag, jint rsmi,
|
|
1483
|
+
jdoubleArray geoposArray, jdouble atpress, jdouble attemp,
|
|
1484
|
+
jdouble horhgt, jdoubleArray tretArray, jobject errBuilder) {
|
|
1485
|
+
DEFINE_CHAR_SERR
|
|
1486
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1487
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1488
|
+
|
|
1489
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
1490
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1491
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
1492
|
+
|
|
1493
|
+
int32 retc = swe_rise_trans_true_hor(tjd_ut, ipl, star_name, epheflag,
|
|
1494
|
+
rsmi, geopos, atpress, attemp, horhgt, tret, serr);
|
|
1495
|
+
|
|
1496
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
1497
|
+
|
|
1498
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1499
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1500
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1501
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1502
|
+
return retc;
|
|
1503
|
+
}
|
|
1504
|
+
|
|
1505
|
+
/*
|
|
1506
|
+
* int32 swe_rise_trans(double tjd_ut, int32 ipl, char *starname, int32 epheflag, int32 rsmi,
|
|
1507
|
+
* double *geopos, double atpress, double attemp, double *tret, char *serr);
|
|
1508
|
+
*
|
|
1509
|
+
* Class: swisseph_SwephExp
|
|
1510
|
+
* Method: swe_rise_trans
|
|
1511
|
+
* Signature: (DILjava/lang/StringBuilder;II[DDD[DLjava/lang/StringBuilder;)I
|
|
1512
|
+
*/
|
|
1513
|
+
JNIEXPORT jint JNICALL
|
|
1514
|
+
Java_swisseph_SwephExp_swe_1rise_1trans(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint ipl,
|
|
1515
|
+
jobject starNameBuilder, jint epheflag, jint rsmi,
|
|
1516
|
+
jdoubleArray geoposArray, jdouble atpress,
|
|
1517
|
+
jdouble attemp, jdoubleArray tretArray,
|
|
1518
|
+
jobject errBuilder) {
|
|
1519
|
+
DEFINE_CHAR_SERR
|
|
1520
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1521
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1522
|
+
|
|
1523
|
+
jstring starName = getBuilderString(env, starNameBuilder);
|
|
1524
|
+
GET_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1525
|
+
CPY_CSTRING_TO_CHARS(starname, star_name)
|
|
1526
|
+
|
|
1527
|
+
int32 retc = swe_rise_trans(tjd_ut, ipl, star_name, epheflag, rsmi, geopos, atpress, attemp, tret, serr);
|
|
1528
|
+
|
|
1529
|
+
BUILDER_APPEND_IF_DIFF(starNameBuilder, starname, star_name)
|
|
1530
|
+
|
|
1531
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isGeoposCopy, geoposArray, geopos)
|
|
1532
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isTretCopy, tretArray, tret)
|
|
1533
|
+
RLZ_STRING_UTF_CHARS(isCopy, starName, starname)
|
|
1534
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1535
|
+
return retc;
|
|
1536
|
+
}
|
|
1537
|
+
|
|
1538
|
+
/*
|
|
1539
|
+
* int32 swe_nod_aps(double tjd_et, int32 ipl, int32 iflag, int32 method,
|
|
1540
|
+
* double *xnasc, double *xndsc, double *xperi, double *xaphe, char *serr);
|
|
1541
|
+
*
|
|
1542
|
+
* Class: swisseph_SwephExp
|
|
1543
|
+
* Method: swe_nod_aps
|
|
1544
|
+
* Signature: (DIII[D[D[D[DLjava/lang/StringBuilder;)I
|
|
1545
|
+
*/
|
|
1546
|
+
JNIEXPORT jint JNICALL
|
|
1547
|
+
Java_swisseph_SwephExp_swe_1nod_1aps(JNIEnv *env, jclass swephexp, jdouble tjd_et, jint ipl, jint iflag,
|
|
1548
|
+
jint method, jdoubleArray xnascArray, jdoubleArray xndscArray,
|
|
1549
|
+
jdoubleArray xperiArray, jdoubleArray xapheArray, jobject errBuilder) {
|
|
1550
|
+
DEFINE_CHAR_SERR
|
|
1551
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, xnascArray, xnasc)
|
|
1552
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xndscArray, xndsc)
|
|
1553
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, xperiArray, xperi)
|
|
1554
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, xapheArray, xaphe)
|
|
1555
|
+
|
|
1556
|
+
int32 retc = swe_nod_aps(tjd_et, ipl, iflag, method, xnasc, xndsc, xperi, xaphe, serr);
|
|
1557
|
+
|
|
1558
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, xnascArray, xnasc)
|
|
1559
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, xndscArray, xndsc)
|
|
1560
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, xperiArray, xperi)
|
|
1561
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, xapheArray, xaphe)
|
|
1562
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1563
|
+
return retc;
|
|
1564
|
+
}
|
|
1565
|
+
|
|
1566
|
+
/*
|
|
1567
|
+
* int32 swe_nod_aps_ut(double tjd_ut, int32 ipl, int32 iflag, int32 method,
|
|
1568
|
+
* double *xnasc, double *xndsc, double *xperi, double *xaphe, char *serr);
|
|
1569
|
+
*
|
|
1570
|
+
* Class: swisseph_SwephExp
|
|
1571
|
+
* Method: swe_nod_aps_ut
|
|
1572
|
+
* Signature: (DIII[D[D[D[DLjava/lang/StringBuilder;)I
|
|
1573
|
+
*/
|
|
1574
|
+
JNIEXPORT jint JNICALL
|
|
1575
|
+
Java_swisseph_SwephExp_swe_1nod_1aps_1ut(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jint ipl, jint iflag,
|
|
1576
|
+
jint method, jdoubleArray xnascArray, jdoubleArray xndscArray,
|
|
1577
|
+
jdoubleArray xperiArray, jdoubleArray xapheArray, jobject errBuilder) {
|
|
1578
|
+
DEFINE_CHAR_SERR
|
|
1579
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, xnascArray, xnasc)
|
|
1580
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xndscArray, xndsc)
|
|
1581
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, xperiArray, xperi)
|
|
1582
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy4, xapheArray, xaphe)
|
|
1583
|
+
|
|
1584
|
+
int32 retc = swe_nod_aps_ut(tjd_ut, ipl, iflag, method, xnasc, xndsc, xperi, xaphe, serr);
|
|
1585
|
+
|
|
1586
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, xnascArray, xnasc)
|
|
1587
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, xndscArray, xndsc)
|
|
1588
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, xperiArray, xperi)
|
|
1589
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy4, xapheArray, xaphe)
|
|
1590
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1591
|
+
return retc;
|
|
1592
|
+
}
|
|
1593
|
+
|
|
1594
|
+
/*
|
|
1595
|
+
* int32 swe_get_orbital_elements(double tjd_et, int32 ipl, int32 iflag, double *dret, char *serr)
|
|
1596
|
+
*
|
|
1597
|
+
* Class: swisseph_SwephExp
|
|
1598
|
+
* Method: swe_get_orbital_elements
|
|
1599
|
+
* Signature: (DII[DLjava/lang/StringBuilder;)I
|
|
1600
|
+
*/
|
|
1601
|
+
JNIEXPORT jint JNICALL
|
|
1602
|
+
Java_swisseph_SwephExp_swe_1get_1orbital_1elements(JNIEnv *env, jclass swephexp, jdouble tjd_et, jint ipl,
|
|
1603
|
+
jint iflag, jdoubleArray dretArray, jobject errBuilder) {
|
|
1604
|
+
DEFINE_CHAR_SERR
|
|
1605
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, dretArray, dret)
|
|
1606
|
+
|
|
1607
|
+
int32 retc = swe_get_orbital_elements(tjd_et, ipl, iflag, dret, serr);
|
|
1608
|
+
|
|
1609
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, dretArray, dret)
|
|
1610
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1611
|
+
return retc;
|
|
1612
|
+
}
|
|
1613
|
+
|
|
1614
|
+
/*
|
|
1615
|
+
* int32 swe_orbit_max_min_true_distance(double tjd_et, int32 ipl, int32 iflag,
|
|
1616
|
+
* double *dmax, double *dmin, double *dtrue, char *serr)
|
|
1617
|
+
*
|
|
1618
|
+
* Class: swisseph_SwephExp
|
|
1619
|
+
* Method: swe_orbit_max_min_true_distance
|
|
1620
|
+
* Signature: (DII[D[D[DLjava/lang/StringBuilder;)I
|
|
1621
|
+
*/
|
|
1622
|
+
JNIEXPORT jint JNICALL
|
|
1623
|
+
Java_swisseph_SwephExp_swe_1orbit_1max_1min_1true_1distance(JNIEnv *env, jclass swephexp, jdouble tjd_et,
|
|
1624
|
+
jint ipl, jint iflag, jdoubleArray dmaxArray,
|
|
1625
|
+
jdoubleArray dminArray, jdoubleArray dtrueArray,
|
|
1626
|
+
jobject errBuilder) {
|
|
1627
|
+
DEFINE_CHAR_SERR
|
|
1628
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, dmaxArray, dmax)
|
|
1629
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, dminArray, dmin)
|
|
1630
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy3, dtrueArray, dtrue)
|
|
1631
|
+
|
|
1632
|
+
int32 retc = swe_orbit_max_min_true_distance(tjd_et, ipl, iflag, dmax, dmin, dtrue, serr);
|
|
1633
|
+
|
|
1634
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, dmaxArray, dmax)
|
|
1635
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy2, dminArray, dmin)
|
|
1636
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy3, dtrueArray, dtrue)
|
|
1637
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1638
|
+
return retc;
|
|
1639
|
+
}
|
|
1640
|
+
|
|
1641
|
+
/*
|
|
1642
|
+
* Class: swisseph_SwephExp
|
|
1643
|
+
* Method: swe_deltat
|
|
1644
|
+
* Signature: (D)D
|
|
1645
|
+
*/
|
|
1646
|
+
JNIEXPORT jdouble JNICALL
|
|
1647
|
+
Java_swisseph_SwephExp_swe_1deltat(JNIEnv *env, jclass swephexp, jdouble tjd) {
|
|
1648
|
+
return swe_deltat(tjd);
|
|
1649
|
+
}
|
|
1650
|
+
|
|
1651
|
+
/*
|
|
1652
|
+
* Class: swisseph_SwephExp
|
|
1653
|
+
* Method: swe_deltat_ex
|
|
1654
|
+
* Signature: (DILjava/lang/StringBuilder;)D
|
|
1655
|
+
*/
|
|
1656
|
+
JNIEXPORT jdouble JNICALL
|
|
1657
|
+
Java_swisseph_SwephExp_swe_1deltat_1ex(JNIEnv *env, jclass swephexp,
|
|
1658
|
+
jdouble tjd, jint iflag, jobject errBuilder) {
|
|
1659
|
+
DEFINE_CHAR_SERR
|
|
1660
|
+
|
|
1661
|
+
double deltat = swe_deltat_ex(tjd, iflag, serr);
|
|
1662
|
+
|
|
1663
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1664
|
+
return deltat;
|
|
1665
|
+
}
|
|
1666
|
+
|
|
1667
|
+
/*
|
|
1668
|
+
* int32 swe_time_equ(double tjd, double *te, char *serr)
|
|
1669
|
+
*
|
|
1670
|
+
* Class: swisseph_SwephExp
|
|
1671
|
+
* Method: swe_time_equ
|
|
1672
|
+
* Signature: (D[DLjava/lang/StringBuilder;)I
|
|
1673
|
+
*/
|
|
1674
|
+
JNIEXPORT jint JNICALL
|
|
1675
|
+
Java_swisseph_SwephExp_swe_1time_1equ(JNIEnv *env, jclass swephexp, jdouble tjd,
|
|
1676
|
+
jdoubleArray teArray, jobject errBuilder) {
|
|
1677
|
+
DEFINE_CHAR_SERR
|
|
1678
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, teArray, te)
|
|
1679
|
+
|
|
1680
|
+
int32 retc = swe_time_equ(tjd, te, serr);
|
|
1681
|
+
|
|
1682
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, teArray, te)
|
|
1683
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1684
|
+
return retc;
|
|
1685
|
+
}
|
|
1686
|
+
|
|
1687
|
+
/*
|
|
1688
|
+
* int32 swe_lmt_to_lat(double tjd_lmt, double geolon, double *tjd_lat, char *serr)
|
|
1689
|
+
*
|
|
1690
|
+
* Class: swisseph_SwephExp
|
|
1691
|
+
* Method: swe_lmt_to_lat
|
|
1692
|
+
* Signature: (DD[DLjava/lang/StringBuilder;)I
|
|
1693
|
+
*/
|
|
1694
|
+
JNIEXPORT jint JNICALL
|
|
1695
|
+
Java_swisseph_SwephExp_swe_1lmt_1to_1lat(JNIEnv *env, jclass swephexp, jdouble tjd_lmt, jdouble geolon,
|
|
1696
|
+
jdoubleArray tjdLatArray, jobject errBuilder) {
|
|
1697
|
+
DEFINE_CHAR_SERR
|
|
1698
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, tjdLatArray, tjd_lat)
|
|
1699
|
+
|
|
1700
|
+
int32 retc = swe_lmt_to_lat(tjd_lmt, geolon, tjd_lat, serr);
|
|
1701
|
+
|
|
1702
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, tjdLatArray, tjd_lat)
|
|
1703
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1704
|
+
return retc;
|
|
1705
|
+
}
|
|
1706
|
+
|
|
1707
|
+
/*
|
|
1708
|
+
* int32 swe_lat_to_lmt(double tjd_lat, double geolon, double *tjd_lmt, char *serr)
|
|
1709
|
+
*
|
|
1710
|
+
* Class: swisseph_SwephExp
|
|
1711
|
+
* Method: swe_lat_to_lmt
|
|
1712
|
+
* Signature: (DD[DLjava/lang/StringBuilder;)I
|
|
1713
|
+
*/
|
|
1714
|
+
JNIEXPORT jint JNICALL
|
|
1715
|
+
Java_swisseph_SwephExp_swe_1lat_1to_1lmt(JNIEnv *env, jclass swephexp, jdouble tjd_lat, jdouble geolon,
|
|
1716
|
+
jdoubleArray tjdLmtArray, jobject errBuilder) {
|
|
1717
|
+
DEFINE_CHAR_SERR
|
|
1718
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, tjdLmtArray, tjd_lmt)
|
|
1719
|
+
|
|
1720
|
+
int32 retc = swe_lat_to_lmt(tjd_lat, geolon, tjd_lmt, serr);
|
|
1721
|
+
|
|
1722
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isDblCopy, tjdLmtArray, tjd_lmt)
|
|
1723
|
+
ERR_BUILDER_APPEND_IF_ERR
|
|
1724
|
+
return retc;
|
|
1725
|
+
}
|
|
1726
|
+
|
|
1727
|
+
/*
|
|
1728
|
+
* double swe_sidtime0(double tjd_ut, double eps, double nut)
|
|
1729
|
+
*
|
|
1730
|
+
* Class: swisseph_SwephExp
|
|
1731
|
+
* Method: swe_sidtime0
|
|
1732
|
+
* Signature: (DDD)D
|
|
1733
|
+
*/
|
|
1734
|
+
JNIEXPORT jdouble JNICALL
|
|
1735
|
+
Java_swisseph_SwephExp_swe_1sidtime0(JNIEnv *env, jclass swephexp, jdouble tjd_ut, jdouble eps, jdouble nut) {
|
|
1736
|
+
return swe_sidtime0(tjd_ut, eps, nut);
|
|
1737
|
+
}
|
|
1738
|
+
|
|
1739
|
+
/*
|
|
1740
|
+
* double swe_sidtime(double tjd_ut)
|
|
1741
|
+
*
|
|
1742
|
+
* Class: swisseph_SwephExp
|
|
1743
|
+
* Method: swe_sidtime
|
|
1744
|
+
* Signature: (D)D
|
|
1745
|
+
*/
|
|
1746
|
+
JNIEXPORT jdouble JNICALL
|
|
1747
|
+
Java_swisseph_SwephExp_swe_1sidtime(JNIEnv *env, jclass swephexp, jdouble tjd_ut) {
|
|
1748
|
+
return swe_sidtime(tjd_ut);
|
|
1749
|
+
}
|
|
1750
|
+
|
|
1751
|
+
/*
|
|
1752
|
+
* void swe_set_interpolate_nut(AS_BOOL do_interpolate)
|
|
1753
|
+
*
|
|
1754
|
+
* Class: swisseph_SwephExp
|
|
1755
|
+
* Method: swe_set_interpolate_nut
|
|
1756
|
+
* Signature: (I)V
|
|
1757
|
+
*/
|
|
1758
|
+
JNIEXPORT void JNICALL
|
|
1759
|
+
Java_swisseph_SwephExp_swe_1set_1interpolate_1nut(JNIEnv *env, jclass swephexp, jint do_interpolate) {
|
|
1760
|
+
swe_set_interpolate_nut(do_interpolate);
|
|
1761
|
+
}
|
|
1762
|
+
|
|
1763
|
+
/*
|
|
1764
|
+
* void swe_cotrans(double *xpo, double *xpn, double eps)
|
|
1765
|
+
*
|
|
1766
|
+
* Class: swisseph_SwephExp
|
|
1767
|
+
* Method: swe_cotrans
|
|
1768
|
+
* Signature: ([D[DD)V
|
|
1769
|
+
*/
|
|
1770
|
+
JNIEXPORT void JNICALL
|
|
1771
|
+
Java_swisseph_SwephExp_swe_1cotrans(JNIEnv *env, jclass swephexp,
|
|
1772
|
+
jdoubleArray xpoArray, jdoubleArray xpnArray, jdouble eps) {
|
|
1773
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, xpoArray, xpo)
|
|
1774
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xpnArray, xpn)
|
|
1775
|
+
|
|
1776
|
+
swe_cotrans(xpo, xpn, eps);
|
|
1777
|
+
|
|
1778
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy1, xpoArray, xpo)
|
|
1779
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy2, xpnArray, xpn)
|
|
1780
|
+
}
|
|
1781
|
+
|
|
1782
|
+
/*
|
|
1783
|
+
* void swe_cotrans_sp(double *xpo, double *xpn, double eps)
|
|
1784
|
+
*
|
|
1785
|
+
* Class: swisseph_SwephExp
|
|
1786
|
+
* Method: swe_cotrans_sp
|
|
1787
|
+
* Signature: ([D[DD)V
|
|
1788
|
+
*/
|
|
1789
|
+
JNIEXPORT void JNICALL
|
|
1790
|
+
Java_swisseph_SwephExp_swe_1cotrans_1sp(JNIEnv *env, jclass swephexp,
|
|
1791
|
+
jdoubleArray xpoArray, jdoubleArray xpnArray, jdouble eps) {
|
|
1792
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, xpoArray, xpo)
|
|
1793
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xpnArray, xpn)
|
|
1794
|
+
|
|
1795
|
+
swe_cotrans_sp(xpo, xpn, eps);
|
|
1796
|
+
|
|
1797
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy1, xpoArray, xpo)
|
|
1798
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy2, xpnArray, xpn)
|
|
1799
|
+
}
|
|
1800
|
+
|
|
1801
|
+
/*
|
|
1802
|
+
* double swe_get_tid_acc(void)
|
|
1803
|
+
*
|
|
1804
|
+
* Class: swisseph_SwephExp
|
|
1805
|
+
* Method: swe_get_tid_acc
|
|
1806
|
+
* Signature: ()D
|
|
1807
|
+
*/
|
|
1808
|
+
JNIEXPORT jdouble JNICALL
|
|
1809
|
+
Java_swisseph_SwephExp_swe_1get_1tid_1acc(JNIEnv *env, jclass swephexp) {
|
|
1810
|
+
return swe_get_tid_acc();
|
|
1811
|
+
}
|
|
1812
|
+
|
|
1813
|
+
/*
|
|
1814
|
+
* void swe_set_tid_acc(double t_acc)
|
|
1815
|
+
*
|
|
1816
|
+
* Class: swisseph_SwephExp
|
|
1817
|
+
* Method: swe_set_tid_acc
|
|
1818
|
+
* Signature: (D)V
|
|
1819
|
+
*/
|
|
1820
|
+
JNIEXPORT void JNICALL
|
|
1821
|
+
Java_swisseph_SwephExp_swe_1set_1tid_1acc(JNIEnv *env, jclass swephexp, jdouble t_acc) {
|
|
1822
|
+
swe_set_tid_acc(t_acc);
|
|
1823
|
+
}
|
|
1824
|
+
|
|
1825
|
+
/*
|
|
1826
|
+
* void swe_set_delta_t_userdef(double dt)
|
|
1827
|
+
*
|
|
1828
|
+
* Class: swisseph_SwephExp
|
|
1829
|
+
* Method: swe_set_delta_t_userdef
|
|
1830
|
+
* Signature: (D)V
|
|
1831
|
+
*/
|
|
1832
|
+
JNIEXPORT void JNICALL
|
|
1833
|
+
Java_swisseph_SwephExp_swe_1set_1delta_1t_1userdef(JNIEnv *env, jclass swephexp, jdouble dt) {
|
|
1834
|
+
swe_set_delta_t_userdef(dt);
|
|
1835
|
+
}
|
|
1836
|
+
|
|
1837
|
+
/*
|
|
1838
|
+
* double swe_degnorm(double x);
|
|
1839
|
+
*
|
|
1840
|
+
* Class: swisseph_SwephExp
|
|
1841
|
+
* Method: swe_degnorm
|
|
1842
|
+
* Signature: (D)D
|
|
1843
|
+
*/
|
|
1844
|
+
JNIEXPORT jdouble JNICALL
|
|
1845
|
+
Java_swisseph_SwephExp_swe_1degnorm(JNIEnv *env, jclass swephexp, jdouble x) {
|
|
1846
|
+
return swe_degnorm(x);
|
|
1847
|
+
}
|
|
1848
|
+
|
|
1849
|
+
/*
|
|
1850
|
+
* double swe_radnorm(double x);
|
|
1851
|
+
*
|
|
1852
|
+
* Class: swisseph_SwephExp
|
|
1853
|
+
* Method: swe_radnorm
|
|
1854
|
+
* Signature: (D)D
|
|
1855
|
+
*/
|
|
1856
|
+
JNIEXPORT jdouble JNICALL
|
|
1857
|
+
Java_swisseph_SwephExp_swe_1radnorm(JNIEnv *env, jclass swephexp, jdouble x) {
|
|
1858
|
+
return swe_radnorm(x);
|
|
1859
|
+
}
|
|
1860
|
+
|
|
1861
|
+
/*
|
|
1862
|
+
* double swe_rad_midp(double x1, double x0);
|
|
1863
|
+
*
|
|
1864
|
+
* Class: swisseph_SwephExp
|
|
1865
|
+
* Method: swe_rad_midp
|
|
1866
|
+
* Signature: (DD)D
|
|
1867
|
+
*/
|
|
1868
|
+
JNIEXPORT jdouble JNICALL
|
|
1869
|
+
Java_swisseph_SwephExp_swe_1rad_1midp(JNIEnv *env, jclass swephexp, jdouble x1, jdouble x0) {
|
|
1870
|
+
return swe_rad_midp(x1, x0);
|
|
1871
|
+
}
|
|
1872
|
+
|
|
1873
|
+
/*
|
|
1874
|
+
* double swe_deg_midp(double x1, double x0);
|
|
1875
|
+
*
|
|
1876
|
+
* Class: swisseph_SwephExp
|
|
1877
|
+
* Method: swe_deg_midp
|
|
1878
|
+
* Signature: (DD)D
|
|
1879
|
+
*/
|
|
1880
|
+
JNIEXPORT jdouble JNICALL
|
|
1881
|
+
Java_swisseph_SwephExp_swe_1deg_1midp(JNIEnv *env, jclass swephexp, jdouble x1, jdouble x0) {
|
|
1882
|
+
return swe_deg_midp(x1, x0);
|
|
1883
|
+
}
|
|
1884
|
+
|
|
1885
|
+
/*
|
|
1886
|
+
* void swe_split_deg(double ddeg, int32 roundflag, int32 *ideg, int32 *imin, int32 *isec, double *dsecfr, int32 *isgn)
|
|
1887
|
+
*
|
|
1888
|
+
* Class: swisseph_SwephExp
|
|
1889
|
+
* Method: swe_split_deg
|
|
1890
|
+
* Signature: (DI[I[D[I)V
|
|
1891
|
+
*/
|
|
1892
|
+
JNIEXPORT void JNICALL
|
|
1893
|
+
Java_swisseph_SwephExp_swe_1split_1deg(JNIEnv *env, jclass swephexp, jdouble ddeg, jint roundflag,
|
|
1894
|
+
jintArray iDmsArray, jdoubleArray dSfrArray, jintArray iSgnArray) {
|
|
1895
|
+
GET_INT_ARRAY_ELEMENTS(isInt1Copy, iDmsArray, dmsOut)
|
|
1896
|
+
GET_INT_ARRAY_ELEMENTS(isInt2Copy, iSgnArray, sgnOut)
|
|
1897
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isDblCopy, dSfrArray, sfrOut)
|
|
1898
|
+
|
|
1899
|
+
int32 dmss[4];
|
|
1900
|
+
double scfr[1];
|
|
1901
|
+
|
|
1902
|
+
swe_split_deg(ddeg, roundflag, &dmss[0], &dmss[1], &dmss[2], &scfr[0], &dmss[3]);
|
|
1903
|
+
|
|
1904
|
+
dmsOut[0] = dmss[0];
|
|
1905
|
+
dmsOut[1] = dmss[1];
|
|
1906
|
+
dmsOut[2] = dmss[2];
|
|
1907
|
+
sgnOut[0] = dmss[3];
|
|
1908
|
+
sfrOut[0] = scfr[0];
|
|
1909
|
+
|
|
1910
|
+
RLZ_INT_ARRAY_ELEMENTS_OK(isInt1Copy, iDmsArray, dmsOut)
|
|
1911
|
+
RLZ_INT_ARRAY_ELEMENTS_OK(isInt2Copy, iSgnArray, sgnOut)
|
|
1912
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isDblCopy, dSfrArray, sfrOut)
|
|
1913
|
+
}
|
|
1914
|
+
|
|
1915
|
+
/*
|
|
1916
|
+
* double swe_solcross(double x2cross, double jd_et, int32 flag, char *serr)
|
|
1917
|
+
*
|
|
1918
|
+
* Class: swisseph_SwephExp
|
|
1919
|
+
* Method: swe_solcross
|
|
1920
|
+
*/
|
|
1921
|
+
JNIEXPORT jdouble JNICALL
|
|
1922
|
+
Java_swisseph_SwephExp_swe_1solcross(JNIEnv *env, jclass swephexp, jdouble x2cross, jdouble jd_et, jint flag, jobject errBuilder) {
|
|
1923
|
+
DEFINE_CHAR_SERR
|
|
1924
|
+
|
|
1925
|
+
jdouble juldate = swe_solcross(x2cross, jd_et, flag, serr);
|
|
1926
|
+
|
|
1927
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1928
|
+
return juldate;
|
|
1929
|
+
}
|
|
1930
|
+
|
|
1931
|
+
/*
|
|
1932
|
+
* double swe_solcross_ut(double x2cross, double jd_ut, int32 flag, char *serr)
|
|
1933
|
+
*
|
|
1934
|
+
* Class: swisseph_SwephExp
|
|
1935
|
+
* Method: swe_solcross_ut
|
|
1936
|
+
*/
|
|
1937
|
+
JNIEXPORT jdouble JNICALL
|
|
1938
|
+
Java_swisseph_SwephExp_swe_1solcross_1ut(JNIEnv *env, jclass swephexp, jdouble x2cross, jdouble jd_ut, jint flag, jobject errBuilder) {
|
|
1939
|
+
DEFINE_CHAR_SERR
|
|
1940
|
+
|
|
1941
|
+
jdouble juldate = swe_solcross_ut(x2cross, jd_ut, flag, serr);
|
|
1942
|
+
|
|
1943
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1944
|
+
return juldate;
|
|
1945
|
+
}
|
|
1946
|
+
|
|
1947
|
+
/*
|
|
1948
|
+
* double swe_mooncross(double x2cross, double jd_et, int flag, char *serr)
|
|
1949
|
+
*
|
|
1950
|
+
* Class: swisseph_SwephExp
|
|
1951
|
+
* Method: swe_mooncross
|
|
1952
|
+
*/
|
|
1953
|
+
JNIEXPORT jdouble JNICALL
|
|
1954
|
+
Java_swisseph_SwephExp_swe_1mooncross(JNIEnv *env, jclass swephexp, jdouble x2cross, jdouble jd_et, jint flag, jobject errBuilder) {
|
|
1955
|
+
DEFINE_CHAR_SERR
|
|
1956
|
+
|
|
1957
|
+
jdouble juldate = swe_mooncross(x2cross, jd_et, flag, serr);
|
|
1958
|
+
|
|
1959
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1960
|
+
return juldate;
|
|
1961
|
+
}
|
|
1962
|
+
|
|
1963
|
+
/*
|
|
1964
|
+
* double swe_mooncross_ut(double x2cross, double jd_ut, int flag, char *serr)
|
|
1965
|
+
*
|
|
1966
|
+
* Class: swisseph_SwephExp
|
|
1967
|
+
* Method: swe_mooncross_ut
|
|
1968
|
+
*/
|
|
1969
|
+
JNIEXPORT jdouble JNICALL
|
|
1970
|
+
Java_swisseph_SwephExp_swe_1mooncross_1ut(JNIEnv *env, jclass swephexp, jdouble x2cross, jdouble jd_ut, jint flag, jobject errBuilder) {
|
|
1971
|
+
DEFINE_CHAR_SERR
|
|
1972
|
+
|
|
1973
|
+
jdouble juldate = swe_mooncross_ut(x2cross, jd_ut, flag, serr);
|
|
1974
|
+
|
|
1975
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1976
|
+
return juldate;
|
|
1977
|
+
}
|
|
1978
|
+
|
|
1979
|
+
/*
|
|
1980
|
+
* double swe_mooncross_node(double jd_et, int flag, double *xlon, double *xla, char *serr)
|
|
1981
|
+
*
|
|
1982
|
+
* Class: swisseph_SwephExp
|
|
1983
|
+
* Method: swe_mooncross_node
|
|
1984
|
+
*/
|
|
1985
|
+
JNIEXPORT jdouble JNICALL
|
|
1986
|
+
Java_swisseph_SwephExp_swe_1mooncross_1node(JNIEnv *env, jclass swephexp, jdouble jd_et, jint flag,
|
|
1987
|
+
jdoubleArray xlonArray, jdoubleArray xlatArray, jobject errBuilder) {
|
|
1988
|
+
DEFINE_CHAR_SERR
|
|
1989
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, xlonArray, xlon)
|
|
1990
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xlatArray, xlat)
|
|
1991
|
+
|
|
1992
|
+
double juldate = swe_mooncross_node(jd_et, flag, xlon, xlat, serr);
|
|
1993
|
+
|
|
1994
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy1, xlonArray, xlon)
|
|
1995
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy2, xlatArray, xlat)
|
|
1996
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
1997
|
+
return juldate;
|
|
1998
|
+
}
|
|
1999
|
+
|
|
2000
|
+
/*
|
|
2001
|
+
* double swe_mooncross_node_ut(double jd_ut, int flag, double *xlon, double *xla, char *serr)
|
|
2002
|
+
*
|
|
2003
|
+
* Class: swisseph_SwephExp
|
|
2004
|
+
* Method: swe_mooncross_node_ut
|
|
2005
|
+
*/
|
|
2006
|
+
JNIEXPORT jdouble JNICALL
|
|
2007
|
+
Java_swisseph_SwephExp_swe_1mooncross_1node_1ut(JNIEnv *env, jclass swephexp, jdouble jd_ut, jint flag,
|
|
2008
|
+
jdoubleArray xlonArray, jdoubleArray xlatArray, jobject errBuilder) {
|
|
2009
|
+
DEFINE_CHAR_SERR
|
|
2010
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, xlonArray, xlon)
|
|
2011
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy2, xlatArray, xlat)
|
|
2012
|
+
|
|
2013
|
+
double juldate = swe_mooncross_node_ut(jd_ut, flag, xlon, xlat, serr);
|
|
2014
|
+
|
|
2015
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy1, xlonArray, xlon)
|
|
2016
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS_OK(isCopy2, xlatArray, xlat)
|
|
2017
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
2018
|
+
return juldate;
|
|
2019
|
+
}
|
|
2020
|
+
|
|
2021
|
+
/*
|
|
2022
|
+
* int32 swe_helio_cross(int ipl, double x2cross, double jd_et, int iflag, int dir, double *jd_cross, char *serr)
|
|
2023
|
+
*
|
|
2024
|
+
* Class: swisseph_SwephExp
|
|
2025
|
+
* Method: swe_helio_cross
|
|
2026
|
+
*/
|
|
2027
|
+
JNIEXPORT jint JNICALL
|
|
2028
|
+
Java_swisseph_SwephExp_swe_1helio_1cross(JNIEnv *env, jclass swephexp, jint ipl, jdouble x2cross, jdouble jd_et,
|
|
2029
|
+
jint iflag, jint dir, jdoubleArray jdCrossArray, jobject errBuilder) {
|
|
2030
|
+
DEFINE_CHAR_SERR
|
|
2031
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, jdCrossArray, jd_cross)
|
|
2032
|
+
|
|
2033
|
+
int32 retc = swe_helio_cross(ipl, x2cross, jd_et, iflag, dir, jd_cross, serr);
|
|
2034
|
+
|
|
2035
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, jdCrossArray, jd_cross)
|
|
2036
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
2037
|
+
return retc;
|
|
2038
|
+
}
|
|
2039
|
+
|
|
2040
|
+
/*
|
|
2041
|
+
* int32 swe_helio_cross_ut(int32 ipl, double x2cross, double jd_ut, int32 iflag, int32 dir, double *jd_cross, char *serr)
|
|
2042
|
+
*
|
|
2043
|
+
* Class: swisseph_SwephExp
|
|
2044
|
+
* Method: swe_helio_cross_ut
|
|
2045
|
+
*/
|
|
2046
|
+
JNIEXPORT jint JNICALL
|
|
2047
|
+
Java_swisseph_SwephExp_swe_1helio_1cross_1ut(JNIEnv *env, jclass swephexp, jint ipl, jdouble x2cross, jdouble jd_ut,
|
|
2048
|
+
jint iflag, jint dir, jdoubleArray jdCrossArray, jobject errBuilder) {
|
|
2049
|
+
DEFINE_CHAR_SERR
|
|
2050
|
+
GET_DOUBLE_ARRAY_ELEMENTS(isCopy1, jdCrossArray, jd_cross)
|
|
2051
|
+
|
|
2052
|
+
int32 retc = swe_helio_cross_ut(ipl, x2cross, jd_ut, iflag, dir, jd_cross, serr);
|
|
2053
|
+
|
|
2054
|
+
RLZ_DOUBLE_ARRAY_ELEMENTS(isCopy1, jdCrossArray, jd_cross)
|
|
2055
|
+
ERR_BUILDER_APPEND_IF_SERR
|
|
2056
|
+
return retc;
|
|
2057
|
+
}
|