-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat!: Conceal serde types with Swift SPI #805
Changes from 6 commits
c65802e
160b4cd
d604508
0958d29
516bf67
e1621de
ab14ee8
34578e9
bb4bfef
f8bef3f
fcf2d6a
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,9 +7,10 @@ | |
|
||
import class SmithyHTTPAPI.HTTPResponse | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Below you will see that many declarations and imports of those declarations are tagged with I will not comment on the rest of these type of changes below. |
||
import enum Smithy.ByteStream | ||
import protocol SmithyReadWrite.WireDataProviding | ||
@_spi(SmithyReadWrite) import protocol SmithyReadWrite.WireDataProviding | ||
import struct Foundation.Data | ||
|
||
@_spi(SmithyReadWrite) | ||
extension HTTPResponse: WireDataProviding { | ||
|
||
public func data() async throws -> Data { | ||
|
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,8 +7,10 @@ | |
|
||
import struct Foundation.Data | ||
import struct Foundation.Date | ||
import enum SmithyTimestamps.TimestampFormat | ||
@_spi(SmithyTimestamps) import enum SmithyTimestamps.TimestampFormat | ||
import enum Smithy.ByteStream | ||
|
||
@_spi(SmithyReadWrite) | ||
public protocol SmithyWriter: AnyObject { | ||
associatedtype NodeInfo | ||
|
||
|
@@ -47,6 +49,17 @@ public protocol SmithyWriter: AnyObject { | |
|
||
public extension SmithyWriter { | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The function below was moved here from |
||
func write(_ value: ByteStream?) throws { | ||
// This serialization will never be performed in practice, since | ||
// a ByteStream will never be a part of | ||
// a XML body - if there is a streaming member in a restXml | ||
// input shape, the rest of the input members must all be bound | ||
// to HTML components outside the body. | ||
// | ||
// This empty implementation is only provided to quiet the | ||
// compiler when a structure with a ByteSteam is code-generated. | ||
} | ||
|
||
static func write<T>( | ||
_ value: T, | ||
rootNodeInfo: NodeInfo, | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since ByteStream is now in the
Smithy
module,SmithyReadWrite
takes a dependency onSmithy
and provides its own read-write implementation forByteStream
.