2014-08-29 06:06:30 +02:00
|
|
|
|
using MediaBrowser.Model.Configuration;
|
|
|
|
|
using MediaBrowser.Model.Drawing;
|
2014-08-28 03:27:46 +02:00
|
|
|
|
using System.Collections.Generic;
|
2014-08-29 06:06:30 +02:00
|
|
|
|
using System.Linq;
|
|
|
|
|
using System.Runtime.Serialization;
|
2014-12-20 07:06:27 +01:00
|
|
|
|
using MediaBrowser.Model.Users;
|
2014-02-13 06:11:54 +01:00
|
|
|
|
|
|
|
|
|
namespace MediaBrowser.Controller.Entities
|
|
|
|
|
{
|
|
|
|
|
public class Photo : BaseItem, IHasTags, IHasTaglines
|
|
|
|
|
{
|
|
|
|
|
public List<string> Tags { get; set; }
|
|
|
|
|
public List<string> Taglines { get; set; }
|
|
|
|
|
|
|
|
|
|
public Photo()
|
|
|
|
|
{
|
|
|
|
|
Tags = new List<string>();
|
|
|
|
|
Taglines = new List<string>();
|
|
|
|
|
}
|
|
|
|
|
|
2014-08-30 16:26:29 +02:00
|
|
|
|
[IgnoreDataMember]
|
2014-08-29 06:06:30 +02:00
|
|
|
|
public override bool SupportsLocalMetadata
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2014-08-30 16:26:29 +02:00
|
|
|
|
[IgnoreDataMember]
|
2014-02-13 06:11:54 +01:00
|
|
|
|
public override string MediaType
|
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return Model.Entities.MediaType.Photo;
|
|
|
|
|
}
|
|
|
|
|
}
|
2014-08-28 03:27:46 +02:00
|
|
|
|
|
2014-08-29 06:06:30 +02:00
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public override Folder LatestItemsIndexContainer
|
2014-08-30 16:26:29 +02:00
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return Album;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
[IgnoreDataMember]
|
|
|
|
|
public PhotoAlbum Album
|
2014-08-29 06:06:30 +02:00
|
|
|
|
{
|
|
|
|
|
get
|
|
|
|
|
{
|
|
|
|
|
return Parents.OfType<PhotoAlbum>().FirstOrDefault();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2014-08-28 03:27:46 +02:00
|
|
|
|
public int? Width { get; set; }
|
|
|
|
|
public int? Height { get; set; }
|
2014-08-29 02:49:25 +02:00
|
|
|
|
public string CameraMake { get; set; }
|
2014-08-28 03:27:46 +02:00
|
|
|
|
public string CameraModel { get; set; }
|
|
|
|
|
public string Software { get; set; }
|
|
|
|
|
public double? ExposureTime { get; set; }
|
|
|
|
|
public double? FocalLength { get; set; }
|
|
|
|
|
public ImageOrientation? Orientation { get; set; }
|
|
|
|
|
public double? Aperture { get; set; }
|
|
|
|
|
public double? ShutterSpeed { get; set; }
|
2014-08-29 06:06:30 +02:00
|
|
|
|
|
2014-08-30 16:26:29 +02:00
|
|
|
|
public double? Latitude { get; set; }
|
|
|
|
|
public double? Longitude { get; set; }
|
|
|
|
|
public double? Altitude { get; set; }
|
|
|
|
|
public int? IsoSpeedRating { get; set; }
|
2014-12-20 07:06:27 +01:00
|
|
|
|
|
|
|
|
|
protected override bool GetBlockUnratedValue(UserPolicy config)
|
2014-08-29 06:06:30 +02:00
|
|
|
|
{
|
|
|
|
|
return config.BlockUnratedItems.Contains(UnratedItem.Other);
|
|
|
|
|
}
|
2014-02-13 06:11:54 +01:00
|
|
|
|
}
|
|
|
|
|
}
|