本文整理了Java中org.glassfish.grizzly.websockets.Version
类的一些代码示例,展示了Version
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Version
类的具体详情如下:
包路径:org.glassfish.grizzly.websockets.Version
类名称:Version
暂无
代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server
public static ProtocolHandler loadHandler(MimeHeaders headers) {
for (Version version : Version.values()) {
if (version.validate(headers)) {
return version.createHandler(false);
}
}
return null;
}
代码示例来源:origin: javaee/grizzly
@Override
public String toString() {
return name();
}
代码示例来源:origin: com.ning/async-http-client
final URI wsURI = httpTxCtx.wsRequestURI.toJavaNetURI();
secure = "wss".equalsIgnoreCase(wsURI.getScheme());
httpTxCtx.protocolHandler = Version.RFC6455.createHandler(true);
httpTxCtx.handshake = httpTxCtx.protocolHandler.createClientHandShake(wsURI);
requestPacket = (HttpRequestPacket) httpTxCtx.handshake.composeHeaders().getHttpHeader();
代码示例来源:origin: javaee/grizzly
public static String getSupportedWireProtocolVersions() {
final StringBuilder sb = new StringBuilder();
for (Version v : Version.values()) {
if (v.wireProtocolVersion.length() > 0) {
sb.append(v.wireProtocolVersion).append(", ");
}
}
return sb.substring(0, sb.length() - 2);
}
}
代码示例来源:origin: javaee/grizzly
private WebSocketEngine() {
mapper.setDefaultHostName("localhost");
unsupportedVersionsResponseBuilder = new HttpResponsePacket.Builder();
unsupportedVersionsResponseBuilder.status(HttpStatus.BAD_REQUEST_400.getStatusCode());
unsupportedVersionsResponseBuilder.header(Constants.SEC_WS_VERSION,
Version.getSupportedWireProtocolVersions());
}
代码示例来源:origin: org.glassfish.grizzly/grizzly-http-client
final URI wsURI = httpTxCtx.wsRequestURI.toJavaNetURI();
secure = "wss".equalsIgnoreCase(wsURI.getScheme());
httpTxCtx.protocolHandler = Version.RFC6455.createHandler(true);
httpTxCtx.handshake = httpTxCtx.protocolHandler.createClientHandShake(wsURI);
requestPacket = (HttpRequestPacket) httpTxCtx.handshake.composeHeaders().getHttpHeader();
代码示例来源:origin: org.mule.glassfish.grizzly/grizzly-websockets
public static String getSupportedWireProtocolVersions() {
final StringBuilder sb = new StringBuilder();
for (Version v : Version.values()) {
if (v.wireProtocolVersion.length() > 0) {
sb.append(v.wireProtocolVersion).append(", ");
}
}
return sb.substring(0, sb.length() - 2);
}
}
代码示例来源:origin: javaee/grizzly
private WebSocketEngine() {
mapper.setDefaultHostName("localhost");
unsupportedVersionsResponseBuilder = new HttpResponsePacket.Builder();
unsupportedVersionsResponseBuilder.status(HttpStatus.BAD_REQUEST_400.getStatusCode());
unsupportedVersionsResponseBuilder.header(Constants.SEC_WS_VERSION,
Version.getSupportedWireProtocolVersions());
}
代码示例来源:origin: javaee/grizzly
public static ProtocolHandler loadHandler(MimeHeaders headers) {
for (Version version : Version.values()) {
if (version.validate(headers)) {
return version.createHandler(false);
}
}
return null;
}
代码示例来源:origin: org.apache.apex/apex-shaded-ning19
final URI wsURI = httpTxCtx.wsRequestURI.toJavaNetURI();
secure = "wss".equalsIgnoreCase(wsURI.getScheme());
httpTxCtx.protocolHandler = Version.RFC6455.createHandler(true);
httpTxCtx.handshake = httpTxCtx.protocolHandler.createClientHandShake(wsURI);
requestPacket = (HttpRequestPacket) httpTxCtx.handshake.composeHeaders().getHttpHeader();
代码示例来源:origin: org.glassfish.grizzly/grizzly-websockets-server
public static String getSupportedWireProtocolVersions() {
final StringBuilder sb = new StringBuilder();
for (Version v : Version.values()) {
if (v.wireProtocolVersion.length() > 0) {
sb.append(v.wireProtocolVersion).append(", ");
}
}
return sb.substring(0, sb.length() - 2);
}
}
代码示例来源:origin: org.mule.glassfish.grizzly/grizzly-websockets
private WebSocketEngine() {
mapper.setDefaultHostName("localhost");
unsupportedVersionsResponseBuilder = new HttpResponsePacket.Builder();
unsupportedVersionsResponseBuilder.status(HttpStatus.BAD_REQUEST_400.getStatusCode());
unsupportedVersionsResponseBuilder.header(Constants.SEC_WS_VERSION,
Version.getSupportedWireProtocolVersions());
}
代码示例来源:origin: javaee/grizzly
@Override
public String toString() {
return name();
}
代码示例来源:origin: javaee/grizzly
public static ProtocolHandler loadHandler(MimeHeaders headers) {
for (Version version : Version.values()) {
if (version.validate(headers)) {
return version.createHandler(false);
}
}
return null;
}
代码示例来源:origin: javaee/grizzly-ahc
final URI wsURI = httpTxCtx.wsRequestURI.toJavaNetURI();
secure = "wss".equalsIgnoreCase(wsURI.getScheme());
httpTxCtx.protocolHandler = Version.RFC6455.createHandler(true);
httpTxCtx.handshake = httpTxCtx.protocolHandler.createClientHandShake(wsURI);
requestPacket = (HttpRequestPacket) httpTxCtx.handshake.composeHeaders().getHttpHeader();
代码示例来源:origin: javaee/grizzly
public static String getSupportedWireProtocolVersions() {
final StringBuilder sb = new StringBuilder();
for (Version v : Version.values()) {
if (v.wireProtocolVersion.length() > 0) {
sb.append(v.wireProtocolVersion).append(", ");
}
}
return sb.substring(0, sb.length() - 2);
}
}
代码示例来源:origin: javaee/grizzly
private WebSocketEngine() {
mapper.setDefaultHostName("localhost");
unsupportedVersionsResponseBuilder = new HttpResponsePacket.Builder();
unsupportedVersionsResponseBuilder.status(HttpStatus.BAD_REQUEST_400.getStatusCode());
unsupportedVersionsResponseBuilder.header(Constants.SEC_WS_VERSION,
Version.getSupportedWireProtocolVersions());
}
代码示例来源:origin: org.mule.glassfish.grizzly/grizzly-websockets
@Override
public String toString() {
return name();
}
代码示例来源:origin: org.mule.glassfish.grizzly/grizzly-websockets
public static ProtocolHandler loadHandler(MimeHeaders headers) {
for (Version version : Version.values()) {
if (version.validate(headers)) {
return version.createHandler(false);
}
}
return null;
}
代码示例来源:origin: io.gatling/async-http-client
final URI wsURI = httpCtx.wsRequestURI.toURI();
secure = "wss".equalsIgnoreCase(wsURI.getScheme());
httpCtx.protocolHandler = Version.RFC6455.createHandler(true);
httpCtx.handshake = httpCtx.protocolHandler.createHandShake(wsURI);
requestPacket = (HttpRequestPacket)
内容来源于网络,如有侵权,请联系作者删除!