Просмотр исходного кода

新增,可能需要支持多种类型媒体服务器的接口

Signed-off-by: allan716 <[email protected]>
allan716 4 лет назад
Родитель
Сommit
ff325efe82
2 измененных файлов с 25 добавлено и 0 удалено
  1. 4 0
      internal/ifaces/iMediaSystem.go
  2. 21 0
      internal/types/media_system/type.go

+ 4 - 0
internal/ifaces/iMediaSystem.go

@@ -0,0 +1,4 @@
+package ifaces
+
+type iMediaSystem interface {
+}

+ 21 - 0
internal/types/media_system/type.go

@@ -0,0 +1,21 @@
+package media_system
+
+type RecentlyItems struct {
+	Items            []RecentlyItem `json:"Items,omitempty"`
+	TotalRecordCount int            `json:"TotalRecordCount,omitempty"`
+}
+
+type RecentlyItem struct {
+	Name              string `json:"Name,omitempty"`
+	Id                string `json:"Id,omitempty"`
+	IndexNumber       int    `json:"IndexNumber,omitempty"`
+	ParentIndexNumber int    `json:"ParentIndexNumber,omitempty"`
+	Type              string `json:"Type,omitempty"`
+	UserData          struct {
+		PlaybackPositionTicks int  `json:"PlaybackPositionTicks"`
+		PlayCount             int  `json:"PlayCount"`
+		IsFavorite            bool `json:"IsFavorite"`
+		Played                bool `json:"Played"`
+	} `json:"UserData"`
+	SeriesName string `json:"SeriesName,omitempty"`
+}