The app's wire code has the chapters' messages (#477)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RqkrVBuJRne2JAhFpaDV2U
This commit is contained in:
2026-11-22 12:02:49 -05:00
parent 882cd5f03c
commit 4aeb5c510f

View File

@@ -1201,6 +1201,34 @@ nonisolated struct Ipx_SeasonRows: Sendable {
init() {} init() {}
} }
/// One chapter of a file in GET /api/enclosures/{id}/chapters (#477): its start in seconds, in
/// the clock of what plays, and its title, which may be empty.
nonisolated struct Ipx_Chapter: Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
// methods supported on all messages.
var start: Double = 0
var title: String = String()
var unknownFields = SwiftProtobuf.UnknownStorage()
init() {}
}
nonisolated struct Ipx_Chapters: Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
// methods supported on all messages.
var items: [Ipx_Chapter] = []
var unknownFields = SwiftProtobuf.UnknownStorage()
init() {}
}
/// POST /api/playlists, the answer. /// POST /api/playlists, the answer.
nonisolated struct Ipx_PlaylistId: Sendable { nonisolated struct Ipx_PlaylistId: Sendable {
// SwiftProtobuf.Message conformance is added in an extension below. See the // SwiftProtobuf.Message conformance is added in an extension below. See the
@@ -4007,6 +4035,71 @@ nonisolated extension Ipx_SeasonRows: SwiftProtobuf.Message, SwiftProtobuf._Mess
} }
} }
nonisolated extension Ipx_Chapter: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".Chapter"
static let _protobuf_nameMap = SwiftProtobuf._NameMap(bytecode: "\0\u{1}start\0\u{1}title\0")
mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
while let fieldNumber = try decoder.nextFieldNumber() {
// The use of inline closures is to circumvent an issue where the compiler
// allocates stack space for every case branch when no optimizations are
// enabled. https://github.com/apple/swift-protobuf/issues/1034
switch fieldNumber {
case 1: try { try decoder.decodeSingularDoubleField(value: &self.start) }()
case 2: try { try decoder.decodeSingularStringField(value: &self.title) }()
default: break
}
}
}
func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
if self.start.bitPattern != 0 {
try visitor.visitSingularDoubleField(value: self.start, fieldNumber: 1)
}
if !self.title.isEmpty {
try visitor.visitSingularStringField(value: self.title, fieldNumber: 2)
}
try unknownFields.traverse(visitor: &visitor)
}
static func ==(lhs: Ipx_Chapter, rhs: Ipx_Chapter) -> Bool {
if lhs.start != rhs.start {return false}
if lhs.title != rhs.title {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
nonisolated extension Ipx_Chapters: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".Chapters"
static let _protobuf_nameMap = SwiftProtobuf._NameMap(bytecode: "\0\u{1}items\0")
mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
while let fieldNumber = try decoder.nextFieldNumber() {
// The use of inline closures is to circumvent an issue where the compiler
// allocates stack space for every case branch when no optimizations are
// enabled. https://github.com/apple/swift-protobuf/issues/1034
switch fieldNumber {
case 1: try { try decoder.decodeRepeatedMessageField(value: &self.items) }()
default: break
}
}
}
func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
if !self.items.isEmpty {
try visitor.visitRepeatedMessageField(value: self.items, fieldNumber: 1)
}
try unknownFields.traverse(visitor: &visitor)
}
static func ==(lhs: Ipx_Chapters, rhs: Ipx_Chapters) -> Bool {
if lhs.items != rhs.items {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
nonisolated extension Ipx_PlaylistId: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding { nonisolated extension Ipx_PlaylistId: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".PlaylistId" static let protoMessageName: String = _protobuf_package + ".PlaylistId"
static let _protobuf_nameMap = SwiftProtobuf._NameMap(bytecode: "\0\u{1}id\0") static let _protobuf_nameMap = SwiftProtobuf._NameMap(bytecode: "\0\u{1}id\0")