scoop:scoop.http:0.1.0
src/http2_settings_builder.scoop
Selected production source · src/http2_settings_builder.scoop
1
package scoop.http3
public fun Http2Settings.copy(configure: Http2SettingsBuilder.() -> Unit = {}): Http2Settings {4
val builder = Http2SettingsBuilder()5
builder.headerTableSize = this.headerTableSize6
builder.maxConcurrentStreams = this.maxConcurrentStreams7
builder.initialWindowSize = this.initialWindowSize8
builder.maxFrameSize = this.maxFrameSize9
builder.maxHeaderListSize = this.maxHeaderListSize10
builder.configure()11
return builder.snapshot()12
}14
public class Http2SettingsBuilder internal constructor() {15
public var headerTableSize: UInt = 4096U16
public var maxConcurrentStreams: UInt = 100U17
public var initialWindowSize: UInt = 65535U18
public var maxFrameSize: UInt = 16384U19
public var maxHeaderListSize: UInt = 65536U20
internal fun snapshot(): Http2Settings =21
Http2Settings(22
headerTableSize,23
maxConcurrentStreams,24
initialWindowSize,25
maxFrameSize,26
maxHeaderListSize27
)28
}