diff options
Diffstat (limited to 'MediaBrowser.Model/Dto')
23 files changed, 0 insertions, 1865 deletions
diff --git a/MediaBrowser.Model/Dto/BaseItemDto.cs b/MediaBrowser.Model/Dto/BaseItemDto.cs deleted file mode 100644 index ba975db442..0000000000 --- a/MediaBrowser.Model/Dto/BaseItemDto.cs +++ /dev/null @@ -1,824 +0,0 @@ -using MediaBrowser.Model.Drawing; -using MediaBrowser.Model.Entities; -using MediaBrowser.Model.Extensions; -using MediaBrowser.Model.Library; -using MediaBrowser.Model.LiveTv; -using MediaBrowser.Model.Providers; -using MediaBrowser.Model.Sync; -using System; -using System.Collections.Generic; -using System.Diagnostics; -using MediaBrowser.Model.Serialization; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// This is strictly used as a data transfer object from the api layer. - /// This holds information about a BaseItem in a format that is convenient for the client. - /// </summary> - [DebuggerDisplay("Name = {Name}, ID = {Id}, Type = {Type}")] - public class BaseItemDto : IHasProviderIds, IItemDto, IHasServerId, IHasSyncInfo - { - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - - public string OriginalTitle { get; set; } - - /// <summary> - /// Gets or sets the server identifier. - /// </summary> - /// <value>The server identifier.</value> - public string ServerId { get; set; } - - /// <summary> - /// Gets or sets the id. - /// </summary> - /// <value>The id.</value> - public string Id { get; set; } - - /// <summary> - /// Gets or sets the etag. - /// </summary> - /// <value>The etag.</value> - public string Etag { get; set; } - - /// <summary> - /// Gets or sets the type of the source. - /// </summary> - /// <value>The type of the source.</value> - public string SourceType { get; set; } - - /// <summary> - /// Gets or sets the playlist item identifier. - /// </summary> - /// <value>The playlist item identifier.</value> - public string PlaylistItemId { get; set; } - - /// <summary> - /// Gets or sets the date created. - /// </summary> - /// <value>The date created.</value> - public DateTime? DateCreated { get; set; } - - public DateTime? DateLastMediaAdded { get; set; } - public string ExtraType { get; set; } - - public int? AirsBeforeSeasonNumber { get; set; } - public int? AirsAfterSeasonNumber { get; set; } - public int? AirsBeforeEpisodeNumber { get; set; } - public int? AbsoluteEpisodeNumber { get; set; } - public bool? DisplaySpecialsWithSeasons { get; set; } - public bool? CanDelete { get; set; } - public bool? CanDownload { get; set; } - - public bool? HasSubtitles { get; set; } - - public string PreferredMetadataLanguage { get; set; } - public string PreferredMetadataCountryCode { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether [supports synchronize]. - /// </summary> - /// <value><c>null</c> if [supports synchronize] contains no value, <c>true</c> if [supports synchronize]; otherwise, <c>false</c>.</value> - public bool? SupportsSync { get; set; } - /// <summary> - /// Gets or sets a value indicating whether this instance has synchronize job. - /// </summary> - /// <value><c>null</c> if [has synchronize job] contains no value, <c>true</c> if [has synchronize job]; otherwise, <c>false</c>.</value> - public bool? HasSyncJob { get; set; } - /// <summary> - /// Gets or sets a value indicating whether this instance is synced. - /// </summary> - /// <value><c>null</c> if [is synced] contains no value, <c>true</c> if [is synced]; otherwise, <c>false</c>.</value> - public bool? IsSynced { get; set; } - /// <summary> - /// Gets or sets the synchronize status. - /// </summary> - /// <value>The synchronize status.</value> - public SyncJobItemStatus? SyncStatus { get; set; } - /// <summary> - /// Gets or sets the synchronize percent. - /// </summary> - /// <value>The synchronize percent.</value> - public double? SyncPercent { get; set; } - - public string Container { get; set; } - - /// <summary> - /// Gets or sets the DVD season number. - /// </summary> - /// <value>The DVD season number.</value> - public int? DvdSeasonNumber { get; set; } - /// <summary> - /// Gets or sets the DVD episode number. - /// </summary> - /// <value>The DVD episode number.</value> - public float? DvdEpisodeNumber { get; set; } - - /// <summary> - /// Gets or sets the name of the sort. - /// </summary> - /// <value>The name of the sort.</value> - public string SortName { get; set; } - public string ForcedSortName { get; set; } - - /// <summary> - /// Gets or sets the video3 D format. - /// </summary> - /// <value>The video3 D format.</value> - public Video3DFormat? Video3DFormat { get; set; } - - /// <summary> - /// Gets or sets the premiere date. - /// </summary> - /// <value>The premiere date.</value> - public DateTime? PremiereDate { get; set; } - - /// <summary> - /// Gets or sets the external urls. - /// </summary> - /// <value>The external urls.</value> - public ExternalUrl[] ExternalUrls { get; set; } - - /// <summary> - /// Gets or sets the media versions. - /// </summary> - /// <value>The media versions.</value> - public List<MediaSourceInfo> MediaSources { get; set; } - - /// <summary> - /// Gets or sets the critic rating. - /// </summary> - /// <value>The critic rating.</value> - public float? CriticRating { get; set; } - - /// <summary> - /// Gets or sets the game system. - /// </summary> - /// <value>The game system.</value> - public string GameSystem { get; set; } - - public string[] ProductionLocations { get; set; } - - public string[] MultiPartGameFiles { get; set; } - - /// <summary> - /// Gets or sets the path. - /// </summary> - /// <value>The path.</value> - public string Path { get; set; } - - /// <summary> - /// Gets or sets the official rating. - /// </summary> - /// <value>The official rating.</value> - public string OfficialRating { get; set; } - - /// <summary> - /// Gets or sets the custom rating. - /// </summary> - /// <value>The custom rating.</value> - public string CustomRating { get; set; } - - /// <summary> - /// Gets or sets the channel identifier. - /// </summary> - /// <value>The channel identifier.</value> - public string ChannelId { get; set; } - public string ChannelName { get; set; } - public string ServiceName { get; set; } - - /// <summary> - /// Gets or sets the overview. - /// </summary> - /// <value>The overview.</value> - public string Overview { get; set; } - - /// <summary> - /// Gets or sets the taglines. - /// </summary> - /// <value>The taglines.</value> - public string[] Taglines { get; set; } - - /// <summary> - /// Gets or sets the genres. - /// </summary> - /// <value>The genres.</value> - public List<string> Genres { get; set; } - - /// <summary> - /// Gets or sets the community rating. - /// </summary> - /// <value>The community rating.</value> - public float? CommunityRating { get; set; } - - /// <summary> - /// Gets or sets the cumulative run time ticks. - /// </summary> - /// <value>The cumulative run time ticks.</value> - public long? CumulativeRunTimeTicks { get; set; } - - /// <summary> - /// Gets or sets the run time ticks. - /// </summary> - /// <value>The run time ticks.</value> - public long? RunTimeTicks { get; set; } - - /// <summary> - /// Gets or sets the play access. - /// </summary> - /// <value>The play access.</value> - public PlayAccess? PlayAccess { get; set; } - - /// <summary> - /// Gets or sets the aspect ratio. - /// </summary> - /// <value>The aspect ratio.</value> - public string AspectRatio { get; set; } - - /// <summary> - /// Gets or sets the production year. - /// </summary> - /// <value>The production year.</value> - public int? ProductionYear { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is place holder. - /// </summary> - /// <value><c>null</c> if [is place holder] contains no value, <c>true</c> if [is place holder]; otherwise, <c>false</c>.</value> - public bool? IsPlaceHolder { get; set; } - - /// <summary> - /// Gets or sets the number. - /// </summary> - /// <value>The number.</value> - public string Number { get; set; } - public string ChannelNumber { get; set; } - - /// <summary> - /// Gets or sets the index number. - /// </summary> - /// <value>The index number.</value> - public int? IndexNumber { get; set; } - - /// <summary> - /// Gets or sets the index number end. - /// </summary> - /// <value>The index number end.</value> - public int? IndexNumberEnd { get; set; } - - /// <summary> - /// Gets or sets the parent index number. - /// </summary> - /// <value>The parent index number.</value> - public int? ParentIndexNumber { get; set; } - - /// <summary> - /// Gets or sets the trailer urls. - /// </summary> - /// <value>The trailer urls.</value> - public MediaUrl[] RemoteTrailers { get; set; } - - /// <summary> - /// Gets or sets the provider ids. - /// </summary> - /// <value>The provider ids.</value> - public Dictionary<string, string> ProviderIds { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is HD. - /// </summary> - /// <value><c>null</c> if [is HD] contains no value, <c>true</c> if [is HD]; otherwise, <c>false</c>.</value> - public bool? IsHD { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is folder. - /// </summary> - /// <value><c>true</c> if this instance is folder; otherwise, <c>false</c>.</value> - public bool? IsFolder { get; set; } - - /// <summary> - /// Gets or sets the parent id. - /// </summary> - /// <value>The parent id.</value> - public string ParentId { get; set; } - - /// <summary> - /// Gets or sets the type. - /// </summary> - /// <value>The type.</value> - public string Type { get; set; } - - /// <summary> - /// Gets or sets the people. - /// </summary> - /// <value>The people.</value> - public BaseItemPerson[] People { get; set; } - - /// <summary> - /// Gets or sets the studios. - /// </summary> - /// <value>The studios.</value> - public NameIdPair[] Studios { get; set; } - - public NameIdPair[] GenreItems { get; set; } - - /// <summary> - /// If the item does not have a logo, this will hold the Id of the Parent that has one. - /// </summary> - /// <value>The parent logo item id.</value> - public string ParentLogoItemId { get; set; } - - /// <summary> - /// If the item does not have any backdrops, this will hold the Id of the Parent that has one. - /// </summary> - /// <value>The parent backdrop item id.</value> - public string ParentBackdropItemId { get; set; } - - /// <summary> - /// Gets or sets the parent backdrop image tags. - /// </summary> - /// <value>The parent backdrop image tags.</value> - public string[] ParentBackdropImageTags { get; set; } - - /// <summary> - /// Gets or sets the local trailer count. - /// </summary> - /// <value>The local trailer count.</value> - public int? LocalTrailerCount { get; set; } - - /// <summary> - /// User data for this item based on the user it's being requested for - /// </summary> - /// <value>The user data.</value> - public UserItemDataDto UserData { get; set; } - - /// <summary> - /// Gets or sets the recursive item count. - /// </summary> - /// <value>The recursive item count.</value> - public int? RecursiveItemCount { get; set; } - - /// <summary> - /// Gets or sets the child count. - /// </summary> - /// <value>The child count.</value> - public int? ChildCount { get; set; } - - /// <summary> - /// Gets or sets the name of the series. - /// </summary> - /// <value>The name of the series.</value> - public string SeriesName { get; set; } - - /// <summary> - /// Gets or sets the series id. - /// </summary> - /// <value>The series id.</value> - public string SeriesId { get; set; } - - /// <summary> - /// Gets or sets the season identifier. - /// </summary> - /// <value>The season identifier.</value> - public string SeasonId { get; set; } - - /// <summary> - /// Gets or sets the special feature count. - /// </summary> - /// <value>The special feature count.</value> - public int? SpecialFeatureCount { get; set; } - - /// <summary> - /// Gets or sets the display preferences id. - /// </summary> - /// <value>The display preferences id.</value> - public string DisplayPreferencesId { get; set; } - - /// <summary> - /// Gets or sets the status. - /// </summary> - /// <value>The status.</value> - public string Status { get; set; } - - /// <summary> - /// Gets or sets the air time. - /// </summary> - /// <value>The air time.</value> - public string AirTime { get; set; } - - /// <summary> - /// Gets or sets the air days. - /// </summary> - /// <value>The air days.</value> - public DayOfWeek[] AirDays { get; set; } - - /// <summary> - /// Gets or sets the tags. - /// </summary> - /// <value>The tags.</value> - public string[] Tags { get; set; } - - /// <summary> - /// Gets or sets the primary image aspect ratio, after image enhancements. - /// </summary> - /// <value>The primary image aspect ratio.</value> - public double? PrimaryImageAspectRatio { get; set; } - - /// <summary> - /// Gets or sets the artists. - /// </summary> - /// <value>The artists.</value> - public string[] Artists { get; set; } - - /// <summary> - /// Gets or sets the artist items. - /// </summary> - /// <value>The artist items.</value> - public NameIdPair[] ArtistItems { get; set; } - - /// <summary> - /// Gets or sets the album. - /// </summary> - /// <value>The album.</value> - public string Album { get; set; } - - /// <summary> - /// Gets or sets the type of the collection. - /// </summary> - /// <value>The type of the collection.</value> - public string CollectionType { get; set; } - - /// <summary> - /// Gets or sets the display order. - /// </summary> - /// <value>The display order.</value> - public string DisplayOrder { get; set; } - - /// <summary> - /// Gets or sets the album id. - /// </summary> - /// <value>The album id.</value> - public string AlbumId { get; set; } - /// <summary> - /// Gets or sets the album image tag. - /// </summary> - /// <value>The album image tag.</value> - public string AlbumPrimaryImageTag { get; set; } - - /// <summary> - /// Gets or sets the series primary image tag. - /// </summary> - /// <value>The series primary image tag.</value> - public string SeriesPrimaryImageTag { get; set; } - - /// <summary> - /// Gets or sets the album artist. - /// </summary> - /// <value>The album artist.</value> - public string AlbumArtist { get; set; } - - /// <summary> - /// Gets or sets the album artists. - /// </summary> - /// <value>The album artists.</value> - public NameIdPair[] AlbumArtists { get; set; } - - /// <summary> - /// Gets or sets the name of the season. - /// </summary> - /// <value>The name of the season.</value> - public string SeasonName { get; set; } - - /// <summary> - /// Gets or sets the media streams. - /// </summary> - /// <value>The media streams.</value> - public MediaStream[] MediaStreams { get; set; } - - /// <summary> - /// Gets or sets the type of the video. - /// </summary> - /// <value>The type of the video.</value> - public VideoType? VideoType { get; set; } - - /// <summary> - /// Gets or sets the part count. - /// </summary> - /// <value>The part count.</value> - public int? PartCount { get; set; } - public int? MediaSourceCount { get; set; } - - /// <summary> - /// Determines whether the specified type is type. - /// </summary> - /// <param name="type">The type.</param> - /// <returns><c>true</c> if the specified type is type; otherwise, <c>false</c>.</returns> - public bool IsType(Type type) - { - return IsType(type.Name); - } - - /// <summary> - /// Determines whether the specified type is type. - /// </summary> - /// <param name="type">The type.</param> - /// <returns><c>true</c> if the specified type is type; otherwise, <c>false</c>.</returns> - public bool IsType(string type) - { - return StringHelper.EqualsIgnoreCase(Type, type); - } - - /// <summary> - /// Gets or sets the image tags. - /// </summary> - /// <value>The image tags.</value> - public Dictionary<ImageType, string> ImageTags { get; set; } - - /// <summary> - /// Gets or sets the backdrop image tags. - /// </summary> - /// <value>The backdrop image tags.</value> - public string[] BackdropImageTags { get; set; } - - /// <summary> - /// Gets or sets the screenshot image tags. - /// </summary> - /// <value>The screenshot image tags.</value> - public string[] ScreenshotImageTags { get; set; } - - /// <summary> - /// Gets or sets the parent logo image tag. - /// </summary> - /// <value>The parent logo image tag.</value> - public string ParentLogoImageTag { get; set; } - - /// <summary> - /// If the item does not have a art, this will hold the Id of the Parent that has one. - /// </summary> - /// <value>The parent art item id.</value> - public string ParentArtItemId { get; set; } - - /// <summary> - /// Gets or sets the parent art image tag. - /// </summary> - /// <value>The parent art image tag.</value> - public string ParentArtImageTag { get; set; } - - /// <summary> - /// Gets or sets the series thumb image tag. - /// </summary> - /// <value>The series thumb image tag.</value> - public string SeriesThumbImageTag { get; set; } - - /// <summary> - /// Gets or sets the series studio. - /// </summary> - /// <value>The series studio.</value> - public string SeriesStudio { get; set; } - - /// <summary> - /// Gets or sets the parent thumb item id. - /// </summary> - /// <value>The parent thumb item id.</value> - public string ParentThumbItemId { get; set; } - - /// <summary> - /// Gets or sets the parent thumb image tag. - /// </summary> - /// <value>The parent thumb image tag.</value> - public string ParentThumbImageTag { get; set; } - - /// <summary> - /// Gets or sets the parent primary image item identifier. - /// </summary> - /// <value>The parent primary image item identifier.</value> - public string ParentPrimaryImageItemId { get; set; } - - /// <summary> - /// Gets or sets the parent primary image tag. - /// </summary> - /// <value>The parent primary image tag.</value> - public string ParentPrimaryImageTag { get; set; } - - /// <summary> - /// Gets or sets the chapters. - /// </summary> - /// <value>The chapters.</value> - public List<ChapterInfoDto> Chapters { get; set; } - - /// <summary> - /// Gets or sets the type of the location. - /// </summary> - /// <value>The type of the location.</value> - public LocationType? LocationType { get; set; } - - /// <summary> - /// Gets or sets the type of the iso. - /// </summary> - /// <value>The type of the iso.</value> - public IsoType? IsoType { get; set; } - - /// <summary> - /// Gets or sets the type of the media. - /// </summary> - /// <value>The type of the media.</value> - public string MediaType { get; set; } - - /// <summary> - /// Gets or sets the end date. - /// </summary> - /// <value>The end date.</value> - public DateTime? EndDate { get; set; } - - /// <summary> - /// Gets or sets the home page URL. - /// </summary> - /// <value>The home page URL.</value> - public string HomePageUrl { get; set; } - - /// <summary> - /// Gets or sets the locked fields. - /// </summary> - /// <value>The locked fields.</value> - public MetadataFields[] LockedFields { get; set; } - - /// <summary> - /// Gets or sets the trailer count. - /// </summary> - /// <value>The trailer count.</value> - public int? TrailerCount { get; set; } - /// <summary> - /// Gets or sets the movie count. - /// </summary> - /// <value>The movie count.</value> - public int? MovieCount { get; set; } - /// <summary> - /// Gets or sets the series count. - /// </summary> - /// <value>The series count.</value> - public int? SeriesCount { get; set; } - public int? ProgramCount { get; set; } - /// <summary> - /// Gets or sets the episode count. - /// </summary> - /// <value>The episode count.</value> - public int? EpisodeCount { get; set; } - /// <summary> - /// Gets or sets the game count. - /// </summary> - /// <value>The game count.</value> - public int? GameCount { get; set; } - /// <summary> - /// Gets or sets the song count. - /// </summary> - /// <value>The song count.</value> - public int? SongCount { get; set; } - /// <summary> - /// Gets or sets the album count. - /// </summary> - /// <value>The album count.</value> - public int? AlbumCount { get; set; } - public int? ArtistCount { get; set; } - /// <summary> - /// Gets or sets the music video count. - /// </summary> - /// <value>The music video count.</value> - public int? MusicVideoCount { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether [enable internet providers]. - /// </summary> - /// <value><c>true</c> if [enable internet providers]; otherwise, <c>false</c>.</value> - public bool? LockData { get; set; } - - public int? Width { get; set; } - public int? Height { get; set; } - public string CameraMake { get; set; } - public string CameraModel { get; set; } - public string Software { get; set; } - public double? ExposureTime { get; set; } - public double? FocalLength { get; set; } - public ImageOrientation? ImageOrientation { get; set; } - public double? Aperture { get; set; } - public double? ShutterSpeed { get; set; } - public double? Latitude { get; set; } - public double? Longitude { get; set; } - public double? Altitude { get; set; } - public int? IsoSpeedRating { get; set; } - - /// <summary> - /// Used by RecordingGroup - /// </summary> - public int? RecordingCount { get; set; } - - /// <summary> - /// Gets or sets the series timer identifier. - /// </summary> - /// <value>The series timer identifier.</value> - public string SeriesTimerId { get; set; } - - /// <summary> - /// Gets or sets the program identifier. - /// </summary> - /// <value>The program identifier.</value> - public string ProgramId { get; set; } - - /// <summary> - /// Gets or sets the channel primary image tag. - /// </summary> - /// <value>The channel primary image tag.</value> - public string ChannelPrimaryImageTag { get; set; } - - /// <summary> - /// The start date of the recording, in UTC. - /// </summary> - public DateTime? StartDate { get; set; } - - /// <summary> - /// Gets or sets the completion percentage. - /// </summary> - /// <value>The completion percentage.</value> - public double? CompletionPercentage { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is repeat. - /// </summary> - /// <value><c>true</c> if this instance is repeat; otherwise, <c>false</c>.</value> - public bool? IsRepeat { get; set; } - - /// <summary> - /// Gets or sets the episode title. - /// </summary> - /// <value>The episode title.</value> - public string EpisodeTitle { get; set; } - - /// <summary> - /// Gets or sets the type of the channel. - /// </summary> - /// <value>The type of the channel.</value> - public ChannelType? ChannelType { get; set; } - - /// <summary> - /// Gets or sets the audio. - /// </summary> - /// <value>The audio.</value> - public ProgramAudio? Audio { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is movie. - /// </summary> - /// <value><c>true</c> if this instance is movie; otherwise, <c>false</c>.</value> - public bool? IsMovie { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is sports. - /// </summary> - /// <value><c>true</c> if this instance is sports; otherwise, <c>false</c>.</value> - public bool? IsSports { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is series. - /// </summary> - /// <value><c>true</c> if this instance is series; otherwise, <c>false</c>.</value> - public bool? IsSeries { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is live. - /// </summary> - /// <value><c>true</c> if this instance is live; otherwise, <c>false</c>.</value> - public bool? IsLive { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is news. - /// </summary> - /// <value><c>true</c> if this instance is news; otherwise, <c>false</c>.</value> - public bool? IsNews { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is kids. - /// </summary> - /// <value><c>true</c> if this instance is kids; otherwise, <c>false</c>.</value> - public bool? IsKids { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is premiere. - /// </summary> - /// <value><c>true</c> if this instance is premiere; otherwise, <c>false</c>.</value> - public bool? IsPremiere { get; set; } - - /// <summary> - /// Gets or sets the timer identifier. - /// </summary> - /// <value>The timer identifier.</value> - public string TimerId { get; set; } - /// <summary> - /// Gets or sets the current program. - /// </summary> - /// <value>The current program.</value> - public BaseItemDto CurrentProgram { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/BaseItemPerson.cs b/MediaBrowser.Model/Dto/BaseItemPerson.cs deleted file mode 100644 index e73872cb76..0000000000 --- a/MediaBrowser.Model/Dto/BaseItemPerson.cs +++ /dev/null @@ -1,55 +0,0 @@ -using System.Diagnostics; -using MediaBrowser.Model.Serialization; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// This is used by the api to get information about a Person within a BaseItem - /// </summary> - [DebuggerDisplay("Name = {Name}, Role = {Role}, Type = {Type}")] - public class BaseItemPerson - { - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - - /// <summary> - /// Gets or sets the identifier. - /// </summary> - /// <value>The identifier.</value> - public string Id { get; set; } - - /// <summary> - /// Gets or sets the role. - /// </summary> - /// <value>The role.</value> - public string Role { get; set; } - - /// <summary> - /// Gets or sets the type. - /// </summary> - /// <value>The type.</value> - public string Type { get; set; } - - /// <summary> - /// Gets or sets the primary image tag. - /// </summary> - /// <value>The primary image tag.</value> - public string PrimaryImageTag { get; set; } - - /// <summary> - /// Gets a value indicating whether this instance has primary image. - /// </summary> - /// <value><c>true</c> if this instance has primary image; otherwise, <c>false</c>.</value> - [IgnoreDataMember] - public bool HasPrimaryImage - { - get - { - return PrimaryImageTag != null; - } - } - } -} diff --git a/MediaBrowser.Model/Dto/ChapterInfoDto.cs b/MediaBrowser.Model/Dto/ChapterInfoDto.cs deleted file mode 100644 index 51e0a545af..0000000000 --- a/MediaBrowser.Model/Dto/ChapterInfoDto.cs +++ /dev/null @@ -1,40 +0,0 @@ -using System.Diagnostics; -using MediaBrowser.Model.Serialization; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class ChapterInfo - /// </summary> - [DebuggerDisplay("Name = {Name}")] - public class ChapterInfoDto - { - /// <summary> - /// Gets or sets the start position ticks. - /// </summary> - /// <value>The start position ticks.</value> - public long StartPositionTicks { get; set; } - - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - - /// <summary> - /// Gets or sets the image tag. - /// </summary> - /// <value>The image tag.</value> - public string ImageTag { get; set; } - - /// <summary> - /// Gets a value indicating whether this instance has image. - /// </summary> - /// <value><c>true</c> if this instance has image; otherwise, <c>false</c>.</value> - [IgnoreDataMember] - public bool HasImage - { - get { return ImageTag != null; } - } - } -} diff --git a/MediaBrowser.Model/Dto/GameSystemSummary.cs b/MediaBrowser.Model/Dto/GameSystemSummary.cs deleted file mode 100644 index 2cd9d408db..0000000000 --- a/MediaBrowser.Model/Dto/GameSystemSummary.cs +++ /dev/null @@ -1,48 +0,0 @@ -using System.Collections.Generic; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class GameSystemSummary - /// </summary> - public class GameSystemSummary - { - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string DisplayName { get; set; } - - /// <summary> - /// Gets or sets the game count. - /// </summary> - /// <value>The game count.</value> - public int GameCount { get; set; } - - /// <summary> - /// Gets or sets the game extensions. - /// </summary> - /// <value>The game extensions.</value> - public string[] GameFileExtensions { get; set; } - - /// <summary> - /// Gets or sets the client installed game count. - /// </summary> - /// <value>The client installed game count.</value> - public int ClientInstalledGameCount { get; set; } - - /// <summary> - /// Initializes a new instance of the <see cref="GameSystemSummary"/> class. - /// </summary> - public GameSystemSummary() - { - GameFileExtensions = new string[] { }; - } - } -} diff --git a/MediaBrowser.Model/Dto/IHasServerId.cs b/MediaBrowser.Model/Dto/IHasServerId.cs deleted file mode 100644 index 0515203da9..0000000000 --- a/MediaBrowser.Model/Dto/IHasServerId.cs +++ /dev/null @@ -1,8 +0,0 @@ - -namespace MediaBrowser.Model.Dto -{ - public interface IHasServerId - { - string ServerId { get; } - } -} diff --git a/MediaBrowser.Model/Dto/IHasSyncInfo.cs b/MediaBrowser.Model/Dto/IHasSyncInfo.cs deleted file mode 100644 index 7471dacdd7..0000000000 --- a/MediaBrowser.Model/Dto/IHasSyncInfo.cs +++ /dev/null @@ -1,14 +0,0 @@ -using MediaBrowser.Model.Sync; - -namespace MediaBrowser.Model.Dto -{ - public interface IHasSyncInfo - { - string Id { get; } - bool? SupportsSync { get; set; } - bool? HasSyncJob { get; set; } - double? SyncPercent { get; set; } - bool? IsSynced { get; set; } - SyncJobItemStatus? SyncStatus { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/IItemDto.cs b/MediaBrowser.Model/Dto/IItemDto.cs deleted file mode 100644 index 3e7d1c6085..0000000000 --- a/MediaBrowser.Model/Dto/IItemDto.cs +++ /dev/null @@ -1,15 +0,0 @@ - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Interface IItemDto - /// </summary> - public interface IItemDto - { - /// <summary> - /// Gets or sets the primary image aspect ratio. - /// </summary> - /// <value>The primary image aspect ratio.</value> - double? PrimaryImageAspectRatio { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/ImageByNameInfo.cs b/MediaBrowser.Model/Dto/ImageByNameInfo.cs deleted file mode 100644 index b7921d993d..0000000000 --- a/MediaBrowser.Model/Dto/ImageByNameInfo.cs +++ /dev/null @@ -1,32 +0,0 @@ - -namespace MediaBrowser.Model.Dto -{ - public class ImageByNameInfo - { - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - /// <summary> - /// Gets or sets the theme. - /// </summary> - /// <value>The theme.</value> - public string Theme { get; set; } - /// <summary> - /// Gets or sets the context. - /// </summary> - /// <value>The context.</value> - public string Context { get; set; } - /// <summary> - /// Gets or sets the length of the file. - /// </summary> - /// <value>The length of the file.</value> - public long FileLength { get; set; } - /// <summary> - /// Gets or sets the format. - /// </summary> - /// <value>The format.</value> - public string Format { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/ImageInfo.cs b/MediaBrowser.Model/Dto/ImageInfo.cs deleted file mode 100644 index 5eabb16a56..0000000000 --- a/MediaBrowser.Model/Dto/ImageInfo.cs +++ /dev/null @@ -1,51 +0,0 @@ -using MediaBrowser.Model.Entities; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class ImageInfo - /// </summary> - public class ImageInfo - { - /// <summary> - /// Gets or sets the type of the image. - /// </summary> - /// <value>The type of the image.</value> - public ImageType ImageType { get; set; } - - /// <summary> - /// Gets or sets the index of the image. - /// </summary> - /// <value>The index of the image.</value> - public int? ImageIndex { get; set; } - - /// <summary> - /// The image tag - /// </summary> - public string ImageTag; - - /// <summary> - /// Gets or sets the path. - /// </summary> - /// <value>The path.</value> - public string Path { get; set; } - - /// <summary> - /// Gets or sets the height. - /// </summary> - /// <value>The height.</value> - public int? Height { get; set; } - - /// <summary> - /// Gets or sets the width. - /// </summary> - /// <value>The width.</value> - public int? Width { get; set; } - - /// <summary> - /// Gets or sets the size. - /// </summary> - /// <value>The size.</value> - public long Size { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/ImageOptions.cs b/MediaBrowser.Model/Dto/ImageOptions.cs deleted file mode 100644 index 98bd0279a7..0000000000 --- a/MediaBrowser.Model/Dto/ImageOptions.cs +++ /dev/null @@ -1,110 +0,0 @@ -using MediaBrowser.Model.Drawing; -using MediaBrowser.Model.Entities; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class ImageOptions - /// </summary> - public class ImageOptions - { - /// <summary> - /// Gets or sets the type of the image. - /// </summary> - /// <value>The type of the image.</value> - public ImageType ImageType { get; set; } - - /// <summary> - /// Gets or sets the index of the image. - /// </summary> - /// <value>The index of the image.</value> - public int? ImageIndex { get; set; } - - /// <summary> - /// Gets or sets the width. - /// </summary> - /// <value>The width.</value> - public int? Width { get; set; } - - /// <summary> - /// Gets or sets the height. - /// </summary> - /// <value>The height.</value> - public int? Height { get; set; } - - /// <summary> - /// Gets or sets the width of the max. - /// </summary> - /// <value>The width of the max.</value> - public int? MaxWidth { get; set; } - - /// <summary> - /// Gets or sets the height of the max. - /// </summary> - /// <value>The height of the max.</value> - public int? MaxHeight { get; set; } - - /// <summary> - /// Gets or sets the quality. - /// </summary> - /// <value>The quality.</value> - public int? Quality { get; set; } - - /// <summary> - /// Gets or sets the image tag. - /// If set this will result in strong, unconditional response caching - /// </summary> - /// <value>The hash.</value> - public string Tag { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether [crop whitespace]. - /// </summary> - /// <value><c>null</c> if [crop whitespace] contains no value, <c>true</c> if [crop whitespace]; otherwise, <c>false</c>.</value> - public bool? CropWhitespace { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether [enable image enhancers]. - /// </summary> - /// <value><c>true</c> if [enable image enhancers]; otherwise, <c>false</c>.</value> - public bool EnableImageEnhancers { get; set; } - - /// <summary> - /// Gets or sets the format. - /// </summary> - /// <value>The format.</value> - public ImageFormat? Format { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether [add played indicator]. - /// </summary> - /// <value><c>true</c> if [add played indicator]; otherwise, <c>false</c>.</value> - public bool AddPlayedIndicator { get; set; } - - /// <summary> - /// Gets or sets the percent played. - /// </summary> - /// <value>The percent played.</value> - public int? PercentPlayed { get; set; } - - /// <summary> - /// Gets or sets the un played count. - /// </summary> - /// <value>The un played count.</value> - public int? UnPlayedCount { get; set; } - - /// <summary> - /// Gets or sets the color of the background. - /// </summary> - /// <value>The color of the background.</value> - public string BackgroundColor { get; set; } - - /// <summary> - /// Initializes a new instance of the <see cref="ImageOptions" /> class. - /// </summary> - public ImageOptions() - { - EnableImageEnhancers = true; - } - } -} diff --git a/MediaBrowser.Model/Dto/ItemCounts.cs b/MediaBrowser.Model/Dto/ItemCounts.cs deleted file mode 100644 index 8ceb3a86b9..0000000000 --- a/MediaBrowser.Model/Dto/ItemCounts.cs +++ /dev/null @@ -1,67 +0,0 @@ -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class LibrarySummary - /// </summary> - public class ItemCounts - { - /// <summary> - /// Gets or sets the movie count. - /// </summary> - /// <value>The movie count.</value> - public int MovieCount { get; set; } - /// <summary> - /// Gets or sets the series count. - /// </summary> - /// <value>The series count.</value> - public int SeriesCount { get; set; } - /// <summary> - /// Gets or sets the episode count. - /// </summary> - /// <value>The episode count.</value> - public int EpisodeCount { get; set; } - /// <summary> - /// Gets or sets the game count. - /// </summary> - /// <value>The game count.</value> - public int GameCount { get; set; } - public int ArtistCount { get; set; } - public int ProgramCount { get; set; } - /// <summary> - /// Gets or sets the game system count. - /// </summary> - /// <value>The game system count.</value> - public int GameSystemCount { get; set; } - /// <summary> - /// Gets or sets the trailer count. - /// </summary> - /// <value>The trailer count.</value> - public int TrailerCount { get; set; } - /// <summary> - /// Gets or sets the song count. - /// </summary> - /// <value>The song count.</value> - public int SongCount { get; set; } - /// <summary> - /// Gets or sets the album count. - /// </summary> - /// <value>The album count.</value> - public int AlbumCount { get; set; } - /// <summary> - /// Gets or sets the music video count. - /// </summary> - /// <value>The music video count.</value> - public int MusicVideoCount { get; set; } - /// <summary> - /// Gets or sets the box set count. - /// </summary> - /// <value>The box set count.</value> - public int BoxSetCount { get; set; } - /// <summary> - /// Gets or sets the book count. - /// </summary> - /// <value>The book count.</value> - public int BookCount { get; set; } - public int ItemCount { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/ItemIndex.cs b/MediaBrowser.Model/Dto/ItemIndex.cs deleted file mode 100644 index 96cef622b2..0000000000 --- a/MediaBrowser.Model/Dto/ItemIndex.cs +++ /dev/null @@ -1,21 +0,0 @@ - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class ItemIndex - /// </summary> - public class ItemIndex - { - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - - /// <summary> - /// Gets or sets the item count. - /// </summary> - /// <value>The item count.</value> - public int ItemCount { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/MediaSourceInfo.cs b/MediaBrowser.Model/Dto/MediaSourceInfo.cs deleted file mode 100644 index d6301b331f..0000000000 --- a/MediaBrowser.Model/Dto/MediaSourceInfo.cs +++ /dev/null @@ -1,228 +0,0 @@ -using MediaBrowser.Model.Entities; -using MediaBrowser.Model.Extensions; -using MediaBrowser.Model.MediaInfo; -using System.Collections.Generic; -using MediaBrowser.Model.Serialization; -using MediaBrowser.Model.Session; - -namespace MediaBrowser.Model.Dto -{ - public class MediaSourceInfo - { - public MediaProtocol Protocol { get; set; } - public string Id { get; set; } - - public string Path { get; set; } - - public MediaSourceType Type { get; set; } - - public string Container { get; set; } - public long? Size { get; set; } - - public string Name { get; set; } - - /// <summary> - /// Differentiate internet url vs local network - /// </summary> - public bool IsRemote { get; set; } - - public string ETag { get; set; } - public long? RunTimeTicks { get; set; } - public bool ReadAtNativeFramerate { get; set; } - public bool IgnoreDts { get; set; } - public bool IgnoreIndex { get; set; } - public bool GenPtsInput { get; set; } - public bool SupportsTranscoding { get; set; } - public bool SupportsDirectStream { get; set; } - public bool SupportsDirectPlay { get; set; } - public bool IsInfiniteStream { get; set; } - public bool RequiresOpening { get; set; } - public string OpenToken { get; set; } - public bool RequiresClosing { get; set; } - public bool SupportsProbing { get; set; } - public string LiveStreamId { get; set; } - public int? BufferMs { get; set; } - - public bool RequiresLooping { get; set; } - - public VideoType? VideoType { get; set; } - - public IsoType? IsoType { get; set; } - - public Video3DFormat? Video3DFormat { get; set; } - - public List<MediaStream> MediaStreams { get; set; } - - public string[] Formats { get; set; } - - public int? Bitrate { get; set; } - - public TransportStreamTimestamp? Timestamp { get; set; } - public Dictionary<string, string> RequiredHttpHeaders { get; set; } - - public string TranscodingUrl { get; set; } - public string TranscodingSubProtocol { get; set; } - public string TranscodingContainer { get; set; } - - public int? AnalyzeDurationMs { get; set; } - - public MediaSourceInfo() - { - Formats = new string[] { }; - MediaStreams = new List<MediaStream>(); - RequiredHttpHeaders = new Dictionary<string, string>(); - SupportsTranscoding = true; - SupportsDirectStream = true; - SupportsDirectPlay = true; - SupportsProbing = true; - } - - public void InferTotalBitrate(bool force = false) - { - if (MediaStreams == null) - { - return; - } - - if (!force && Bitrate.HasValue) - { - return; - } - - var bitrate = 0; - foreach (var stream in MediaStreams) - { - if (!stream.IsExternal) - { - bitrate += stream.BitRate ?? 0; - } - } - - if (bitrate > 0) - { - Bitrate = bitrate; - } - } - - [IgnoreDataMember] - public List<TranscodeReason> TranscodeReasons { get; set; } - - public int? DefaultAudioStreamIndex { get; set; } - public int? DefaultSubtitleStreamIndex { get; set; } - - [IgnoreDataMember] - public MediaStream DefaultAudioStream - { - get { return GetDefaultAudioStream(DefaultAudioStreamIndex); } - } - - public MediaStream GetDefaultAudioStream(int? defaultIndex) - { - if (defaultIndex.HasValue) - { - var val = defaultIndex.Value; - - foreach (MediaStream i in MediaStreams) - { - if (i.Type == MediaStreamType.Audio && i.Index == val) - { - return i; - } - } - } - - foreach (MediaStream i in MediaStreams) - { - if (i.Type == MediaStreamType.Audio && i.IsDefault) - { - return i; - } - } - - foreach (MediaStream i in MediaStreams) - { - if (i.Type == MediaStreamType.Audio) - { - return i; - } - } - - return null; - } - - [IgnoreDataMember] - public MediaStream VideoStream - { - get - { - foreach (MediaStream i in MediaStreams) - { - if (i.Type == MediaStreamType.Video) - { - return i; - } - } - - return null; - } - } - - public MediaStream GetMediaStream(MediaStreamType type, int index) - { - foreach (MediaStream i in MediaStreams) - { - if (i.Type == type && i.Index == index) - { - return i; - } - } - - return null; - } - - public int? GetStreamCount(MediaStreamType type) - { - int numMatches = 0; - int numStreams = 0; - - foreach (MediaStream i in MediaStreams) - { - numStreams++; - if (i.Type == type) - { - numMatches++; - } - } - - if (numStreams == 0) - { - return null; - } - - return numMatches; - } - - public bool? IsSecondaryAudio(MediaStream stream) - { - // Look for the first audio track marked as default - foreach (MediaStream currentStream in MediaStreams) - { - if (currentStream.Type == MediaStreamType.Audio && currentStream.IsDefault) - { - return currentStream.Index != stream.Index; - } - } - - // Look for the first audio track - foreach (MediaStream currentStream in MediaStreams) - { - if (currentStream.Type == MediaStreamType.Audio) - { - return currentStream.Index != stream.Index; - } - } - - return null; - } - } -} diff --git a/MediaBrowser.Model/Dto/MediaSourceType.cs b/MediaBrowser.Model/Dto/MediaSourceType.cs deleted file mode 100644 index e049785025..0000000000 --- a/MediaBrowser.Model/Dto/MediaSourceType.cs +++ /dev/null @@ -1,9 +0,0 @@ -namespace MediaBrowser.Model.Dto -{ - public enum MediaSourceType - { - Default = 0, - Grouping = 1, - Placeholder = 2 - } -}
\ No newline at end of file diff --git a/MediaBrowser.Model/Dto/MetadataEditorInfo.cs b/MediaBrowser.Model/Dto/MetadataEditorInfo.cs deleted file mode 100644 index aa8b33c817..0000000000 --- a/MediaBrowser.Model/Dto/MetadataEditorInfo.cs +++ /dev/null @@ -1,27 +0,0 @@ -using MediaBrowser.Model.Entities; -using MediaBrowser.Model.Globalization; -using MediaBrowser.Model.Providers; -using System.Collections.Generic; - -namespace MediaBrowser.Model.Dto -{ - public class MetadataEditorInfo - { - public ParentalRating[] ParentalRatingOptions { get; set; } - public CountryInfo[] Countries { get; set; } - public CultureDto[] Cultures { get; set; } - public ExternalIdInfo[] ExternalIdInfos { get; set; } - - public string ContentType { get; set; } - public NameValuePair[] ContentTypeOptions { get; set; } - - public MetadataEditorInfo() - { - ParentalRatingOptions = new ParentalRating[] { }; - Countries = new CountryInfo[] { }; - Cultures = new CultureDto[] { }; - ExternalIdInfos = new ExternalIdInfo[] { }; - ContentTypeOptions = new NameValuePair[] { }; - } - } -} diff --git a/MediaBrowser.Model/Dto/NameIdPair.cs b/MediaBrowser.Model/Dto/NameIdPair.cs deleted file mode 100644 index d3931516cd..0000000000 --- a/MediaBrowser.Model/Dto/NameIdPair.cs +++ /dev/null @@ -1,17 +0,0 @@ - -namespace MediaBrowser.Model.Dto -{ - public class NameIdPair - { - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - /// <summary> - /// Gets or sets the identifier. - /// </summary> - /// <value>The identifier.</value> - public string Id { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/NameValuePair.cs b/MediaBrowser.Model/Dto/NameValuePair.cs deleted file mode 100644 index a6e6879491..0000000000 --- a/MediaBrowser.Model/Dto/NameValuePair.cs +++ /dev/null @@ -1,28 +0,0 @@ - -namespace MediaBrowser.Model.Dto -{ - public class NameValuePair - { - public NameValuePair() - { - - } - - public NameValuePair(string name, string value) - { - Name = name; - Value = value; - } - - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - /// <summary> - /// Gets or sets the value. - /// </summary> - /// <value>The value.</value> - public string Value { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/RatingType.cs b/MediaBrowser.Model/Dto/RatingType.cs deleted file mode 100644 index f151adce9c..0000000000 --- a/MediaBrowser.Model/Dto/RatingType.cs +++ /dev/null @@ -1,8 +0,0 @@ -namespace MediaBrowser.Model.Dto -{ - public enum RatingType - { - Score, - Likes - } -}
\ No newline at end of file diff --git a/MediaBrowser.Model/Dto/RecommendationDto.cs b/MediaBrowser.Model/Dto/RecommendationDto.cs deleted file mode 100644 index 275f97c281..0000000000 --- a/MediaBrowser.Model/Dto/RecommendationDto.cs +++ /dev/null @@ -1,14 +0,0 @@ - -namespace MediaBrowser.Model.Dto -{ - public class RecommendationDto - { - public BaseItemDto[] Items { get; set; } - - public RecommendationType RecommendationType { get; set; } - - public string BaselineItemName { get; set; } - - public string CategoryId { get; set; } - } -} diff --git a/MediaBrowser.Model/Dto/RecommendationType.cs b/MediaBrowser.Model/Dto/RecommendationType.cs deleted file mode 100644 index 1adf9b0824..0000000000 --- a/MediaBrowser.Model/Dto/RecommendationType.cs +++ /dev/null @@ -1,17 +0,0 @@ -namespace MediaBrowser.Model.Dto -{ - public enum RecommendationType - { - SimilarToRecentlyPlayed = 0, - - SimilarToLikedItem = 1, - - HasDirectorFromRecentlyPlayed = 2, - - HasActorFromRecentlyPlayed = 3, - - HasLikedDirector = 4, - - HasLikedActor = 5 - } -}
\ No newline at end of file diff --git a/MediaBrowser.Model/Dto/SubtitleDownloadOptions.cs b/MediaBrowser.Model/Dto/SubtitleDownloadOptions.cs deleted file mode 100644 index 02a0164060..0000000000 --- a/MediaBrowser.Model/Dto/SubtitleDownloadOptions.cs +++ /dev/null @@ -1,29 +0,0 @@ -namespace MediaBrowser.Model.Dto -{ - public class SubtitleDownloadOptions - { - /// <summary> - /// Gets or sets the item identifier. - /// </summary> - /// <value>The item identifier.</value> - public string ItemId { get; set; } - - /// <summary> - /// Gets or sets the media source identifier. - /// </summary> - /// <value>The media source identifier.</value> - public string MediaSourceId { get; set; } - - /// <summary> - /// Gets or sets the index of the stream. - /// </summary> - /// <value>The index of the stream.</value> - public int StreamIndex { get; set; } - - /// <summary> - /// Gets or sets the format. - /// </summary> - /// <value>The format.</value> - public string Format { get; set; } - } -}
\ No newline at end of file diff --git a/MediaBrowser.Model/Dto/UserDto.cs b/MediaBrowser.Model/Dto/UserDto.cs deleted file mode 100644 index 2b5672896c..0000000000 --- a/MediaBrowser.Model/Dto/UserDto.cs +++ /dev/null @@ -1,127 +0,0 @@ -using MediaBrowser.Model.Configuration; -using MediaBrowser.Model.Connect; -using MediaBrowser.Model.Users; -using System; -using System.Diagnostics; -using MediaBrowser.Model.Serialization; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class UserDto - /// </summary> - [DebuggerDisplay("Name = {Name}, ID = {Id}, HasPassword = {HasPassword}")] - public class UserDto : IItemDto, IHasServerId - { - /// <summary> - /// Gets or sets the name. - /// </summary> - /// <value>The name.</value> - public string Name { get; set; } - - /// <summary> - /// Gets or sets the server identifier. - /// </summary> - /// <value>The server identifier.</value> - public string ServerId { get; set; } - - /// <summary> - /// Gets or sets the name of the server. - /// This is not used by the server and is for client-side usage only. - /// </summary> - /// <value>The name of the server.</value> - public string ServerName { get; set; } - - /// <summary> - /// Gets or sets the name of the connect user. - /// </summary> - /// <value>The name of the connect user.</value> - public string ConnectUserName { get; set; } - /// <summary> - /// Gets or sets the connect user identifier. - /// </summary> - /// <value>The connect user identifier.</value> - public string ConnectUserId { get; set; } - /// <summary> - /// Gets or sets the type of the connect link. - /// </summary> - /// <value>The type of the connect link.</value> - public UserLinkType? ConnectLinkType { get; set; } - - /// <summary> - /// Gets or sets the id. - /// </summary> - /// <value>The id.</value> - public string Id { get; set; } - - /// <summary> - /// Gets or sets the primary image tag. - /// </summary> - /// <value>The primary image tag.</value> - public string PrimaryImageTag { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance has password. - /// </summary> - /// <value><c>true</c> if this instance has password; otherwise, <c>false</c>.</value> - public bool HasPassword { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance has configured password. - /// </summary> - /// <value><c>true</c> if this instance has configured password; otherwise, <c>false</c>.</value> - public bool HasConfiguredPassword { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance has configured easy password. - /// </summary> - /// <value><c>true</c> if this instance has configured easy password; otherwise, <c>false</c>.</value> - public bool HasConfiguredEasyPassword { get; set; } - - public bool? EnableAutoLogin { get; set; } - - /// <summary> - /// Gets or sets the last login date. - /// </summary> - /// <value>The last login date.</value> - public DateTime? LastLoginDate { get; set; } - - /// <summary> - /// Gets or sets the last activity date. - /// </summary> - /// <value>The last activity date.</value> - public DateTime? LastActivityDate { get; set; } - - /// <summary> - /// Gets or sets the configuration. - /// </summary> - /// <value>The configuration.</value> - public UserConfiguration Configuration { get; set; } - - /// <summary> - /// Gets or sets the policy. - /// </summary> - /// <value>The policy.</value> - public UserPolicy Policy { get; set; } - - /// <summary> - /// Gets or sets the primary image aspect ratio. - /// </summary> - /// <value>The primary image aspect ratio.</value> - public double? PrimaryImageAspectRatio { get; set; } - - /// <summary> - /// Initializes a new instance of the <see cref="UserDto"/> class. - /// </summary> - public UserDto() - { - Configuration = new UserConfiguration(); - Policy = new UserPolicy(); - } - - public override string ToString() - { - return Name ?? base.ToString(); - } - } -} diff --git a/MediaBrowser.Model/Dto/UserItemDataDto.cs b/MediaBrowser.Model/Dto/UserItemDataDto.cs deleted file mode 100644 index 507dbb06d9..0000000000 --- a/MediaBrowser.Model/Dto/UserItemDataDto.cs +++ /dev/null @@ -1,76 +0,0 @@ -using System; - -namespace MediaBrowser.Model.Dto -{ - /// <summary> - /// Class UserItemDataDto - /// </summary> - public class UserItemDataDto - { - /// <summary> - /// Gets or sets the rating. - /// </summary> - /// <value>The rating.</value> - public double? Rating { get; set; } - - /// <summary> - /// Gets or sets the played percentage. - /// </summary> - /// <value>The played percentage.</value> - public double? PlayedPercentage { get; set; } - - /// <summary> - /// Gets or sets the unplayed item count. - /// </summary> - /// <value>The unplayed item count.</value> - public int? UnplayedItemCount { get; set; } - - /// <summary> - /// Gets or sets the playback position ticks. - /// </summary> - /// <value>The playback position ticks.</value> - public long PlaybackPositionTicks { get; set; } - - /// <summary> - /// Gets or sets the play count. - /// </summary> - /// <value>The play count.</value> - public int PlayCount { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this instance is favorite. - /// </summary> - /// <value><c>true</c> if this instance is favorite; otherwise, <c>false</c>.</value> - public bool IsFavorite { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this <see cref="UserItemDataDto" /> is likes. - /// </summary> - /// <value><c>null</c> if [likes] contains no value, <c>true</c> if [likes]; otherwise, <c>false</c>.</value> - public bool? Likes { get; set; } - - /// <summary> - /// Gets or sets the last played date. - /// </summary> - /// <value>The last played date.</value> - public DateTime? LastPlayedDate { get; set; } - - /// <summary> - /// Gets or sets a value indicating whether this <see cref="UserItemDataDto" /> is played. - /// </summary> - /// <value><c>true</c> if played; otherwise, <c>false</c>.</value> - public bool Played { get; set; } - - /// <summary> - /// Gets or sets the key. - /// </summary> - /// <value>The key.</value> - public string Key { get; set; } - - /// <summary> - /// Gets or sets the item identifier. - /// </summary> - /// <value>The item identifier.</value> - public string ItemId { get; set; } - } -} |
