| OLD | NEW |
| 1 /* Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 /* Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 * Use of this source code is governed by a BSD-style license that can be | 2 * Use of this source code is governed by a BSD-style license that can be |
| 3 * found in the LICENSE file. | 3 * found in the LICENSE file. |
| 4 */ | 4 */ |
| 5 | 5 |
| 6 /* From ppb_websocket.idl modified Wed Apr 25 11:48:30 2012. */ | 6 /* From ppb_websocket.idl modified Mon May 14 20:20:06 2012. */ |
| 7 | 7 |
| 8 #ifndef PPAPI_C_PPB_WEBSOCKET_H_ | 8 #ifndef PPAPI_C_PPB_WEBSOCKET_H_ |
| 9 #define PPAPI_C_PPB_WEBSOCKET_H_ | 9 #define PPAPI_C_PPB_WEBSOCKET_H_ |
| 10 | 10 |
| 11 #include "ppapi/c/pp_bool.h" | 11 #include "ppapi/c/pp_bool.h" |
| 12 #include "ppapi/c/pp_completion_callback.h" | 12 #include "ppapi/c/pp_completion_callback.h" |
| 13 #include "ppapi/c/pp_instance.h" | 13 #include "ppapi/c/pp_instance.h" |
| 14 #include "ppapi/c/pp_macros.h" | 14 #include "ppapi/c/pp_macros.h" |
| 15 #include "ppapi/c/pp_resource.h" | 15 #include "ppapi/c/pp_resource.h" |
| 16 #include "ppapi/c/pp_stdint.h" | 16 #include "ppapi/c/pp_stdint.h" |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 * GetCloseCode(). Refer to RFC 6455, The WebSocket Protocol, for further | 65 * GetCloseCode(). Refer to RFC 6455, The WebSocket Protocol, for further |
| 66 * information. | 66 * information. |
| 67 * <code>PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE</code> and codes in the range | 67 * <code>PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE</code> and codes in the range |
| 68 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MIN</code> to | 68 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MIN</code> to |
| 69 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MAX</code>, and | 69 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MAX</code>, and |
| 70 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MIN</code> to | 70 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MIN</code> to |
| 71 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MAX</code> are valid for Close(). | 71 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MAX</code> are valid for Close(). |
| 72 */ | 72 */ |
| 73 typedef enum { | 73 typedef enum { |
| 74 /** | 74 /** |
| 75 * Indicates to request closing connection without status code. This code is |
| 76 * internally assigned in WebKit, and not based on any WebSocket related |
| 77 * specification. |
| 78 */ |
| 79 PP_WEBSOCKETSTATUSCODE_NOT_SPECIFIED = 65535, |
| 80 /** |
| 75 * Status codes in the range 0-999 are not used. | 81 * Status codes in the range 0-999 are not used. |
| 76 */ | 82 */ |
| 77 /** | 83 /** |
| 78 * Indicates a normal closure. | 84 * Indicates a normal closure. |
| 79 */ | 85 */ |
| 80 PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE = 1000, | 86 PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE = 1000, |
| 81 /** | 87 /** |
| 82 * Indicates that an endpoint is "going away", such as a server going down. | 88 * Indicates that an endpoint is "going away", such as a server going down. |
| 83 */ | 89 */ |
| 84 PP_WEBSOCKETSTATUSCODE_GOING_AWAY = 1001, | 90 PP_WEBSOCKETSTATUSCODE_GOING_AWAY = 1001, |
| (...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 425 struct PP_Var (*GetURL)(PP_Resource web_socket); | 431 struct PP_Var (*GetURL)(PP_Resource web_socket); |
| 426 }; | 432 }; |
| 427 | 433 |
| 428 typedef struct PPB_WebSocket_1_0 PPB_WebSocket; | 434 typedef struct PPB_WebSocket_1_0 PPB_WebSocket; |
| 429 /** | 435 /** |
| 430 * @} | 436 * @} |
| 431 */ | 437 */ |
| 432 | 438 |
| 433 #endif /* PPAPI_C_PPB_WEBSOCKET_H_ */ | 439 #endif /* PPAPI_C_PPB_WEBSOCKET_H_ */ |
| 434 | 440 |
| OLD | NEW |