Top Description Inners Fields Constructors Methods
io.netty.handler.codec.http.websocketx

public final Class WebSocketDecoderConfig

extends Object
Class Inheritance
Imports
io.netty.util.internal.ObjectUtil

Frames decoder configuration.

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
private final boolean
private final boolean
private final boolean
pack-priv static final WebSocketDecoderConfig
private final boolean
private final int
private final boolean

Constructor Summary

AccessConstructor and Description
private
WebSocketDecoderConfig(int
Maximum length of a frame's payload. Setting this to an appropriate value for you application helps check for denial of services attacks.
maxFramePayloadLength
,
boolean
Web socket servers must set this to true processed incoming masked payload. Client implementations must set this to false.
expectMaskedFrames
,
boolean
Allows to loosen the masking requirement on received frames. When this is set to false then also frames which are not masked properly according to the standard will still be accepted.
allowMaskMismatch
,
boolean
Flag to allow reserved extension bits to be used or not
allowExtensions
,
boolean
Flag to send close frame immediately on any protocol violation.ion.
closeOnProtocolViolation
,
boolean
Allows you to avoid adding of Utf8FrameValidator to the pipeline on the WebSocketServerProtocolHandler creation. This is useful (less overhead) when you use only BinaryWebSocketFrame within your web socket connection.
withUTF8Validator
)

Constructor

Method Summary

Modifier and TypeMethod and Description
public boolean
public boolean
public boolean
public boolean
public int
public static WebSocketDecoderConfig.Builder
public WebSocketDecoderConfig.Builder
public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.
public boolean
Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

allowExtensionsback to summary
private final boolean allowExtensions
allowMaskMismatchback to summary
private final boolean allowMaskMismatch
closeOnProtocolViolationback to summary
private final boolean closeOnProtocolViolation
DEFAULTback to summary
pack-priv static final WebSocketDecoderConfig DEFAULT
expectMaskedFramesback to summary
private final boolean expectMaskedFrames
maxFramePayloadLengthback to summary
private final int maxFramePayloadLength
withUTF8Validatorback to summary
private final boolean withUTF8Validator

Constructor Detail

WebSocketDecoderConfigback to summary
private WebSocketDecoderConfig(int maxFramePayloadLength, boolean expectMaskedFrames, boolean allowMaskMismatch, boolean allowExtensions, boolean closeOnProtocolViolation, boolean withUTF8Validator)

Constructor

Parameters
maxFramePayloadLength:int

Maximum length of a frame's payload. Setting this to an appropriate value for you application helps check for denial of services attacks.

expectMaskedFrames:boolean

Web socket servers must set this to true processed incoming masked payload. Client implementations must set this to false.

allowMaskMismatch:boolean

Allows to loosen the masking requirement on received frames. When this is set to false then also frames which are not masked properly according to the standard will still be accepted.

allowExtensions:boolean

Flag to allow reserved extension bits to be used or not

closeOnProtocolViolation:boolean

Flag to send close frame immediately on any protocol violation.ion.

withUTF8Validator:boolean

Allows you to avoid adding of Utf8FrameValidator to the pipeline on the WebSocketServerProtocolHandler creation. This is useful (less overhead) when you use only BinaryWebSocketFrame within your web socket connection.

Method Detail

allowExtensionsback to summary
public boolean allowExtensions()
allowMaskMismatchback to summary
public boolean allowMaskMismatch()
closeOnProtocolViolationback to summary
public boolean closeOnProtocolViolation()
expectMaskedFramesback to summary
public boolean expectMaskedFrames()
maxFramePayloadLengthback to summary
public int maxFramePayloadLength()
newBuilderback to summary
public static WebSocketDecoderConfig.Builder newBuilder()
toBuilderback to summary
public WebSocketDecoderConfig.Builder toBuilder()
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object.

Returns:String

a string representation of the object

Annotations
@Override
withUTF8Validatorback to summary
public boolean withUTF8Validator()
io.netty.handler.codec.http.websocketx back to summary

public final Class WebSocketDecoderConfig.Builder

extends Object
Class Inheritance
  • java.lang.Object
  • io.netty.handler.codec.http.websocketx.WebSocketDecoderConfig.Builder

Field Summary

Modifier and TypeField and Description
private boolean
private boolean
private boolean
private boolean
private int
private boolean

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public WebSocketDecoderConfig.Builder
allowExtensions(boolean allowExtensions)

public WebSocketDecoderConfig.Builder
allowMaskMismatch(boolean allowMaskMismatch)

public WebSocketDecoderConfig
public WebSocketDecoderConfig.Builder
closeOnProtocolViolation(boolean closeOnProtocolViolation)

public WebSocketDecoderConfig.Builder
expectMaskedFrames(boolean expectMaskedFrames)

public WebSocketDecoderConfig.Builder
maxFramePayloadLength(int maxFramePayloadLength)

public WebSocketDecoderConfig.Builder
withUTF8Validator(boolean withUTF8Validator)

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Field Detail

allowExtensionsback to summary
private boolean allowExtensions
allowMaskMismatchback to summary
private boolean allowMaskMismatch
closeOnProtocolViolationback to summary
private boolean closeOnProtocolViolation
expectMaskedFramesback to summary
private boolean expectMaskedFrames
maxFramePayloadLengthback to summary
private int maxFramePayloadLength
withUTF8Validatorback to summary
private boolean withUTF8Validator

Constructor Detail

Builderback to summary
private Builder(WebSocketDecoderConfig decoderConfig)

Method Detail

allowExtensionsback to summary
public WebSocketDecoderConfig.Builder allowExtensions(boolean allowExtensions)
allowMaskMismatchback to summary
public WebSocketDecoderConfig.Builder allowMaskMismatch(boolean allowMaskMismatch)
buildback to summary
public WebSocketDecoderConfig build()
closeOnProtocolViolationback to summary
public WebSocketDecoderConfig.Builder closeOnProtocolViolation(boolean closeOnProtocolViolation)
expectMaskedFramesback to summary
public WebSocketDecoderConfig.Builder expectMaskedFrames(boolean expectMaskedFrames)
maxFramePayloadLengthback to summary
public WebSocketDecoderConfig.Builder maxFramePayloadLength(int maxFramePayloadLength)
withUTF8Validatorback to summary
public WebSocketDecoderConfig.Builder withUTF8Validator(boolean withUTF8Validator)