Added new api handlers to get plugin information

This commit is contained in:
LukePulverenti Luke Pulverenti luke pulverenti
2012-07-24 10:54:34 -04:00
parent 6c7175e33d
commit 84af205572
30 changed files with 269 additions and 193 deletions

View File

@@ -0,0 +1,16 @@

namespace MediaBrowser.Model.Configuration
{
/// <summary>
/// This holds settings that can be personalized on a per-user, per-device basis.
/// </summary>
public class UserConfiguration
{
public int RecentItemDays { get; set; }
public UserConfiguration()
{
RecentItemDays = 14;
}
}
}

View File

@@ -35,6 +35,7 @@
<!-- A reference to the entire .NET Framework is automatically included -->
</ItemGroup>
<ItemGroup>
<Compile Include="Configuration\UserConfiguration.cs" />
<Compile Include="Entities\ApiBaseItem.cs" />
<Compile Include="Entities\Audio.cs" />
<Compile Include="Entities\BaseItem.cs" />
@@ -45,6 +46,8 @@
<Compile Include="Entities\Studio.cs" />
<Compile Include="Entities\Video.cs" />
<Compile Include="Entities\Year.cs" />
<Compile Include="Plugins\BasePluginConfiguration.cs" />
<Compile Include="Plugins\PluginInfo.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Users\User.cs" />
<Compile Include="Users\UserItemData.cs" />

View File

@@ -0,0 +1,18 @@
using System;
using System.Runtime.Serialization;
namespace MediaBrowser.Model.Plugins
{
public class BasePluginConfiguration
{
public bool Enabled { get; set; }
[IgnoreDataMember]
public DateTime DateLastModified { get; set; }
public BasePluginConfiguration()
{
Enabled = true;
}
}
}

View File

@@ -0,0 +1,17 @@
using System;
namespace MediaBrowser.Model.Plugins
{
/// <summary>
/// This is a serializable stub class that is used by the api to provide information about installed plugins.
/// </summary>
public class PluginInfo
{
public string Name { get; set; }
public string Path { get; set; }
public bool Enabled { get; set; }
public bool DownloadToUI { get; set; }
public DateTime ConfigurationDateLastModified { get; set; }
public Version Version { get; set; }
}
}