using System.Runtime.Serialization;
using MediaBrowser.Controller.Providers;
using MediaBrowser.Model.Configuration;
using System;
namespace MediaBrowser.Controller.Entities
{
///
/// Class GameSystem
///
public class GameSystem : Folder, IHasLookupInfo
{
///
/// Return the id that should be used to key display prefs for this item.
/// Default is based on the type for everything except actual generic folders.
///
/// The display prefs id.
[IgnoreDataMember]
public override Guid DisplayPreferencesId
{
get
{
return Id;
}
}
///
/// Gets or sets the game system.
///
/// The game system.
public string GameSystemName { get; set; }
///
/// Gets the user data key.
///
/// System.String.
public override string GetUserDataKey()
{
if (!string.IsNullOrEmpty(GameSystemName))
{
return "GameSystem-" + GameSystemName;
}
return base.GetUserDataKey();
}
protected override bool GetBlockUnratedValue(UserConfiguration config)
{
// Don't block. Determine by game
return false;
}
public GameSystemInfo GetLookupInfo()
{
var id = GetItemLookupInfo();
id.Path = Path;
return id;
}
}
}