style: @keep class from minification

This commit is contained in:
antonio 2023-06-21 10:50:54 +02:00
parent cb3f1290d1
commit 76c53bd502
68 changed files with 163 additions and 56 deletions

View file

@ -1,8 +1,10 @@
package com.cappielloantonio.tempo.subsonic.base
import androidx.annotation.Keep
import com.cappielloantonio.tempo.subsonic.models.SubsonicResponse
import com.google.gson.annotations.SerializedName
@Keep
class ApiResponse {
@SerializedName("subsonic-response")
var subsonicResponse: SubsonicResponse? = null

View file

@ -1,20 +1,20 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
import java.util.*
@Keep
@Parcelize
open class AlbumID3 : Parcelable {
var id: String? = null
var name: String? = null
var artist: String? = null
var artistId: String? = null
@SerializedName("coverArt")
var coverArtId: String? = null
var songCount: Int? = 0
var duration: Int? = 0
var playCount: Long? = null

View file

@ -1,6 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class AlbumInfo {
var notes: String? = null
var musicBrainzId: String? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class AlbumList {
var albums: List<Child>? = null
}

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class AlbumList2 {
@SerializedName("album")
var albums: List<AlbumID3>? = null

View file

@ -1,9 +1,11 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class AlbumWithSongsID3 : AlbumID3(), Parcelable {
@SerializedName("song")

View file

@ -1,9 +1,11 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import kotlinx.parcelize.Parcelize
import java.util.Date
@Keep
@Parcelize
class Artist : Parcelable {
var id: String? = null

View file

@ -1,15 +1,16 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
import java.util.*
@Keep
@Parcelize
open class ArtistID3 : Parcelable {
var id: String? = null
var name: String? = null
@SerializedName("coverArt")
var coverArtId: String? = null
var albumCount = 0

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class ArtistInfo : ArtistInfoBase() {
var similarArtists: List<Artist>? = null
}

View file

@ -1,8 +1,10 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import java.util.*
@Keep
class ArtistInfo2 : ArtistInfoBase() {
@SerializedName("similarArtist")
var similarArtists: List<SimilarArtistID3>? = emptyList()

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
open class ArtistInfoBase {
var biography: String? = null
var musicBrainzId: String? = null

View file

@ -1,9 +1,11 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class ArtistWithAlbumsID3 : ArtistID3(), Parcelable {
@SerializedName("album")

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class ArtistsID3 {
@SerializedName("index")
var indices: List<IndexID3>? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class AudioTrack {
var id: String? = null
var name: String? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import java.util.*
@Keep
class Bookmark {
var entry: Child? = null
var position: Long = 0

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Bookmarks {
var bookmarks: List<Bookmark>? = null
}

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Captions {
var id: String? = null
var name: String? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class ChatMessage {
var username: String? = null
var time: Long = 0

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class ChatMessages {
var chatMessages: List<ChatMessage>? = null
}

View file

@ -1,110 +1,82 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import androidx.room.ColumnInfo
import androidx.room.PrimaryKey
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
import java.util.*
@Keep
@Parcelize
open class Child(
@PrimaryKey
@ColumnInfo(name = "id")
open val id: String,
@ColumnInfo(name = "parent_id")
@SerializedName("parent")
var parentId: String? = null,
@ColumnInfo(name = "is_dir")
var isDir: Boolean = false,
@ColumnInfo
var title: String? = null,
@ColumnInfo
var album: String? = null,
@ColumnInfo
var artist: String? = null,
@ColumnInfo
var track: Int? = null,
@ColumnInfo
var year: Int? = null,
@ColumnInfo
@SerializedName("genre")
var genre: String? = null,
@ColumnInfo(name = "cover_art_id")
@SerializedName("coverArt")
var coverArtId: String? = null,
@ColumnInfo
var size: Long? = null,
@ColumnInfo(name = "content_type")
var contentType: String? = null,
@ColumnInfo
var suffix: String? = null,
@ColumnInfo("transcoding_content_type")
var transcodedContentType: String? = null,
@ColumnInfo(name = "transcoded_suffix")
var transcodedSuffix: String? = null,
@ColumnInfo
var duration: Int? = null,
@ColumnInfo("bitrate")
@SerializedName("bitRate")
var bitrate: Int? = null,
@ColumnInfo
var path: String? = null,
@ColumnInfo(name = "is_video")
@SerializedName("isVideo")
var isVideo: Boolean = false,
@ColumnInfo(name = "user_rating")
var userRating: Int? = null,
@ColumnInfo(name = "average_rating")
var averageRating: Double? = null,
@ColumnInfo(name = "play_count")
var playCount: Long? = null,
@ColumnInfo(name = "disc_number")
var discNumber: Int? = null,
@ColumnInfo
var created: Date? = null,
@ColumnInfo
var starred: Date? = null,
@ColumnInfo(name = "album_id")
var albumId: String? = null,
@ColumnInfo(name = "artist_id")
var artistId: String? = null,
@ColumnInfo
var type: String? = null,
@ColumnInfo(name = "bookmark_position")
var bookmarkPosition: Long? = null,
@ColumnInfo(name = "original_width")
var originalWidth: Int? = null,
@ColumnInfo(name = "original_height")
var originalHeight: Int? = null
) : Parcelable

View file

@ -1,10 +1,12 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
import java.util.Date
@Keep
@Parcelize
class Directory : Parcelable {
@SerializedName("child")

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Error {
var code: ErrorCode? = null
var message: String? = null
}

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
class ErrorCode(val value: Int) {
import androidx.annotation.Keep
@Keep
class ErrorCode(val value: Int) {
companion object {
var GENERIC_ERROR = 0
var REQUIRED_PARAMETER_MISSING = 10

View file

@ -1,9 +1,11 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class Genre : Parcelable {
@SerializedName("value")

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class Genres {
@SerializedName("genre")
var genres: List<Genre>? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class Index {
@SerializedName("artist")
var artists: List<Artist>? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class IndexID3 {
@SerializedName("artist")
var artists: List<ArtistID3>? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class Indexes {
var shortcuts: List<Artist>? = null
@SerializedName("index")

View file

@ -1,8 +1,10 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class InternetRadioStation : Parcelable {
var id: String? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class InternetRadioStations {
@SerializedName("internetRadioStation")
var internetRadioStations: List<InternetRadioStation>? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class JukeboxPlaylist : JukeboxStatus() {
var entries: List<Child>? = null
}

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
open class JukeboxStatus {
var currentIndex = 0
var isPlaying = false

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import java.util.*
@Keep
class License {
var isValid = false
var email: String? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Lyrics {
var value: String? = null
var artist: String? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class MediaType {
var value: String? = null

View file

@ -1,8 +1,10 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class MusicFolder : Parcelable {
var id: String? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class MusicFolders {
@SerializedName("musicFolder")
var musicFolders: List<MusicFolder>? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class NewestPodcasts {
@SerializedName("episode")
var episodes: List<PodcastEpisode>? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class NowPlaying {
var entries: List<NowPlayingEntry>? = null
}

View file

@ -1,8 +1,10 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class NowPlayingEntry(
@SerializedName("_id")

View file

@ -1,8 +1,10 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import java.util.*
@Keep
class PlayQueue {
@SerializedName("entry")
var entries: List<Child>? = null

View file

@ -1,6 +1,7 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import androidx.room.ColumnInfo
import androidx.room.Entity
import androidx.room.Ignore
@ -9,6 +10,7 @@ import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
import java.util.*
@Keep
@Parcelize
@Entity(tableName = "playlist")
open class Playlist(
@ -18,32 +20,23 @@ open class Playlist(
) : Parcelable {
@ColumnInfo(name = "name")
var name: String? = null
@Ignore
var comment: String? = null
@Ignore
var owner: String? = null
@Ignore
@SerializedName("public")
var isUniversal: Boolean? = null
@Ignore
var songCount: Int = 0
@ColumnInfo(name = "duration")
var duration: Long = 0
@Ignore
var created: Date? = null
@Ignore
var changed: Date? = null
@ColumnInfo(name = "coverArt")
var coverArtId: String? = null
@Ignore
var allowedUsers: List<String>? = null
}

View file

@ -1,9 +1,11 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class PlaylistWithSongs(
@SerializedName("_id")

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class Playlists(
@SerializedName("playlist")
var playlists: List<Playlist>? = null

View file

@ -1,9 +1,11 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class PodcastChannel : Parcelable {
@SerializedName("episode")

View file

@ -1,18 +1,18 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import androidx.room.ColumnInfo
import com.google.gson.annotations.SerializedName
import kotlinx.parcelize.Parcelize
import java.util.*
@Keep
@Parcelize
class PodcastEpisode : Parcelable {
var id: String? = null
@SerializedName("parent")
var parentId: String? = null
@SerializedName("isDir")
var isDir = false
var title: String? = null
@ -21,7 +21,6 @@ class PodcastEpisode : Parcelable {
var track: Int? = null
var year: Int? = null
var genre: String? = null
@SerializedName("coverArt")
var coverArtId: String? = null
var size: Long? = null
@ -34,7 +33,6 @@ class PodcastEpisode : Parcelable {
@SerializedName("bitRate")
var bitrate: Int? = null
var path: String? = null
@ColumnInfo(name = "is_video")
@SerializedName("isVideo")
var isVideo: Boolean = false

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class PodcastStatus {
var value: String? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class Podcasts {
@SerializedName("channel")
var channels: List<PodcastChannel>? = null

View file

@ -1,11 +1,12 @@
package com.cappielloantonio.tempo.subsonic.models
class ResponseStatus(val value: String) {
import androidx.annotation.Keep
@Keep
class ResponseStatus(val value: String) {
companion object {
@JvmField
var OK = "ok"
@JvmField
var FAILED = "failed"
}

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class ScanStatus {
var isScanning = false
var count: Long? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class SearchResult {
var matches: List<Child>? = null
var offset = 0

View file

@ -1,14 +1,14 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class SearchResult2 {
@SerializedName("artist")
var artists: List<Artist>? = null
@SerializedName("album")
var albums: List<Child>? = null
@SerializedName("song")
var songs: List<Child>? = null
}

View file

@ -1,14 +1,14 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class SearchResult3 {
@SerializedName("artist")
var artists: List<ArtistID3>? = null
@SerializedName("album")
var albums: List<AlbumID3>? = null
@SerializedName("song")
var songs: List<Child>? = null
}

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import java.util.*
@Keep
class Share {
var entries: List<Child>? = null
var id: String? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Shares {
var shares: List<Share>? = null
}

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import android.os.Parcelable
import androidx.annotation.Keep
import kotlinx.parcelize.Parcelize
@Keep
@Parcelize
class SimilarArtistID3 : ArtistID3(), Parcelable

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class SimilarSongs {
var songs: List<Child>? = null
}

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class SimilarSongs2 {
@SerializedName("song")
var songs: List<Child>? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class Songs {
@SerializedName("song")
var songs: List<Child>? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Starred {
var artists: List<Artist>? = null
var albums: List<Child>? = null

View file

@ -1,14 +1,14 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class Starred2 {
@SerializedName("artist")
var artists: List<ArtistID3>? = null
@SerializedName("album")
var albums: List<AlbumID3>? = null
@SerializedName("song")
var songs: List<Child>? = null
}

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class SubsonicResponse {
var error: Error? = null
var scanStatus: ScanStatus? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import com.google.gson.annotations.SerializedName
@Keep
class TopSongs {
@SerializedName("song")
var songs: List<Child>? = null

View file

@ -1,7 +1,9 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
import java.util.*
@Keep
class User {
var folders: List<Int>? = null
var username: String? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Users {
var users: List<User>? = null
}

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class VideoConversion {
var id: String? = null
var bitRate: Int? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class VideoInfo {
var captions: List<Captions>? = null
var audioTracks: List<AudioTrack>? = null

View file

@ -1,5 +1,8 @@
package com.cappielloantonio.tempo.subsonic.models
import androidx.annotation.Keep
@Keep
class Videos {
var videos: List<Child>? = null
}