Imported Upstream version 1.0.0
[platform/upstream/iotivity.git] / service / resource-encapsulation / android / service / src / main / jni / JniRcsResourceObject.h
1 /******************************************************************
2  *
3  * Copyright 2015 Samsung Electronics All Rights Reserved.
4  *
5  *
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  *      http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  ******************************************************************/
20
21 #ifndef JNI_RCS_RESOURCE_OBJECT_H
22 #define JNI_RCS_RESOURCE_OBJECT_H
23
24 #include <jni.h>
25
26 class JNIEnvWrapper;
27
28 void initRCSResourceObject(JNIEnvWrapper*);
29 void clearRCSResourceObject(JNIEnvWrapper*);
30
31 #ifdef __cplusplus
32 extern "C" {
33 #endif
34
35 JNIEXPORT jint JNICALL
36 Java_org_iotivity_service_server_RcsResponse_nativeGetDefaultErrorCode
37 (JNIEnv*, jclass);
38
39 JNIEXPORT jobject JNICALL
40 Java_org_iotivity_service_server_RcsResourceObject_nativeBuild
41 (JNIEnv*, jclass, jstring uri, jstring type, jstring interface, jboolean isObservable,
42         jboolean isDiscovervable, jobject attrs);
43
44 JNIEXPORT void JNICALL
45 Java_org_iotivity_service_server_RcsResourceObject_nativeSetAttribute
46 (JNIEnv*, jobject, jstring key, jobject value);
47
48 JNIEXPORT jobject JNICALL
49 Java_org_iotivity_service_server_RcsResourceObject_nativeGetAttributeValue
50 (JNIEnv*, jobject, jstring key);
51
52 JNIEXPORT jboolean JNICALL
53 Java_org_iotivity_service_server_RcsResourceObject_nativeRemoveAttribute
54 (JNIEnv*, jobject, jstring key);
55
56 JNIEXPORT jboolean JNICALL
57 Java_org_iotivity_service_server_RcsResourceObject_nativeContainsAttribute
58 (JNIEnv*, jobject, jstring key);
59
60 JNIEXPORT jobject JNICALL
61 Java_org_iotivity_service_server_RcsResourceObject_nativeGetAttributes
62 (JNIEnv*, jobject);
63
64 JNIEXPORT jboolean JNICALL
65 Java_org_iotivity_service_server_RcsResourceObject_nativeIsObservable
66 (JNIEnv*, jobject);
67
68 JNIEXPORT jboolean JNICALL
69 Java_org_iotivity_service_server_RcsResourceObject_nativeIsDiscoverable
70 (JNIEnv*, jobject);
71
72 JNIEXPORT void JNICALL
73 Java_org_iotivity_service_server_RcsResourceObject_nativeSetGetRequestHandler
74 (JNIEnv*, jobject, jobject handler);
75
76 JNIEXPORT void JNICALL
77 Java_org_iotivity_service_server_RcsResourceObject_nativeSetSetRequestHandler
78 (JNIEnv*, jobject, jobject handler);
79
80 JNIEXPORT void JNICALL
81 Java_org_iotivity_service_server_RcsResourceObject_nativeAddAttributeUpdatedListener
82 (JNIEnv*, jobject, jstring key, jobject listenr);
83
84 JNIEXPORT jboolean JNICALL
85 Java_org_iotivity_service_server_RcsResourceObject_nativeRemoveAttributeUpdatedListener
86 (JNIEnv*, jobject, jstring key);
87
88 JNIEXPORT void JNICALL Java_org_iotivity_service_server_RcsResourceObject_nativeNotify
89 (JNIEnv*, jobject);
90
91 JNIEXPORT void JNICALL
92 Java_org_iotivity_service_server_RcsResourceObject_nativeSetAutoNotifyPolicy
93 (JNIEnv*, jobject, jobject policyObj);
94
95 JNIEXPORT jobject JNICALL
96 Java_org_iotivity_service_server_RcsResourceObject_nativeGetAutoNotifyPolicy
97 (JNIEnv*, jobject);
98
99 JNIEXPORT void JNICALL
100 Java_org_iotivity_service_server_RcsResourceObject_nativeSetSetRequestHandlerPolicy
101 (JNIEnv*, jobject, jobject policyObj);
102
103 JNIEXPORT jobject JNICALL
104 Java_org_iotivity_service_server_RcsResourceObject_nativeGetSetRequestHandlerPolicy
105 (JNIEnv*, jobject);
106
107 #ifdef __cplusplus
108 }
109 #endif
110 #endif // JNI_RCS_RESOURCE_OBJECT_H
111
112