User Tools

Site Tools


request_and_response

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
request_and_response [2017/12/12 06:44]
Taehyoung Shim [Sequence Diagram]
request_and_response [2017/12/12 06:46] (current)
Taehyoung Shim [Sequence Diagram]
Line 243: Line 243:
   - Client SDK internally calls the setResourceAttributes function of the client wrapper. ​   - Client SDK internally calls the setResourceAttributes function of the client wrapper. ​
   - The C API is called to dispatch the request. Example call: <​code>​OCDoResource(OC_REST_PUT,​ "//​192.168.1.11/​light/​1,​ 0, 0, OC_CONFIRMABLE,​ callback);</​code>​   - The C API is called to dispatch the request. Example call: <​code>​OCDoResource(OC_REST_PUT,​ "//​192.168.1.11/​light/​1,​ 0, 0, OC_CONFIRMABLE,​ callback);</​code>​
-  - Send PUT request to remote device+  - Send PUT request to remote device.
   - The OCProcess() service function (server-side message pump) reads the packet from the socket and dispatches the request to the entity handler for the provided URI.   - The OCProcess() service function (server-side message pump) reads the packet from the socket and dispatches the request to the entity handler for the provided URI.
   - The entity handler, which was provided by an upper layer when the resource was registered, parses the representation and in the case of the C++ API passes the results to the upper layer handler. In a C only environment,​ the results would also be processed in the entity handler.   - The entity handler, which was provided by an upper layer when the resource was registered, parses the representation and in the case of the C++ API passes the results to the upper layer handler. In a C only environment,​ the results would also be processed in the entity handler.
Line 251: Line 251:
   - Returns success or failure to lower layer for transmission to client.   - Returns success or failure to lower layer for transmission to client.
   - Returns success or failure to lower layer for transmission to client.   - Returns success or failure to lower layer for transmission to client.
-  - Result is formatted and sent over network to client +  - Result is formatted and sent over network to client. 
-  - The OCProcess() service function (client-side message pump) reads results and passes the results back to the client application via the callback passed to OCDoResource+  - The OCProcess() service function (client-side message pump) reads results and passes the results back to the client application via the callback passed to OCDoResource.
  
  
request_and_response.txt · Last modified: 2017/12/12 06:46 by Taehyoung Shim