diff options
author | Lyubomir Marinov <lyubomir.marinov@jitsi.org> | 2011-01-05 16:10:17 +0000 |
---|---|---|
committer | Lyubomir Marinov <lyubomir.marinov@jitsi.org> | 2011-01-05 16:10:17 +0000 |
commit | 40440012726f6a9974d1aa927d924bbb0153dd41 (patch) | |
tree | 545739c22e190c41fd6a63d6aa8609aa639936eb /src/native/addrbook/macosx | |
parent | 6d7e078bf6bc16fc47c0c1d904608b8d0aec2c3c (diff) | |
download | jitsi-40440012726f6a9974d1aa927d924bbb0153dd41.zip jitsi-40440012726f6a9974d1aa927d924bbb0153dd41.tar.gz jitsi-40440012726f6a9974d1aa927d924bbb0153dd41.tar.bz2 |
Commits work in progress on adding support for the Address Book of Mac OS X.
Diffstat (limited to 'src/native/addrbook/macosx')
2 files changed, 189 insertions, 0 deletions
diff --git a/src/native/addrbook/macosx/net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery.h b/src/native/addrbook/macosx/net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery.h new file mode 100644 index 0000000..c4d410e --- /dev/null +++ b/src/native/addrbook/macosx/net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery.h @@ -0,0 +1,141 @@ +/* DO NOT EDIT THIS FILE - it is machine generated */
+#include <jni.h>
+/* Header for class net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery */
+
+#ifndef _Included_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+#define _Included_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+#ifdef __cplusplus
+extern "C" {
+#endif
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: ABRecord_valuesForProperties
+ * Signature: (J[J)[Ljava/lang/Object;
+ */
+JNIEXPORT jobjectArray JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_ABRecord_1valuesForProperties
+ (JNIEnv *, jclass, jlong, jlongArray);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: foreachPerson
+ * Signature: (Ljava/lang/String;Lnet/java/sip/communicator/plugin/addrbook/PtrCallback;)V
+ */
+JNIEXPORT void JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_foreachPerson
+ (JNIEnv *, jclass, jstring, jobject);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABAIMInstantProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABAIMInstantProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABEmailProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABEmailProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABFirstNameProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABFirstNameProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABFirstNamePhoneticProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABFirstNamePhoneticProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABICQInstantProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABICQInstantProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABJabberInstantProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABJabberInstantProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABLastNameProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABLastNameProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABLastNamePhoneticProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABLastNamePhoneticProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABMiddleNameProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABMiddleNameProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABMiddleNamePhoneticProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABMiddleNamePhoneticProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABMSNInstantProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABMSNInstantProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABNicknameProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABNicknameProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABPhoneProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABPhoneProperty
+ (JNIEnv *, jclass);
+
+/*
+ * Class: net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery
+ * Method: kABYahooInstantProperty
+ * Signature: ()J
+ */
+JNIEXPORT jlong JNICALL Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_kABYahooInstantProperty
+ (JNIEnv *, jclass);
+
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/src/native/addrbook/macosx/net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery.m b/src/native/addrbook/macosx/net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery.m new file mode 100644 index 0000000..358e7a8 --- /dev/null +++ b/src/native/addrbook/macosx/net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery.m @@ -0,0 +1,48 @@ +/*
+ * SIP Communicator, the OpenSource Java VoIP and Instant Messaging client.
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+
+#include "net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery.h"
+
+#import <AddressBook/AddressBook.h>
+
+JNIEXPORT jobjectArray JNICALL
+Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_ABRecord_1valuesForProperties
+ (JNIEnv *jniEnv, jclass clazz, jlong record, jlongArray properties)
+{
+ /* TODO Auto-generated method stub */
+ return NULL;
+}
+
+JNIEXPORT void JNICALL
+Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_foreachPerson
+ (JNIEnv *jniEnv, jclass clazz, jstring query, jobject callback)
+{
+ /* TODO Auto-generated method stub */
+}
+
+#define DEFINE_ABPERSON_PROPERTY_GETTER(property) \
+ JNIEXPORT jlong JNICALL \
+ Java_net_java_sip_communicator_plugin_addrbook_macosx_MacOSXAddrBookContactQuery_##property \
+ (JNIEnv *jniEnv, jclass clazz) \
+ { \
+ return (jlong) property; \
+ }
+
+DEFINE_ABPERSON_PROPERTY_GETTER(kABAIMInstantProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABEmailProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABFirstNameProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABFirstNamePhoneticProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABICQInstantProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABJabberInstantProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABLastNameProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABLastNamePhoneticProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABMiddleNameProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABMiddleNamePhoneticProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABMSNInstantProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABNicknameProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABPhoneProperty)
+DEFINE_ABPERSON_PROPERTY_GETTER(kABYahooInstantProperty)
|