Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(145)

Side by Side Diff: ppapi/api/ppb_websocket.idl

Issue 10332138: WebSocket Pepper API: allow to close connection without code and reason (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | ppapi/c/ppb_websocket.h » ('j') | ppapi/tests/test_websocket.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 /** 6 /**
7 * This file defines the <code>PPB_WebSocket</code> interface providing 7 * This file defines the <code>PPB_WebSocket</code> interface providing
8 * bi-directional, full-duplex, communications over a single TCP socket. 8 * bi-directional, full-duplex, communications over a single TCP socket.
9 */ 9 */
10 label Chrome { 10 label Chrome {
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 * information. 51 * information.
52 * <code>PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE</code> and codes in the range 52 * <code>PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE</code> and codes in the range
53 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MIN</code> to 53 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MIN</code> to
54 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MAX</code>, and 54 * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MAX</code>, and
55 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MIN</code> to 55 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MIN</code> to
56 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MAX</code> are valid for Close(). 56 * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MAX</code> are valid for Close().
57 */ 57 */
58 [assert_size(4)] 58 [assert_size(4)]
59 enum PP_WebSocketCloseCode { 59 enum PP_WebSocketCloseCode {
60 /** 60 /**
61 * Indicates to request closing connection without status code. This code is
62 * internally assigned in WebKit, and not based on any WebSocket related
63 * specification.
64 */
65 PP_WEBSOCKETSTATUSCODE_NOT_SPECIFIED = 65535,
dmichael (off chromium) 2012/05/14 16:10:49 Maybe you should use -1? Since code is unsigned in
Takashi Toyoshima 2012/05/15 10:55:28 Yes, in the same reason, I defined the equivalent
66
67 /**
61 * Status codes in the range 0-999 are not used. 68 * Status codes in the range 0-999 are not used.
62 */ 69 */
63 70
64 /** 71 /**
65 * Indicates a normal closure. 72 * Indicates a normal closure.
66 */ 73 */
67 PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE = 1000, 74 PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE = 1000,
68 75
69 /** 76 /**
70 * Indicates that an endpoint is "going away", such as a server going down. 77 * Indicates that an endpoint is "going away", such as a server going down.
(...skipping 355 matching lines...) Expand 10 before | Expand all | Expand 10 after
426 * @param[in] web_socket A <code>PP_Resource</code> corresponding to a 433 * @param[in] web_socket A <code>PP_Resource</code> corresponding to a
427 * WebSocket. 434 * WebSocket.
428 * 435 *
429 * @return Returns a <code>PP_VARTYPE_STRING</code> var. If called before the 436 * @return Returns a <code>PP_VARTYPE_STRING</code> var. If called before the
430 * connection is established, the var contains the empty string. Returns a 437 * connection is established, the var contains the empty string. Returns a
431 * <code>PP_VARTYPE_UNDEFINED</code> if this function is called on an 438 * <code>PP_VARTYPE_UNDEFINED</code> if this function is called on an
432 * invalid resource. 439 * invalid resource.
433 */ 440 */
434 PP_Var GetURL([in] PP_Resource web_socket); 441 PP_Var GetURL([in] PP_Resource web_socket);
435 }; 442 };
OLDNEW
« no previous file with comments | « no previous file | ppapi/c/ppb_websocket.h » ('j') | ppapi/tests/test_websocket.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698