Initial Commit Rework

This commit is contained in:
Qstick 2017-09-03 22:20:56 -04:00
commit 95051cbd63
2483 changed files with 101351 additions and 111396 deletions

339
src/Lidarr.sln Normal file
View file

@ -0,0 +1,339 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.26730.10
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{57A04B72-8088-4F75-A582-1158CF8291F7}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Test.Common", "Test.Common", "{47697CDB-27B6-4B05-B4F8-0CBE6F6EDF97}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Test.Dummy", "NzbDrone.Test.Dummy\NzbDrone.Test.Dummy.csproj", "{FAFB5948-A222-4CF6-AD14-026BE7564802}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Test.Common", "NzbDrone.Test.Common\NzbDrone.Test.Common.csproj", "{CADDFCE0-7509-4430-8364-2074E1EEFCA2}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Core.Test", "NzbDrone.Core.Test\NzbDrone.Core.Test.csproj", "{193ADD3B-792B-4173-8E4C-5A3F8F0237F0}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Host.Test", "NzbDrone.App.Test\NzbDrone.Host.Test.csproj", "{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Update.Test", "NzbDrone.Update.Test\NzbDrone.Update.Test.csproj", "{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Common.Test", "NzbDrone.Common.Test\NzbDrone.Common.Test.csproj", "{BEC74619-DDBB-4FBA-B517-D3E20AFC9997}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Api.Test", "NzbDrone.Api.Test\NzbDrone.Api.Test.csproj", "{D18A5DEB-5102-4775-A1AF-B75DAAA8907B}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Libraries.Test", "NzbDrone.Libraries.Test\NzbDrone.Libraries.Test.csproj", "{CBF6B8B0-A015-413A-8C86-01238BB45770}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Integration.Test", "NzbDrone.Integration.Test\NzbDrone.Integration.Test.csproj", "{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Automation.Test", "NzbDrone.Automation.Test\NzbDrone.Automation.Test.csproj", "{CC26800D-F67E-464B-88DE-8EB1A0C227A3}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "WindowsServiceHelpers", "WindowsServiceHelpers", "{F9E67978-5CD6-4A5F-827B-4249711C0B02}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceInstall", "ServiceHelpers\ServiceInstall\ServiceInstall.csproj", "{6BCE712F-846D-4846-9D1B-A66B858DA755}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ServiceUninstall", "ServiceHelpers\ServiceUninstall\ServiceUninstall.csproj", "{700D0B95-95CD-43F3-B6C9-FAA0FC1358D4}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Core", "NzbDrone.Core\NzbDrone.Core.csproj", "{FF5EE3B6-913B-47CE-9CEB-11C51B4E1205}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Update", "NzbDrone.Update\NzbDrone.Update.csproj", "{4CCC53CD-8D5E-4CC4-97D2-5C9312AC2BD7}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Common", "NzbDrone.Common\NzbDrone.Common.csproj", "{F2BE0FDF-6E47-4827-A420-DD4EF82407F8}"
ProjectSection(ProjectDependencies) = postProject
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB} = {9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}
EndProjectSection
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".nuget", ".nuget", "{1E6B3CBE-1578-41C1-9BF9-78D818740BE9}"
ProjectSection(SolutionItems) = preProject
.nuget\NuGet.exe = .nuget\NuGet.exe
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Api", "NzbDrone.Api\NzbDrone.Api.csproj", "{FD286DF8-2D3A-4394-8AD5-443FADE55FB2}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Host", "Host", "{486ADF86-DD89-4E19-B805-9D94F19800D9}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Console", "NzbDrone.Console\NzbDrone.Console.csproj", "{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Host", "NzbDrone.Host\NzbDrone.Host.csproj", "{95C11A9E-56ED-456A-8447-2C89C1139266}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone", "NzbDrone\NzbDrone.csproj", "{D12F7F2F-8A3C-415F-88FA-6DD061A84869}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.SignalR", "NzbDrone.SignalR\NzbDrone.SignalR.csproj", "{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "External", "External", "{F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AspNet.SignalR.Core", "Microsoft.AspNet.SignalR.Core\Microsoft.AspNet.SignalR.Core.csproj", "{1B9A82C4-BCA1-4834-A33E-226F17BE070B}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AspNet.SignalR.Owin", "Microsoft.AspNet.SignalR.Owin\Microsoft.AspNet.SignalR.Owin.csproj", "{2B8C6DAD-4D85-41B1-83FD-248D9F347522}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Marr.Data", "Marr.Data\Marr.Data.csproj", "{F6FC6BE7-0847-4817-A1ED-223DC647C3D7}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Mono", "NzbDrone.Mono\NzbDrone.Mono.csproj", "{15AD7579-A314-4626-B556-663F51D97CD1}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Windows", "NzbDrone.Windows\NzbDrone.Windows.csproj", "{911284D3-F130-459E-836C-2430B6FBF21D}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Platform", "Platform", "{0F0D4998-8F5D-4467-A909-BB192C4B3B4B}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Platform", "Platform", "{4EACDBBC-BCD7-4765-A57B-3E08331E4749}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Windows.Test", "NzbDrone.Windows.Test\NzbDrone.Windows.Test.csproj", "{80B51429-7A0E-46D6-BEE3-C80DCB1C4EAA}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NzbDrone.Mono.Test", "NzbDrone.Mono.Test\NzbDrone.Mono.Test.csproj", "{40D72824-7D02-4A77-9106-8FE0EEA2B997}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "MonoTorrent", "MonoTorrent\MonoTorrent.csproj", "{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LogentriesCore", "LogentriesCore\LogentriesCore.csproj", "{90D6E9FC-7B88-4E1B-B018-8FA742274558}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LogentriesNLog", "LogentriesNLog\LogentriesNLog.csproj", "{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}"
ProjectSection(ProjectDependencies) = postProject
{90D6E9FC-7B88-4E1B-B018-8FA742274558} = {90D6E9FC-7B88-4E1B-B018-8FA742274558}
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "CurlSharp", "ExternalModules\CurlSharp\CurlSharp\CurlSharp.csproj", "{74420A79-CC16-442C-8B1E-7C1B913844F0}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Lidarr.Api.V3", "Sonarr.Api.V3\Lidarr.Api.V3.csproj", "{7140FF1F-79BE-492F-9188-B21A050BF708}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Lidarr.Http", "Sonarr.Http\Lidarr.Http.csproj", "{5370BFF7-1BD7-46BC-AF06-7D9EA5CDA1D6}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x86 = Debug|x86
Mono|x86 = Mono|x86
Release|x86 = Release|x86
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{FAFB5948-A222-4CF6-AD14-026BE7564802}.Debug|x86.ActiveCfg = Debug|x86
{FAFB5948-A222-4CF6-AD14-026BE7564802}.Debug|x86.Build.0 = Debug|x86
{FAFB5948-A222-4CF6-AD14-026BE7564802}.Mono|x86.ActiveCfg = Release|x86
{FAFB5948-A222-4CF6-AD14-026BE7564802}.Mono|x86.Build.0 = Release|x86
{FAFB5948-A222-4CF6-AD14-026BE7564802}.Release|x86.ActiveCfg = Release|x86
{FAFB5948-A222-4CF6-AD14-026BE7564802}.Release|x86.Build.0 = Release|x86
{CADDFCE0-7509-4430-8364-2074E1EEFCA2}.Debug|x86.ActiveCfg = Debug|x86
{CADDFCE0-7509-4430-8364-2074E1EEFCA2}.Debug|x86.Build.0 = Debug|x86
{CADDFCE0-7509-4430-8364-2074E1EEFCA2}.Mono|x86.ActiveCfg = Debug|x86
{CADDFCE0-7509-4430-8364-2074E1EEFCA2}.Mono|x86.Build.0 = Debug|x86
{CADDFCE0-7509-4430-8364-2074E1EEFCA2}.Release|x86.ActiveCfg = Release|x86
{CADDFCE0-7509-4430-8364-2074E1EEFCA2}.Release|x86.Build.0 = Release|x86
{193ADD3B-792B-4173-8E4C-5A3F8F0237F0}.Debug|x86.ActiveCfg = Debug|x86
{193ADD3B-792B-4173-8E4C-5A3F8F0237F0}.Debug|x86.Build.0 = Debug|x86
{193ADD3B-792B-4173-8E4C-5A3F8F0237F0}.Mono|x86.ActiveCfg = Debug|x86
{193ADD3B-792B-4173-8E4C-5A3F8F0237F0}.Mono|x86.Build.0 = Debug|x86
{193ADD3B-792B-4173-8E4C-5A3F8F0237F0}.Release|x86.ActiveCfg = Release|x86
{193ADD3B-792B-4173-8E4C-5A3F8F0237F0}.Release|x86.Build.0 = Release|x86
{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5}.Debug|x86.ActiveCfg = Debug|x86
{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5}.Debug|x86.Build.0 = Debug|x86
{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5}.Mono|x86.ActiveCfg = Debug|x86
{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5}.Mono|x86.Build.0 = Debug|x86
{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5}.Release|x86.ActiveCfg = Release|x86
{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5}.Release|x86.Build.0 = Release|x86
{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97}.Debug|x86.ActiveCfg = Debug|x86
{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97}.Debug|x86.Build.0 = Debug|x86
{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97}.Mono|x86.ActiveCfg = Debug|x86
{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97}.Mono|x86.Build.0 = Debug|x86
{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97}.Release|x86.ActiveCfg = Release|x86
{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97}.Release|x86.Build.0 = Release|x86
{BEC74619-DDBB-4FBA-B517-D3E20AFC9997}.Debug|x86.ActiveCfg = Debug|x86
{BEC74619-DDBB-4FBA-B517-D3E20AFC9997}.Debug|x86.Build.0 = Debug|x86
{BEC74619-DDBB-4FBA-B517-D3E20AFC9997}.Mono|x86.ActiveCfg = Debug|x86
{BEC74619-DDBB-4FBA-B517-D3E20AFC9997}.Mono|x86.Build.0 = Debug|x86
{BEC74619-DDBB-4FBA-B517-D3E20AFC9997}.Release|x86.ActiveCfg = Release|x86
{BEC74619-DDBB-4FBA-B517-D3E20AFC9997}.Release|x86.Build.0 = Release|x86
{D18A5DEB-5102-4775-A1AF-B75DAAA8907B}.Debug|x86.ActiveCfg = Debug|x86
{D18A5DEB-5102-4775-A1AF-B75DAAA8907B}.Debug|x86.Build.0 = Debug|x86
{D18A5DEB-5102-4775-A1AF-B75DAAA8907B}.Mono|x86.ActiveCfg = Release|x86
{D18A5DEB-5102-4775-A1AF-B75DAAA8907B}.Mono|x86.Build.0 = Release|x86
{D18A5DEB-5102-4775-A1AF-B75DAAA8907B}.Release|x86.ActiveCfg = Release|x86
{D18A5DEB-5102-4775-A1AF-B75DAAA8907B}.Release|x86.Build.0 = Release|x86
{CBF6B8B0-A015-413A-8C86-01238BB45770}.Debug|x86.ActiveCfg = Debug|x86
{CBF6B8B0-A015-413A-8C86-01238BB45770}.Debug|x86.Build.0 = Debug|x86
{CBF6B8B0-A015-413A-8C86-01238BB45770}.Mono|x86.ActiveCfg = Debug|x86
{CBF6B8B0-A015-413A-8C86-01238BB45770}.Mono|x86.Build.0 = Debug|x86
{CBF6B8B0-A015-413A-8C86-01238BB45770}.Release|x86.ActiveCfg = Release|x86
{CBF6B8B0-A015-413A-8C86-01238BB45770}.Release|x86.Build.0 = Release|x86
{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB}.Debug|x86.ActiveCfg = Debug|x86
{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB}.Debug|x86.Build.0 = Debug|x86
{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB}.Mono|x86.ActiveCfg = Debug|x86
{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB}.Mono|x86.Build.0 = Debug|x86
{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB}.Release|x86.ActiveCfg = Release|x86
{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB}.Release|x86.Build.0 = Release|x86
{CC26800D-F67E-464B-88DE-8EB1A0C227A3}.Debug|x86.ActiveCfg = Debug|x86
{CC26800D-F67E-464B-88DE-8EB1A0C227A3}.Debug|x86.Build.0 = Debug|x86
{CC26800D-F67E-464B-88DE-8EB1A0C227A3}.Mono|x86.ActiveCfg = Debug|x86
{CC26800D-F67E-464B-88DE-8EB1A0C227A3}.Mono|x86.Build.0 = Debug|x86
{CC26800D-F67E-464B-88DE-8EB1A0C227A3}.Release|x86.ActiveCfg = Release|x86
{CC26800D-F67E-464B-88DE-8EB1A0C227A3}.Release|x86.Build.0 = Release|x86
{6BCE712F-846D-4846-9D1B-A66B858DA755}.Debug|x86.ActiveCfg = Debug|x86
{6BCE712F-846D-4846-9D1B-A66B858DA755}.Debug|x86.Build.0 = Debug|x86
{6BCE712F-846D-4846-9D1B-A66B858DA755}.Mono|x86.ActiveCfg = Debug|x86
{6BCE712F-846D-4846-9D1B-A66B858DA755}.Release|x86.ActiveCfg = Release|x86
{6BCE712F-846D-4846-9D1B-A66B858DA755}.Release|x86.Build.0 = Release|x86
{700D0B95-95CD-43F3-B6C9-FAA0FC1358D4}.Debug|x86.ActiveCfg = Debug|x86
{700D0B95-95CD-43F3-B6C9-FAA0FC1358D4}.Debug|x86.Build.0 = Debug|x86
{700D0B95-95CD-43F3-B6C9-FAA0FC1358D4}.Mono|x86.ActiveCfg = Debug|x86
{700D0B95-95CD-43F3-B6C9-FAA0FC1358D4}.Release|x86.ActiveCfg = Release|x86
{700D0B95-95CD-43F3-B6C9-FAA0FC1358D4}.Release|x86.Build.0 = Release|x86
{FF5EE3B6-913B-47CE-9CEB-11C51B4E1205}.Debug|x86.ActiveCfg = Debug|x86
{FF5EE3B6-913B-47CE-9CEB-11C51B4E1205}.Debug|x86.Build.0 = Debug|x86
{FF5EE3B6-913B-47CE-9CEB-11C51B4E1205}.Mono|x86.ActiveCfg = Release|x86
{FF5EE3B6-913B-47CE-9CEB-11C51B4E1205}.Mono|x86.Build.0 = Release|x86
{FF5EE3B6-913B-47CE-9CEB-11C51B4E1205}.Release|x86.ActiveCfg = Release|x86
{FF5EE3B6-913B-47CE-9CEB-11C51B4E1205}.Release|x86.Build.0 = Release|x86
{4CCC53CD-8D5E-4CC4-97D2-5C9312AC2BD7}.Debug|x86.ActiveCfg = Debug|x86
{4CCC53CD-8D5E-4CC4-97D2-5C9312AC2BD7}.Debug|x86.Build.0 = Debug|x86
{4CCC53CD-8D5E-4CC4-97D2-5C9312AC2BD7}.Mono|x86.ActiveCfg = Debug|x86
{4CCC53CD-8D5E-4CC4-97D2-5C9312AC2BD7}.Mono|x86.Build.0 = Debug|x86
{4CCC53CD-8D5E-4CC4-97D2-5C9312AC2BD7}.Release|x86.ActiveCfg = Release|x86
{4CCC53CD-8D5E-4CC4-97D2-5C9312AC2BD7}.Release|x86.Build.0 = Release|x86
{F2BE0FDF-6E47-4827-A420-DD4EF82407F8}.Debug|x86.ActiveCfg = Debug|x86
{F2BE0FDF-6E47-4827-A420-DD4EF82407F8}.Debug|x86.Build.0 = Debug|x86
{F2BE0FDF-6E47-4827-A420-DD4EF82407F8}.Mono|x86.ActiveCfg = Release|x86
{F2BE0FDF-6E47-4827-A420-DD4EF82407F8}.Mono|x86.Build.0 = Release|x86
{F2BE0FDF-6E47-4827-A420-DD4EF82407F8}.Release|x86.ActiveCfg = Release|x86
{F2BE0FDF-6E47-4827-A420-DD4EF82407F8}.Release|x86.Build.0 = Release|x86
{FD286DF8-2D3A-4394-8AD5-443FADE55FB2}.Debug|x86.ActiveCfg = Debug|x86
{FD286DF8-2D3A-4394-8AD5-443FADE55FB2}.Debug|x86.Build.0 = Debug|x86
{FD286DF8-2D3A-4394-8AD5-443FADE55FB2}.Mono|x86.ActiveCfg = Release|x86
{FD286DF8-2D3A-4394-8AD5-443FADE55FB2}.Mono|x86.Build.0 = Release|x86
{FD286DF8-2D3A-4394-8AD5-443FADE55FB2}.Release|x86.ActiveCfg = Release|x86
{FD286DF8-2D3A-4394-8AD5-443FADE55FB2}.Release|x86.Build.0 = Release|x86
{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976}.Debug|x86.ActiveCfg = Debug|x86
{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976}.Debug|x86.Build.0 = Debug|x86
{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976}.Mono|x86.ActiveCfg = Debug|x86
{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976}.Mono|x86.Build.0 = Debug|x86
{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976}.Release|x86.ActiveCfg = Release|x86
{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976}.Release|x86.Build.0 = Release|x86
{95C11A9E-56ED-456A-8447-2C89C1139266}.Debug|x86.ActiveCfg = Debug|x86
{95C11A9E-56ED-456A-8447-2C89C1139266}.Debug|x86.Build.0 = Debug|x86
{95C11A9E-56ED-456A-8447-2C89C1139266}.Mono|x86.ActiveCfg = Debug|x86
{95C11A9E-56ED-456A-8447-2C89C1139266}.Mono|x86.Build.0 = Debug|x86
{95C11A9E-56ED-456A-8447-2C89C1139266}.Release|x86.ActiveCfg = Release|x86
{95C11A9E-56ED-456A-8447-2C89C1139266}.Release|x86.Build.0 = Release|x86
{D12F7F2F-8A3C-415F-88FA-6DD061A84869}.Debug|x86.ActiveCfg = Debug|x86
{D12F7F2F-8A3C-415F-88FA-6DD061A84869}.Debug|x86.Build.0 = Debug|x86
{D12F7F2F-8A3C-415F-88FA-6DD061A84869}.Mono|x86.ActiveCfg = Release|x86
{D12F7F2F-8A3C-415F-88FA-6DD061A84869}.Release|x86.ActiveCfg = Release|x86
{D12F7F2F-8A3C-415F-88FA-6DD061A84869}.Release|x86.Build.0 = Release|x86
{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}.Debug|x86.ActiveCfg = Debug|x86
{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}.Debug|x86.Build.0 = Debug|x86
{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}.Mono|x86.ActiveCfg = Debug|x86
{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}.Mono|x86.Build.0 = Debug|x86
{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}.Release|x86.ActiveCfg = Release|x86
{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}.Release|x86.Build.0 = Release|x86
{1B9A82C4-BCA1-4834-A33E-226F17BE070B}.Debug|x86.ActiveCfg = Debug|x86
{1B9A82C4-BCA1-4834-A33E-226F17BE070B}.Debug|x86.Build.0 = Debug|x86
{1B9A82C4-BCA1-4834-A33E-226F17BE070B}.Mono|x86.ActiveCfg = Debug|x86
{1B9A82C4-BCA1-4834-A33E-226F17BE070B}.Mono|x86.Build.0 = Debug|x86
{1B9A82C4-BCA1-4834-A33E-226F17BE070B}.Release|x86.ActiveCfg = Release|x86
{1B9A82C4-BCA1-4834-A33E-226F17BE070B}.Release|x86.Build.0 = Release|x86
{2B8C6DAD-4D85-41B1-83FD-248D9F347522}.Debug|x86.ActiveCfg = Debug|x86
{2B8C6DAD-4D85-41B1-83FD-248D9F347522}.Debug|x86.Build.0 = Debug|x86
{2B8C6DAD-4D85-41B1-83FD-248D9F347522}.Mono|x86.ActiveCfg = Release|x86
{2B8C6DAD-4D85-41B1-83FD-248D9F347522}.Mono|x86.Build.0 = Release|x86
{2B8C6DAD-4D85-41B1-83FD-248D9F347522}.Release|x86.ActiveCfg = Release|x86
{2B8C6DAD-4D85-41B1-83FD-248D9F347522}.Release|x86.Build.0 = Release|x86
{F6FC6BE7-0847-4817-A1ED-223DC647C3D7}.Debug|x86.ActiveCfg = Debug|x86
{F6FC6BE7-0847-4817-A1ED-223DC647C3D7}.Debug|x86.Build.0 = Debug|x86
{F6FC6BE7-0847-4817-A1ED-223DC647C3D7}.Mono|x86.ActiveCfg = Release|x86
{F6FC6BE7-0847-4817-A1ED-223DC647C3D7}.Mono|x86.Build.0 = Release|x86
{F6FC6BE7-0847-4817-A1ED-223DC647C3D7}.Release|x86.ActiveCfg = Release|x86
{F6FC6BE7-0847-4817-A1ED-223DC647C3D7}.Release|x86.Build.0 = Release|x86
{15AD7579-A314-4626-B556-663F51D97CD1}.Debug|x86.ActiveCfg = Debug|x86
{15AD7579-A314-4626-B556-663F51D97CD1}.Debug|x86.Build.0 = Debug|x86
{15AD7579-A314-4626-B556-663F51D97CD1}.Mono|x86.ActiveCfg = Release|x86
{15AD7579-A314-4626-B556-663F51D97CD1}.Release|x86.ActiveCfg = Release|x86
{15AD7579-A314-4626-B556-663F51D97CD1}.Release|x86.Build.0 = Release|x86
{911284D3-F130-459E-836C-2430B6FBF21D}.Debug|x86.ActiveCfg = Debug|x86
{911284D3-F130-459E-836C-2430B6FBF21D}.Debug|x86.Build.0 = Debug|x86
{911284D3-F130-459E-836C-2430B6FBF21D}.Mono|x86.ActiveCfg = Release|x86
{911284D3-F130-459E-836C-2430B6FBF21D}.Release|x86.ActiveCfg = Release|x86
{911284D3-F130-459E-836C-2430B6FBF21D}.Release|x86.Build.0 = Release|x86
{80B51429-7A0E-46D6-BEE3-C80DCB1C4EAA}.Debug|x86.ActiveCfg = Debug|x86
{80B51429-7A0E-46D6-BEE3-C80DCB1C4EAA}.Debug|x86.Build.0 = Debug|x86
{80B51429-7A0E-46D6-BEE3-C80DCB1C4EAA}.Mono|x86.ActiveCfg = Release|x86
{80B51429-7A0E-46D6-BEE3-C80DCB1C4EAA}.Release|x86.ActiveCfg = Release|x86
{80B51429-7A0E-46D6-BEE3-C80DCB1C4EAA}.Release|x86.Build.0 = Release|x86
{40D72824-7D02-4A77-9106-8FE0EEA2B997}.Debug|x86.ActiveCfg = Debug|x86
{40D72824-7D02-4A77-9106-8FE0EEA2B997}.Debug|x86.Build.0 = Debug|x86
{40D72824-7D02-4A77-9106-8FE0EEA2B997}.Mono|x86.ActiveCfg = Release|x86
{40D72824-7D02-4A77-9106-8FE0EEA2B997}.Release|x86.ActiveCfg = Release|x86
{40D72824-7D02-4A77-9106-8FE0EEA2B997}.Release|x86.Build.0 = Release|x86
{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8}.Debug|x86.ActiveCfg = Debug|x86
{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8}.Debug|x86.Build.0 = Debug|x86
{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8}.Mono|x86.ActiveCfg = Release|x86
{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8}.Mono|x86.Build.0 = Release|x86
{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8}.Release|x86.ActiveCfg = Release|x86
{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8}.Release|x86.Build.0 = Release|x86
{90D6E9FC-7B88-4E1B-B018-8FA742274558}.Debug|x86.ActiveCfg = Debug|x86
{90D6E9FC-7B88-4E1B-B018-8FA742274558}.Debug|x86.Build.0 = Debug|x86
{90D6E9FC-7B88-4E1B-B018-8FA742274558}.Mono|x86.ActiveCfg = Release|x86
{90D6E9FC-7B88-4E1B-B018-8FA742274558}.Mono|x86.Build.0 = Release|x86
{90D6E9FC-7B88-4E1B-B018-8FA742274558}.Release|x86.ActiveCfg = Release|x86
{90D6E9FC-7B88-4E1B-B018-8FA742274558}.Release|x86.Build.0 = Release|x86
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}.Debug|x86.ActiveCfg = Debug|x86
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}.Debug|x86.Build.0 = Debug|x86
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}.Mono|x86.ActiveCfg = Release|x86
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}.Mono|x86.Build.0 = Release|x86
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}.Release|x86.ActiveCfg = Release|x86
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB}.Release|x86.Build.0 = Release|x86
{74420A79-CC16-442C-8B1E-7C1B913844F0}.Debug|x86.ActiveCfg = Debug|Any CPU
{74420A79-CC16-442C-8B1E-7C1B913844F0}.Debug|x86.Build.0 = Debug|Any CPU
{74420A79-CC16-442C-8B1E-7C1B913844F0}.Mono|x86.ActiveCfg = Release|Any CPU
{74420A79-CC16-442C-8B1E-7C1B913844F0}.Mono|x86.Build.0 = Release|Any CPU
{74420A79-CC16-442C-8B1E-7C1B913844F0}.Release|x86.ActiveCfg = Release|Any CPU
{74420A79-CC16-442C-8B1E-7C1B913844F0}.Release|x86.Build.0 = Release|Any CPU
{7140FF1F-79BE-492F-9188-B21A050BF708}.Debug|x86.ActiveCfg = Debug|x86
{7140FF1F-79BE-492F-9188-B21A050BF708}.Debug|x86.Build.0 = Debug|x86
{7140FF1F-79BE-492F-9188-B21A050BF708}.Mono|x86.ActiveCfg = Release|x86
{7140FF1F-79BE-492F-9188-B21A050BF708}.Mono|x86.Build.0 = Release|x86
{7140FF1F-79BE-492F-9188-B21A050BF708}.Release|x86.ActiveCfg = Release|x86
{7140FF1F-79BE-492F-9188-B21A050BF708}.Release|x86.Build.0 = Release|x86
{5370BFF7-1BD7-46BC-AF06-7D9EA5CDA1D6}.Debug|x86.ActiveCfg = Debug|x86
{5370BFF7-1BD7-46BC-AF06-7D9EA5CDA1D6}.Debug|x86.Build.0 = Debug|x86
{5370BFF7-1BD7-46BC-AF06-7D9EA5CDA1D6}.Mono|x86.ActiveCfg = Release|x86
{5370BFF7-1BD7-46BC-AF06-7D9EA5CDA1D6}.Mono|x86.Build.0 = Release|x86
{5370BFF7-1BD7-46BC-AF06-7D9EA5CDA1D6}.Release|x86.ActiveCfg = Release|x86
{5370BFF7-1BD7-46BC-AF06-7D9EA5CDA1D6}.Release|x86.Build.0 = Release|x86
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{47697CDB-27B6-4B05-B4F8-0CBE6F6EDF97} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{FAFB5948-A222-4CF6-AD14-026BE7564802} = {47697CDB-27B6-4B05-B4F8-0CBE6F6EDF97}
{CADDFCE0-7509-4430-8364-2074E1EEFCA2} = {47697CDB-27B6-4B05-B4F8-0CBE6F6EDF97}
{193ADD3B-792B-4173-8E4C-5A3F8F0237F0} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{C0EA1A40-91AD-4EEB-BD16-2DDDEBD20AE5} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{35388E8E-0CDB-4A84-AD16-E4B6EFDA5D97} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{BEC74619-DDBB-4FBA-B517-D3E20AFC9997} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{D18A5DEB-5102-4775-A1AF-B75DAAA8907B} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{CBF6B8B0-A015-413A-8C86-01238BB45770} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{8CEFECD0-A6C2-498F-98B1-3FBE5820F9AB} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{CC26800D-F67E-464B-88DE-8EB1A0C227A3} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{6BCE712F-846D-4846-9D1B-A66B858DA755} = {F9E67978-5CD6-4A5F-827B-4249711C0B02}
{700D0B95-95CD-43F3-B6C9-FAA0FC1358D4} = {F9E67978-5CD6-4A5F-827B-4249711C0B02}
{3DCA7B58-B8B3-49AC-9D9E-56F4A0460976} = {486ADF86-DD89-4E19-B805-9D94F19800D9}
{95C11A9E-56ED-456A-8447-2C89C1139266} = {486ADF86-DD89-4E19-B805-9D94F19800D9}
{D12F7F2F-8A3C-415F-88FA-6DD061A84869} = {486ADF86-DD89-4E19-B805-9D94F19800D9}
{1B9A82C4-BCA1-4834-A33E-226F17BE070B} = {F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}
{2B8C6DAD-4D85-41B1-83FD-248D9F347522} = {F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}
{F6FC6BE7-0847-4817-A1ED-223DC647C3D7} = {F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}
{15AD7579-A314-4626-B556-663F51D97CD1} = {0F0D4998-8F5D-4467-A909-BB192C4B3B4B}
{911284D3-F130-459E-836C-2430B6FBF21D} = {0F0D4998-8F5D-4467-A909-BB192C4B3B4B}
{4EACDBBC-BCD7-4765-A57B-3E08331E4749} = {57A04B72-8088-4F75-A582-1158CF8291F7}
{80B51429-7A0E-46D6-BEE3-C80DCB1C4EAA} = {4EACDBBC-BCD7-4765-A57B-3E08331E4749}
{40D72824-7D02-4A77-9106-8FE0EEA2B997} = {4EACDBBC-BCD7-4765-A57B-3E08331E4749}
{411A9E0E-FDC6-4E25-828A-0C2CD1CD96F8} = {F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}
{90D6E9FC-7B88-4E1B-B018-8FA742274558} = {F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}
{9DC31DE3-79FF-47A8-96B4-6BA18F6BB1CB} = {F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}
{74420A79-CC16-442C-8B1E-7C1B913844F0} = {F6E3A728-AE77-4D02-BAC8-82FBC1402DDA}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
EnterpriseLibraryConfigurationToolBinariesPath = packages\Unity.2.1.505.0\lib\NET35;packages\Unity.2.1.505.2\lib\NET35
SolutionGuid = {2C047BC5-490F-4DCE-962F-141370D23765}
EndGlobalSection
GlobalSection(MonoDevelopProperties) = preSolution
StartupItem = NzbDrone.Console\NzbDrone.Console.csproj
EndGlobalSection
GlobalSection(JSLint) = preSolution
SolutionConfigurationLocation = JSLintOptions.xml
EndGlobalSection
EndGlobal

View file

@ -1,6 +1,6 @@
using FluentAssertions;
using FluentAssertions;
using NUnit.Framework;
using NzbDrone.Api.ClientSchema;
using Lidarr.Http.ClientSchema;
using NzbDrone.Core.Annotations;
using NzbDrone.Test.Common;
@ -45,4 +45,4 @@ namespace NzbDrone.Api.Test.ClientSchemaTests
public string Other { get; set; }
}
}
}

View file

@ -90,6 +90,10 @@
<Project>{CADDFCE0-7509-4430-8364-2074E1EEFCA2}</Project>
<Name>NzbDrone.Test.Common</Name>
</ProjectReference>
<ProjectReference Include="..\Sonarr.Http\Lidarr.Http.csproj">
<Project>{5370bff7-1bd7-46bc-af06-7d9ea5cda1d6}</Project>
<Name>Lidarr.Http</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup>
<None Include="..\NzbDrone.Test.Common\App.config">

View file

@ -1,5 +1,5 @@
using Nancy;
using NzbDrone.Api.Extensions;
using Nancy;
using Lidarr.Http.Extensions;
using NzbDrone.Core.Music;
namespace NzbDrone.Api.AlbumPass

View file

@ -1,5 +1,5 @@
using System.Collections.Generic;
using NzbDrone.Api.REST;
using System.Collections.Generic;
using Lidarr.Http.REST;
using NzbDrone.Core.Music;
using NzbDrone.Core.ArtistStats;
using NzbDrone.Core.DecisionEngine;
@ -12,7 +12,7 @@ namespace NzbDrone.Api.Albums
public AlbumModule(IArtistService artistService,
IArtistStatisticsService artistStatisticsService,
IAlbumService albumService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(albumService, artistStatisticsService, artistService, qualityUpgradableSpecification, signalRBroadcaster)
{

View file

@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using FluentValidation;
@ -13,20 +13,21 @@ using NzbDrone.Core.Messaging.Events;
using NzbDrone.Core.Music;
using NzbDrone.Core.ArtistStats;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.Albums
{
public abstract class AlbumModuleWithSignalR : NzbDroneRestModuleWithSignalR<AlbumResource, Track>
public abstract class AlbumModuleWithSignalR : LidarrRestModuleWithSignalR<AlbumResource, Album>
{
protected readonly IAlbumService _albumService;
protected readonly IArtistStatisticsService _artistStatisticsService;
protected readonly IArtistService _artistService;
protected readonly IQualityUpgradableSpecification _qualityUpgradableSpecification;
protected readonly IUpgradableSpecification _qualityUpgradableSpecification;
protected AlbumModuleWithSignalR(IAlbumService albumService,
IArtistStatisticsService artistStatisticsService,
IArtistService artistService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(signalRBroadcaster)
{
@ -41,7 +42,7 @@ namespace NzbDrone.Api.Albums
protected AlbumModuleWithSignalR(IAlbumService albumService,
IArtistStatisticsService artistStatisticsService,
IArtistService artistService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster,
string resource)
: base(signalRBroadcaster, resource)

View file

@ -1,9 +1,9 @@
using NzbDrone.Core.Music;
using NzbDrone.Core.Music;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Api.Music;
using NzbDrone.Core.MediaCover;

View file

@ -1,9 +1,10 @@
using NzbDrone.Core.Blacklisting;
using NzbDrone.Core.Blacklisting;
using NzbDrone.Core.Datastore;
using Lidarr.Http;
namespace NzbDrone.Api.Blacklist
{
public class BlacklistModule : NzbDroneRestModule<BlacklistResource>
public class BlacklistModule : LidarrRestModule<BlacklistResource>
{
private readonly IBlacklistService _blacklistService;

View file

@ -1,9 +1,10 @@
using System;
using System;
using System.Collections.Generic;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Qualities;
using NzbDrone.Api.Music;
using NzbDrone.Core.Indexers;
using NzbDrone.Core.Languages;
namespace NzbDrone.Api.Blacklist
{
@ -17,6 +18,7 @@ namespace NzbDrone.Api.Blacklist
public DownloadProtocol Protocol { get; set; }
public string Indexer { get; set; }
public string Message { get; set; }
public Language Language { get; set; }
public ArtistResource Artist { get; set; }
}

View file

@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.Episodes;
@ -16,9 +16,9 @@ namespace NzbDrone.Api.Calendar
public CalendarModule(IAlbumService albumService,
IArtistStatisticsService artistStatisticsService,
IArtistService artistService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification upgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(albumService, artistStatisticsService, artistService, qualityUpgradableSpecification, signalRBroadcaster, "calendar")
: base(albumService, artistStatisticsService, artistService, upgradableSpecification, signalRBroadcaster, "calendar")
{
GetResourceAll = GetCalendar;
}

View file

@ -1,4 +0,0 @@
namespace NzbDrone.Api.ClientSchema
{
}

View file

@ -1,7 +0,0 @@
namespace NzbDrone.Api.ClientSchema
{
public static class SchemaDeserializer
{
}
}

View file

@ -1,19 +1,21 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.Extensions;
using NzbDrone.Api.Validation;
using Lidarr.Http.Extensions;
using NzbDrone.Common;
using NzbDrone.Core.Datastore.Events;
using NzbDrone.Core.Messaging.Commands;
using NzbDrone.Core.Messaging.Events;
using NzbDrone.Core.ProgressMessaging;
using NzbDrone.SignalR;
using Lidarr.Http;
using Lidarr.Http.Mapping;
using Lidarr.Http.Validation;
namespace NzbDrone.Api.Commands
{
public class CommandModule : NzbDroneRestModuleWithSignalR<CommandResource, CommandModel>, IHandle<CommandUpdatedEvent>
public class CommandModule : LidarrRestModuleWithSignalR<CommandResource, CommandModel>, IHandle<CommandUpdatedEvent>
{
private readonly IManageCommandQueue _commandQueueManager;
private readonly IServiceFactory _serviceFactory;
@ -63,4 +65,4 @@ namespace NzbDrone.Api.Commands
}
}
}
}
}

View file

@ -1,8 +1,8 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using Newtonsoft.Json;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Messaging.Commands;
namespace NzbDrone.Api.Commands

View file

@ -1,4 +1,4 @@
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Configuration;
namespace NzbDrone.Api.Config

View file

@ -1,4 +1,4 @@
using System.Linq;
using System.Linq;
using System.Reflection;
using FluentValidation;
using NzbDrone.Common.EnvironmentInfo;
@ -8,10 +8,11 @@ using NzbDrone.Core.Configuration;
using NzbDrone.Core.Update;
using NzbDrone.Core.Validation;
using NzbDrone.Core.Validation.Paths;
using Lidarr.Http;
namespace NzbDrone.Api.Config
{
public class HostConfigModule : NzbDroneRestModule<HostConfigResource>
public class HostConfigModule : LidarrRestModule<HostConfigResource>
{
private readonly IConfigFileProvider _configFileProvider;
private readonly IConfigService _configService;

View file

@ -1,4 +1,4 @@
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Authentication;
using NzbDrone.Core.Configuration;
using NzbDrone.Core.Update;

View file

@ -1,5 +1,5 @@
using FluentValidation;
using NzbDrone.Api.Validation;
using FluentValidation;
using Lidarr.Http.Validation;
using NzbDrone.Core.Configuration;
namespace NzbDrone.Api.Config
@ -25,4 +25,4 @@ namespace NzbDrone.Api.Config
return IndexerConfigResourceMapper.ToResource(model);
}
}
}
}

View file

@ -1,4 +1,4 @@
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Configuration;
namespace NzbDrone.Api.Config

View file

@ -1,4 +1,4 @@
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Configuration;
using NzbDrone.Core.MediaFiles;

View file

@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using FluentValidation;
using FluentValidation.Results;
@ -6,11 +6,13 @@ using Nancy.Responses;
using NzbDrone.Common.Extensions;
using NzbDrone.Core.Organizer;
using Nancy.ModelBinding;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Config
{
public class NamingConfigModule : NzbDroneRestModule<NamingConfigResource>
public class NamingConfigModule : LidarrRestModule<NamingConfigResource>
{
private readonly INamingConfigService _namingConfigService;
private readonly IFilenameSampleService _filenameSampleService;

View file

@ -1,4 +1,4 @@
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Organizer;
namespace NzbDrone.Api.Config

View file

@ -1,11 +1,12 @@
using System.Linq;
using System.Linq;
using System.Reflection;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Configuration;
using Lidarr.Http;
namespace NzbDrone.Api.Config
{
public abstract class NzbDroneConfigModule<TResource> : NzbDroneRestModule<TResource> where TResource : RestResource, new()
public abstract class NzbDroneConfigModule<TResource> : LidarrRestModule<TResource> where TResource : RestResource, new()
{
private readonly IConfigService _configService;

View file

@ -1,4 +1,4 @@
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Configuration;
namespace NzbDrone.Api.Config

View file

@ -1,9 +1,10 @@
using System.Collections.Generic;
using System.Collections.Generic;
using NzbDrone.Core.DiskSpace;
using Lidarr.Http;
namespace NzbDrone.Api.DiskSpace
{
public class DiskSpaceModule :NzbDroneRestModule<DiskSpaceResource>
public class DiskSpaceModule : LidarrRestModule<DiskSpaceResource>
{
private readonly IDiskSpaceService _diskSpaceService;

View file

@ -1,4 +1,4 @@
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
namespace NzbDrone.Api.DiskSpace
{

View file

@ -1,7 +1,7 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.IO;
using NLog;
using NzbDrone.Api.REST;
using Lidarr.Http;
using NzbDrone.Common.Disk;
using NzbDrone.Common.Extensions;
using NzbDrone.Core.Datastore.Events;
@ -15,14 +15,14 @@ using System;
namespace NzbDrone.Api.EpisodeFiles
{
public class EpisodeFileModule : NzbDroneRestModuleWithSignalR<EpisodeFileResource, EpisodeFile>,
public class EpisodeFileModule : LidarrRestModuleWithSignalR<EpisodeFileResource, EpisodeFile>,
IHandle<EpisodeFileAddedEvent>
{
private readonly IMediaFileService _mediaFileService;
private readonly IDiskProvider _diskProvider;
private readonly IRecycleBinProvider _recycleBinProvider;
private readonly ISeriesService _seriesService;
private readonly IQualityUpgradableSpecification _qualityUpgradableSpecification;
private readonly IUpgradableSpecification _upgradableSpecification;
private readonly Logger _logger;
public EpisodeFileModule(IBroadcastSignalRMessage signalRBroadcaster,
@ -30,7 +30,7 @@ namespace NzbDrone.Api.EpisodeFiles
IDiskProvider diskProvider,
IRecycleBinProvider recycleBinProvider,
ISeriesService seriesService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification upgradableSpecification,
Logger logger)
: base(signalRBroadcaster)
{
@ -38,7 +38,7 @@ namespace NzbDrone.Api.EpisodeFiles
_diskProvider = diskProvider;
_recycleBinProvider = recycleBinProvider;
_seriesService = seriesService;
_qualityUpgradableSpecification = qualityUpgradableSpecification;
_upgradableSpecification = upgradableSpecification;
_logger = logger;
GetResourceById = GetEpisodeFile;
GetResourceAll = GetEpisodeFiles;
@ -95,4 +95,4 @@ namespace NzbDrone.Api.EpisodeFiles
BroadcastResourceChange(ModelAction.Updated, message.EpisodeFile.Id);
}
}
}
}

View file

@ -1,7 +1,10 @@
using System;
using System;
using System.IO;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.DecisionEngine;
using NzbDrone.Core.MediaFiles;
using NzbDrone.Core.Qualities;
using NzbDrone.Core.Languages;
namespace NzbDrone.Api.EpisodeFiles
{
@ -15,13 +18,14 @@ namespace NzbDrone.Api.EpisodeFiles
public DateTime DateAdded { get; set; }
public string SceneName { get; set; }
public QualityModel Quality { get; set; }
public Language Language { get; set; }
public bool QualityCutoffNotMet { get; set; }
}
public static class EpisodeFileResourceMapper
{
private static EpisodeFileResource ToResource(this Core.MediaFiles.EpisodeFile model)
private static EpisodeFileResource ToResource(this EpisodeFile model)
{
if (model == null) return null;
@ -41,7 +45,7 @@ namespace NzbDrone.Api.EpisodeFiles
};
}
public static EpisodeFileResource ToResource(this Core.MediaFiles.EpisodeFile model, Core.Tv.Series series, Core.DecisionEngine.IQualityUpgradableSpecification qualityUpgradableSpecification)
public static EpisodeFileResource ToResource(this EpisodeFile model, Core.Tv.Series series, IUpgradableSpecification upgradableSpecification)
{
if (model == null) return null;
@ -57,7 +61,8 @@ namespace NzbDrone.Api.EpisodeFiles
DateAdded = model.DateAdded,
SceneName = model.SceneName,
Quality = model.Quality,
QualityCutoffNotMet = qualityUpgradableSpecification.CutoffNotMet(series.Profile.Value, model.Quality)
Language = model.Language,
QualityCutoffNotMet = upgradableSpecification.CutoffNotMet(series.Profile.Value, series.LanguageProfile.Value, model.Quality, model.Language)
};
}
}

View file

@ -1,5 +1,5 @@
using System.Collections.Generic;
using NzbDrone.Api.REST;
using System.Collections.Generic;
using Lidarr.Http.REST;
using NzbDrone.Core.Tv;
using NzbDrone.Core.DecisionEngine;
using NzbDrone.SignalR;
@ -10,7 +10,7 @@ namespace NzbDrone.Api.Episodes
{
public EpisodeModule(ISeriesService seriesService,
IEpisodeService episodeService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(episodeService, seriesService, qualityUpgradableSpecification, signalRBroadcaster)
{

View file

@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using NzbDrone.Common.Extensions;
using NzbDrone.Api.EpisodeFiles;
using NzbDrone.Api.Series;
@ -9,20 +9,21 @@ using NzbDrone.Core.MediaFiles.Events;
using NzbDrone.Core.Messaging.Events;
using NzbDrone.Core.Tv;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.Episodes
{
public abstract class EpisodeModuleWithSignalR : NzbDroneRestModuleWithSignalR<EpisodeResource, Episode>,
public abstract class EpisodeModuleWithSignalR : LidarrRestModuleWithSignalR<EpisodeResource, Episode>,
IHandle<EpisodeGrabbedEvent>,
IHandle<EpisodeDownloadedEvent>
{
protected readonly IEpisodeService _episodeService;
protected readonly ISeriesService _seriesService;
protected readonly IQualityUpgradableSpecification _qualityUpgradableSpecification;
protected readonly IUpgradableSpecification _qualityUpgradableSpecification;
protected EpisodeModuleWithSignalR(IEpisodeService episodeService,
ISeriesService seriesService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(signalRBroadcaster)
{
@ -35,7 +36,7 @@ namespace NzbDrone.Api.Episodes
protected EpisodeModuleWithSignalR(IEpisodeService episodeService,
ISeriesService seriesService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster,
string resource)
: base(signalRBroadcaster, resource)

View file

@ -1,9 +1,9 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using Newtonsoft.Json;
using NzbDrone.Api.EpisodeFiles;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Api.Series;
using NzbDrone.Core.Tv;

View file

@ -1,8 +1,8 @@
using System;
using System;
using System.IO;
using System.Linq;
using Nancy;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using NzbDrone.Common.Disk;
using NzbDrone.Common.Extensions;
using NzbDrone.Core.MediaFiles;
@ -73,4 +73,4 @@ namespace NzbDrone.Api.FileSystem
}).AsResponse();
}
}
}
}

View file

@ -1,12 +1,13 @@
using System.Collections.Generic;
using System.Collections.Generic;
using NzbDrone.Core.Datastore.Events;
using NzbDrone.Core.HealthCheck;
using NzbDrone.Core.Messaging.Events;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.Health
{
public class HealthModule : NzbDroneRestModuleWithSignalR<HealthResource, HealthCheck>,
public class HealthModule : LidarrRestModuleWithSignalR<HealthResource, HealthCheck>,
IHandle<HealthCheckCompleteEvent>
{
private readonly IHealthCheckService _healthCheckService;
@ -28,4 +29,4 @@ namespace NzbDrone.Api.Health
BroadcastResourceChange(ModelAction.Sync);
}
}
}
}

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Common.Http;
using NzbDrone.Core.HealthCheck;

View file

@ -1,29 +1,30 @@
using System;
using System;
using Nancy;
using NzbDrone.Api.Episodes;
using NzbDrone.Api.Albums;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using NzbDrone.Api.Series;
using NzbDrone.Api.Music;
using NzbDrone.Core.Datastore;
using NzbDrone.Core.DecisionEngine;
using NzbDrone.Core.Download;
using NzbDrone.Core.History;
using Lidarr.Http;
namespace NzbDrone.Api.History
{
public class HistoryModule : NzbDroneRestModule<HistoryResource>
public class HistoryModule : LidarrRestModule<HistoryResource>
{
private readonly IHistoryService _historyService;
private readonly IQualityUpgradableSpecification _qualityUpgradableSpecification;
private readonly IUpgradableSpecification _upgradableSpecification;
private readonly IFailedDownloadService _failedDownloadService;
public HistoryModule(IHistoryService historyService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IFailedDownloadService failedDownloadService)
{
_historyService = historyService;
_qualityUpgradableSpecification = qualityUpgradableSpecification;
_upgradableSpecification = qualityUpgradableSpecification;
_failedDownloadService = failedDownloadService;
GetResourcePaged = GetHistory;
@ -39,7 +40,10 @@ namespace NzbDrone.Api.History
if (model.Artist != null)
{
resource.QualityCutoffNotMet = _qualityUpgradableSpecification.CutoffNotMet(model.Artist.Profile.Value, model.Quality);
resource.QualityCutoffNotMet = _upgradableSpecification.CutoffNotMet(model.Artist.Profile.Value,
model.Artist.LanguageProfile,
model.Quality,
model.Language);
}
return resource;

View file

@ -1,12 +1,13 @@
using System;
using System;
using System.Collections.Generic;
using NzbDrone.Api.Episodes;
using NzbDrone.Api.Albums;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Api.Series;
using NzbDrone.Api.Music;
using NzbDrone.Core.History;
using NzbDrone.Core.Qualities;
using NzbDrone.Core.Languages;
namespace NzbDrone.Api.History
@ -20,6 +21,7 @@ namespace NzbDrone.Api.History
public bool QualityCutoffNotMet { get; set; }
public DateTime Date { get; set; }
public string DownloadId { get; set; }
public Language Language { get; set; }
public HistoryEventType EventType { get; set; }

View file

@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using FluentValidation;
using Nancy;
@ -10,7 +10,7 @@ using NzbDrone.Core.IndexerSearch;
using NzbDrone.Core.Indexers;
using NzbDrone.Core.Parser.Model;
using Nancy.ModelBinding;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using NzbDrone.Common.Cache;
using HttpStatusCode = System.Net.HttpStatusCode;
@ -117,4 +117,4 @@ namespace NzbDrone.Api.Indexers
return base.MapDecision(decision, initialWeight);
}
}
}
}

View file

@ -1,9 +1,10 @@
using System.Collections.Generic;
using System.Collections.Generic;
using NzbDrone.Core.DecisionEngine;
using Lidarr.Http;
namespace NzbDrone.Api.Indexers
{
public abstract class ReleaseModuleBase : NzbDroneRestModule<ReleaseResource>
public abstract class ReleaseModuleBase : LidarrRestModule<ReleaseResource>
{
protected virtual List<ReleaseResource> MapDecisions(IEnumerable<DownloadDecision> decisions)
{

View file

@ -1,4 +1,4 @@
using Nancy;
using Nancy;
using Nancy.ModelBinding;
using FluentValidation;
using NzbDrone.Core.DecisionEngine;
@ -6,7 +6,7 @@ using NzbDrone.Core.Download;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Core.Parser.Model;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using NLog;
namespace NzbDrone.Api.Indexers

View file

@ -1,10 +1,11 @@
using System;
using System;
using System.Collections.Generic;
using Newtonsoft.Json;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Parser;
using NzbDrone.Core.Qualities;
using NzbDrone.Core.Indexers;
using NzbDrone.Core.Languages;
using NzbDrone.Core.Parser.Model;
using NzbDrone.Core.DecisionEngine;
using System.Linq;
@ -154,4 +155,4 @@ namespace NzbDrone.Api.Indexers
return model;
}
}
}
}

View file

@ -1,14 +1,15 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using NzbDrone.Common.Disk;
using Nancy;
using Nancy.Responses;
using NzbDrone.Core.Configuration;
using Lidarr.Http;
namespace NzbDrone.Api.Logs
{
public abstract class LogFileModuleBase : NzbDroneRestModule<LogFileResource>
public abstract class LogFileModuleBase : LidarrRestModule<LogFileResource>
{
protected const string LOGFILE_ROUTE = @"/(?<filename>[-.a-zA-Z0-9]+?\.txt)";
@ -68,4 +69,4 @@ namespace NzbDrone.Api.Logs
protected abstract string DownloadUrlRoot { get; }
}
}
}

View file

@ -1,5 +1,5 @@
using System;
using NzbDrone.Api.REST;
using System;
using Lidarr.Http.REST;
namespace NzbDrone.Api.Logs
{

View file

@ -1,8 +1,10 @@
using NzbDrone.Core.Instrumentation;
using NzbDrone.Core.Instrumentation;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Logs
{
public class LogModule : NzbDroneRestModule<LogResource>
public class LogModule : LidarrRestModule<LogResource>
{
private readonly ILogService _logService;
@ -49,4 +51,4 @@ namespace NzbDrone.Api.Logs
return ApplyToPage(_logService.Paged, pageSpec, LogResourceMapper.ToResource);
}
}
}
}

View file

@ -1,5 +1,5 @@
using System;
using NzbDrone.Api.REST;
using System;
using Lidarr.Http.REST;
namespace NzbDrone.Api.Logs
{

View file

@ -2,10 +2,11 @@ using System.Collections.Generic;
using System.Linq;
using NzbDrone.Core.MediaFiles.TrackImport.Manual;
using NzbDrone.Core.Qualities;
using Lidarr.Http;
namespace NzbDrone.Api.ManualImport
{
public class ManualImportModule : NzbDroneRestModule<ManualImportResource>
public class ManualImportModule : LidarrRestModule<ManualImportResource>
{
private readonly IManualImportService _manualImportService;

View file

@ -1,7 +1,7 @@
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.Episodes;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Api.Series;
using NzbDrone.Common.Crypto;
using NzbDrone.Core.DecisionEngine;

View file

@ -1,8 +1,8 @@
using System.Collections;
using System.Collections.Generic;
using Nancy;
using NzbDrone.Api.REST;
using NzbDrone.Api.Extensions;
using Lidarr.Http.REST;
using Lidarr.Http.Extensions;
using NzbDrone.Core.MediaCover;
using NzbDrone.Core.MetadataSource;
using NzbDrone.Core.Parser;
@ -16,6 +16,7 @@ using NzbDrone.Core.MediaFiles.TrackImport;
using NzbDrone.Core.RootFolders;
using NzbDrone.Common.Cache;
using NzbDrone.Core.Music;
using Lidarr.Http;
namespace NzbDrone.Api.Music
{
@ -28,7 +29,7 @@ namespace NzbDrone.Api.Music
}
}
public class MusicBulkImportModule : NzbDroneRestModule<ArtistResource>
public class MusicBulkImportModule : LidarrRestModule<ArtistResource>
{
private readonly ISearchForNewArtist _searchProxy;
private readonly IRootFolderService _rootFolderService;

View file

@ -1,7 +1,7 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using Nancy;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using NzbDrone.Core.Music;
namespace NzbDrone.Api.Music

View file

@ -1,15 +1,16 @@
using Nancy;
using NzbDrone.Api.Extensions;
using Nancy;
using Lidarr.Http.Extensions;
using NzbDrone.Core.MediaCover;
using NzbDrone.Core.MetadataSource;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Lidarr.Http;
namespace NzbDrone.Api.Music
{
public class ArtistLookupModule : NzbDroneRestModule<ArtistResource>
public class ArtistLookupModule : LidarrRestModule<ArtistResource>
{
private readonly ISearchForNewArtist _searchProxy;

View file

@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using FluentValidation;
@ -14,10 +14,12 @@ using NzbDrone.Core.ArtistStats;
using NzbDrone.Core.Validation;
using NzbDrone.Core.Validation.Paths;
using NzbDrone.SignalR;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Music
{
public class ArtistModule : NzbDroneRestModuleWithSignalR<ArtistResource, Core.Music.Artist>,
public class ArtistModule : LidarrRestModuleWithSignalR<ArtistResource, Artist>,
IHandle<TrackImportedEvent>,
IHandle<TrackFileDeletedEvent>,
IHandle<ArtistUpdatedEvent>,
@ -39,9 +41,9 @@ namespace NzbDrone.Api.Music
RootFolderValidator rootFolderValidator,
ArtistPathValidator seriesPathValidator,
ArtistExistsValidator artistExistsValidator,
DroneFactoryValidator droneFactoryValidator,
SeriesAncestorValidator seriesAncestorValidator,
ProfileExistsValidator profileExistsValidator
ProfileExistsValidator profileExistsValidator,
LanguageProfileExistsValidator languageProfileExistsValidator
)
: base(signalRBroadcaster)
{
@ -56,19 +58,20 @@ namespace NzbDrone.Api.Music
CreateResource = AddArtist;
UpdateResource = UpdatArtist;
DeleteResource = DeleteArtist;
Validation.RuleBuilderExtensions.ValidId(SharedValidator.RuleFor(s => s.ProfileId));
SharedValidator.RuleFor(s => s.ProfileId).ValidId();
SharedValidator.RuleFor(s => s.LanguageProfileId);
SharedValidator.RuleFor(s => s.Path)
.Cascade(CascadeMode.StopOnFirstFailure)
.IsValidPath()
.SetValidator(rootFolderValidator)
.SetValidator(seriesPathValidator)
.SetValidator(droneFactoryValidator)
.SetValidator(seriesAncestorValidator)
.When(s => !s.Path.IsNullOrWhiteSpace());
SharedValidator.RuleFor(s => s.ProfileId).SetValidator(profileExistsValidator);
SharedValidator.RuleFor(s => s.LanguageProfileId).SetValidator(languageProfileExistsValidator);
PostValidator.RuleFor(s => s.Path).IsValidPath().When(s => s.RootFolderPath.IsNullOrWhiteSpace());
PostValidator.RuleFor(s => s.RootFolderPath).IsValidPath().When(s => s.Path.IsNullOrWhiteSpace());

View file

@ -1,5 +1,4 @@
using NzbDrone.Api.REST;
using NzbDrone.Api.Series;
using Lidarr.Http.REST;
using NzbDrone.Api.Albums;
using NzbDrone.Core.MediaCover;
using NzbDrone.Core.Music;
@ -44,6 +43,7 @@ namespace NzbDrone.Api.Music
//View & Edit
public string Path { get; set; }
public int ProfileId { get; set; }
public int LanguageProfileId { get; set; }
//Editing Only
public bool AlbumFolder { get; set; }
@ -97,6 +97,7 @@ namespace NzbDrone.Api.Music
Path = model.Path,
ProfileId = model.ProfileId,
LanguageProfileId = model.LanguageProfileId,
Monitored = model.Monitored,
AlbumFolder = model.AlbumFolder,
@ -154,6 +155,7 @@ namespace NzbDrone.Api.Music
Path = resource.Path,
ProfileId = resource.ProfileId,
LanguageProfileId = resource.LanguageProfileId,
AlbumFolder = resource.AlbumFolder,
Monitored = resource.Monitored,

View file

@ -1,8 +1,8 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using Nancy;
using Nancy.Extensions;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using NzbDrone.Core.Music;
namespace NzbDrone.Api.Music
@ -27,4 +27,4 @@ namespace NzbDrone.Api.Music
return _artistService.AddArtists(Artists).ToResource().AsResponse(HttpStatusCode.Accepted);
}
}
}
}

View file

@ -90,20 +90,10 @@
</Compile>
<Compile Include="Albums\AlbumModuleWithSignalR.cs" />
<Compile Include="Albums\AlbumStatisticsResource.cs" />
<Compile Include="Authentication\AuthenticationService.cs" />
<Compile Include="Authentication\EnableAuthInNancy.cs" />
<Compile Include="Authentication\AuthenticationModule.cs" />
<Compile Include="Authentication\LoginResource.cs" />
<Compile Include="Authentication\NzbDroneUser.cs" />
<Compile Include="Blacklist\BlacklistModule.cs" />
<Compile Include="Blacklist\BlacklistResource.cs" />
<Compile Include="Calendar\CalendarFeedModule.cs" />
<Compile Include="Calendar\CalendarModule.cs" />
<Compile Include="ClientSchema\Field.cs" />
<Compile Include="ClientSchema\FieldDefinitionAttribute.cs" />
<Compile Include="ClientSchema\SchemaBuilder.cs" />
<Compile Include="ClientSchema\SchemaDeserializer.cs" />
<Compile Include="ClientSchema\SelectOption.cs" />
<Compile Include="Commands\CommandModule.cs" />
<Compile Include="Commands\CommandResource.cs" />
<Compile Include="AlbumStudio\AlbumStudioModule.cs" />
@ -119,12 +109,6 @@
<Compile Include="Tracks\TrackResource.cs" />
<Compile Include="Tracks\RenameTrackModule.cs" />
<Compile Include="Tracks\RenameTrackResource.cs" />
<Compile Include="Extensions\AccessControlHeaders.cs" />
<Compile Include="Extensions\Pipelines\CorsPipeline.cs" />
<Compile Include="Extensions\Pipelines\UrlBasePipeline.cs" />
<Compile Include="Extensions\Pipelines\RequestLoggingPipeline.cs" />
<Compile Include="Frontend\Mappers\LoginHtmlMapper.cs" />
<Compile Include="Frontend\Mappers\RobotsTxtMapper.cs" />
<Compile Include="Indexers\ReleaseModuleBase.cs" />
<Compile Include="Indexers\ReleasePushModule.cs" />
<Compile Include="Albums\AlbumResource.cs" />
@ -164,31 +148,6 @@
<Compile Include="Episodes\EpisodeModule.cs" />
<Compile Include="Episodes\EpisodeModuleWithSignalR.cs" />
<Compile Include="Episodes\EpisodeResource.cs" />
<Compile Include="ErrorManagement\ApiException.cs" />
<Compile Include="ErrorManagement\ErrorHandler.cs" />
<Compile Include="ErrorManagement\ErrorModel.cs" />
<Compile Include="ErrorManagement\NzbDroneErrorPipeline.cs" />
<Compile Include="Exceptions\InvalidApiKeyException.cs" />
<Compile Include="Extensions\NancyJsonSerializer.cs" />
<Compile Include="Extensions\Pipelines\CacheHeaderPipeline.cs" />
<Compile Include="Extensions\Pipelines\GZipPipeline.cs" />
<Compile Include="Extensions\Pipelines\IfModifiedPipeline.cs" />
<Compile Include="Extensions\Pipelines\IRegisterNancyPipeline.cs" />
<Compile Include="Extensions\Pipelines\NzbDroneVersionPipeline.cs" />
<Compile Include="Extensions\ReqResExtensions.cs" />
<Compile Include="Extensions\RequestExtensions.cs" />
<Compile Include="Frontend\CacheableSpecification.cs" />
<Compile Include="Frontend\Mappers\BackupFileMapper.cs" />
<Compile Include="Frontend\Mappers\CacheBreakerProvider.cs" />
<Compile Include="Frontend\Mappers\FaviconMapper.cs" />
<Compile Include="Frontend\Mappers\IMapHttpRequestsToDisk.cs" />
<Compile Include="Frontend\Mappers\IndexHtmlMapper.cs" />
<Compile Include="Frontend\Mappers\LogFileMapper.cs" />
<Compile Include="Frontend\Mappers\MediaCoverMapper.cs" />
<Compile Include="Frontend\Mappers\StaticResourceMapper.cs" />
<Compile Include="Frontend\Mappers\StaticResourceMapperBase.cs" />
<Compile Include="Frontend\Mappers\UpdateLogFileMapper.cs" />
<Compile Include="Frontend\StaticResourceModule.cs" />
<Compile Include="Health\HealthModule.cs" />
<Compile Include="Health\HealthResource.cs" />
<Compile Include="History\HistoryModule.cs" />
@ -206,14 +165,10 @@
<Compile Include="MediaCovers\MediaCoverModule.cs" />
<Compile Include="Metadata\MetadataModule.cs" />
<Compile Include="Metadata\MetadataResource.cs" />
<Compile Include="NancyBootstrapper.cs" />
<Compile Include="Notifications\NotificationModule.cs" />
<Compile Include="Notifications\NotificationResource.cs" />
<Compile Include="NzbDroneApiModule.cs" />
<Compile Include="NzbDroneFeedModule.cs" />
<Compile Include="NzbDroneRestModule.cs" />
<Compile Include="NzbDroneRestModuleWithSignalR.cs" />
<Compile Include="PagingResource.cs" />
<Compile Include="Profiles\Languages\LanguageModule.cs" />
<Compile Include="Profiles\Languages\LanguageResource.cs" />
<Compile Include="Profiles\LegacyProfileModule.cs" />
@ -228,15 +183,8 @@
<Compile Include="Qualities\QualityDefinitionResource.cs" />
<Compile Include="Queue\QueueModule.cs" />
<Compile Include="Queue\QueueResource.cs" />
<Compile Include="ResourceChangeMessage.cs" />
<Compile Include="Restrictions\RestrictionModule.cs" />
<Compile Include="Restrictions\RestrictionResource.cs" />
<Compile Include="REST\NotFoundException.cs" />
<Compile Include="REST\BadRequestException.cs" />
<Compile Include="REST\MethodNotAllowedException.cs" />
<Compile Include="REST\ResourceValidator.cs" />
<Compile Include="REST\RestModule.cs" />
<Compile Include="REST\RestResource.cs" />
<Compile Include="RootFolders\RootFolderModule.cs" />
<Compile Include="RootFolders\RootFolderResource.cs" />
<Compile Include="SeasonPass\SeasonPassResource.cs" />
@ -254,12 +202,8 @@
<Compile Include="System\SystemModule.cs" />
<Compile Include="Tags\TagModule.cs" />
<Compile Include="Tags\TagResource.cs" />
<Compile Include="TinyIoCNancyBootstrapper.cs" />
<Compile Include="Update\UpdateModule.cs" />
<Compile Include="Update\UpdateResource.cs" />
<Compile Include="Validation\RssSyncIntervalValidator.cs" />
<Compile Include="Validation\EmptyCollectionValidator.cs" />
<Compile Include="Validation\RuleBuilderExtensions.cs" />
<Compile Include="Wanted\CutoffModule.cs" />
<Compile Include="Wanted\LegacyMissingModule.cs" />
<Compile Include="Wanted\MissingModule.cs" />
@ -287,6 +231,10 @@
<Project>{7C2CC69F-5CA0-4E5C-85CB-983F9F6C3B36}</Project>
<Name>NzbDrone.SignalR</Name>
</ProjectReference>
<ProjectReference Include="..\Sonarr.Http\Lidarr.Http.csproj">
<Project>{5370bff7-1bd7-46bc-af06-7d9ea5cda1d6}</Project>
<Name>Lidarr.Http</Name>
</ProjectReference>
</ItemGroup>
<ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />

View file

@ -1,10 +1,11 @@
using NzbDrone.Api.Albums;
using NzbDrone.Api.Albums;
using NzbDrone.Api.Music;
using NzbDrone.Core.Parser;
using Lidarr.Http;
namespace NzbDrone.Api.Parse
{
public class ParseModule : NzbDroneRestModule<ParseResource>
public class ParseModule : LidarrRestModule<ParseResource>
{
private readonly IParsingService _parsingService;
@ -47,4 +48,4 @@ namespace NzbDrone.Api.Parse
}
}
}
}
}

View file

@ -1,5 +1,5 @@
using System.Collections.Generic;
using NzbDrone.Api.REST;
using System.Collections.Generic;
using Lidarr.Http.REST;
using NzbDrone.Api.Music;
using NzbDrone.Api.Albums;
using NzbDrone.Core.Parser.Model;
@ -13,4 +13,4 @@ namespace NzbDrone.Api.Parse
public ArtistResource Artist { get; set; }
public List<AlbumResource> Albums { get; set; }
}
}
}

View file

@ -1,13 +1,14 @@
using System.Collections.Generic;
using System.Collections.Generic;
using FluentValidation;
using FluentValidation.Results;
using NzbDrone.Api.REST;
using NzbDrone.Api.Validation;
using Lidarr.Http.REST;
using Lidarr.Http.Validation;
using NzbDrone.Core.Profiles.Delay;
using Lidarr.Http;
namespace NzbDrone.Api.Profiles.Delay
{
public class DelayProfileModule : NzbDroneRestModule<DelayProfileResource>
public class DelayProfileModule : LidarrRestModule<DelayProfileResource>
{
private readonly IDelayProfileService _delayProfileService;
@ -72,4 +73,4 @@ namespace NzbDrone.Api.Profiles.Delay
return _delayProfileService.All().ToResource();
}
}
}
}

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Indexers;
using NzbDrone.Core.Profiles.Delay;

View file

@ -1,11 +1,12 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Core.Parser;
using NzbDrone.Core.Languages;
using Lidarr.Http;
namespace NzbDrone.Api.Profiles.Languages
{
public class LanguageModule : NzbDroneRestModule<LanguageResource>
public class LanguageModule : LidarrRestModule<LanguageResource>
{
public LanguageModule()
{
@ -36,4 +37,4 @@ namespace NzbDrone.Api.Profiles.Languages
.ToList();
}
}
}
}

View file

@ -1,5 +1,5 @@
using Newtonsoft.Json;
using NzbDrone.Api.REST;
using Newtonsoft.Json;
using Lidarr.Http.REST;
namespace NzbDrone.Api.Profiles.Languages
{
@ -10,4 +10,4 @@ namespace NzbDrone.Api.Profiles.Languages
public string Name { get; set; }
public string NameLower => Name.ToLowerInvariant();
}
}
}

View file

@ -1,11 +1,13 @@
using System.Collections.Generic;
using System.Collections.Generic;
using FluentValidation;
using NzbDrone.Core.Profiles;
using NzbDrone.Core.Profiles.Qualities;
using NzbDrone.Core.Validation;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Profiles
{
public class ProfileModule : NzbDroneRestModule<ProfileResource>
public class ProfileModule : LidarrRestModule<ProfileResource>
{
private readonly IProfileService _profileService;
@ -15,7 +17,6 @@ namespace NzbDrone.Api.Profiles
SharedValidator.RuleFor(c => c.Name).NotEmpty();
SharedValidator.RuleFor(c => c.Cutoff).NotNull();
SharedValidator.RuleFor(c => c.Items).MustHaveAllowedQuality();
SharedValidator.RuleFor(c => c.Language).ValidLanguage();
GetResourceAll = GetAll;
GetResourceById = GetById;
@ -53,4 +54,4 @@ namespace NzbDrone.Api.Profiles
return _profileService.All().ToResource();
}
}
}
}

View file

@ -1,8 +1,9 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Parser;
using NzbDrone.Core.Profiles;
using NzbDrone.Core.Profiles.Qualities;
using NzbDrone.Core.Qualities;
namespace NzbDrone.Api.Profiles
@ -12,7 +13,6 @@ namespace NzbDrone.Api.Profiles
public string Name { get; set; }
public Quality Cutoff { get; set; }
public List<ProfileQualityItemResource> Items { get; set; }
public Language Language { get; set; }
}
public class ProfileQualityItemResource : RestResource
@ -33,8 +33,7 @@ namespace NzbDrone.Api.Profiles
Name = model.Name,
Cutoff = model.Cutoff,
Items = model.Items.ConvertAll(ToResource),
Language = model.Language
Items = model.Items.ConvertAll(ToResource)
};
}
@ -59,8 +58,7 @@ namespace NzbDrone.Api.Profiles
Name = resource.Name,
Cutoff = (Quality)resource.Cutoff.Id,
Items = resource.Items.ConvertAll(ToModel),
Language = resource.Language
Items = resource.Items.ConvertAll(ToModel)
};
}
@ -80,4 +78,4 @@ namespace NzbDrone.Api.Profiles
return models.Select(ToResource).ToList();
}
}
}
}

View file

@ -1,12 +1,14 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Core.Parser;
using NzbDrone.Core.Profiles;
using NzbDrone.Core.Profiles.Qualities;
using NzbDrone.Core.Qualities;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Profiles
{
public class ProfileSchemaModule : NzbDroneRestModule<ProfileResource>
public class ProfileSchemaModule : LidarrRestModule<ProfileResource>
{
private readonly IQualityDefinitionService _qualityDefinitionService;
@ -28,9 +30,8 @@ namespace NzbDrone.Api.Profiles
var profile = new Profile();
profile.Cutoff = Quality.Unknown;
profile.Items = items;
profile.Language = Language.English;
return new List<ProfileResource> { profile.ToResource() };
}
}
}
}

View file

@ -1,18 +1,20 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using FluentValidation;
using FluentValidation.Results;
using Nancy;
using NzbDrone.Api.ClientSchema;
using NzbDrone.Api.Extensions;
using Lidarr.Http.ClientSchema;
using Lidarr.Http.Extensions;
using NzbDrone.Common.Reflection;
using NzbDrone.Core.ThingiProvider;
using NzbDrone.Core.Validation;
using Newtonsoft.Json;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api
{
public abstract class ProviderModuleBase<TProviderResource, TProvider, TProviderDefinition> : NzbDroneRestModule<TProviderResource>
public abstract class ProviderModuleBase<TProviderResource, TProvider, TProviderDefinition> : LidarrRestModule<TProviderResource>
where TProviderDefinition : ProviderDefinition, new()
where TProvider : IProvider
where TProviderResource : ProviderResource, new()

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using NzbDrone.Api.ClientSchema;
using NzbDrone.Api.REST;
using System.Collections.Generic;
using Lidarr.Http.ClientSchema;
using Lidarr.Http.REST;
using NzbDrone.Core.ThingiProvider;
namespace NzbDrone.Api
@ -17,4 +17,4 @@ namespace NzbDrone.Api
public List<ProviderResource> Presets { get; set; }
}
}
}

View file

@ -1,9 +1,11 @@
using System.Collections.Generic;
using System.Collections.Generic;
using NzbDrone.Core.Qualities;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Qualities
{
public class QualityDefinitionModule : NzbDroneRestModule<QualityDefinitionResource>
public class QualityDefinitionModule : LidarrRestModule<QualityDefinitionResource>
{
private readonly IQualityDefinitionService _qualityDefinitionService;
@ -34,4 +36,4 @@ namespace NzbDrone.Api.Qualities
return _qualityDefinitionService.All().ToResource();
}
}
}
}

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Qualities;
namespace NzbDrone.Api.Qualities
@ -62,4 +62,4 @@ namespace NzbDrone.Api.Qualities
return models.Select(ToResource).ToList();
}
}
}
}

View file

@ -1,16 +1,17 @@
using System;
using System;
using Nancy;
using Nancy.Responses;
using NzbDrone.Api.Extensions;
using NzbDrone.Api.REST;
using Lidarr.Http.Extensions;
using Lidarr.Http.REST;
using NzbDrone.Core.Download;
using NzbDrone.Core.Download.Pending;
using NzbDrone.Core.Download.TrackedDownloads;
using NzbDrone.Core.Queue;
using Lidarr.Http;
namespace NzbDrone.Api.Queue
{
public class QueueActionModule : NzbDroneRestModule<QueueResource>
public class QueueActionModule : LidarrRestModule<QueueResource>
{
private readonly IQueueService _queueService;
private readonly ITrackedDownloadService _trackedDownloadService;

View file

@ -1,14 +1,15 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Core.Datastore.Events;
using NzbDrone.Core.Download.Pending;
using NzbDrone.Core.Messaging.Events;
using NzbDrone.Core.Queue;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.Queue
{
public class QueueModule : NzbDroneRestModuleWithSignalR<QueueResource, Core.Queue.Queue>,
public class QueueModule : LidarrRestModuleWithSignalR<QueueResource, Core.Queue.Queue>,
IHandle<QueueUpdatedEvent>, IHandle<PendingReleasesUpdatedEvent>
{
private readonly IQueueService _queueService;
@ -45,4 +46,4 @@ namespace NzbDrone.Api.Queue
BroadcastResourceChange(ModelAction.Sync);
}
}
}
}

View file

@ -1,6 +1,6 @@
using System;
using System;
using System.Collections.Generic;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Qualities;
using NzbDrone.Api.Series;
using NzbDrone.Api.Episodes;

View file

@ -1,11 +1,12 @@
using System.Collections.Generic;
using System.Collections.Generic;
using FluentValidation;
using NzbDrone.Core.RemotePathMappings;
using NzbDrone.Core.Validation.Paths;
using Lidarr.Http;
namespace NzbDrone.Api.RemotePathMappings
{
public class RemotePathMappingModule : NzbDroneRestModule<RemotePathMappingResource>
public class RemotePathMappingModule : LidarrRestModule<RemotePathMappingResource>
{
private readonly IRemotePathMappingService _remotePathMappingService;
@ -64,4 +65,4 @@ namespace NzbDrone.Api.RemotePathMappings
_remotePathMappingService.Update(mapping);
}
}
}
}

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.RemotePathMappings;
namespace NzbDrone.Api.RemotePathMappings

View file

@ -1,11 +1,12 @@
using System.Collections.Generic;
using System.Collections.Generic;
using FluentValidation.Results;
using NzbDrone.Common.Extensions;
using NzbDrone.Core.Restrictions;
using Lidarr.Http;
namespace NzbDrone.Api.Restrictions
{
public class RestrictionModule : NzbDroneRestModule<RestrictionResource>
public class RestrictionModule : LidarrRestModule<RestrictionResource>
{
private readonly IRestrictionService _restrictionService;

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Restrictions;
namespace NzbDrone.Api.Restrictions

View file

@ -1,12 +1,13 @@
using System.Collections.Generic;
using System.Collections.Generic;
using FluentValidation;
using NzbDrone.Core.RootFolders;
using NzbDrone.Core.Validation.Paths;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.RootFolders
{
public class RootFolderModule : NzbDroneRestModuleWithSignalR<RootFolderResource, RootFolder>
public class RootFolderModule : LidarrRestModuleWithSignalR<RootFolderResource, RootFolder>
{
private readonly IRootFolderService _rootFolderService;
@ -14,7 +15,6 @@ namespace NzbDrone.Api.RootFolders
IBroadcastSignalRMessage signalRBroadcaster,
RootFolderValidator rootFolderValidator,
PathExistsValidator pathExistsValidator,
DroneFactoryValidator droneFactoryValidator,
MappedNetworkDriveValidator mappedNetworkDriveValidator,
StartupFolderValidator startupFolderValidator,
FolderWritableValidator folderWritableValidator)
@ -31,7 +31,6 @@ namespace NzbDrone.Api.RootFolders
.Cascade(CascadeMode.StopOnFirstFailure)
.IsValidPath()
.SetValidator(rootFolderValidator)
.SetValidator(droneFactoryValidator)
.SetValidator(mappedNetworkDriveValidator)
.SetValidator(startupFolderValidator)
.SetValidator(pathExistsValidator)
@ -60,4 +59,4 @@ namespace NzbDrone.Api.RootFolders
_rootFolderService.Remove(id);
}
}
}
}

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.RootFolders;
namespace NzbDrone.Api.RootFolders
@ -48,4 +48,4 @@ namespace NzbDrone.Api.RootFolders
return models.Select(ToResource).ToList();
}
}
}
}

View file

@ -1,5 +1,5 @@
using Nancy;
using NzbDrone.Api.Extensions;
using Nancy;
using Lidarr.Http.Extensions;
using NzbDrone.Core.Tv;
namespace NzbDrone.Api.SeasonPass

View file

@ -1,7 +1,8 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using Nancy;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using Lidarr.Http.Mapping;
using NzbDrone.Core.Tv;
namespace NzbDrone.Api.Series

View file

@ -1,4 +1,4 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using FluentValidation;
@ -15,10 +15,12 @@ using NzbDrone.Core.Validation.Paths;
using NzbDrone.Core.DataAugmentation.Scene;
using NzbDrone.Core.Validation;
using NzbDrone.SignalR;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Series
{
public class SeriesModule : NzbDroneRestModuleWithSignalR<SeriesResource, Core.Tv.Series>,
public class SeriesModule : LidarrRestModuleWithSignalR<SeriesResource, Core.Tv.Series>,
IHandle<EpisodeImportedEvent>,
IHandle<EpisodeFileDeletedEvent>,
IHandle<SeriesUpdatedEvent>,
@ -43,9 +45,9 @@ namespace NzbDrone.Api.Series
RootFolderValidator rootFolderValidator,
SeriesPathValidator seriesPathValidator,
SeriesExistsValidator seriesExistsValidator,
DroneFactoryValidator droneFactoryValidator,
SeriesAncestorValidator seriesAncestorValidator,
ProfileExistsValidator profileExistsValidator
ProfileExistsValidator profileExistsValidator,
LanguageProfileExistsValidator languageProfileExistsValidator
)
: base(signalRBroadcaster)
{
@ -62,18 +64,19 @@ namespace NzbDrone.Api.Series
UpdateResource = UpdateSeries;
DeleteResource = DeleteSeries;
Validation.RuleBuilderExtensions.ValidId(SharedValidator.RuleFor(s => s.ProfileId));
SharedValidator.RuleFor(s => s.ProfileId).ValidId();
SharedValidator.RuleFor(s => s.LanguageProfileId);
SharedValidator.RuleFor(s => s.Path)
.Cascade(CascadeMode.StopOnFirstFailure)
.IsValidPath()
.SetValidator(rootFolderValidator)
.SetValidator(seriesPathValidator)
.SetValidator(droneFactoryValidator)
.SetValidator(seriesAncestorValidator)
.When(s => !s.Path.IsNullOrWhiteSpace());
SharedValidator.RuleFor(s => s.ProfileId).SetValidator(profileExistsValidator);
SharedValidator.RuleFor(s => s.LanguageProfileId).SetValidator(languageProfileExistsValidator);
PostValidator.RuleFor(s => s.Path).IsValidPath().When(s => s.RootFolderPath.IsNullOrWhiteSpace());
PostValidator.RuleFor(s => s.RootFolderPath).IsValidPath().When(s => s.Path.IsNullOrWhiteSpace());

View file

@ -1,7 +1,7 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.MediaCover;
using NzbDrone.Core.Tv;
@ -52,6 +52,7 @@ namespace NzbDrone.Api.Series
//View & Edit
public string Path { get; set; }
public int ProfileId { get; set; }
public int LanguageProfileId { get; set; }
//Editing Only
public bool SeasonFolder { get; set; }
@ -126,7 +127,8 @@ namespace NzbDrone.Api.Series
Path = model.Path,
ProfileId = model.ProfileId,
LanguageProfileId = model.LanguageProfileId,
SeasonFolder = model.SeasonFolder,
Monitored = model.Monitored,
@ -180,6 +182,7 @@ namespace NzbDrone.Api.Series
Path = resource.Path,
ProfileId = resource.ProfileId,
LanguageProfileId = resource.LanguageProfileId,
SeasonFolder = resource.SeasonFolder,
Monitored = resource.Monitored,

View file

@ -1,11 +1,12 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using NzbDrone.Core.Backup;
using Lidarr.Http;
namespace NzbDrone.Api.System.Backup
{
public class BackupModule : NzbDroneRestModule<BackupResource>
public class BackupModule : LidarrRestModule<BackupResource>
{
private readonly IBackupService _backupService;
@ -21,9 +22,9 @@ namespace NzbDrone.Api.System.Backup
return backups.Select(b => new BackupResource
{
Id = b.Path.GetHashCode(),
Name = Path.GetFileName(b.Path),
Path = b.Path,
Id = b.Name.GetHashCode(),
Name = Path.GetFileName(b.Name),
Path = b.Name,
Type = b.Type,
Time = b.Time
}).ToList();

View file

@ -1,5 +1,5 @@
using System;
using NzbDrone.Api.REST;
using System;
using Lidarr.Http.REST;
using NzbDrone.Core.Backup;
namespace NzbDrone.Api.System.Backup

View file

@ -1,6 +1,6 @@
using Nancy;
using Nancy;
using Nancy.Routing;
using NzbDrone.Api.Extensions;
using Lidarr.Http.Extensions;
using NzbDrone.Common.EnvironmentInfo;
using NzbDrone.Common.Extensions;
using NzbDrone.Core.Configuration;

View file

@ -1,14 +1,15 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using System.Text.RegularExpressions;
using NzbDrone.Core.Datastore.Events;
using NzbDrone.Core.Jobs;
using NzbDrone.Core.Messaging.Events;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.System.Tasks
{
public class TaskModule : NzbDroneRestModuleWithSignalR<TaskResource, ScheduledTask>, IHandle<CommandExecutedEvent>
public class TaskModule : LidarrRestModuleWithSignalR<TaskResource, ScheduledTask>, IHandle<CommandExecutedEvent>
{
private readonly ITaskManager _taskManager;

View file

@ -1,5 +1,5 @@
using System;
using NzbDrone.Api.REST;
using System;
using Lidarr.Http.REST;
namespace NzbDrone.Api.System.Tasks
{

View file

@ -1,12 +1,14 @@
using System.Collections.Generic;
using System.Collections.Generic;
using NzbDrone.Core.Datastore.Events;
using NzbDrone.Core.Messaging.Events;
using NzbDrone.Core.Tags;
using NzbDrone.SignalR;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Tags
{
public class TagModule : NzbDroneRestModuleWithSignalR<TagResource, Tag>, IHandle<TagsUpdatedEvent>
public class TagModule : LidarrRestModuleWithSignalR<TagResource, Tag>, IHandle<TagsUpdatedEvent>
{
private readonly ITagService _tagService;

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Tags;
namespace NzbDrone.Api.Tags

View file

@ -1,7 +1,7 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.IO;
using NLog;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Common.Disk;
using NzbDrone.Common.Extensions;
using NzbDrone.Core.Datastore.Events;
@ -13,10 +13,12 @@ using NzbDrone.Core.Music;
using NzbDrone.Core.DecisionEngine;
using NzbDrone.SignalR;
using System;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.TrackFiles
{
public class TrackFileModule : NzbDroneRestModuleWithSignalR<TrackFileResource, TrackFile>,
public class TrackFileModule : LidarrRestModuleWithSignalR<TrackFileResource, TrackFile>,
IHandle<TrackFileAddedEvent>
{
private readonly IMediaFileService _mediaFileService;
@ -24,7 +26,7 @@ namespace NzbDrone.Api.TrackFiles
private readonly IRecycleBinProvider _recycleBinProvider;
private readonly ISeriesService _seriesService;
private readonly IArtistService _artistService;
private readonly IQualityUpgradableSpecification _qualityUpgradableSpecification;
private readonly IUpgradableSpecification _upgradableSpecification;
private readonly Logger _logger;
public TrackFileModule(IBroadcastSignalRMessage signalRBroadcaster,
@ -33,7 +35,7 @@ namespace NzbDrone.Api.TrackFiles
IRecycleBinProvider recycleBinProvider,
ISeriesService seriesService,
IArtistService artistService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification upgradableSpecification,
Logger logger)
: base(signalRBroadcaster)
{
@ -42,7 +44,7 @@ namespace NzbDrone.Api.TrackFiles
_recycleBinProvider = recycleBinProvider;
_seriesService = seriesService;
_artistService = artistService;
_qualityUpgradableSpecification = qualityUpgradableSpecification;
_upgradableSpecification = upgradableSpecification;
_logger = logger;
GetResourceById = GetTrackFile;
GetResourceAll = GetTrackFiles;
@ -55,7 +57,7 @@ namespace NzbDrone.Api.TrackFiles
var trackFile = _mediaFileService.Get(id);
var artist = _artistService.GetArtist(trackFile.ArtistId);
return trackFile.ToResource(artist, _qualityUpgradableSpecification);
return trackFile.ToResource(artist, _upgradableSpecification);
}
private List<TrackFileResource> GetTrackFiles()
@ -69,7 +71,7 @@ namespace NzbDrone.Api.TrackFiles
var artist = _artistService.GetArtist(artistId);
return _mediaFileService.GetFilesByArtist(artistId).ConvertAll(f => f.ToResource(artist, _qualityUpgradableSpecification));
return _mediaFileService.GetFilesByArtist(artistId).ConvertAll(f => f.ToResource(artist, _upgradableSpecification));
}
private void SetQuality(TrackFileResource trackFileResource)
@ -97,4 +99,4 @@ namespace NzbDrone.Api.TrackFiles
BroadcastResourceChange(ModelAction.Updated, message.TrackFile.Id);
}
}
}
}

View file

@ -1,7 +1,8 @@
using System;
using System;
using System.IO;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Qualities;
using NzbDrone.Core.Languages;
namespace NzbDrone.Api.TrackFiles
{
@ -12,6 +13,7 @@ namespace NzbDrone.Api.TrackFiles
public string RelativePath { get; set; }
public string Path { get; set; }
public long Size { get; set; }
public Language Language { get; set; }
public DateTime DateAdded { get; set; }
//public string SceneName { get; set; }
public QualityModel Quality { get; set; }
@ -41,7 +43,7 @@ namespace NzbDrone.Api.TrackFiles
};
}
public static TrackFileResource ToResource(this Core.MediaFiles.TrackFile model, Core.Music.Artist artist, Core.DecisionEngine.IQualityUpgradableSpecification qualityUpgradableSpecification)
public static TrackFileResource ToResource(this Core.MediaFiles.TrackFile model, Core.Music.Artist artist, Core.DecisionEngine.IUpgradableSpecification upgradableSpecification)
{
if (model == null) return null;
@ -57,7 +59,8 @@ namespace NzbDrone.Api.TrackFiles
DateAdded = model.DateAdded,
//SceneName = model.SceneName,
Quality = model.Quality,
QualityCutoffNotMet = qualityUpgradableSpecification.CutoffNotMet(artist.Profile.Value, model.Quality)
Language = model.Language,
QualityCutoffNotMet = upgradableSpecification.CutoffNotMet(artist.Profile.Value, artist.LanguageProfile.Value, model.Quality, model.Language)
};
}
}

View file

@ -1,10 +1,12 @@
using System.Collections.Generic;
using NzbDrone.Api.REST;
using System.Collections.Generic;
using Lidarr.Http.REST;
using NzbDrone.Core.MediaFiles;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Tracks
{
public class RenameTrackModule : NzbDroneRestModule<RenameTrackResource>
public class RenameTrackModule : LidarrRestModule<RenameTrackResource>
{
private readonly IRenameTrackFileService _renameTrackFileService;

View file

@ -1,6 +1,6 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
namespace NzbDrone.Api.Tracks
{

View file

@ -1,5 +1,5 @@
using System.Collections.Generic;
using NzbDrone.Api.REST;
using System.Collections.Generic;
using Lidarr.Http.REST;
using NzbDrone.Core.Music;
using NzbDrone.Core.DecisionEngine;
using NzbDrone.SignalR;
@ -10,9 +10,9 @@ namespace NzbDrone.Api.Tracks
{
public TrackModule(IArtistService artistService,
ITrackService trackService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification upgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(trackService, artistService, qualityUpgradableSpecification, signalRBroadcaster)
: base(trackService, artistService, upgradableSpecification, signalRBroadcaster)
{
GetResourceAll = GetTracks;
UpdateResource = SetMonitored;

View file

@ -1,4 +1,4 @@
using System.Collections.Generic;
using System.Collections.Generic;
using NzbDrone.Common.Extensions;
using NzbDrone.Api.TrackFiles;
using NzbDrone.Api.Music;
@ -10,39 +10,41 @@ using NzbDrone.Core.Messaging.Events;
using NzbDrone.Core.Tv;
using NzbDrone.Core.Music;
using NzbDrone.SignalR;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Tracks
{
public abstract class TrackModuleWithSignalR : NzbDroneRestModuleWithSignalR<TrackResource, Track>,
public abstract class TrackModuleWithSignalR : LidarrRestModuleWithSignalR<TrackResource, Track>,
IHandle<TrackDownloadedEvent>
{
protected readonly ITrackService _trackService;
protected readonly IArtistService _artistService;
protected readonly IQualityUpgradableSpecification _qualityUpgradableSpecification;
protected readonly IUpgradableSpecification _upgradableSpecification;
protected TrackModuleWithSignalR(ITrackService trackService,
IArtistService artistService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification upgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(signalRBroadcaster)
{
_trackService = trackService;
_artistService = artistService;
_qualityUpgradableSpecification = qualityUpgradableSpecification;
_upgradableSpecification = upgradableSpecification;
GetResourceById = GetTrack;
}
protected TrackModuleWithSignalR(ITrackService trackService,
IArtistService artistService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification upgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster,
string resource)
: base(signalRBroadcaster, resource)
{
_trackService = trackService;
_artistService = artistService;
_qualityUpgradableSpecification = qualityUpgradableSpecification;
_upgradableSpecification = upgradableSpecification;
GetResourceById = GetTrack;
}
@ -68,7 +70,7 @@ namespace NzbDrone.Api.Tracks
}
if (includeTrackFile && track.TrackFileId != 0)
{
resource.TrackFile = track.TrackFile.Value.ToResource(artist, _qualityUpgradableSpecification);
resource.TrackFile = track.TrackFile.Value.ToResource(artist, _upgradableSpecification);
}
}
@ -96,7 +98,7 @@ namespace NzbDrone.Api.Tracks
}
if (includeTrackFile && tracks[i].TrackFileId != 0)
{
resource.TrackFile = tracks[i].TrackFile.Value.ToResource(artist, _qualityUpgradableSpecification);
resource.TrackFile = tracks[i].TrackFile.Value.ToResource(artist, _upgradableSpecification);
}
}
}

View file

@ -1,9 +1,9 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using Newtonsoft.Json;
using NzbDrone.Api.TrackFiles;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Api.Music;
using NzbDrone.Core.Music;

View file

@ -1,11 +1,13 @@
using System.Collections.Generic;
using System.Collections.Generic;
using System.Linq;
using NzbDrone.Common.EnvironmentInfo;
using NzbDrone.Core.Update;
using Lidarr.Http;
using Lidarr.Http.Mapping;
namespace NzbDrone.Api.Update
{
public class UpdateModule : NzbDroneRestModule<UpdateResource>
public class UpdateModule : LidarrRestModule<UpdateResource>
{
private readonly IRecentUpdateProvider _recentUpdateProvider;
@ -42,4 +44,4 @@ namespace NzbDrone.Api.Update
return resources;
}
}
}
}

View file

@ -1,8 +1,8 @@
using System;
using System;
using System.Collections.Generic;
using System.Linq;
using Newtonsoft.Json;
using NzbDrone.Api.REST;
using Lidarr.Http.REST;
using NzbDrone.Core.Update;
namespace NzbDrone.Api.Update

View file

@ -1,8 +1,9 @@
using NzbDrone.Api.Episodes;
using NzbDrone.Api.Episodes;
using NzbDrone.Core.Datastore;
using NzbDrone.Core.DecisionEngine;
using NzbDrone.Core.Tv;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.Wanted
{
@ -13,7 +14,7 @@ namespace NzbDrone.Api.Wanted
public CutoffModule(IEpisodeCutoffService episodeCutoffService,
IEpisodeService episodeService,
ISeriesService seriesService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(episodeService, seriesService, qualityUpgradableSpecification, signalRBroadcaster, "wanted/cutoff")
{

View file

@ -1,10 +1,12 @@
using NzbDrone.Api.Episodes;
using NzbDrone.Api.Episodes;
using NzbDrone.Api.Albums;
using NzbDrone.Core.Datastore;
using NzbDrone.Core.DecisionEngine;
using NzbDrone.Core.ArtistStats;
using NzbDrone.Core.Music;
using NzbDrone.Core.Tv;
using NzbDrone.SignalR;
using Lidarr.Http;
namespace NzbDrone.Api.Wanted
{
@ -13,7 +15,7 @@ namespace NzbDrone.Api.Wanted
public MissingModule(IAlbumService albumService,
IArtistStatisticsService artistStatisticsService,
IArtistService artistService,
IQualityUpgradableSpecification qualityUpgradableSpecification,
IUpgradableSpecification qualityUpgradableSpecification,
IBroadcastSignalRMessage signalRBroadcaster)
: base(albumService, artistStatisticsService, artistService, qualityUpgradableSpecification, signalRBroadcaster, "wanted/missing")
{

View file

@ -1,8 +1,7 @@
using System;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using NLog;
using NzbDrone.Common.EnvironmentInfo;
using NzbDrone.Common.Extensions;
@ -16,7 +15,6 @@ namespace NzbDrone.Common.Disk
public class FileSystemLookupService : IFileSystemLookupService
{
private readonly IDiskProvider _diskProvider;
private readonly Logger _logger;
private readonly HashSet<string> _setToRemove = new HashSet<string>
{
@ -48,10 +46,9 @@ namespace NzbDrone.Common.Disk
"@eadir"
};
public FileSystemLookupService(IDiskProvider diskProvider, Logger logger)
public FileSystemLookupService(IDiskProvider diskProvider)
{
_diskProvider = diskProvider;
_logger = logger;
}
public FileSystemResult LookupContents(string query, bool includeFiles)
@ -154,6 +151,16 @@ namespace NzbDrone.Common.Disk
.ToList();
}
private static string GetVolumeName(IMount mountInfo)
{
if (mountInfo.VolumeLabel.IsNullOrWhiteSpace())
{
return mountInfo.Name;
}
return $"{mountInfo.Name} ({mountInfo.VolumeLabel})";
}
private string GetDirectoryPath(string path)
{
if (path.Last() != Path.DirectorySeparatorChar)
@ -164,7 +171,7 @@ namespace NzbDrone.Common.Disk
return path;
}
private string GetParent(string path)
private static string GetParent(string path)
{
var di = new DirectoryInfo(path);

View file

@ -1,14 +1,17 @@
using System;
using System;
namespace NzbDrone.Common.EnvironmentInfo
{
public interface IRuntimeInfo
{
DateTime StartTime { get; }
bool IsUserInteractive { get; }
bool IsAdmin { get; }
bool IsWindowsService { get; }
bool IsExiting { get; set; }
bool IsTray { get; }
RuntimeMode Mode { get; }
bool RestartPending { get; set; }
string ExecutingApplication { get; }
}
}
}

View file

@ -1,20 +1,23 @@
using System;
using System;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Security.Principal;
using System.ServiceProcess;
using NLog;
using NzbDrone.Common.Processes;
namespace NzbDrone.Common.EnvironmentInfo
{
public class RuntimeInfo : IRuntimeInfo
{
private readonly Logger _logger;
private readonly DateTime _startTime = DateTime.UtcNow;
public RuntimeInfo(IServiceProvider serviceProvider, Logger logger)
{
_logger = logger;
IsWindowsService = !IsUserInteractive &&
OsInfo.IsWindows &&
@ -35,6 +38,14 @@ namespace NzbDrone.Common.EnvironmentInfo
IsProduction = InternalIsProduction();
}
public DateTime StartTime
{
get
{
return _startTime;
}
}
public static bool IsUserInteractive => Environment.UserInteractive;
bool IRuntimeInfo.IsUserInteractive => IsUserInteractive;
@ -59,6 +70,39 @@ namespace NzbDrone.Common.EnvironmentInfo
public bool IsWindowsService { get; private set; }
public bool IsExiting { get; set; }
public bool IsTray
{
get
{
if (OsInfo.IsWindows)
{
return IsUserInteractive && Process.GetCurrentProcess().ProcessName.Equals(ProcessProvider.NZB_DRONE_PROCESS_NAME, StringComparison.InvariantCultureIgnoreCase);
}
return false;
}
}
public RuntimeMode Mode
{
get
{
if (IsWindowsService)
{
return RuntimeMode.Service;
}
if (IsTray)
{
return RuntimeMode.Tray;
}
return RuntimeMode.Console;
}
}
public bool RestartPending { get; set; }
public string ExecutingApplication { get; }

Some files were not shown because too many files have changed in this diff Show more