mirror of
https://github.com/apple/swift-nio-http2
synced 2026-11-29 05:24:22 +00:00
Apply swift-format changes and CI (#472)
Motivation: Standardised formatting makes the project cleaner to look at and work on. Modifications: Setup swift-format with the same settings as Swift-NIO Result: Common formatting throughout
This commit is contained in:
1 parent
93586110f2
commit
1118370ec4
125 files changed
+21869
-11457
No files matched your search
@@ -44,7 +44,6 @@ enum StateMachineResult {
|
||||
case succeed
|
||||
}
|
||||
|
||||
|
||||
/// Operations that may need to be performed after receiving a frame.
|
||||
enum PostFrameOperation {
|
||||
/// An appropriate ACK must be sent.
|
||||
@@ -54,7 +53,6 @@ enum PostFrameOperation {
|
||||
case nothing
|
||||
}
|
||||
|
||||
|
||||
/// An encapsulation of a state machine result along with a possible triggered state change.
|
||||
struct StateMachineResultWithEffect {
|
||||
var result: StateMachineResult
|
||||
@@ -66,12 +64,18 @@ struct StateMachineResultWithEffect {
|
||||
self.effect = effect
|
||||
}
|
||||
|
||||
init(_ streamEffect: StateMachineResultWithStreamEffect,
|
||||
inboundFlowControlWindow: HTTP2FlowControlWindow,
|
||||
outboundFlowControlWindow: HTTP2FlowControlWindow) {
|
||||
init(
|
||||
_ streamEffect: StateMachineResultWithStreamEffect,
|
||||
inboundFlowControlWindow: HTTP2FlowControlWindow,
|
||||
outboundFlowControlWindow: HTTP2FlowControlWindow
|
||||
) {
|
||||
self.result = streamEffect.result
|
||||
self.effect = streamEffect.effect.map {
|
||||
NIOHTTP2ConnectionStateChange($0, inboundFlowControlWindow: inboundFlowControlWindow, outboundFlowControlWindow: outboundFlowControlWindow)
|
||||
NIOHTTP2ConnectionStateChange(
|
||||
$0,
|
||||
inboundFlowControlWindow: inboundFlowControlWindow,
|
||||
outboundFlowControlWindow: outboundFlowControlWindow
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user