2 * //******************************************************************
4 * // Copyright 2015 Intel Corporation.
6 * //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
8 * // Licensed under the Apache License, Version 2.0 (the "License");
9 * // you may not use this file except in compliance with the License.
10 * // You may obtain a copy of the License at
12 * // http://www.apache.org/licenses/LICENSE-2.0
14 * // Unless required by applicable law or agreed to in writing, software
15 * // distributed under the License is distributed on an "AS IS" BASIS,
16 * // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
17 * // See the License for the specific language governing permissions and
18 * // limitations under the License.
20 * //-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
22 #include "JniOcStack.h"
24 #ifndef _Included_org_iotivity_base_OcResourceRequest
25 #define _Included_org_iotivity_base_OcResourceRequest
29 class JniOcResourceRequest
32 JniOcResourceRequest(const std::shared_ptr<OCResourceRequest> resourceRequest);
34 ~JniOcResourceRequest();
36 std::string getRequestType();
38 const QueryParamsMap& getQueryParameters() const;
40 int getRequestHandlerFlag() const;
42 const OCRepresentation& getResourceRepresentation() const;
44 const ObservationInfo& getObservationInfo() const;
46 void setResourceUri(const std::string resourceUri);
48 std::string getResourceUri(void);
50 const HeaderOptions& getHeaderOptions() const;
52 const OCRequestHandle& getRequestHandle() const;
54 const OCResourceHandle& getResourceHandle() const;
56 static JniOcResourceRequest* getJniOcResourceRequestPtr
57 (JNIEnv *env, jobject thiz);
60 std::shared_ptr<OCResourceRequest> m_request;
68 * Class: org_iotivity_base_OcResourceRequest
69 * Method: getRequestTypeNative
70 * Signature: ()Ljava/lang/String;
72 JNIEXPORT jstring JNICALL Java_org_iotivity_base_OcResourceRequest_getRequestTypeNative
76 * Class: org_iotivity_base_OcResourceRequest
77 * Method: getQueryParameters
78 * Signature: ()Ljava/util/Map;
80 JNIEXPORT jobject JNICALL Java_org_iotivity_base_OcResourceRequest_getQueryParameters
84 * Class: org_iotivity_base_OcResourceRequest
85 * Method: getRequestHandlerFlagNative
88 JNIEXPORT jint JNICALL Java_org_iotivity_base_OcResourceRequest_getRequestHandlerFlagNative
92 * Class: org_iotivity_base_OcResourceRequest
93 * Method: getResourceRepresentation
94 * Signature: ()Lorg/iotivity/base/OcRepresentation;
96 JNIEXPORT jobject JNICALL Java_org_iotivity_base_OcResourceRequest_getResourceRepresentation
100 * Class: org_iotivity_base_OcResourceRequest
101 * Method: getObservationInfo
102 * Signature: ()Lorg/iotivity/base/ObservationInfo;
104 JNIEXPORT jobject JNICALL Java_org_iotivity_base_OcResourceRequest_getObservationInfo
108 * Class: org_iotivity_base_OcResourceRequest
109 * Method: setResourceUri
110 * Signature: (Ljava/lang/String;)V
112 JNIEXPORT void JNICALL Java_org_iotivity_base_OcResourceRequest_setResourceUri
113 (JNIEnv *, jobject, jstring);
116 * Class: org_iotivity_base_OcResourceRequest
117 * Method: getResourceUri
118 * Signature: ()Ljava/lang/String;
120 JNIEXPORT jstring JNICALL Java_org_iotivity_base_OcResourceRequest_getResourceUri
124 * Class: org_iotivity_base_OcResourceRequest
125 * Method: getHeaderOptions
126 * Signature: ()Ljava/util/List;
128 JNIEXPORT jobject JNICALL Java_org_iotivity_base_OcResourceRequest_getHeaderOptions
132 * Class: org_iotivity_base_OcResourceRequest
133 * Method: getRequestHandle
134 * Signature: ()Lorg/iotivity/base/OcRequestHandle;
136 JNIEXPORT jobject JNICALL Java_org_iotivity_base_OcResourceRequest_getRequestHandle
140 * Class: org_iotivity_base_OcResourceRequest
141 * Method: getResourceHandle
142 * Signature: ()Lorg/iotivity/base/OcResourceHandle;
144 JNIEXPORT jobject JNICALL Java_org_iotivity_base_OcResourceRequest_getResourceHandle
148 * Class: org_iotivity_base_OcResourceRequest
152 JNIEXPORT void JNICALL Java_org_iotivity_base_OcResourceRequest_dispose