001/* 002 * Copyright (C) 2015 Neo Visionaries Inc. 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package NeoVisionaries.WebSockets; 017 018 019/** 020 * Opcode. 021 * 022 * <EMBED CLASS='external-html' DATA-FILE-ID=LICENSE> 023 * 024 * @see <a href="https://tools.ietf.org/html/rfc6455#section-5.2" 025 * >RFC 6455, 5.2. Base Framing Protocol</a> 026 */ 027public class WebSocketOpcode 028{ 029 /** 030 * Opcode for "frame continuation" (0x0). 031 */ 032 public static final int CONTINUATION = 0x0; 033 034 035 /** 036 * Opcode for "text frame" (0x1). 037 */ 038 public static final int TEXT = 0x1; 039 040 041 /** 042 * Opcode for "binary frame" (0x2). 043 */ 044 public static final int BINARY = 0x2; 045 046 047 /** 048 * Opcode for "connection close" (0x8). 049 */ 050 public static final int CLOSE = 0x8; 051 052 053 /** 054 * Opcode for "ping" (0x9). 055 */ 056 public static final int PING = 0x9; 057 058 059 /** 060 * Opcode for "pong" (0xA). 061 */ 062 public static final int PONG = 0xA; 063 064 065 private WebSocketOpcode() 066 { 067 } 068}