diff --git a/.gitignore b/.gitignore index 9af1b3434..81d9e0a9e 100644 --- a/.gitignore +++ b/.gitignore @@ -44,6 +44,7 @@ BLToolkit.2010.sln.docstates UnitTests/BLToolkit.Linq.VisualState.xml UnitTests/Linq/UserDataProviders.txt !*.dll +*.ncrunchsolution !*.exe !*.pdb BLToolkit.2012.opensdf diff --git a/BLToolkit.2010.sln b/BLToolkit.2010.sln index 30277c4ab..783ea0a9b 100644 --- a/BLToolkit.2010.sln +++ b/BLToolkit.2010.sln @@ -149,6 +149,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.4.JointureAddOn", EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Extensions", "Extensions", "{218E3584-CDC7-4A77-AD1A-CF9FBE90F67F}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UnitTests.Regression", "UnitTests\UnitTests.Regression\UnitTests.Regression.csproj", "{74D1AF0E-C0AB-4A62-99A3-0975585760A5}" +EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuGet", "NuGet", "{4A9C0E31-8697-48BA-A46B-6A5EE78424D6}" ProjectSection(SolutionItems) = preProject NuGet\BLToolkit.DB2.nuspec = NuGet\BLToolkit.DB2.nuspec @@ -171,10 +173,12 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.CP.4", "Source\BL EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NorthwindDataService", "Demo\WebServices\NorthwindDataService\NorthwindDataService.csproj", "{87FB4F28-5DCC-4F21-B83E-59C85E1A7423}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.OracleManaged.4", "DataProviders\Oracle\BLToolkit.Data.DataProvider.OracleManaged.4.csproj", "{785CE174-0A91-465F-9E41-65E6E05A0EC9}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.OracleManaged.4", "DataProviders\Oracle\BLToolkit.Data.DataProvider.OracleManaged.4.csproj", "{61985B06-67FD-4941-B1B0-7F3794FD237C}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.DevartOracle.4", "DataProviders\DevartOraclePro\BLToolkit.Data.DataProvider.DevartOracle.4.csproj", "{CB303F0B-0AA3-4589-850A-95E985A09492}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.Generic.4", "DataProviders\Generic\BLToolkit.Data.DataProvider.Generic.4.csproj", "{6E7FE7FC-551F-4273-ACEB-72DC0D01120E}" +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug FW 3.5|Any CPU = Debug FW 3.5|Any CPU @@ -1283,7 +1287,6 @@ Global {7DAA2EBB-A724-498F-93BB-68966E2B738F}.Release|Any CPU.ActiveCfg = Debug|Any CPU {7DAA2EBB-A724-498F-93BB-68966E2B738F}.Release|Any CPU.Build.0 = Debug|Any CPU {7DAA2EBB-A724-498F-93BB-68966E2B738F}.Release|Mixed Platforms.ActiveCfg = Debug|Any CPU - {7DAA2EBB-A724-498F-93BB-68966E2B738F}.Release|Mixed Platforms.Build.0 = Debug|Any CPU {7DAA2EBB-A724-498F-93BB-68966E2B738F}.Release|Win32.ActiveCfg = Debug|Any CPU {7DAA2EBB-A724-498F-93BB-68966E2B738F}.Release|x64.ActiveCfg = Debug|Any CPU {7DAA2EBB-A724-498F-93BB-68966E2B738F}.Release|x86.ActiveCfg = Debug|Any CPU @@ -1764,6 +1767,46 @@ Global {9FD2722C-1E6C-4061-8AC0-32EE28808FC0}.Template|Win32.ActiveCfg = Release|Any CPU {9FD2722C-1E6C-4061-8AC0-32EE28808FC0}.Template|x64.ActiveCfg = Release|Any CPU {9FD2722C-1E6C-4061-8AC0-32EE28808FC0}.Template|x86.ActiveCfg = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug FW 3.5|Any CPU.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug FW 3.5|Mixed Platforms.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug FW 3.5|Win32.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug FW 3.5|x64.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug FW 3.5|x86.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug|Any CPU.Build.0 = Debug|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug|Win32.ActiveCfg = Debug|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug|x64.ActiveCfg = Debug|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Debug|x86.ActiveCfg = Debug|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.DebugMono|Any CPU.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.DebugMono|Any CPU.Build.0 = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.DebugMono|Mixed Platforms.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.DebugMono|Mixed Platforms.Build.0 = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.DebugMono|Win32.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.DebugMono|x64.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.DebugMono|x86.ActiveCfg = DebugMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Release|Any CPU.ActiveCfg = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Release|Any CPU.Build.0 = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Release|Mixed Platforms.Build.0 = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Release|Win32.ActiveCfg = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Release|x64.ActiveCfg = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Release|x86.ActiveCfg = Release|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.ReleaseMono|Any CPU.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.ReleaseMono|Any CPU.Build.0 = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.ReleaseMono|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.ReleaseMono|Mixed Platforms.Build.0 = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.ReleaseMono|Win32.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.ReleaseMono|x64.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.ReleaseMono|x86.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Template|Any CPU.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Template|Any CPU.Build.0 = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Template|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Template|Mixed Platforms.Build.0 = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Template|Win32.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Template|x64.ActiveCfg = ReleaseMono|Any CPU + {74D1AF0E-C0AB-4A62-99A3-0975585760A5}.Template|x86.ActiveCfg = ReleaseMono|Any CPU {0C325F5D-E50E-4340-8724-D29896CCC584}.Debug FW 3.5|Any CPU.ActiveCfg = Debug FW 3.5|Any CPU {0C325F5D-E50E-4340-8724-D29896CCC584}.Debug FW 3.5|Any CPU.Build.0 = Debug FW 3.5|Any CPU {0C325F5D-E50E-4340-8724-D29896CCC584}.Debug FW 3.5|Mixed Platforms.ActiveCfg = Debug FW 3.5|Any CPU @@ -1890,48 +1933,48 @@ Global {87FB4F28-5DCC-4F21-B83E-59C85E1A7423}.Template|Win32.ActiveCfg = Release|Any CPU {87FB4F28-5DCC-4F21-B83E-59C85E1A7423}.Template|x64.ActiveCfg = Release|Any CPU {87FB4F28-5DCC-4F21-B83E-59C85E1A7423}.Template|x86.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Any CPU.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Any CPU.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Mixed Platforms.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Mixed Platforms.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Win32.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|x64.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|x86.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Any CPU.Build.0 = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Win32.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|x64.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|x86.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Any CPU.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Any CPU.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Mixed Platforms.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Mixed Platforms.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Win32.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|x64.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|x86.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Any CPU.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Any CPU.Build.0 = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Mixed Platforms.Build.0 = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Win32.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|x64.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|x86.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Any CPU.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Any CPU.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Mixed Platforms.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Win32.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|x64.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|x86.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Any CPU.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Any CPU.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Mixed Platforms.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Win32.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|x64.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|x86.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Any CPU.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Any CPU.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Mixed Platforms.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Mixed Platforms.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Win32.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|x64.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|x86.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Any CPU.Build.0 = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Win32.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|x64.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|x86.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Any CPU.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Any CPU.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Mixed Platforms.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Mixed Platforms.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Win32.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|x64.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|x86.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Any CPU.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Any CPU.Build.0 = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Mixed Platforms.Build.0 = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Win32.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|x64.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|x86.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Any CPU.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Any CPU.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Mixed Platforms.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Win32.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|x64.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|x86.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Any CPU.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Any CPU.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Mixed Platforms.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Win32.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|x64.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|x86.ActiveCfg = ReleaseMono|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Debug FW 3.5|Any CPU.ActiveCfg = Debug|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Debug FW 3.5|Any CPU.Build.0 = Debug|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Debug FW 3.5|Mixed Platforms.ActiveCfg = Debug|Any CPU @@ -1974,20 +2017,60 @@ Global {CB303F0B-0AA3-4589-850A-95E985A09492}.Template|Win32.ActiveCfg = Release|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Template|x64.ActiveCfg = Release|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Template|x86.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Any CPU.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Any CPU.Build.0 = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Mixed Platforms.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Mixed Platforms.Build.0 = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Win32.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|x64.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|x86.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug|Any CPU.Build.0 = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug|Win32.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug|x64.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug|x86.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.DebugMono|Any CPU.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.DebugMono|Any CPU.Build.0 = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.DebugMono|Mixed Platforms.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.DebugMono|Mixed Platforms.Build.0 = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.DebugMono|Win32.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.DebugMono|x64.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.DebugMono|x86.ActiveCfg = Debug|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Release|Any CPU.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Release|Any CPU.Build.0 = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Release|Mixed Platforms.Build.0 = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Release|Win32.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Release|x64.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Release|x86.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.ReleaseMono|Any CPU.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.ReleaseMono|Any CPU.Build.0 = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.ReleaseMono|Mixed Platforms.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.ReleaseMono|Mixed Platforms.Build.0 = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.ReleaseMono|Win32.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.ReleaseMono|x64.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.ReleaseMono|x86.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|Any CPU.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|Any CPU.Build.0 = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|Mixed Platforms.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|Mixed Platforms.Build.0 = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|Win32.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|x64.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|x86.ActiveCfg = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection GlobalSection(NestedProjects) = preSolution {D527524F-EC92-465E-9CAE-86278121675A} = {2CC0A340-512C-4F0D-A5E6-87C042EE13B9} - {D11617AB-9F88-4C74-8ABD-F8580DB4B01B} = {2CC0A340-512C-4F0D-A5E6-87C042EE13B9} - {07997A18-86D3-47AC-A514-AB1B03E6AEC8} = {2CC0A340-512C-4F0D-A5E6-87C042EE13B9} {4FDE7340-F60F-49BC-86CD-756CCD26C92A} = {2CC0A340-512C-4F0D-A5E6-87C042EE13B9} {2BB4AD77-190F-4D7E-A83E-7B254A0A1FCA} = {2CC0A340-512C-4F0D-A5E6-87C042EE13B9} {6AE74A35-B337-4B17-8092-E1B98DEF06AF} = {2CC0A340-512C-4F0D-A5E6-87C042EE13B9} + {74D1AF0E-C0AB-4A62-99A3-0975585760A5} = {2CC0A340-512C-4F0D-A5E6-87C042EE13B9} {6E0C5565-F9A3-441C-9CB2-8B1878A800EF} = {C0306556-68F4-4DD5-95F2-AAFEE8FACDFA} {65FC918C-FF12-4C75-96F5-180B552989E5} = {C0306556-68F4-4DD5-95F2-AAFEE8FACDFA} - {F2B014F7-3807-4938-8F02-3CF8247C47DC} = {C0306556-68F4-4DD5-95F2-AAFEE8FACDFA} {86BF4F10-3606-4016-9919-84C3335813B6} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {C1F8C201-BBD9-44F4-884C-CFF8CC960B68} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {B1DEA25C-7667-471B-BBAD-64D017FDD104} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} @@ -1997,8 +2080,9 @@ Global {85E90F57-8DE1-4912-8414-28578F4D71CD} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {3E414663-B673-47A8-AB59-0E08FE43DA86} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {6CD8CC3D-643D-4D09-8660-A26085C44FBC} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} - {785CE174-0A91-465F-9E41-65E6E05A0EC9} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {CB303F0B-0AA3-4589-850A-95E985A09492} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} + {61985B06-67FD-4941-B1B0-7F3794FD237C} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {83C0070F-E639-4D65-B392-34F621165A1C} = {B75C60BF-F5B7-472E-A0A8-8A12DDDDAA7D} {0F3F166F-9927-4BC0-855F-ADB0D20218F1} = {B75C60BF-F5B7-472E-A0A8-8A12DDDDAA7D} {35E61C2A-2B8C-4AF4-AD21-353936581EF5} = {B75C60BF-F5B7-472E-A0A8-8A12DDDDAA7D} @@ -2021,8 +2105,6 @@ Global {87FB4F28-5DCC-4F21-B83E-59C85E1A7423} = {2F6B63C4-295A-433C-91CB-CAE4CADE6B8B} {FF377109-1931-499F-9346-449D259977F2} = {8A7F38C5-EF9A-410B-8539-A58879F3AA22} {34989C73-F82A-4905-9349-D0CF1419CD1C} = {8A7F38C5-EF9A-410B-8539-A58879F3AA22} - {308A4189-53AB-460D-B2B1-0EB4B9219654} = {8A7F38C5-EF9A-410B-8539-A58879F3AA22} - {8DA66999-005A-49AB-86A9-2C1F62905B50} = {8A7F38C5-EF9A-410B-8539-A58879F3AA22} {9FD2722C-1E6C-4061-8AC0-32EE28808FC0} = {218E3584-CDC7-4A77-AD1A-CF9FBE90F67F} EndGlobalSection EndGlobal diff --git a/BLToolkit.2012.sln b/BLToolkit.2012.sln index 291ff6288..af05f6e06 100644 --- a/BLToolkit.2012.sln +++ b/BLToolkit.2012.sln @@ -168,14 +168,22 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.CP.4", "Source\BL EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NorthwindDataService", "Demo\WebServices\NorthwindDataService\NorthwindDataService.csproj", "{87FB4F28-5DCC-4F21-B83E-59C85E1A7423}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.OracleManaged.4", "DataProviders\Oracle\BLToolkit.Data.DataProvider.OracleManaged.4.csproj", "{785CE174-0A91-465F-9E41-65E6E05A0EC9}" +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.OracleManaged.4", "DataProviders\Oracle\BLToolkit.Data.DataProvider.OracleManaged.4.csproj", "{61985B06-67FD-4941-B1B0-7F3794FD237C}" EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.DevartOracle.4", "DataProviders\DevartOraclePro\BLToolkit.Data.DataProvider.DevartOracle.4.csproj", "{CB303F0B-0AA3-4589-850A-95E985A09492}" EndProject +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.Generic.4", "DataProviders\Generic\BLToolkit.Data.DataProvider.Generic.4.csproj", "{6E7FE7FC-551F-4273-ACEB-72DC0D01120E}" +EndProject Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "UnitTests.Fluent", "UnitTests\Fluent\UnitTests.Fluent.csproj", "{527300F8-9F04-434C-8239-4FE5E174FF6B}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "BLToolkit.Data.DataProvider.Generic.4", "DataProviders\Generic\BLToolkit.Data.DataProvider.Generic.4.csproj", "{6E7FE7FC-551F-4273-ACEB-72DC0D01120E}" +<<<<<<< HEAD +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Examples.Cpp", "Examples\Cpp\Examples.Cpp.vcxproj", "{9D063CAA-4C44-4C5E-9C9E-74EFA4049FEC}" + ProjectSection(ProjectDependencies) = postProject + {0C325F5D-E50E-4340-8724-D29896CCC583} = {0C325F5D-E50E-4340-8724-D29896CCC583} + EndProjectSection EndProject +======= +>>>>>>> 53d1ceacdf65b20d099321f78348d626df085662 Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug FW 3.5|Any CPU = Debug FW 3.5|Any CPU @@ -1848,48 +1856,48 @@ Global {87FB4F28-5DCC-4F21-B83E-59C85E1A7423}.Template|Win32.ActiveCfg = Release|Any CPU {87FB4F28-5DCC-4F21-B83E-59C85E1A7423}.Template|x64.ActiveCfg = Release|Any CPU {87FB4F28-5DCC-4F21-B83E-59C85E1A7423}.Template|x86.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Any CPU.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Any CPU.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Mixed Platforms.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Mixed Platforms.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|Win32.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|x64.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug FW 3.5|x86.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Any CPU.Build.0 = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|Win32.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|x64.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Debug|x86.ActiveCfg = Debug|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Any CPU.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Any CPU.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Mixed Platforms.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Mixed Platforms.Build.0 = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|Win32.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|x64.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.DebugMono|x86.ActiveCfg = DebugMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Any CPU.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Any CPU.Build.0 = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Mixed Platforms.Build.0 = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|Win32.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|x64.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Release|x86.ActiveCfg = Release|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Any CPU.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Any CPU.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Mixed Platforms.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|Win32.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|x64.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.ReleaseMono|x86.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Any CPU.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Any CPU.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Mixed Platforms.Build.0 = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|Win32.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|x64.ActiveCfg = ReleaseMono|Any CPU - {785CE174-0A91-465F-9E41-65E6E05A0EC9}.Template|x86.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Any CPU.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Any CPU.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Mixed Platforms.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Mixed Platforms.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|Win32.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|x64.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug FW 3.5|x86.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Any CPU.Build.0 = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|Win32.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|x64.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Debug|x86.ActiveCfg = Debug|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Any CPU.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Any CPU.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Mixed Platforms.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Mixed Platforms.Build.0 = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|Win32.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|x64.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.DebugMono|x86.ActiveCfg = DebugMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Any CPU.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Any CPU.Build.0 = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Mixed Platforms.Build.0 = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|Win32.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|x64.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Release|x86.ActiveCfg = Release|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Any CPU.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Any CPU.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Mixed Platforms.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|Win32.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|x64.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.ReleaseMono|x86.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Any CPU.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Any CPU.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Mixed Platforms.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Mixed Platforms.Build.0 = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|Win32.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|x64.ActiveCfg = ReleaseMono|Any CPU + {61985B06-67FD-4941-B1B0-7F3794FD237C}.Template|x86.ActiveCfg = ReleaseMono|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Debug FW 3.5|Any CPU.ActiveCfg = Debug|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Debug FW 3.5|Any CPU.Build.0 = Debug|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Debug FW 3.5|Mixed Platforms.ActiveCfg = Debug|Any CPU @@ -1932,48 +1940,6 @@ Global {CB303F0B-0AA3-4589-850A-95E985A09492}.Template|Win32.ActiveCfg = Release|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Template|x64.ActiveCfg = Release|Any CPU {CB303F0B-0AA3-4589-850A-95E985A09492}.Template|x86.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Any CPU.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Any CPU.Build.0 = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Mixed Platforms.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Mixed Platforms.Build.0 = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Win32.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|x64.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|x86.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Any CPU.Build.0 = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Win32.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|x64.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|x86.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Any CPU.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Any CPU.Build.0 = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Mixed Platforms.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Mixed Platforms.Build.0 = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Win32.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|x64.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|x86.ActiveCfg = Debug|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Any CPU.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Any CPU.Build.0 = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Mixed Platforms.Build.0 = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Win32.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|x64.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|x86.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Any CPU.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Any CPU.Build.0 = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Mixed Platforms.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Mixed Platforms.Build.0 = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Win32.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|x64.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|x86.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Any CPU.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Any CPU.Build.0 = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Mixed Platforms.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Mixed Platforms.Build.0 = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Win32.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|x64.ActiveCfg = Release|Any CPU - {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|x86.ActiveCfg = Release|Any CPU {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Any CPU.ActiveCfg = Debug|Any CPU {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Any CPU.Build.0 = Debug|Any CPU {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Debug FW 3.5|Mixed Platforms.ActiveCfg = Debug|Any CPU @@ -2015,7 +1981,49 @@ Global {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|Mixed Platforms.Build.0 = Release|Any CPU {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|Win32.ActiveCfg = Release|Any CPU {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|x64.ActiveCfg = Release|Any CPU - {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|x86.ActiveCfg = Release|Any CPU + {6E7FE7FC-551F-4273-ACEB-72DC0D01120E}.Template|x86.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Any CPU.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Any CPU.Build.0 = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Mixed Platforms.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Mixed Platforms.Build.0 = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|Win32.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|x64.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug FW 3.5|x86.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Any CPU.Build.0 = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|Win32.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|x64.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Debug|x86.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Any CPU.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Any CPU.Build.0 = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Mixed Platforms.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Mixed Platforms.Build.0 = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|Win32.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|x64.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.DebugMono|x86.ActiveCfg = Debug|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Any CPU.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Any CPU.Build.0 = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Mixed Platforms.Build.0 = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|Win32.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|x64.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Release|x86.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Any CPU.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Any CPU.Build.0 = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Mixed Platforms.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Mixed Platforms.Build.0 = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|Win32.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|x64.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.ReleaseMono|x86.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Any CPU.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Any CPU.Build.0 = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Mixed Platforms.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Mixed Platforms.Build.0 = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|Win32.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|x64.ActiveCfg = Release|Any CPU + {527300F8-9F04-434C-8239-4FE5E174FF6B}.Template|x86.ActiveCfg = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -2040,7 +2048,7 @@ Global {85E90F57-8DE1-4912-8414-28578F4D71CD} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {3E414663-B673-47A8-AB59-0E08FE43DA86} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {6CD8CC3D-643D-4D09-8660-A26085C44FBC} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} - {785CE174-0A91-465F-9E41-65E6E05A0EC9} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} + {61985B06-67FD-4941-B1B0-7F3794FD237C} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {CB303F0B-0AA3-4589-850A-95E985A09492} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {6E7FE7FC-551F-4273-ACEB-72DC0D01120E} = {E6CE0ECB-3373-4DC0-98CB-F4E9DC2293C4} {83C0070F-E639-4D65-B392-34F621165A1C} = {B75C60BF-F5B7-472E-A0A8-8A12DDDDAA7D} diff --git a/Data/BLToolkitData.mdb b/Data/BLToolkitData.mdb index da3924256..b46db5de1 100644 Binary files a/Data/BLToolkitData.mdb and b/Data/BLToolkitData.mdb differ diff --git a/Data/BLToolkitData.sdf b/Data/BLToolkitData.sdf index 1fc88217a..9a0eaf777 100644 Binary files a/Data/BLToolkitData.sdf and b/Data/BLToolkitData.sdf differ diff --git a/Data/BLToolkitData.sqlite b/Data/BLToolkitData.sqlite index 8e3300157..76fd5a710 100644 Binary files a/Data/BLToolkitData.sqlite and b/Data/BLToolkitData.sqlite differ diff --git a/DataProviders/DevartOraclePro/app.config b/DataProviders/DevartOraclePro/app.config index a6ffc7cdb..48410298d 100644 --- a/DataProviders/DevartOraclePro/app.config +++ b/DataProviders/DevartOraclePro/app.config @@ -1,8 +1,8 @@ - - - - - - - + + + + + + + \ No newline at end of file diff --git a/DataProviders/DevartOraclePro/packages.config b/DataProviders/DevartOraclePro/packages.config index 17ca0f170..cb4fa1177 100644 --- a/DataProviders/DevartOraclePro/packages.config +++ b/DataProviders/DevartOraclePro/packages.config @@ -1,4 +1,4 @@ - - - + + + \ No newline at end of file diff --git a/DataProviders/Firebird/BLToolkit.Data.DataProvider.Firebird.4.csproj b/DataProviders/Firebird/BLToolkit.Data.DataProvider.Firebird.4.csproj index 3a267a231..a786d4161 100644 --- a/DataProviders/Firebird/BLToolkit.Data.DataProvider.Firebird.4.csproj +++ b/DataProviders/Firebird/BLToolkit.Data.DataProvider.Firebird.4.csproj @@ -130,7 +130,9 @@ - + + Designer + + --> \ No newline at end of file diff --git a/Demo/Partial.Trust/Asp.Net/Partial.Trust.Asp.Net.csproj b/Demo/Partial.Trust/Asp.Net/Partial.Trust.Asp.Net.csproj index 7f83922f8..374d4007a 100644 --- a/Demo/Partial.Trust/Asp.Net/Partial.Trust.Asp.Net.csproj +++ b/Demo/Partial.Trust/Asp.Net/Partial.Trust.Asp.Net.csproj @@ -19,6 +19,10 @@ false + + + + true @@ -137,7 +141,7 @@ False True - 59174 + 55400 / diff --git a/Demo/WebServices/NorthwindDataService/NorthwindDataService.csproj b/Demo/WebServices/NorthwindDataService/NorthwindDataService.csproj index c479a37f2..daf0f78cf 100644 --- a/Demo/WebServices/NorthwindDataService/NorthwindDataService.csproj +++ b/Demo/WebServices/NorthwindDataService/NorthwindDataService.csproj @@ -19,6 +19,10 @@ 4.0 + + + + true @@ -126,7 +130,7 @@ False True - 58025 + 55407 / diff --git a/Demo/WebServices/Server/Server.csproj b/Demo/WebServices/Server/Server.csproj index f32bb2ddb..d67d4300b 100644 --- a/Demo/WebServices/Server/Server.csproj +++ b/Demo/WebServices/Server/Server.csproj @@ -18,14 +18,15 @@ OnOutputUpdated - 4.0 + 3.5 + false - - - - + + + + true @@ -142,7 +143,7 @@ False False - 59179 + 12583 / diff --git a/Examples/Cpp/Examples.Cpp.vcxproj b/Examples/Cpp/Examples.Cpp.vcxproj index 7b0a5d997..80209ea41 100644 --- a/Examples/Cpp/Examples.Cpp.vcxproj +++ b/Examples/Cpp/Examples.Cpp.vcxproj @@ -11,7 +11,7 @@ - {9D063CAA-4C44-4C5E-9C9E-74EFA4049FEC} + {FF377109-1931-499F-9346-449D259977F2} v4.5 ManagedCProj ExamplesCpp diff --git a/Extensions/JointureAddOn/BLToolkit.4.JointureAddOn.csproj b/Extensions/JointureAddOn/BLToolkit.4.JointureAddOn.csproj index 1d59dff7c..de23570d8 100644 --- a/Extensions/JointureAddOn/BLToolkit.4.JointureAddOn.csproj +++ b/Extensions/JointureAddOn/BLToolkit.4.JointureAddOn.csproj @@ -1,86 +1,84 @@ - - - - Debug - AnyCPU - 8.0.30703 - 2.0 - {9FD2722C-1E6C-4061-8AC0-32EE28808FC0} - Library - Properties - BLToolkit - BLToolkit.4.JointureAddOn - v4.0 - 512 - - - true - full - false - bin\Debug\ - TRACE;DEBUG;FW4;OVERRIDETOSTRING; - prompt - 4 - - - pdbonly - true - bin\Release\ - TRACE - prompt - 4 - - - - False - ..\..\packages\Castle.Core.3.2.1\lib\net40-client\Castle.Core.dll - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - {0C325F5D-E50E-4340-8724-D29896CCC583} - BLToolkit.4 - - - - - - + + + + Debug + AnyCPU + 8.0.30703 + 2.0 + {9FD2722C-1E6C-4061-8AC0-32EE28808FC0} + Library + Properties + BLToolkit + BLToolkit.4.JointureAddOn + v4.0 + 512 + + + true + full + false + bin\Debug\ + TRACE;DEBUG;FW4;OVERRIDETOSTRING; + prompt + 4 + + + pdbonly + true + bin\Release\ + TRACE + prompt + 4 + + + + False + ..\..\packages\Castle.Core.3.2.1\lib\net40-client\Castle.Core.dll + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + {0C325F5D-E50E-4340-8724-D29896CCC583} + BLToolkit.4 + + + + + + + --> \ No newline at end of file diff --git a/Extensions/JointureAddOn/DataAccess/FullSqlQueryBase.cs b/Extensions/JointureAddOn/DataAccess/FullSqlQueryBase.cs deleted file mode 100644 index 0ba8e847a..000000000 --- a/Extensions/JointureAddOn/DataAccess/FullSqlQueryBase.cs +++ /dev/null @@ -1,280 +0,0 @@ -using System; -using System.Collections; -using System.Linq; -using System.Reflection; -using System.Text; -using BLToolkit.Aspects; -using BLToolkit.Data; -using BLToolkit.Data.DataProvider; -using BLToolkit.Mapping; -using BLToolkit.TypeBuilder; - -namespace BLToolkit.DataAccess -{ - public abstract class FullSqlQueryBase : SqlQueryBase - { - private readonly bool _ignoreLazyLoad; - - #region Constructors - - protected FullSqlQueryBase(DbManager dbManager, bool ignoreLazyLoad = false, MappingOrder mappingOrder = MappingOrder.ByColumnIndex) - : base(dbManager) - { - dbManager.MappingSchema = new FullMappingSchema(dbManager, mappingOrder: mappingOrder); - - _ignoreLazyLoad = ignoreLazyLoad; - } - - #endregion - - #region Overrides - - [NoInterception] - protected override SqlQueryInfo CreateSqlText(DbManager db, Type type, string actionName) - { - switch (actionName) - { - case "SelectByKey": - return CreateSelectFullByKeySqlText(db, type); - case "SelectAll": - return CreateSelectAllFullSqlText(db, type); - default: - return base.CreateSqlText(db, type, actionName); - } - } - - protected override void AppendTableName(StringBuilder sb, DbManager db, Type type) - { - var database = GetDatabaseName(type); - var owner = GetOwnerName(type); - var name = base.GetTableName(type); - - db.DataProvider.CreateSqlProvider().BuildTableName(sb, - database == null ? null : db.DataProvider.Convert(database, ConvertType.NameToDatabase).ToString(), - owner == null ? null : db.DataProvider.Convert(owner, ConvertType.NameToOwner).ToString(), - name == null ? null : db.DataProvider.Convert(name, ConvertType.NameToQueryTable).ToString()); - - //TODO Override OracleSqlProvider in order to avoid this mess... - string alias = GetTableName(type); - sb.Append(" " + alias); - sb.AppendLine(); - } - - protected override string GetTableName(Type type) - { - //bool isSet; - //return MappingSchema.MetadataProvider.GetTableName(type, Extensions, out isSet); - - return type.Name; - } - - #endregion - - private SqlQueryInfo CreateSelectAllFullSqlText(DbManager db, Type type) - { - var sb = new StringBuilder(); - var query = new FullSqlQueryInfo(); - - sb.Append("SELECT\n"); - - var mainMapper = (FullObjectMapper)db.MappingSchema.GetObjectMapper(type); ; - BuildSelectSQL(mainMapper, sb, db); - - sb.Remove(sb.Length - 2, 1); - - sb.Append("FROM\n\t"); - - AppendTableName(sb, db, type); - - AppendJoinTableName(sb, db, type); - - query.QueryText = sb.ToString(); - - return query; - } - - private SqlQueryInfo CreateSelectFullByKeySqlText(DbManager db, Type type) - { - var sb = new StringBuilder(); - var query = new FullSqlQueryInfo(); - - sb.Append("SELECT\n"); - - var mainMapper = (FullObjectMapper)db.MappingSchema.GetObjectMapper(type); - - BuildSelectSQL(mainMapper, sb, db); - - sb.Remove(sb.Length - 2, 1); - - sb.Append("FROM\n\t"); - - AppendTableName(sb, db, type); - - AppendJoinTableName(sb, db, type); - - AddWherePK(db, query, sb, -1, mainMapper); - - query.QueryText = sb.ToString(); - - return query; - } - - private void BuildSelectSQL(IPropertiesMapping mapper, StringBuilder sb, DbManager db) - { - foreach (IMapper mapField in mapper.PropertiesMapping) - { - if (mapField is ValueMapper) - sb.AppendFormat("\t{0}.{1},\n", ((IObjectMapper)mapper).PropertyType.Name, - db.DataProvider.Convert(((ValueMapper)mapField).ColumnName, ConvertType.NameToQueryField)); - else if (mapField is IPropertiesMapping) - { - var propertiesMapping = (IPropertiesMapping)mapField; - var cel = propertiesMapping.ParentMapping; - while (cel != null) - { - // To avoid recursion dont take in account types already loaded. - if (((IMapper)cel).PropertyType == mapField.PropertyType) - continue; - cel = cel.ParentMapping; - } - var objectMapper = (IObjectMapper)mapField; - if (!objectMapper.IsLazy) - BuildSelectSQL(propertiesMapping, sb, db); - } - else - throw new NotImplementedException(mapField.GetType() + " is not yet implemented."); - } - } - - private void AppendJoinTableName(StringBuilder sb, DbManager db, Type type) - { - string parentName = GetTableName(type); - - foreach (PropertyInfo prop in type.GetProperties()) - { - bool isCollection = prop.PropertyType.GetInterfaces().ToList().Contains(typeof(IList)); - Type listElementType = null; - if (isCollection) - { - listElementType = FullMappingSchema.GetGenericType(prop.PropertyType); - } - - if (!_ignoreLazyLoad) - { - object[] lazy = prop.GetCustomAttributes(typeof(LazyInstanceAttribute), true); - if (lazy.Length > 0) - { - if (((LazyInstanceAttribute)lazy[0]).IsLazy) - { - continue; - } - } - } - - object[] attribs = prop.GetCustomAttributes(typeof(AssociationAttribute), true); - if (attribs.Length > 0) - { - var assocAttrib = (AssociationAttribute)attribs[0]; - - PropertyInfo parentField = type.GetProperty(assocAttrib.ThisKey); - PropertyInfo childField = prop.PropertyType.GetProperty(assocAttrib.OtherKey); - if (isCollection) - { - childField = listElementType.GetProperty(assocAttrib.OtherKey); - //FullMappingSchema.GetColumnFromProperty(listElementType, associationAttribute.OtherKey); - } - - object[] parentFieldAttributes = parentField.GetCustomAttributes(typeof(MapFieldAttribute), true); - string parentDbField = parentFieldAttributes.Length > 0 - ? ((MapFieldAttribute)parentFieldAttributes[0]).MapName - : assocAttrib.ThisKey; - - object[] childFieldAttributes = childField.GetCustomAttributes(typeof(MapFieldAttribute), true); - string childDbField = childFieldAttributes.Length > 0 - ? ((MapFieldAttribute)childFieldAttributes[0]).MapName - : assocAttrib.OtherKey; - - - string childDatabase = isCollection - ? GetDatabaseName(listElementType) - : GetDatabaseName(prop.PropertyType); - - string childOwner = isCollection ? base.GetOwnerName(listElementType) : base.GetOwnerName(prop.PropertyType); - string childName = isCollection ? base.GetTableName(listElementType) : base.GetTableName(prop.PropertyType); - string childAlias = isCollection ? GetTableName(listElementType) : GetTableName(prop.PropertyType); - - StringBuilder childFullName = db.DataProvider.CreateSqlProvider().BuildTableName( - new StringBuilder(), - childDatabase == null - ? null - : db.DataProvider.Convert(childDatabase, ConvertType.NameToDatabase).ToString(), - childOwner == null - ? null - : db.DataProvider.Convert(childOwner, ConvertType.NameToOwner).ToString(), - childName == null - ? null - : db.DataProvider.Convert(childName, ConvertType.NameToQueryTable).ToString()); - - sb.AppendFormat("\tINNER JOIN {0} {1} ON {2}.{3}={4}.{5}\n", - childFullName, - childAlias, - parentName, - parentDbField, - childAlias, - childDbField - ); - - AppendJoinTableName(sb, db, isCollection ? listElementType : prop.PropertyType); - } - } - - sb.AppendLine(); - - //SELECT - // ARTIST2.ID_ARTIST, - // ARTIST2.ARTIST, - // TRACK.ID_TRACK, - // TRACK.TRACK, - // TRACK.ID_ARTIST, - // ARTIST.ID_ARTIST, - // ARTIST.ARTIST - //FROM - // PITAFR01.ARTIST ARTIST2 - // INNER JOIN PITAFR01.TRACK TRACK ON ARTIST2.ID_ARTIST=TRACK.ID_ARTIST - // INNER JOIN PITAFR01.ARTIST ARTIST ON TRACK.ID_ARTIST=ARTIST.ID_ARTIST - //WHERE - // ARTIST2.ID_ARTIST = 2566 - } - - private void AddWherePK(DbManager db, SqlQueryInfo query, StringBuilder sb, int nParameter, - FullObjectMapper mapper) - { - sb.Append("WHERE\n"); - - foreach (IMapper mm in mapper.PropertiesMapping) - { - if (mm is ValueMapper && mm.DataReaderIndex == mapper.DataReaderIndex) - { - var valueMapper = (ValueMapper)mm; - - string tableAlias = mapper.PropertyType.Name; - - //mm.Name = ID_TRACK - SqlQueryParameterInfo p = query.AddParameter( - db.DataProvider.Convert(valueMapper.ColumnName + "_W", ConvertType.NameToQueryParameter). - ToString(), - valueMapper.ColumnName); - - sb.AppendFormat("\t{0}.{1} = ", tableAlias, db.DataProvider.Convert(p.FieldName, ConvertType.NameToQueryField)); - - if (nParameter < 0) - sb.AppendFormat("{0} AND\n", p.ParameterName); - else - sb.AppendFormat("{{{0}}} AND\n", nParameter++); - } - } - - sb.Remove(sb.Length - 5, 5); - } - } -} \ No newline at end of file diff --git a/Extensions/JointureAddOn/Mapping/DataBindingFactory.cs b/Extensions/JointureAddOn/Mapping/DataBindingFactory.cs deleted file mode 100644 index 309b5f0d2..000000000 --- a/Extensions/JointureAddOn/Mapping/DataBindingFactory.cs +++ /dev/null @@ -1,69 +0,0 @@ -using System; -using System.ComponentModel; -using Castle.DynamicProxy; - -namespace BLToolkit.Mapping -{ - public static class DataBindingFactory - { - private static readonly ProxyGenerator ProxyGenerator = new ProxyGenerator(); - - public static T Create() - { - return (T) Create(typeof (T)); - } - - public static object Create(Type type) - { - return ProxyGenerator.CreateClassProxy(type, new[] - { - typeof (INotifyPropertyChanged), - typeof (IMarkerInterface) - }, new NotifyPropertyChangedInterceptor(type.FullName)); - } - - public interface IMarkerInterface - { - string TypeName { get; } - } - - public class NotifyPropertyChangedInterceptor : IInterceptor - { - private readonly string typeName; - private PropertyChangedEventHandler subscribers = delegate { }; - - public NotifyPropertyChangedInterceptor(string typeName) - { - this.typeName = typeName; - } - - public void Intercept(IInvocation invocation) - { - if (invocation.Method.DeclaringType == typeof (IMarkerInterface)) - { - invocation.ReturnValue = typeName; - return; - } - if (invocation.Method.DeclaringType == typeof (INotifyPropertyChanged)) - { - var propertyChangedEventHandler = (PropertyChangedEventHandler) invocation.Arguments[0]; - if (invocation.Method.Name.StartsWith("add_")) - { - subscribers += propertyChangedEventHandler; - } - else - { - subscribers -= propertyChangedEventHandler; - } - return; - } - invocation.Proceed(); - if (invocation.Method.Name.StartsWith("set_")) - { - var propertyName = invocation.Method.Name.Substring(4); - subscribers(invocation.InvocationTarget, new PropertyChangedEventArgs(propertyName)); - } - } - } - } -} \ No newline at end of file diff --git a/Extensions/JointureAddOn/Mapping/MappingOrder.cs b/Extensions/JointureAddOn/Mapping/MappingOrder.cs deleted file mode 100644 index 95a83591c..000000000 --- a/Extensions/JointureAddOn/Mapping/MappingOrder.cs +++ /dev/null @@ -1,8 +0,0 @@ -namespace BLToolkit.Mapping -{ - public enum MappingOrder - { - ByColumnName, - ByColumnIndex, - } -} \ No newline at end of file diff --git a/Extensions/JointureAddOn/Reflection/FullInitContext.cs b/Extensions/JointureAddOn/Reflection/FullInitContext.cs deleted file mode 100644 index 7de393862..000000000 --- a/Extensions/JointureAddOn/Reflection/FullInitContext.cs +++ /dev/null @@ -1,38 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Diagnostics; - -using BLToolkit.Mapping; - -namespace BLToolkit.Reflection -{ - public class FullInitContext - { - public object[] MemberParameters { get; set; } - public object[] Parameters { get; set; } - public bool IsInternal { get; set; } - public bool IsLazyInstance { get; set; } - public object Parent { get; set; } - public object SourceObject { get; set; } - public FullObjectMapper ObjectMapper { get; set; } - public MappingSchema MappingSchema { get; set; } - public bool IsSource { get; set; } - public bool StopMapping { get; set; } - public IMapDataSource DataSource { get; set; } - - private Dictionary _items; - public Dictionary Items - { - [DebuggerStepThrough] - get { return _items ?? (_items = new Dictionary()); } - } - - public bool IsDestination - { - [DebuggerStepThrough] - get { return !IsSource; } - [DebuggerStepThrough] - set { IsSource = !value; } - } - } -} diff --git a/Redist/Castle/Castle.Core.dll b/Redist/Castle/Castle.Core.dll deleted file mode 100644 index 2c8811072..000000000 Binary files a/Redist/Castle/Castle.Core.dll and /dev/null differ diff --git a/Redist/Castle/Castle.Core.xml b/Redist/Castle/Castle.Core.xml deleted file mode 100644 index 448fd69a0..000000000 --- a/Redist/Castle/Castle.Core.xml +++ /dev/null @@ -1,4927 +0,0 @@ - - - - Castle.Core - - - - - Assignes a specific dictionary key. - - - - - Defines the contract for customizing dictionary access. - - - - - Determines relative order to apply related behaviors. - - - - - Determines relative order to apply related behaviors. - - - - - Defines the contract for updating dictionary values. - - - - - Sets the stored dictionary value. - - The dictionary adapter. - The key. - The stored value. - The property. - true if the property should be stored. - - - - Defines the contract for building s. - - - - - Builds the dictionary behaviors. - - - - - - Abstract adapter for the support - needed by the - - - - - Adds an element with the provided key and value to the object. - - The to use as the key of the element to add. - The to use as the value of the element to add. - An element with the same key already exists in the object. - key is null. - The is read-only.-or- The has a fixed size. - - - - Removes all elements from the object. - - The object is read-only. - - - - Determines whether the object contains an element with the specified key. - - The key to locate in the object. - - true if the contains an element with the key; otherwise, false. - - key is null. - - - - Returns an object for the object. - - - An object for the object. - - - - - Removes the element with the specified key from the object. - - The key of the element to remove. - The object is read-only.-or- The has a fixed size. - key is null. - - - - Copies the elements of the to an , starting at a particular index. - - The one-dimensional that is the destination of the elements copied from . The must have zero-based indexing. - The zero-based index in array at which copying begins. - array is null. - The type of the source cannot be cast automatically to the type of the destination array. - index is less than zero. - array is multidimensional.-or- index is equal to or greater than the length of array.-or- The number of elements in the source is greater than the available space from index to the end of the destination array. - - - - Returns an enumerator that iterates through a collection. - - - An object that can be used to iterate through the collection. - - - - - Gets a value indicating whether the object has a fixed size. - - - true if the object has a fixed size; otherwise, false. - - - - Gets a value indicating whether the object is read-only. - - - true if the object is read-only; otherwise, false. - - - - Gets an object containing the keys of the object. - - - An object containing the keys of the object. - - - - Gets an object containing the values in the object. - - - An object containing the values in the object. - - - - Gets or sets the with the specified key. - - - - - - Gets the number of elements contained in the . - - - The number of elements contained in the . - - - - Gets a value indicating whether access to the is synchronized (thread safe). - - - true if access to the is synchronized (thread safe); otherwise, false. - - - - Gets an object that can be used to synchronize access to the . - - - An object that can be used to synchronize access to the . - - - - Constant to use when making assembly internals visible to Castle.Core - [assembly: InternalsVisibleTo(CoreInternalsVisible.ToCastleCore)] - - - - - Constant to use when making assembly internals visible to proxy types generated by DynamicProxy. Required when proxying internal types. - [assembly: InternalsVisibleTo(CoreInternalsVisible.ToDynamicProxyGenAssembly2)] - - - - - Abstract implementation of . - - - - - Conract for traversing a . - - - - - Identifies a property should be represented as a nested component. - - - - - Defines the contract for building typed dictionary keys. - - - - - Builds the specified key. - - The dictionary adapter. - The current key. - The property. - The updated key - - - - Defines the contract for retrieving dictionary values. - - - - - Gets the effective dictionary value. - - The dictionary adapter. - The key. - The stored value. - The property. - true if return only existing. - The effective property value. - - - - Applies no prefix. - - - - - Gets or sets the prefix. - - The prefix. - - - - Identifies the dictionary adapter types. - - - - - Identifies an interface or property to be pre-feteched. - - - - - Instructs fetching to occur. - - - - - Instructs fetching according to - - - - - - Gets whether or not fetching should occur. - - - - - Assigns a property to a group. - - - - - Constructs a group assignment. - - The group name. - - - - Constructs a group assignment. - - The group name. - - - - Gets the group the property is assigned to. - - - - - Assigns a specific dictionary key. - - - - - Initializes a new instance of the class. - - The key. - - - - Initializes a new instance of the class. - - The compound key. - - - - Assigns a prefix to the keyed properties of an interface. - - - - - Initializes a default instance of the class. - - - - - Initializes a new instance of the class. - - The prefix for the keyed properties of the interface. - - - - Gets the prefix key added to the properties of the interface. - - - - - Substitutes part of key with another string. - - - - - Initializes a new instance of the class. - - The old value. - The new value. - - - - Requests support for multi-level editing. - - - - - Contract for dictionary initialization. - - - - - Performs any initialization of the - - The dictionary adapter. - The dictionary behaviors. - - - - Generates a new GUID on demand. - - - - - Support for on-demand value resolution. - - - - - Suppress property change notifications. - - - - - Provides simple string formatting from existing properties. - - - - - Gets the string format. - - - - - Gets the format properties. - - - - - Identifies a property should be represented as a delimited string value. - - - - - Gets the separator. - - - - - Converts all properties to strings. - - - - - Gets or sets the format. - - The format. - - - - Suppress property change notifications. - - - - - Contract for property descriptor initialization. - - - - - Performs any initialization of the - - The property descriptor. - The property behaviors. - - - - Assigns a prefix to the keyed properties using the interface name. - - - - - Manages conversion between property values. - - - - - Initializes a new instance of the class. - - The converter. - - - - Gets the effective dictionary value. - - The dictionary adapter. - The key. - The stored value. - The property. - true if return only existing. - The effective property value. - - - - - - - - - Contract for creating additional Dictionary adapters. - - - - - Contract for manipulating the Dictionary adapter. - - - - - Contract for editing the Dictionary adapter. - - - - - Contract for managing Dictionary adapter notifications. - - - - - Contract for validating Dictionary adapter. - - - - - Uses Reflection.Emit to expose the properties of a dictionary - through a dynamic implementation of a typed interface. - - - - - Defines the contract for building typed dictionary adapters. - - - - - Gets a typed adapter bound to the . - - The typed interface. - The underlying source of properties. - An implementation of the typed interface bound to the dictionary. - - The type represented by T must be an interface with properties. - - - - - Gets a typed adapter bound to the . - - The typed interface. - The underlying source of properties. - An implementation of the typed interface bound to the dictionary. - - The type represented by T must be an interface with properties. - - - - - Gets a typed adapter bound to the . - - The typed interface. - The underlying source of properties. - The property descriptor. - An implementation of the typed interface bound to the dictionary. - - The type represented by T must be an interface with properties. - - - - - Gets a typed adapter bound to the . - - The typed interface. - The underlying source of properties. - An implementation of the typed interface bound to the namedValues. - - The type represented by T must be an interface with properties. - - - - - Gets a typed adapter bound to the . - - The typed interface. - The underlying source of properties. - An implementation of the typed interface bound to the namedValues. - - The type represented by T must be an interface with properties. - - - - - Gets a typed adapter bound to the . - - The typed interface. - The underlying source of properties. - An implementation of the typed interface bound to the xpath navigable. - - The type represented by T must be an interface with properties. - - - - - Gets a typed adapter bound to the . - - The typed interface. - The underlying source of properties. - An implementation of the typed interface bound to the xpath navigable. - - The type represented by T must be an interface with properties. - - - - - Gets the associated with the type. - - The typed interface. - The adapter meta-data. - - - - Gets the associated with the type. - - The typed interface. - The property descriptor. - The adapter meta-data. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Describes a dictionary property. - - - - - Initializes an empty class. - - - - - Initializes a new instance of the class. - - The property. - The property behaviors. - - - - Copies an existinginstance of the class. - - - - - - - Gets the key. - - The dictionary adapter. - The key. - The descriptor. - - - - - Adds the key builder. - - The builder. - - - - Adds the key builders. - - The builders. - - - - Copies the key builders to the other - - - - - - - Copies the selected key builders to the other - - - - - - - - Gets the property value. - - The dictionary adapter. - The key. - The stored value. - The descriptor. - true if return only existing. - - - - - Adds the dictionary getter. - - The getter. - - - - Adds the dictionary getters. - - The getters. - - - - Copies the property getters to the other - - - - - - - Copies the selected property getters to the other - - - - - - - - Sets the property value. - - The dictionary adapter. - The key. - The value. - The descriptor. - - - - - Adds the dictionary setter. - - The setter. - - - - Adds the dictionary setters. - - The setters. - - - - Copies the property setters to the other - - - - - - - Copies the selected property setters to the other - - - - - - - - Adds the behaviors. - - - - - - - Adds the behaviors. - - - - - - - Adds the behaviors from the builders. - - - - - - - Copies the behaviors to the other - - - - - - - Copies the behaviors to the other - - - - - - - - - - - - - Gets the property name. - - - - - Gets the property type. - - - - - Gets the property. - - The property. - - - - Returns true if the property is dynamic. - - - - - Gets additional state. - - - - - Determines if property should be fetched. - - - - - Determines if notifications should occur. - - - - - Gets the property behaviors. - - - - - Gets the type converter. - - The type converter. - - - - Gets the key builders. - - The key builders. - - - - Gets the setter. - - The setter. - - - - Gets the getter. - - The getter. - - - - Adds the dictionary initializers. - - The initializers. - - - - Adds the dictionary initializers. - - The initializers. - - - - Copies the initializers to the other - - - - - - - Copies the filtered initializers to the other - - - - - - - - Adds the dictionary meta-data initializers. - - The meta-data initializers. - - - - Adds the dictionary meta-data initializers. - - The meta-data initializers. - - - - Copies the meta-initializers to the other - - - - - - - Copies the filtered meta-initializers to the other - - - - - - - - Gets the initializers. - - The initializers. - - - - Gets the meta-data initializers. - - The meta-data initializers. - - - - Contract for dictionary meta-data initialization. - - - - - Performs any initialization of the dictionary adapter meta-data. - - The dictionary adapter factory. - The dictionary adapter meta. - - - - - Contract for dictionary validation. - - - - - Determines if is valid. - - The dictionary adapter. - true if valid. - - - - Validates the . - - The dictionary adapter. - The error summary information. - - - - Validates the for a property. - - The dictionary adapter. - The property to validate. - The property summary information. - - - - Invalidates any results cached by the validator. - - The dictionary adapter. - - - - - - - - - Initializes a new instance of the class. - - The name values. - - - - Determines whether the object contains an element with the specified key. - - The key to locate in the object. - - true if the contains an element with the key; otherwise, false. - - key is null. - - - - Adapts the specified name values. - - The name values. - - - - - Gets a value indicating whether the object is read-only. - - - true if the object is read-only; otherwise, false. - - - - Gets or sets the with the specified key. - - - - - - Helper class for retrieving attributes. - - - - - Gets the attribute. - - The member. - The member attribute. - - - - Gets the attributes. Does not consider inherited attributes! - - The member. - The member attributes. - - - - Gets the type attribute. - - The type. - The type attribute. - - - - Gets the type attributes. - - The type. - The type attributes. - - - - Gets the type converter. - - The member. - - - - - Gets the attribute. - - The member. - The member attribute. - - - - Contract for typed dynamic value resolution. - - - - - - Contract for dynamic value resolution. - - - - - Encapsulates an invocation of a proxied method. - - - - - Overrides the value of an argument at the given with the - new provided. - - - This method accepts an , however the value provided must be compatible - with the type of the argument defined on the method, otherwise an exception will be thrown. - - The index of the argument to override. - The new value for the argument. - - - - Gets the value of the argument at the specified . - - The index. - The value of the argument at the specified . - - - - Returns the concrete instantiation of the on the proxy, with any generic - parameters bound to real types. - - - The concrete instantiation of the on the proxy, or the if - not a generic method. - - Can be slower than calling . - - - - Returns the concrete instantiation of , with any - generic parameters bound to real types. - For interface proxies, this will point to the on the target class. - - The concrete instantiation of , or - if not a generic method. - In debug builds this can be slower than calling . - - - - Proceeds the call to the next interceptor in line, and ultimately to the target method. - - - Since interface proxies without a target don't have the target implementation to proceed to, - it is important, that the last interceptor does not call this method, otherwise a - will be thrown. - - - - - Gets the proxy object on which the intercepted method is invoked. - - Proxy object on which the intercepted method is invoked. - - - - Gets the object on which the invocation is performed. This is different from proxy object - because most of the time this will be the proxy target object. - - - The invocation target. - - - - Gets the type of the target object for the intercepted method. - - The type of the target object. - - - - Gets the arguments that the has been invoked with. - - The arguments the method was invoked with. - - - - Gets the generic arguments of the method. - - The generic arguments, or null if not a generic method. - - - - Gets the representing the method being invoked on the proxy. - - The representing the method being invoked. - - - - For interface proxies, this will point to the on the target class. - - The method invocation target. - - - - Gets or sets the return value of the method. - - The return value of the method. - - - - Used during the target type inspection process. Implementors have a chance to customize the - proxy generation process. - - - - - Invoked by the generation process to determine if the specified method should be proxied. - - The type which declares the given method. - The method to inspect. - True if the given method should be proxied; false otherwise. - - - - Invoked by the generation process to notify that a member was not marked as virtual. - - The type which declares the non-virtual member. - The non-virtual member. - - This method gives an opportunity to inspect any non-proxyable member of a type that has - been requested to be proxied, and if appropriate - throw an exception to notify the caller. - - - - - Invoked by the generation process to notify that the whole process has completed. - - - - - Interface describing elements composing generated type - - - - - Checks if the method is public or protected. - - - - - - - Performs some basic screening and invokes the - to select methods. - - - - - - - - - Provides functionality for disassembling instances of attributes to CustomAttributeBuilder form, during the process of emiting new types by Dynamic Proxy. - - - - - Disassembles given attribute instance back to corresponding CustomAttributeBuilder. - - An instance of attribute to disassemble - corresponding 1 to 1 to given attribute instance, or null reference. - - Implementers should return that corresponds to given attribute instance 1 to 1, - that is after calling specified constructor with specified arguments, and setting specified properties and fields with values specified - we should be able to get an attribute instance identical to the one passed in . Implementer can return null - if it wishes to opt out of replicating the attribute. Notice however, that for some cases, like attributes passed explicitly by the user - it is illegal to return null, and doing so will result in exception. - - - - - Handles error during disassembly process - - Type of the attribute being disassembled - Exception thrown during the process - usually null, or (re)throws the exception - - - - Here we try to match a constructor argument to its value. - Since we can't get the values from the assembly, we use some heuristics to get it. - a/ we first try to match all the properties on the attributes by name (case insensitive) to the argument - b/ if we fail we try to match them by property type, with some smarts about convertions (i,e: can use Guid for string). - - - - - We have the following rules here. - Try to find a matching type, failing that, if the parameter is string, get the first property (under the assumption that - we can convert it. - - - - - Attributes can only accept simple types, so we return null for null, - if the value is passed as string we call to string (should help with converting), - otherwise, we use the value as is (enums, integer, etc). - - - - - Applied to the assemblies saved by in order to persist the cache data included in the persisted assembly. - - - - - Base class that exposes the common functionalities - to proxy generation. - - - - - Generates a parameters constructor that initializes the proxy - state with just to make it non-null. - - This constructor is important to allow proxies to be XML serializable - - - - - - It is safe to add mapping (no mapping for the interface exists) - - - - - - - - Generates the constructor for the class that extends - - - - - - - - - Default implementation of interface producing in-memory proxy assemblies. - - - - - Abstracts the implementation of proxy type construction. - - - - - Creates a proxy type for given , using provided. - - The class type to proxy. - The proxy generation options. - The generated proxy type. - Thrown when is a generic type definition. - Thrown when is not public. - Note that to avoid this exception, you can mark offending type internal, and define - pointing to Castle Dynamic Proxy assembly, in assembly containing that type, if this is appropriate. - - - - - Creates a proxy type for given , implementing , using provided. - - The class type to proxy. - Additional interface types to proxy. - The proxy generation options. - The generated proxy type. - - Implementers should return a proxy type for the specified class and interfaces. - Additional interfaces should be only 'mark' interfaces, that is, they should work like interface proxy without target. (See method.) - - Thrown when or any of is a generic type definition. - Thrown when or any of is not public. - Note that to avoid this exception, you can mark offending type internal, and define - pointing to Castle Dynamic Proxy assembly, in assembly containing that type, if this is appropriate. - - - - - Creates a proxy type for given , implementing , using provided. - - The class type to proxy. - Additional interface types to proxy. - The proxy generation options. - The generated proxy type. - - Implementers should return a proxy type for the specified class and interfaces. - Additional interfaces should be only 'mark' interfaces, that is, they should work like interface proxy without target. (See method.) - - Thrown when or any of is a generic type definition. - Thrown when or any of is not public. - Note that to avoid this exception, you can mark offending type internal, and define - pointing to Castle Dynamic Proxy assembly, in assembly containing that type, if this is appropriate. - - - - - Creates a proxy type that proxies calls to members on , implementing , using provided. - - The interface type to proxy. - Additional interface types to proxy. - Type implementing on which calls to the interface members should be intercepted. - The proxy generation options. - The generated proxy type. - - Implementers should return a proxy type for the specified interface that 'proceeds' executions to the specified target. - Additional interfaces should be only 'mark' interfaces, that is, they should work like interface proxy without target. (See method.) - - Thrown when or any of is a generic type definition. - Thrown when or any of is not public. - Note that to avoid this exception, you can mark offending type internal, and define - pointing to Castle Dynamic Proxy assembly, in assembly containing that type, if this is appropriate. - - - - - Creates a proxy type for given that delegates all calls to the provided interceptors. - - The interface type to proxy. - Additional interface types to proxy. - The proxy generation options. - The generated proxy type. - - Implementers should return a proxy type for the specified interface and additional interfaces that delegate all executions to the specified interceptors. - - Thrown when or any of is a generic type definition. - Thrown when or any of is not public. - Note that to avoid this exception, you can mark offending type internal, and define - pointing to Castle Dynamic Proxy assembly, in assembly containing that type, if this is appropriate. - - - - - Creates a proxy type for given and that delegates all calls to the provided interceptors and allows interceptors to switch the actual target of invocation. - - The interface type to proxy. - Additional interface types to proxy. - The proxy generation options. - The generated proxy type. - - Implementers should return a proxy type for the specified interface(s) that delegate all executions to the specified interceptors - and uses an instance of the interface as their targets (i.e. ), rather than a class. All classes should then implement interface, - to allow interceptors to switch invocation target with instance of another type implementing called interface. - - Thrown when or any of is a generic type definition. - Thrown when or any of is not public. - Note that to avoid this exception, you can mark offending type internal, and define - pointing to Castle Dynamic Proxy assembly, in assembly containing that type, if this is appropriate. - - - - - Gets or sets the that this logs to. - - - - - Gets the associated with this builder. - - The module scope associated with this builder. - - - - Initializes a new instance of the class with new . - - - - - Initializes a new instance of the class. - - The module scope for generated proxy types. - - - - Registers custom disassembler to handle disassembly of specified type of attributes. - - Type of attributes to handle - Disassembler converting existing instances of Attributes to CustomAttributeBuilders - - When disassembling an attribute Dynamic Proxy will first check if an custom disassembler has been registered to handle attributes of that type, - and if none is found, it'll use the . - - - - - Attributes should be replicated if they are non-inheritable, - but there are some special cases where the attributes means - something to the CLR, where they should be skipped. - - - - - Initializes a new instance of the class. - - Target element. This is either target type or target method for invocation types. - The type of the proxy. This is base type for invocation types. - The interfaces. - The options. - - - - Initializes a new instance of the class. - - Type of the target. - The interfaces. - The options. - - - s - Provides appropriate Ldc.X opcode for the type of primitive value to be loaded. - - - - - Provides appropriate Ldind.X opcode for - the type of primitive value to be loaded indirectly. - - - - - Emits a load opcode of the appropriate kind for a constant string or - primitive value. - - - - - - - Emits a load opcode of the appropriate kind for the constant default value of a - type, such as 0 for value types and null for reference types. - - - - - Emits a load indirect opcode of the appropriate type for a value or object reference. - Pops a pointer off the evaluation stack, dereferences it and loads - a value of the specified type. - - - - - - - Emits a store indirectopcode of the appropriate type for a value or object reference. - Pops a value of the specified type and a pointer off the evaluation stack, and - stores the value. - - - - - - - Summary description for PropertiesCollection. - - - - - Wraps a reference that is passed - ByRef and provides indirect load/store support. - - - - - Summary description for NewArrayExpression. - - - - - - - - - - Provides appropriate Stind.X opcode - for the type of primitive value to be stored indirectly. - - - - - Returns list of all unique interfaces implemented given types, including their base interfaces. - - - - - - - Initializes a new instance of the class. - - The name. - Type declaring the original event being overriten, or null. - - The add method. - The remove method. - The attributes. - - - - Represents the scope of uniquenes of names for types and their members - - - - - Gets a unique name based on - - Name suggested by the caller - Unique name based on . - - Implementers should provide name as closely resembling as possible. - Generally if no collision occurs it is suggested to return suggested name, otherwise append sequential suffix. - Implementers must return deterministic names, that is when is called twice - with the same suggested name, the same returned name should be provided each time. Non-deterministic return - values, like appending random suffices will break serialization of proxies. - - - - - Returns new, disposable naming scope. It is responsibilty of the caller to make sure that no naming collision - with enclosing scope, or other subscopes is possible. - - New naming scope. - - - - Returns the methods implemented by a type. Use this instead of Type.GetMethods() to work around a CLR issue - where duplicate MethodInfos are returned by Type.GetMethods() after a token of a generic type's method was loaded. - - - - - Determines whether this assembly has internals visible to dynamic proxy. - - The assembly to inspect. - - - - Determines whether the specified method is internal. - - The method. - - true if the specified method is internal; otherwise, false. - - - - - Because we need to cache the types based on the mixed in mixins, we do the following here: - - Get all the mixin interfaces - - Sort them by full name - - Return them by position - - The idea is to have reproducable behavior for the case that mixins are registered in different orders. - This method is here because it is required - - - - - Summary description for ModuleScope. - - - - - The default file name used when the assembly is saved using . - - - - - The default assembly (simple) name used for the assemblies generated by a instance. - - - - - Initializes a new instance of the class; assemblies created by this instance will not be saved. - - - - - Initializes a new instance of the class, allowing to specify whether the assemblies generated by this instance - should be saved. - - If set to true saves the generated module. - - - - Initializes a new instance of the class, allowing to specify whether the assemblies generated by this instance - should be saved. - - If set to true saves the generated module. - If set to true disables ability to generate signed module. This should be used in cases where ran under constrained permissions. - - - - Initializes a new instance of the class, allowing to specify whether the assemblies generated by this instance - should be saved and what simple names are to be assigned to them. - - If set to true saves the generated module. - If set to true disables ability to generate signed module. This should be used in cases where ran under constrained permissions. - The simple name of the strong-named assembly generated by this . - The path and file name of the manifest module of the strong-named assembly generated by this . - The simple name of the weak-named assembly generated by this . - The path and file name of the manifest module of the weak-named assembly generated by this . - - - - Initializes a new instance of the class, allowing to specify whether the assemblies generated by this instance - should be saved and what simple names are to be assigned to them. - - If set to true saves the generated module. - If set to true disables ability to generate signed module. This should be used in cases where ran under constrained permissions. - Naming scope used to provide unique names to generated types and their members (usually via sub-scopes). - The simple name of the strong-named assembly generated by this . - The path and file name of the manifest module of the strong-named assembly generated by this . - The simple name of the weak-named assembly generated by this . - The path and file name of the manifest module of the weak-named assembly generated by this . - - - - Returns a type from this scope's type cache, or null if the key cannot be found. - - The key to be looked up in the cache. - The type from this scope's type cache matching the key, or null if the key cannot be found - - - - Registers a type in this scope's type cache. - - The key to be associated with the type. - The type to be stored in the cache. - - - - Gets the key pair used to sign the strong-named assembly generated by this . - - - - - - Gets the specified module generated by this scope, creating a new one if none has yet been generated. - - If set to true, a strong-named module is returned; otherwise, a weak-named module is returned. - A strong-named or weak-named module generated by this scope, as specified by the parameter. - - - - Gets the strong-named module generated by this scope, creating a new one if none has yet been generated. - - A strong-named module generated by this scope. - - - - Gets the weak-named module generated by this scope, creating a new one if none has yet been generated. - - A weak-named module generated by this scope. - - - - Saves the generated assembly with the name and directory information given when this instance was created (or with - the and current directory if none was given). - - - - This method stores the generated assembly in the directory passed as part of the module information specified when this instance was - constructed (if any, else the current directory is used). If both a strong-named and a weak-named assembly - have been generated, it will throw an exception; in this case, use the overload. - - - If this was created without indicating that the assembly should be saved, this method does nothing. - - Both a strong-named and a weak-named assembly have been generated. - The path of the generated assembly file, or null if no file has been generated. - - - - Saves the specified generated assembly with the name and directory information given when this instance was created - (or with the and current directory if none was given). - - True if the generated assembly with a strong name should be saved (see ); - false if the generated assembly without a strong name should be saved (see . - - - This method stores the specified generated assembly in the directory passed as part of the module information specified when this instance was - constructed (if any, else the current directory is used). - - - If this was created without indicating that the assembly should be saved, this method does nothing. - - - No assembly has been generated that matches the parameter. - - The path of the generated assembly file, or null if no file has been generated. - - - - Loads the generated types from the given assembly into this 's cache. - - The assembly to load types from. This assembly must have been saved via or - , or it must have the manually applied. - - This method can be used to load previously generated and persisted proxy types from disk into this scope's type cache, eg. in order - to avoid the performance hit associated with proxy generation. - - - - - Users of this should use this lock when accessing the cache. - - - - - Gets the strong-named module generated by this scope, or if none has yet been generated. - - The strong-named module generated by this scope, or if none has yet been generated. - - - - Gets the file name of the strongly named module generated by this scope. - - The file name of the strongly named module generated by this scope. - - - - Gets the directory where the strongly named module generated by this scope will be saved, or if the current directory - is used. - - The directory where the strongly named module generated by this scope will be saved when is called - (if this scope was created to save modules). - - - - Gets the weak-named module generated by this scope, or if none has yet been generated. - - The weak-named module generated by this scope, or if none has yet been generated. - - - - Gets the file name of the weakly named module generated by this scope. - - The file name of the weakly named module generated by this scope. - - - - Gets the directory where the weakly named module generated by this scope will be saved, or if the current directory - is used. - - The directory where the weakly named module generated by this scope will be saved when is called - (if this scope was created to save modules). - - - - ProxyBuilder that persists the generated type. - - - The saved assembly contains just the last generated type. - - - - - Initializes a new instance of the class. - - - - - Saves the generated assembly to a physical file. Note that this renders the unusable. - - The path of the generated assembly file, or null if no assembly has been generated. - This method does not support saving multiple files. If both a signed and an unsigned module have been generated, use the - respective methods of the . - - - - Initializes a new instance of the class. - - The hook. - - - - Initializes a new instance of the class. - - - - - Provides proxy objects for classes and interfaces. - - - - - Initializes a new instance of the class. - - Proxy types builder. - - - - Initializes a new instance of the class. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The interceptors called during the invocation of proxied methods. - Object proxying calls to members of on object. - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is not an interface type. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method generates new proxy type for each type of , which affects performance. If you don't want to proxy types differently depending on the type of the target - use method. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of on object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is not an interface type. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method generates new proxy type for each type of , which affects performance. If you don't want to proxy types differently depending on the type of the target - use method. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method generates new proxy type for each type of , which affects performance. If you don't want to proxy types differently depending on the type of the target - use method. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method generates new proxy type for each type of , which affects performance. If you don't want to proxy types differently depending on the type of the target - use method. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - Additional interface types. Calls to their members will be proxied as well. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of and types on object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method generates new proxy type for each type of , which affects performance. If you don't want to proxy types differently depending on the type of the target - use method. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - Additional interface types. Calls to their members will be proxied as well. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of and types on object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method generates new proxy type for each type of , which affects performance. If you don't want to proxy types differently depending on the type of the target - use method. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - Interceptors can use interface to provide other target for method invocation than default . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on object or alternative implementation swapped at runtime by an interceptor. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - Interceptors can use interface to provide other target for method invocation than default . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on object or alternative implementation swapped at runtime by an interceptor. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is not an interface type. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - Interceptors can use interface to provide other target for method invocation than default . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on object or alternative implementation swapped at runtime by an interceptor. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is not an interface type. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - Interceptors can use interface to provide other target for method invocation than default . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - Additional interface types. Calls to their members will be proxied as well. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of and types on object or alternative implementation swapped at runtime by an interceptor. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - Interceptors can use interface to provide other target for method invocation than default . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on object or alternative implementation swapped at runtime by an interceptor. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on object with given . - Interceptors can use interface to provide other target for method invocation than default . - - Type of the interface implemented by which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - Additional interface types. Calls to their members will be proxied as well. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of and types on object or alternative implementation swapped at runtime by an interceptor. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not an interface type. - Thrown when given does not implement interface. - Thrown when no default constructor exists on actual type of object. - Thrown when default constructor of actual type of throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of types on generated target object. - - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is not an interface type. - - Since this method uses an empty-shell implementation of interfaces to proxy generated at runtime, the actual implementation of proxied methods must be provided by given implementations. - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - As a result of that also at least one implementation must be provided. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of types on generated target object. - - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is not an interface type. - - Since this method uses an empty-shell implementation of interfaces to proxy generated at runtime, the actual implementation of proxied methods must be provided by given implementations. - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - As a result of that also at least one implementation must be provided. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of types on generated target object. - - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is not an interface type. - - Since this method uses an empty-shell implementation of interfaces to proxy generated at runtime, the actual implementation of proxied methods must be provided by given implementations. - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - As a result of that also at least one implementation must be provided. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on generated target object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not an interface type. - - Since this method uses an empty-shell implementation of interfaces to proxy generated at runtime, the actual implementation of proxied methods must be provided by given implementations. - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of type on generated target object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not an interface type. - - Since this method uses an empty-shell implementation of interfaces to proxy generated at runtime, the actual implementation of proxied methods must be provided by given implementations. - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - Additional interface types. Calls to their members will be proxied as well. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of and types on generated target object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not an interface type. - - Since this method uses an empty-shell implementation of interfaces to proxy generated at runtime, the actual implementation of proxied methods must be provided by given implementations. - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of on generated target object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not an interface type. - - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to members of interface on target object generated at runtime with given . - - Type of the interface which will be proxied. - The proxy generation options used to influence generated proxy type and object. - Additional interface types. Calls to their members will be proxied as well. - The interceptors called during the invocation of proxied methods. - - Object proxying calls to members of and types on generated target object. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given array is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not an interface type. - - Since this method uses an empty-shell implementation of to proxy generated at runtime, the actual implementation of proxied methods must be provided by given implementations. - They are responsible for setting return value (and out parameters) on proxied methods. It is also illegal for an interceptor to call , since there's no actual implementation to proceed with. - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The target object, calls to which will be intercepted. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - Additional interface types. Calls to their members will be proxied as well. - The target object, calls to which will be intercepted. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of and types. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - Arguments of constructor of type which should be used to create a new instance of that type. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no constructor exists on type with parameters matching . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The target object, calls to which will be intercepted. - Arguments of constructor of type which should be used to create a new instance of that type. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no constructor exists on type with parameters matching . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The target object, calls to which will be intercepted. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no parameterless constructor exists on type . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - Additional interface types. Calls to their members will be proxied as well. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of and types. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - Additional interface types. Calls to their members will be proxied as well. - The target object, calls to which will be intercepted. - The proxy generation options used to influence generated proxy type and object. - Arguments of constructor of type which should be used to create a new instance of that type. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of and types. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not a class type. - Thrown when no constructor exists on type with parameters matching . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - Additional interface types. Calls to their members will be proxied as well. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of and types. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The proxy generation options used to influence generated proxy type and object. - Arguments of constructor of type which should be used to create a new instance of that type. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no constructor exists on type with parameters matching . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - Arguments of constructor of type which should be used to create a new instance of that type. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no constructor exists on type with parameters matching . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no parameterless constructor exists on type . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of type. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given is a generic type definition. - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - Additional interface types. Calls to their members will be proxied as well. - The proxy generation options used to influence generated proxy type and object. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of and types. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not a class type. - Thrown when no default constructor exists on type . - Thrown when default constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates proxy object intercepting calls to virtual members of type on newly created instance of that type with given . - - Type of class which will be proxied. - Additional interface types. Calls to their members will be proxied as well. - The proxy generation options used to influence generated proxy type and object. - Arguments of constructor of type which should be used to create a new instance of that type. - The interceptors called during the invocation of proxied methods. - - New object of type proxying calls to virtual members of and types. - - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given object is a null reference (Nothing in Visual Basic). - Thrown when given or any of is a generic type definition. - Thrown when given is not a class type. - Thrown when no constructor exists on type with parameters matching . - Thrown when constructor of type throws an exception. - - This method uses implementation to generate a proxy type. - As such caller should expect any type of exception that given implementation may throw. - - - - - Creates the proxy type for class proxy with given class, implementing given and using provided . - - The base class for proxy type. - The interfaces that proxy type should implement. - The options for proxy generation process. - of proxy. - - - - Creates the proxy type for interface proxy with target for given interface, implementing given on given and using provided . - - The interface proxy type should implement. - The additional interfaces proxy type should implement. - Actual type that the proxy type will encompass. - The options for proxy generation process. - of proxy. - - - - Creates the proxy type for interface proxy with target interface for given interface, implementing given on given and using provided . - - The interface proxy type should implement. - The additional interfaces proxy type should implement. - The options for proxy generation process. - of proxy. - - - - Creates the proxy type for interface proxy without target for given interface, implementing given and using provided . - - The interface proxy type should implement. - The additional interfaces proxy type should implement. - The options for proxy generation process. - of proxy. - - - - Gets or sets the that this log to. - - - - - Gets the proxy builder instance used to generate proxy types. - - The proxy builder. - - - - - - - - - - - - - - - For interface proxies, this will point to the - on the target class - - - - - Handles the deserialization of proxies. - - - - - Resets the used for deserialization to a new scope. - - This is useful for test cases. - - - - Resets the used for deserialization to a given . - - The scope to be used for deserialization. - By default, the deserialization process uses a different scope than the rest of the application, which can lead to multiple proxies - being generated for the same type. By explicitly setting the deserialization scope to the application's scope, this can be avoided. - - - - Gets the used for deserialization. - - As has no way of automatically determining the scope used by the application (and the application - might use more than one scope at the same time), uses a dedicated scope instance for deserializing proxy - types. This instance can be reset and set to a specific value via and . - - - - Holds objects representing methods of class. - - - - - Holds objects representing methods of class. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Provides an extension point that allows proxies to choose specific interceptors on - a per method basis. - - - - - Selects the interceptors that should intercept calls to the given . - - The type declaring the method to intercept. - The method that will be intercepted. - All interceptors registered with the proxy. - An array of interceptors to invoke upon calling the . - - This method is called only once per proxy instance, upon the first call to the - . Either an empty array or null are valid return values to indicate - that no interceptor should intercept calls to the method. Although it is not advised, it is - legal to return other implementations than these provided in - . - - - - - Creates a new lock. - - - - - - This interface should be implemented by classes - that are available in a bigger context, exposing - the container to different areas in the same application. - - For example, in Web application, the (global) HttpApplication - subclasses should implement this interface to expose - the configured container - - - - - - Exposes means to change target objects of proxies and invocations - - - - - Changes the target object () of current . - - The new value of target of invocation. - - Although the method takes the actual instance must be of type assignable to , otherwise an will be thrown. - Also while it's technically legal to pass null reference (Nothing in Visual Basic) as , for obvious reasons Dynamic Proxy will not be able to call the intercepted method on such target. - In this case last interceptor in the pipeline mustn't call or a will be throws. - Also while it's technically legal to pass proxy itself as , this would create stack overflow. - In this case last interceptor in the pipeline mustn't call or a will be throws. - - Thrown when is not assignable to the proxied type. - - - - Permanently changes the target object of the proxy. This does not affect target of the current invocation. - - The new value of target of the proxy. - - Although the method takes the actual instance must be of type assignable to proxy's target type, otherwise an will be thrown. - Also while it's technically legal to pass null reference (Nothing in Visual Basic) as , for obvious reasons Dynamic Proxy will not be able to call the intercepted method on such target. - In this case last interceptor in the pipeline mustn't call or a will be throws. - Also while it's technically legal to pass proxy itself as , this would create stack overflow. - In this case last interceptor in the pipeline mustn't call or a will be throws. - - Thrown when is not assignable to the proxied type. - - - - New interface that is going to be used by DynamicProxy 2 - - - - - Get the proxy target (note that null is a valid target!) - - - - - - Gets the interceptors for the proxy - - - - - - Defines that the implementation wants a - in order to - access other components. The creator must be aware - that the component might (or might not) implement - the interface. - - - Used by Castle Project components to, for example, - gather logging factories - - - - - Increments IServiceProvider with a generic service resolution operation. - - - - - Provides a factory that can produce either or - classes. - - - - - Manages the instantiation of s. - - - - - Creates a new logger, getting the logger name from the specified type. - - - - - Creates a new logger. - - - - - Creates a new logger, getting the logger name from the specified type. - - - - - Creates a new logger. - - - - - Creates a new extended logger, getting the logger name from the specified type. - - - - - Creates a new extended logger. - - - - - Creates a new extended logger, getting the logger name from the specified type. - - - - - Creates a new extended logger. - - - - - Creates a new extended logger, getting the logger name from the specified type. - - - - - Creates a new extended logger. - - - - - Creates a new extended logger, getting the logger name from the specified type. - - - - - Creates a new extended logger. - - - - - Creates a new logger, getting the logger name from the specified type. - - - - - Creates a new logger. - - - - - Creates a new logger, getting the logger name from the specified type. - - - - - Creates a new logger. - - - - - Gets the configuration file. - - i.e. log4net.config - - - - - Used to create the TraceLogger implementation of ILogger interface. See . - - - - - Gets the configuration file. - - i.e. log4net.config - - - - - Interface for Context Properties implementations - - - - This interface defines a basic property get set accessor. - - - Based on the ContextPropertiesBase of log4net, by Nicko Cadell. - - - - - - Gets or sets the value of a property - - - The value for the property with the specified key - - - - Gets or sets the value of a property - - - - - - NullLogFactory used when logging is turned off. - - - - - Creates an instance of ILogger with the specified name. - - Name. - - - - - Creates an instance of ILogger with the specified name and LoggerLevel. - - Name. - Level. - - - - - Creates outputing - to files. The name of the file is derived from the log name - plus the 'log' extension. - - - - - Provides an interface that supports and - allows the storage and retrieval of Contexts. These are supported in - both log4net and NLog. - - - - - Manages logging. - - - This is a facade for the different logging subsystems. - It offers a simplified interface that follows IOC patterns - and a simplified priority/level/severity abstraction. - - - - - Logs a debug message. - - The message to log - - - - Logs a debug message. - - The exception to log - The message to log - - - - Logs a debug message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - The message to log - - - - Logs an info message. - - The exception to log - The message to log - - - - Logs an info message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - The message to log - - - - Logs a warn message. - - The exception to log - The message to log - - - - Logs a warn message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - The message to log - - - - Logs an error message. - - The exception to log - The message to log - - - - Logs an error message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - The message to log - - - - Logs a fatal message. - - The exception to log - The message to log - - - - Logs a fatal message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal error message. - - The Message - - - - Logs a fatal error message. - - The Message - The Exception - - - - Logs a fatal error message. - - Message format - Array of objects to write using format - - - - Create a new child logger. - The name of the child logger is [current-loggers-name].[passed-in-name] - - The Subname of this logger. - The New ILogger instance. - If the name has an empty element name. - - - - Determines if messages of priority "debug" will be logged. - - True if "debug" messages will be logged. - - - - Determines if messages of priority "info" will be logged. - - True if "info" messages will be logged. - - - - Determines if messages of priority "warn" will be logged. - - True if "warn" messages will be logged. - - - - Determines if messages of priority "error" will be logged. - - True if "error" messages will be logged. - - - - Determines if messages of priority "fatal" will be logged. - - True if "fatal" messages will be logged. - - - - Determines if messages of priority "fatalError" will be logged. - - True if "fatalError" messages will be logged. - - - - Exposes the Global Context of the extended logger. - - - - - Exposes the Thread Context of the extended logger. - - - - - Exposes the Thread Stack of the extended logger. - - - - - Supporting Logger levels. - - - - - Logging will be off - - - - - Fatal logging level - - - - - Error logging level - - - - - Warn logging level - - - - - Info logging level - - - - - Debug logging level - - - - - The Logger sending everything to the standard output streams. - This is mainly for the cases when you have a utility that - does not have a logger to supply. - - - - - The Level Filtered Logger class. This is a base clase which - provides a LogLevel attribute and reroutes all functions into - one Log method. - - - - - Creates a new LevelFilteredLogger. - - - - - Keep the instance alive in a remoting scenario - - - - - - Logs a debug message. - - The message to log - - - - Logs a debug message. - - The exception to log - The message to log - - - - Logs a debug message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a debug message. - - Message format - Array of objects to write using format - - - - Logs an info message. - - The message to log - - - - Logs an info message. - - The exception to log - The message to log - - - - Logs an info message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an info message. - - Message format - Array of objects to write using format - - - - Logs a warn message. - - The message to log - - - - Logs a warn message. - - The exception to log - The message to log - - - - Logs a warn message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a warn message. - - Message format - Array of objects to write using format - - - - Logs an error message. - - The message to log - - - - Logs an error message. - - The exception to log - The message to log - - - - Logs an error message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs an error message. - - Message format - Array of objects to write using format - - - - Logs a fatal message. - - The message to log - - - - Logs a fatal message. - - The exception to log - The message to log - - - - Logs a fatal message. - - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - The exception to log - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - The exception to log - The format provider to use - Format string for the message to log - Format arguments for the message to log - - - - Logs a fatal message. - - Message format - Array of objects to write using format - - - - Logs a fatal error message. - - The Message - - - - Logs a fatal error message. - - The Message - The Exception - - - - Logs a fatal error message. - - Message format - Array of objects to write using format - - - - Implementors output the log content by implementing this method only. - Note that exception can be null - - - - - - - - - The LoggerLevel that this logger - will be using. Defaults to LoggerLevel.Off - - - - - The name that this logger will be using. - Defaults to String.Empty - - - - - Determines if messages of priority "debug" will be logged. - - true if log level flags include the bit - - - - Determines if messages of priority "info" will be logged. - - true if log level flags include the bit - - - - Determines if messages of priority "warn" will be logged. - - true if log level flags include the bit - - - - Determines if messages of priority "error" will be logged. - - true if log level flags include the bit - - - - Determines if messages of priority "fatal" will be logged. - - true if log level flags include the bit - - - - Determines if messages of priority "fatal" will be logged. - - true if log level flags include the bit - - - - Creates a new ConsoleLogger with the Level - set to LoggerLevel.Debug and the Name - set to String.Empty. - - - - - Creates a new ConsoleLogger with the Name - set to String.Empty. - - The logs Level. - - - - Creates a new ConsoleLogger with the Level - set to LoggerLevel.Debug. - - The logs Name. - - - - Creates a new ConsoleLogger. - - The logs Name. - The logs Level. - - - - A Common method to log. - - The level of logging - The name of the logger - The Message - The Exception - - - - Returns a new ConsoleLogger with the name - added after this loggers name, with a dot in between. - - The added hierarchical name. - A new ConsoleLogger. - - - - The Logger using standart Diagnostics namespace. - - - - - Creates a logger based on . - - - - - - Creates a logger based on . - - - - - - - Creates a logger based on . - - - - - - - - The Null Logger class. This is useful for implementations where you need - to provide a logger to a utility class, but do not want any output from it. - It also helps when you have a utility that does not have a logger to supply. - - - - - Creates a new NullLogger. - - - - - No-op. - - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - Ignored - Ignored - - - - No-op. - - Ignored - - - - No-op. - - Ignored - Ignored - - - - No-op. - - Ignored - Ignored - - - - Returns this NullLogger. - - Ignored - This ILogger instance. - - - - No-op. - - false - - - - No-op. - - false - - - - No-op. - - false - - - - No-op. - - false - - - - No-op. - - false - - - - No-op. - - false - - - - Returns empty context properties. - - - - - Returns empty context properties. - - - - - Returns empty context stacks. - - - - - The Stream Logger class. This class can stream log information - to any stream, it is suitable for storing a log file to disk, - or to a MemoryStream for testing your components. - - - This logger is not thread safe. - - - - - Creates a new StreamLogger with default encoding - and buffer size. Initial Level is set to Debug. - - - The name of the log. - - - The stream that will be used for logging, - seeking while the logger is alive - - - - - Creates a new StreamLogger with default buffer size. - Initial Level is set to Debug. - - - The name of the log. - - - The stream that will be used for logging, - seeking while the logger is alive - - - The encoding that will be used for this stream. - - - - - - Creates a new StreamLogger. - Initial Level is set to Debug. - - - The name of the log. - - - The stream that will be used for logging, - seeking while the logger is alive - - - The encoding that will be used for this stream. - - - - The buffer size that will be used for this stream. - - - - - - Creates a new StreamLogger with - Debug as default Level. - - The name of the log. - The StreamWriter the log will write to. - - - - The TraceLogger sends all logging to the System.Diagnostics.TraceSource - built into the .net framework. - - - Logging can be configured in the system.diagnostics configuration - section. - - If logger doesn't find a source name with a full match it will - use source names which match the namespace partially. For example you can - configure from all castle components by adding a source name with the - name "Castle". - - If no portion of the namespace matches the source named "Default" will - be used. - - - - - Build a new trace logger based on the named TraceSource - - The name used to locate the best TraceSource. In most cases comes from the using type's fullname. - - - - Build a new trace logger based on the named TraceSource - - The name used to locate the best TraceSource. In most cases comes from the using type's fullname. - The default logging level at which this source should write messages. In almost all cases this - default value will be overridden in the config file. - - - - Create a new child logger. - The name of the child logger is [current-loggers-name].[passed-in-name] - - The Subname of this logger. - The New ILogger instance. - - - - This is an abstract implementation - that deals with methods that can be abstracted away - from underlying implementations. - - - AbstractConfiguration makes easier to implementers - to create a new version of - - - - - is a interface encapsulating a configuration node - used to retrieve configuration values. - - - - - Gets the value of the node and converts it - into specified . - - The - - The Default value returned if the conversion fails. - - The Value converted into the specified type. - - - - Gets the name of the node. - - - The Name of the node. - - - - - Gets the value of the node. - - - The Value of the node. - - - - - Gets an of - elements containing all node children. - - The Collection of child nodes. - - - - Gets an of the configuration attributes. - - - - - Gets the value of the node and converts it - into specified . - - The - - The Default value returned if the convertion fails. - - The Value converted into the specified type. - - - - Gets the name of the . - - - The Name of the . - - - - - Gets the value of . - - - The Value of the . - - - - - Gets all child nodes. - - The of child nodes. - - - - Gets node attributes. - - - All attributes of the node. - - - - - A collection of objects. - - - - - Creates a new instance of ConfigurationCollection. - - - - - Creates a new instance of ConfigurationCollection. - - - - - Summary description for MutableConfiguration. - - - - - Initializes a new instance of the class. - - The name. - - - - Gets the value of . - - - The Value of the . - - - - - Pendent - - - - - Deserializes the specified node into an abstract representation of configuration. - - The node. - - - - - If a config value is an empty string we return null, this is to keep - backward compability with old code - - - - - General purpose class to represent a standard pair of values. - - Type of the first value - Type of the second value - - - - Constructs a pair with its values - - - - - - - List of utility methods related to dynamic proxy operations - - - - - Determines whether the specified type is a proxy generated by - DynamicProxy (1 or 2). - - The type. - - true if it is a proxy; otherwise, false. - - - - - Pendent - - - - - Initializes a new instance of the class. - - The target. - - - - Determines whether the object contains an element with the specified key. - - The key to locate in the object. - - true if the contains an element with the key; otherwise, false. - - - is null. - - - - Adds an element with the provided key and value to the object. - - The to use as the key of the element to add. - The to use as the value of the element to add. - - is null. - An element with the same key already exists in the object. - The is read-only.-or- The has a fixed size. - - - - Removes all elements from the object. - - The object is read-only. - - - - Returns an object for the object. - - - An object for the object. - - - - - Removes the element with the specified key from the object. - - The key of the element to remove. - - is null. - The object is read-only.-or- The has a fixed size. - - - - Copies the elements of the to an , starting at a particular index. - - The one-dimensional that is the destination of the elements copied from . The must have zero-based indexing. - The zero-based index in at which copying begins. - - is null. - - is less than zero. - - is multidimensional.-or- is equal to or greater than the length of .-or- The number of elements in the source is greater than the available space from to the end of the destination . - The type of the source cannot be cast automatically to the type of the destination . - - - - Returns an enumerator that iterates through a collection. - - - An object that can be used to iterate through the collection. - - - - - Gets or sets the with the specified key. - - - - - - Gets an object containing the keys of the object. - - - An object containing the keys of the object. - - - - Gets an object containing the values in the object. - - - An object containing the values in the object. - - - - Gets a value indicating whether the object is read-only. - - - true if the object is read-only; otherwise, false. - - - - Gets a value indicating whether the object has a fixed size. - - - true if the object has a fixed size; otherwise, false. - - - - Gets the number of elements contained in the . - - - The number of elements contained in the . - - - - Gets an object that can be used to synchronize access to the . - - - An object that can be used to synchronize access to the . - - - - Gets a value indicating whether access to the is synchronized (thread safe). - - - true if access to the is synchronized (thread safe); otherwise, false. - - - - Represents a 'streamable' resource. Can - be a file, a resource in an assembly. - - - - - Returns a reader for the stream - - - It's up to the caller to dispose the reader. - - - - - - Returns a reader for the stream - - - It's up to the caller to dispose the reader. - - - - - - - Returns an instance of - created according to the relativePath - using itself as the root. - - - - - - - - - - Only valid for resources that - can be obtained through relative paths - - - - - - - - - - This returns a new stream instance each time it is called. - It is the responsability of the caller to dispose of this stream - - - - - Depicts the contract for resource factories. - - - - - Used to check whether the resource factory - is able to deal with the given resource - identifier. - - - Implementors should return true - only if the given identifier is supported - by the resource factory - - - - - - - Creates an instance - for the given resource identifier - - - - - - - Creates an instance - for the given resource identifier - - - - - - - - - - - - - - - - - - Adapts a static string content as an - - - - - Enable access to files on network shares - - - - - Email sender abstraction. - - - - - Sends a mail message. - - From field - To field - E-mail's subject - message's body - - - - Sends a message. - - Message instance - - - - Sends multiple messages. - - List of messages - - - - Default implementation. - - - - - Initializes a new instance of the class based on the configuration provided in the application configuration file. - - - This constructor is based on the default configuration in the application configuration file. - - - - - This service implementation - requires a host name in order to work - - The smtp server name - - - - Sends a message. - - If any of the parameters is null - From field - To field - e-mail's subject - message's body - - - - Sends a message. - - If the message is null - Message instance - - - - Configures the sender - with port information and eventual credential - informed - - Message instance - - - - Gets or sets the port used to - access the SMTP server - - - - - Gets the hostname. - - The hostname. - - - - Gets or sets a value which is used to - configure if emails are going to be sent asyncrhonously or not. - - - - - Gets or sets a value that specifies - the amount of time after which a synchronous Send call times out. - - - - - Gets or sets a value indicating whether the email should be sent using - a secure communication channel. - - true if should use SSL; otherwise, false. - - - - Gets or sets the domain. - - The domain. - - - - Gets or sets the name of the user. - - The name of the user. - - - - Gets or sets the password. - - The password. - - - - Gets a value indicating whether credentials were informed. - - - if this instance has credentials; otherwise, . - - - - diff --git a/Redist/Castle/Castle.Windsor.XML b/Redist/Castle/Castle.Windsor.XML deleted file mode 100644 index f6bc29dc1..000000000 --- a/Redist/Castle/Castle.Windsor.XML +++ /dev/null @@ -1,7741 +0,0 @@ - - - - Castle.Windsor - - - - - Attempts to dynamically load a UserControl by invoking Page.LoadControl. - There are two uses of this class. - - 1) Add a component to the Kernel and add a VirtualPath attribute specifying - the relative path of the .ascx file for the associated UserControl. (easy) - - - - <component id="BasketView" - service="Castle.ShoppingCart.IBasketView, Castle.ShoppingCart" - type="Castle.ShoppingCart.BasketView, Castle.ShoppingCart" - lifestyle="transient" - virtualPath="~/Views/BasketView.ascx" - /> - - - - 2) Precompile a UserControl and add the pre-compiled class to the Kernel. (hard) - Has not been tested with proxies. - - - - - - Standard implementation of . - Handles the selection of the best constructor, fills the - writable properties the component exposes, run the commission - and decommission lifecycles, etc. - - - Custom implementors can just override the CreateInstance method. - Please note however that the activator is responsible for the proxy creation - when needed. - - - - - Abstract implementation of . - The implementors must only override the InternalCreate and - InternalDestroy methods in order to perform their creation and - destruction logic. - - - - - Implements the instance creation logic. The default - implementation should rely on an ordinary call to - Activator.CreateInstance(). - - - This interface is provided in order to allow custom components - to be created using a different logic, such as using a specific factory - or builder. - - The constructor for implementation has the following signature: - - - ComponentModel model, IKernel kernel, - ComponentInstanceDelegate onCreation, - ComponentInstanceDelegate onDestruction - - - The Activator should raise the events onCreation and onDestruction - in order to correctly implement the contract. Usually the best - way of creating a custom activator is by extending the existing ones. - - - - - - - - Should return a new component instance. - - - - - - Should perform all necessary work to dispose the instance - and/or any resource related to it. - - - - - - Constructs an AbstractComponentActivator - - - - - Initializes a new instance of the class. - - - - - - - - - Initializes a new instance of the class. - - The model. - The kernel. - The on creation. - The on destruction. - - - - Creates the instance. - - The context. - The arguments. - The signature. - - - - - Implements a Lifestyle Manager for Web Apps that - create at most one object per web request. - - - - - Summary description for AbstractLifestyleManager. - - - - - The ILifestyleManager implements - a strategy for a given lifestyle, like singleton, per-thread - and transient. - - - The responsibility of ILifestyleManager - is only the management of lifestyle. It should rely on - to obtain a new component instance - - - - - Initializes the ILifestyleManager with the - - - - - - - - - Implementors should return the component instance based - on the lifestyle semantic. - - - - - - Implementors should release the component instance based - on the lifestyle semantic, for example, singleton components - should not be released on a call for release, instead they should - release them when disposed is invoked. - - - - - - This attribute is useful only when you want to register all components - on an assembly as a batch process. - By doing so, the batch register will look - for this attribute to distinguish components from other classes. - - - - - Base for Attributes that want to express lifestyle - chosen by the component. - - - - - Initializes a new instance of the class. - - The type. - - - - Gets or sets the lifestyle. - - The lifestyle. - - - - Associates a custom component with a component - - - - - Initializes a new instance of the class. - - Type of the component activator. - - - - Gets the type of the component activator. - - The type of the component activator. - - - - Specifies the proxying behavior for a component. - - - - - Gets or sets a value indicating whether the generated - interface proxy should inherit from . - - - - - Determines if the component requires a single interface proxy. - - true if the component requires a single interface proxy. - - - - Gets or sets the additional interfaces used during proxy generation. - - - - - Marks as property to be skipped and not be wired - by the IoC container - - - - - Represents a concern that will be applied to a component instance - during commission or decommission phase. - - - - - Implementors should act on the instance in response to - a decommission or commission phase. - - The model. - The component. - - - - Lifecycle interface. If implemented by a component, - the method Initialized will be invoked by the container - before making the component available to the external world. - - - - - Implementors should perform any initialization logic. - - - - - Used to declare that a component wants interceptors acting on it. - - - - - Constructs the InterceptorAttribute pointing to - a key to a interceptor - - - - - - Constructs the InterceptorAttribute pointing to - a service - - - - - - Marker class used to denote components that have late bound type - That is the actual type is not known exactly at the time when - is created. Those are for example components instantiated via abstract factory. - - - - - If the extended type is a Foo[] or IEnumerable{Foo} which is assignable from Foo[] this method will return typeof(Foo) - otherwise null. - - - - - - - Indicates that the target components wants a - singleton lifestyle. - - - - - Initializes a new instance of the class. - - - - - Indicates that the target components wants a - transient lifestyle. - - - - - Initializes a new instance of the class. - - - - - Indicates that the target components wants a - per thread lifestyle. - - - - - Initializes a new instance of the class. - - - - - Indicates that the target components wants a - per web request lifestyle. - - - - - Indicates that the target components wants a - pooled lifestyle. - - - - - Initializes a new instance of the class - using the default initial pool size (5) and the max pool size (15). - - - - - Initializes a new instance of the class. - - Initial size of the pool. - Max pool size. - - - - Gets the initial size of the pool. - - The initial size of the pool. - - - - Gets the maximum pool size. - - The size of the max pool. - - - - Indicates that the target components wants a - custom lifestyle. - - - - - Initializes a new instance of the class. - - The lifestyle handler. - - - - Gets the type of the lifestyle handler. - - The type of the lifestyle handler. - - - - Enumeration used to mark the component's lifestyle. - - - - - No lifestyle specified. - - - - - Singleton components are instantiated once, and shared - between all clients. - - - - - Thread components have a unique instance per thread. - - - - - Transient components are created on demand. - - - - - Optimization of transient components that keeps - instance in a pool instead of always creating them. - - - - - PerWebRequest components are created once per Http Request - - - - - Any other logic to create/release components. - - - - - Collects information about subscribers for given event - - - - - Extracts MethodInfo of metho invoked in delegate. Based on ILReader class from http://www.gocosmos.org project - - - - - Implementors must inspect the component for - a given information or parameter. - - - - - Usually the implementation will look in the configuration property - of the model or the service interface, or the implementation looking for - something. - - The kernel instance - The component model - - - - Selects one or both of component name and type, for given method - called on given typed factory type. - When component should be requested by type only, - componentName should be null. - When component should be requested by name only, - componentType should be null. - - - - - - - - - Builds for given call. - By default if is a collection - returns for the collection's item type, - otherwise standard . - - - - - - - - - - Selects arguments to be passed to resolution pipeline. - By default passes all given - keyed by names of their corresponding parameters. - - - - - - - - Selects name of the component to resolve. - If Name is GetFoo returns "Foo", otherwise null. - - - - - - - - Selects type of the component to resolve. Uses return type. - - - - - - - - Provides lazy registration capabilities to the container. - - - When a component is requested from a container and it was not registered, - container loads up all registered implementers of this interface and asks - them in turn whether they can provide that component, until it finds one that will. - - - - - Used by container to allow the loader to register component for given and to the container at the time when it is requested - - Key of the requested component or null - Type of requested service or null - User supplied arguments or null - Registration that registers component for given key and/or service or null. - - While either key or service can be null reference it is guaranteed that at least one of them will not be null. - When implementer opts in to provide the requested component (by returning not-null registration) it is required - to register component for requested key/service combination (when one of the elements is null, it should be ignored as well). - When implementer does not want to register the requested component it must return null. - - - - - Summary description for ComponentActivatorException. - - - - - - - - - - Represents collection of arguments used when resolving a component. - - - - - Exception thrown when component has no resolvable constructor that can be used to create an instance. - - - - - Default arguments store used to store items where no specialized store exists - - - - - Extends adding and - information. The MemberInfo is only useful to provide detailed information - on exceptions. - The ComponentModel is required so we can get resolve an object that takes as a parameter itself, but - with difference model. (See IoC 51 for the details) - - - - - Represents a dependency (other component or a - fixed value available through external configuration). - - - - - Initializes a new instance of the class. - - The type. - The dependency key. - Type of the target. - if set to true [is optional]. - - - - Returns a that represents the current . - - - A that represents the current . - - - - - Gets or sets the dependency key. - - The dependency key. - - - - Gets or sets the type of the dependency. - - The type of the dependency. - - - - Gets or sets whether this dependency is optional. - - - true if this dependency is optional; otherwise, false. - - - - - Gets the service type of the dependency. - This is the same type as or if is by ref, - then it's the element type of the reference. (in other words if dependency - is out IFoo foo this will be IFoo, while will be &IFoo); - - - - - Gets the type of the target. - - The type of the target. - - - - Summary description for DefaultHandler. - - - - - Implements the basis of - - - - - - Contract for the IHandler, which manages an - component state and coordinates its creation - and destruction (dispatching to activators, lifestyle managers) - - - - - Implementors should use a strategy to obtain - valid references to properties and/or services - requested in the dependency model. - - - - - Should return an instance of a service or property values as - specified by the dependency model instance. - It is also the responsibility of - to throw an exception in the case a non-optional dependency - could not be resolved. - - Creation context, which is a resolver itself - Parent resolver - normally the IHandler implementation - Model of the component that is requesting the dependency - The dependency model - The dependency resolved value or null - - - - Returns true if the resolver is able to satisfy this dependency. - - Creation context, which is a resolver itself - Parent resolver - normally the IHandler implementation - Model of the component that is requesting the dependency - The dependency model - true if the dependency can be satisfied - - - - Initializes the handler with a reference to the - kernel. - - - - - - Implementors should return a valid instance - for the component the handler is responsible. - It should throw an exception in the case the component - can't be created for some reason - - - - - - Implementors should return a valid instance - for the component the handler is responsible. - It should return null in the case the component - can't be created for some reason - - - - - - Implementors should dispose the component instance - - - true if destroyed. - - - - Dictionary of String/object used to - associate data with a component dependency. - For example, if you component SmtpServer depends on - host and port, you can add those to this - dictionary and the handler will be able to use them. - - - TODO: Document this - - - - - TODO: Document this - - - - - - TODO: Document this - - - - - - - Tests whether the handler is already being resolved in given context. - - - - - Gets the state of the handler - - - - - Gets the model of the component being - managed by this handler. - - - - - The service that this handler handles - - - - - Allow to track state changes of a handler that is modified directly. - This can happen if the client calls AddCustomDependencyValue or - RemoveCustomDependencyValue - - - - - Might be implemented by a handler - so it can expose access to dependency information - which is used to construct meaningful error messages - - - - - Returns human readable list of dependencies - this handler is waiting for. - list of the dependencies that was already checked, used to avoid cycles. - - - - - Lifestyle manager instance - - - - - Custom dependencies values associated with the handler - - - - - Dictionary of key (string) to - - - - - - Dictionary of Type to a list of - - - - - - Constructs and initializes the handler - - - - - - Should be implemented by derived classes: - disposes the component instance (or recycle it) - - - true if destroyed. - - - - Should be implemented by derived classes: - returns an instance of the component this handler - is responsible for - - - - When false, handler can not create valid instance and return null instead. - - - - - Returns human readable list of dependencies - this handler is waiting for. - - - - - - Saves the kernel instance, subscribes to - - event, - creates the lifestyle manager instance and computes - the handler state. - - - - - - disposes the component instance (or recycle it). - - - - - - - Returns an instance of the component this handler - is responsible for - - - - - - - Invoked by - - in order to check if a dependency can be satisfied. - If not, the handler is set to a 'waiting dependency' state. - - - This method registers the dependencies within the correct collection - or dictionary and changes the handler state to - - - - - - - Creates an implementation of - - based - on - - and invokes - - to initialize the newly created manager. - - - - - - - Invoked by the kernel - when one of registered dependencies were satisfied by - new components registered. - - - Handler for the event - - - - - - - Checks if the handler is able to, at very least, satisfy - the dependencies for the constructor with less parameters - - - For each non*optional dependency, the implementation will invoke - - - - - - Invoked when the container receives a parent container reference. - - - This method implementation checks whether the parent container - is able to supply the dependencies for this handler. - - - - - - - Returns an instance of the component this handler - is responsible for - - - when false, handler can not create valid instance and return null instead - - - - - Handler for the event - - - - - - - - Gets the component model. - - - - - Gets the handler state. - - - - - Initializes a new instance of the class. - - - - - - Returns an instance of the component this handler - is responsible for - - - - - - - - - disposes the component instance (or recycle it) - - - true if destroyed - - - - Used during a component request, passed along to the whole process. - This allow some data to be passed along the process, which is used - to detected cycled dependency graphs and now it's also being used - to provide arguments to components. - - - - - Holds the scoped dependencies being resolved. - If a dependency appears twice on the same scope, we'd have a cycle. - - - - - The list of handlers that are used to resolve - the component. - We track that in order to try to avoid attempts to resolve a service - with itself. - - - - - Initializes a new instance of the class. - - The type to extract generic arguments. - The parent context. - When set to true will clone . - - - - Initializes a new instance of the class. - - The handler. - The release policy. - The type to extract generic arguments. - The additional arguments. - The conversion manager. - Parent context - - - - Initializes a new instance of the class. - - - - - Method used by handlers to test whether they are being resolved in the context. - - - - - This method is provided as part of double dispatch mechanism for use by handlers. - Outside of handlers, call instead. - - - - - Creates a new, empty instance. - - - A new CreationContext should be created every time, as the contexts keeps some state related to dependency resolution. - - - - - Default implementation of . - This implementation is complete and also support a kernel - hierarchy (sub containers). - - - Default implementation of . - This implementation is complete and also support a kernel - hierarchy (sub containers). - - - - - The IKernel interface exposes all the functionality - the MicroKernel implements. - - - It allows you to register components and - request them by the key or the service they implemented. - It also allow you to register facilities and subsystem, thus - augmenting the functionality exposed by the kernel alone to fits - your needs. - - - - - - - Summary description for IKernelEvents. - - - - - Event fired when a new component is registered - on the kernel. - - - - - Event fired when a component is removed from the kernel. - - - - - Event fired after the ComponentModel is created. - Allows customizations that may affect the handler. - - - - - Event fired when the kernel was added as child of - another kernel. - - - - - Event fired when the kernel was removed from being a child - of another kernel. - - - - - Event fired before the component is created. - - - - - Event fired when a component instance destroyed. - - - - - Event fired when a new handler is registered - (it might be in a valid or waiting dependency state) - - - - - Event fired when a new handler is registered - (it might be in a valid or waiting dependency state) - - - - - Event fired when a dependency is being resolved, - it allows the dependency to be changed, - but the client ComponentModel must not be changed. - - - - - Registers the components provided by the s - with the . - - Create a new registration using .For() or . - - - - kernel.Register(Component.For<IService>().ImplementedBy<DefaultService>()); - - - The component registrations. - The kernel. - - - - Returns true if the specified component was - found and could be removed (i.e. no other component depends on it) - - The component's key - - - - - Returns true if the specified key was registered - - - - - - - Returns true if the specified service was registered - - - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Releases a component instance. This allows - the kernel to execute the proper decommission - lifecycles on the component instance. - - - - - - Returns the - for the specified component key. - - - - - - - Returns the - for the specified service. - - - - - - - Return handlers for components that - implements the specified service. - - - - - - - Return handlers for components that - implements the specified service. - The check is made using IsAssignableFrom - - - - - - - Adds a to the kernel. - - - - - - - - Creates and adds an facility to the kernel. - - The facility type. - - - - - Creates and adds an facility to the kernel. - - The facility type. - - The callback for creation. - - - - Creates and adds an facility to the kernel. - - The facility type. - - The callback for creation. - - - - Creates and adds an facility to the kernel. - - The facility type. - - - - - Creates and adds an facility to the kernel. - - The facility type. - The callback for creation. - - - - - Creates and adds an facility to the kernel. - - The facility type. - The callback for creation. - - - - - Returns the facilities registered on the kernel. - - - - - - Adds (or replaces) an - - - - - - - Returns an implementation of - for the specified key. - - - - - - - - Support for kernel hierarchy - - - - - - Remove child kernel - - - - - - Register a new component resolver that can take part in the decision - making about which handler to resolve - - - - - Returns the component instance by the service type - - - - - Returns all the valid component instances by - the service type - - The service type - - - - Returns all the valid component instances by - the service type - - The service type - Arguments to resolve the services - - - - Returns all the valid component instances by - the service type - - The service type - Arguments to resolve the services - - - - Returns the component instance by the service type - using dynamic arguments - - - - - - - - Returns the component instance by the component key - using dynamic arguments - - - - - - - - Returns the component instance by the service type - using dynamic arguments - - Service to resolve - Arguments to resolve the services - - - - - Returns the component instance by the component key - using dynamic arguments - - Key to resolve - Arguments to resolve the services - - - - - Returns a component instance by the key - - - - - - - - Returns the component instance by the service type - using dynamic arguments - - - - - - - Returns the component instance by the service type - using dynamic arguments - - Arguments to resolve the services - - - - - Returns the component instance by the component key - - - - - - Returns a component instance by the key - - Component's key - Service type - The Component instance - - - - Returns a component instance by the key - - Service type - Component's key - - The Component instance - - - - Returns component instances that implement TService - - - - - - - Returns component instances that implement TService - - - - - - - Returns component instances that implement TService - - - - - - - Returns a component instance by the key - - - - - - - - - Returns the implementation of - - - - - Returns the implementation of - - - - - Gets or sets the implementation of - - - - - Gets or sets the implementation for - - - - - Returns the implementation for - - - - - Gets or sets the implementation of - allowing different strategies for proxy creation. - - - - - Returns the parent kernel - - - - - Graph of components and interactions. - - - - - Returns the component instance by the key - - - - - Returns the component instance by the service type - - - - - Extended contract of kernel, used internally. - - - - - Constructs an implementation of - for the given - - - - - - - Raise the handler registered event, required so - dependant handlers will be notified about their dependant moving - to valid state. - - - - - - Registers the to be forwarded - to the component registered with . - - The service type that gets forwarded. - The name of the component to forward to. - - - - Adds a custom made . - Used by facilities. - - - - - - List of sub containers. - - - - - List of registered. - - - - - The implementation of - - - - - The dependency resolver. - - - - - Map of subsystems registered. - - - - - The parent kernel, if exists. - - - - - Holds the implementation of - - - - - Implements a policy to control component's - disposal that the user forgot. - - - - - Constructs a DefaultKernel with no component - proxy support. - - - - - Constructs a DefaultKernel with the specified - implementation of and - - - - - - - Constructs a DefaultKernel with the specified - implementation of - - - - - Starts the process of component disposal. - - - - - Return handlers for components that - implements the specified service. - The check is made using IsAssignableFrom - - - - - - - Returns the facilities registered on the kernel. - - - - - - Return handlers for components that - implements the specified service. - - - - - - - Registers the components described by the s - with the . - The component registrations. - The kernel. - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Associates objects with a component handler, - allowing it to use the specified dictionary - when resolving dependencies - - - - - - - Releases a component instance. This allows - the kernel to execute the proper decommission - lifecycles on the component instance. - - - - - - Returns true if the specified component was - found and could be removed (i.e. no other component depends on it) - - The component's key - - - - - Gets the service object of the specified type. - - - A service object of type serviceType. - - An object that specifies the type of service object to get. - - - - Gets the service object of the specified type. - - - A service object of type serviceType. - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the key - - - - - - - - - Returns the component instance by the service type - using dynamic arguments - - - - - - - Returns the component instance by the service type - using dynamic arguments - - - - - - - Returns the component instance by the component key - - - - - - Returns a component instance by the key - - Component's key - Service type - - The Component instance - - - - - Returns a component instance by the key - - Service type - Component's key - - - The Component instance - - - - - Returns the component instance by the service type - - - - - Returns the component instance by the service type - using dynamic arguments - - - - - - - - Returns the component instance by the service type - using dynamic arguments - - - - - - - - Returns the component instance by the component key - using dynamic arguments - - - - - - - - Returns the component instance by the component key - using dynamic arguments - - - - - - - - Returns all the valid component instances by - the service type - - The service type - - - - Returns all the valid component instances by - the service type - - The service type - - Arguments to resolve the services - - - - - Returns all the valid component instances by - the service type - - The service type - - Arguments to resolve the services - - - - - Returns component instances that implement TService - - - - - - - - Returns component instances that implement TService - - - - - - - - Returns component instances that implement TService - - - - - - - Graph of components and interactions. - - - - - Exception throw when a circular dependency is detected - - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the class. - - The message. - - - - Initializes a new instance of the class. - - The message. - The inner exception. - - - - Initializes a new instance of the class. - - The that holds the serialized object data about the exception being thrown. - The that contains contextual information about the source or destination. - The parameter is . - The class name is or is zero (0). - - - - Exception threw when a request for a component - cannot be satisfied because the component does not - exist in the container - - - - - Initializes a new instance of the - - class. - - The name. - - - - Initializes a new instance of the - - class. - - The name. - Exception message. - - - - Initializes a new instance of the - - class. - - The service. - Exception message. - - - - Initializes a new instance of the - - class. - - The service. - - - - Initializes a new instance of the - - class. - - The object that holds the serialized object data. - The contextual information about the source or destination. - - - - Exception threw when there is a problem - registering a component - - - - - Initializes a new instance of the class. - - The message. - - - - Initializes a new instance of the class. - - The object that holds the serialized object data. - The contextual information about the source or destination. - - - - Exception threw by Kernel operations that failed - for some reason. - - - - - Initializes a new instance of the class. - - The message. - - - - Initializes a new instance of the class. - - The message. - The inner exception. - - - - Initializes a new instance of the class. - - The object that holds the serialized object data. - The contextual information about the source or destination. - - - - Base class for facilities. - - - - - Unit of extension. A facility should use - the extension points offered by the kernel - to augment its functionality. - - - - - - - - - - - - - - - - - The custom initialization for the Facility. - - - It must be overridden. - - - - - Performs the tasks associated with freeing, releasing, or resetting - the facility resources. - - - It can be overriden. - - - - - Initializes the facility. First it performs the initialization common for all - facilities, setting the and the - . After it, the Init method is invoked - and the custom initilization is perfomed. - - - - - - - Terminates the Facility, invokes the method and sets - the Kernel to a null reference. - - - - - Gets the facility configuration. - - The representing - the facility configuration. - - - - Gets the where the facility is registered. - - The . - - - - Exception that is thrown when a error occurs during the Event Wiring process - - - - - Base exception to be used by facilities. - - - - - Initializes a new instance of the class. - - The message. - - - - Initializes a new instance of the class. - - The message. - The inner exception. - - - - Initializes a new instance of the class. - - The object that holds the serialized object data. - The contextual information about the source or destination. - - - - Facility to allow components to dynamically subscribe to events offered by - other components. We call the component that offers events publishers and - the components that uses them, subscribers. - - - A component that wish to subscribe to an event must use the external configuration - adding a node subscribers on the publisher. This node can have multiple entries using the - subscriber node. - - - This example shows two simple components: one is the event publisher and the other is the - subscriber. The subscription will be done by the facility, using the publisher associated configuration. - The Publisher class: - - public class SimplePublisher - { - public event PublishEventHandler Event; - - public void Trigger() - { - if (Event != null) - { - Event(this, new EventArgs()); - } - } - } - - The Subscriber class: - - public class SimpleListener - { - private bool _listened; - private object _sender; - - public void OnPublish(object sender, EventArgs e) - { - _sender = sender; - _listened = sender != null; - } - - public bool Listened - { - get { return _listened; } - } - - public object Sender - { - get { return _sender; } - } - } - - The configuration file: - - - - - - - - - - - - - - - - - - ]]> - - - - - - Overridden. Initializes the facility, subscribing to the , - , Kernel events. - - - - - Checks if the component we're dealing is a publisher. If it is, - parses the configuration (the subscribers node) getting the event wiring info. - - The component model. - Invalid and/or a error in the configuration - - - - Checks if the component we're dealing is a publisher. If it is, - iterates the subscribers starting them and wiring the events. - - The component model. - The instance representing the component. - When the subscriber is not found -
or
- The handler method isn't found -
or
- The event isn't found -
-
- - - Represents the information about an event. - - - - - Initializes a new instance of the class. - - Name of the event. - The name of the handler method. - - - - Serves as a hash function for a particular type. - - - A hash code for the current . - - - - - Determines whether the specified is equal to the current . - - The to compare with the current . - - true if the specified is equal to the current ; otherwise, false. - - - - - Gets the name of the event. - - The name of the event. - - - - Gets the handler method name. - - The handler. - - - - - - - - - Activates a object connecting to the remote server. - - - - - Initializes a new instance of the class. - - The model. - The kernel. - The oncreation event handler. - The ondestruction event handler. - - - - Activates a client connecting to the remote server, enforcing the uri and the server activation. - - - - - Initializes a new instance of the class. - - The model. - The kernel. - The oncreation event handler. - The ondestruction event handler. - - - - Activates a client connecting to the remote server through the . - - - - - Initializes a new instance of the class. - - The model. - The kernel. - The oncreation event handler. - The ondestruction event handler. - - - - Activates a client activated object. - - - - - Initializes a new instance of the class. - - The model. - The kernel. - The oncreation event handler. - The ondestruction event handler. - - - - Activates and publishes a server object. - - - - - Initializes a new instance of the class. - - The model. - The kernel. - The oncreation event handler. - The ondestruction event handler. - - - - Facility to allow the communication with remote kernel, using the .NET Remoting infrastructure. - - - TODO - - - TODO - - - - - Used for client side (Expand explanation) - - - - - Used for server side. - Holds the local registry - - - - - Used for client side. - Holds a remote proxy to the server registry - - - - - Performs the tasks associated with freeing, releasing, or resetting - the facility resources. - - - It can be overridden. - - - - - Inspects the model looking for remote component configuration. If found, - do the component Remoting configuration. - - - - - Initializes a new instance of the class. - - The converter. - if set to true is a server. - if set to true is a client. - The base URI. - The remote registry. - The local registry. - - - - Client components are not created by the container - so there's no point collecting constructor dependencies - - - - - - Used in case of generics: - - - - - - - This method changes behavior of the facility. Deferred mode should be used when you - have single call to and register all your components there. - Enabling this mode will optimize the behavior of the facility so that it will wait 'till the end of - installation and only after all s were ran it will instantiate and - start all the startable components. An exception will be thrown if a startable component can't be - instantiated and started. This will help you fail fast and diagnose issues quickly. If you don't want - the exception to be thrown and you prefer the component to fail silently, use method instead. - - - It is recommended to use this method over method. - - - - - This method changes behavior of the facility. Deferred mode should be used when you - have single call to and register all your components there. - Enabling this mode will optimize the behavior of the facility so that it will wait 'till the end of - installation and only after all s were ran it will instantiate and - start all the startable components. No exception will be thrown if a startable component can't be - instantiated and started. If you'd rather fail fast and diagnose issues quickly, use method instead. - - - It is recommended to use method over this method. - - - - - For each new component registered, - some components in the WaitingDependency - state may have became valid, so we check them - - - - - Request the component instance - - - - - - Assigns the start method for the startable. - - - The start method. - - Be sure that you first added the - to the kernel, before registering this component. - - - - Assigns the start method for the startable. - - - Method to use. something like: StartUsingMethod(s => s.Start) - - Be sure that you first added the - to the kernel, before registering this component. - - - - Assigns the stop method for the startable. - - - The stop method. - - Be sure that you first added the - to the kernel, before registering this component. - - - - Assigns the stop method for the startable. - - - Method to use. something like: StartUsingMethod(s => s.Start) - - Be sure that you first added the - to the kernel, before registering this component. - - - - Legacy class from old impl. of the facility. Do not use it. - - - - - Legacy interceptor for old impl. of the facility. - - - - - Interceptors might implement this to receive the - ComponentModel on behalf of the component where the - interceptor is acting. - - - - - Represents a single component to be resolved via Typed Factory - - - - - Resolves the component(s) from given kernel. - - - Resolved component(s). - - - - Represents a set of components to be resolved via Typed Factory. Uses to resolve the components. - - - - - Creates new instance of . - - Collection type to resolve. Must be an array (SomeComponent[]) or IEnumerable{SomeComponent}. Type of the element of the collection will be used as first argument to - Additional arguents that will be passed as second argument to - - - - Provides automatically generated factories on top of interfaces or delegates that - you can use to pull components out of the container without ever referencing it - explicitly. - - - - - Marks the component as typed factory. - - - - - - Only interfaces are legal to use as typed factories. Methods with out parameters are not allowed. - When registering component as typed factory no implementation should be provided (in case there is any it will be ignored). - Typed factories rely on set internally, so users should not set interceptor selectors explicitly; - otherwise the factory will not function correctly. - - - - - Marks the component as typed factory. - - - - - - - Only interfaces are legal to use as typed factories. Methods with out parameters are not allowed. - When registering component as typed factory no implementation should be provided (in case there is any it will be ignored). - Typed factories rely on set internally, so users should not set interceptor selectors explicitly; - otherwise the factory will not function correctly. - - - - - Redirects resolution to the main resolver, and if not found uses - the parent handler. - - - - - Initializes a new instance of the class. - - The parent handler. - The child resolver. - - - - Summary description for DefaultGenericHandler. - - - TODO: Consider refactoring AbstractHandler moving lifestylemanager - creation to DefaultHandler - - - - - Initializes a new instance of the class. - - - - - - Clone some of the parent componentmodel properties to the generic subhandler. - - - The following properties are copied: - - - The - - - The - - - - the subhandler - - - - Summary description for DefaultHandlerFactory. - - - - - Extension point to allow the developer - to use his implementation of - - - - - Summary description for HandlerException. - - - - - Initializes a new instance of the class. - - The message. - - - - Initializes a new instance of the class. - - The object that holds the serialized object data. - The contextual information about the source or destination. - - - - Possible states for a IHandler instance - - - - - The component can be requested - - - - - The component can not be requested - as it still depending on a external - dependency not yet available - - - - - - - - - - - - Represents a delegate which holds basic information about a component. - - Key which identifies the component - handler that holds this component and is capable of - creating an instance of it. - - - - - Represents a delegate which holds basic information about a component - and its instance. - - Component meta information - Component instance - - - - Represents a delegate which holds the information about the - component - - - - - Represents a delegate which holds a handler - - handler that holds a component and is capable of - creating an instance of it. - - - - - - Represents a delegate which holds dependency - resolving information. - - - - - Abstract representation of a vertex. - - - - - The nodes that depends on this node - - - - - The nodes that this node depends - - - - - The node has not been visited yet - - - - - This node is in the process of being visited - - - - - This now was visited - - - - - Represents a collection of objects - which are guaranteed to be unique - and holds a color for them - - - - - Holds a timestamp (integer) - for a given item - - - - - Summary description for DisposalConcern. - - - - - Summary description for InitializationConcern. - - - - - Lifetime concern that works for components that don't have their actual type determined upfront - - - - - Summary description for SupportInitializeConcern. - - - - - Only called for components that - belongs to a pool when the component - comes back to the pool. - - - - - Implementors should perform any - initialization/clean up. - - - - - Interface for components that wish to be started by the container - - - - - Starts this instance. - - - - - Stops this instance. - - - - - Summary description for PerThreadLifestyleManager. - - - - - - - - - - Implements a Poolable Lifestyle Manager. - - - - - Pool implementation contract. - - - - - Implementors should return a component instance. - - - - - - Implementors should release the instance or put it - on the pool - - - - - - Initializes the pool to a initial size by requesting - n components and then releasing them. - - - - - Summary description for SingletonLifestyleManager. - - - - - Summary description for TransientLifestyleManager. - - - - - Summary description for DefaultComponentModelBuilder. - - - - - Implementors must construct a populated - instance of ComponentModel by inspecting the component - and|or the configuration. - - - - - Constructs a new ComponentModel by invoking - the registered contributors. - - - - - - - - - - "To give or supply in common with others; give to a - common fund or for a common purpose". The contributor - should inspect the component, or even the configuration - associated with the component, to add or change information - in the model that can be used later. - - - - - Removes the specified contributor - - - - - - Initializes a new instance of the class. - - The kernel. - - - - Constructs a new ComponentModel by invoking - the registered contributors. - - - - - - - - - - "To give or supply in common with others; give to a - common fund or for a common purpose". The contributor - should inspect the component, or even the configuration - associated with the component, to add or change information - in the model that can be used later. - - - - - - Removes the specified contributor - - - - - - Initializes the default contributors. - - - - - Gets the contributors. - - The contributors. - - - - Inspects the component configuration and the type looking for a - definition of component activator type. The configuration preceeds whatever - is defined in the component. - - - This inspector is not guarantee to always set up an component activator type. - If nothing could be found it wont touch the model. In this case is up to - the kernel to establish a default component activator for components. - - - - - Searches for the component activator in the configuration and, if unsuccessful - look for the component activator attribute in the implementation type. - - The kernel instance - The model instance - - - - Reads the attribute "componentActivatorType" associated with the - component configuration and verifies it implements the - interface. - - - If the type does not implement the proper interface - - - - - - - Check if the type expose one of the component activator attributes - defined in Castle.Core namespace. - - - - - - Validates that the provide type implements IComponentActivator - - The custom component activator. - - - - Inspects the component configuration and type looking for information - that can influence the generation of a proxy for that component. - - We specifically look for useSingleInterfaceProxy and marshalByRefProxy - on the component configuration or the - attribute. - - - - - - Searches for proxy behavior in the configuration and, if unsuccessful - look for the attribute in - the implementation type. - - - - - Reads the proxy behavior associated with the - component configuration/type and applies it to the model. - - - If the conversion fails - - - - - - - Returns a instance if the type - uses the attribute. Otherwise returns null. - - - - - - Uses the ConfigurationStore registered in the kernel to obtain - an associated with the component. - - - - - Queries the kernel's ConfigurationStore for a configuration - associated with the component name. - - - - - - - Check for a node 'parameters' within the component - configuration. For each child it, a ParameterModel is created - and added to ComponentModel's Parameters collection - - - - - Inspect the configuration associated with the component - and populates the parameter model collection accordingly - - - - - - - This implementation of - collects all available constructors and populates them in the model - as candidates. The Kernel will pick up one of the candidates - according to a heuristic. - - - - - Only to hold internal constants and get rid of - magic numbers and hardcode names. - - - - - Inspect the component for InterceptorAttribute and - the configuration for the interceptors node - - - - - Inspects the type looking for interfaces that constitutes - lifecycle interfaces, defined in the Castle.Model namespace. - - - - - Checks if the type implements and or - interfaces. - - - - - - - Inspects the component configuration and the type looking for a - definition of lifestyle type. The configuration preceeds whatever - is defined in the component. - - - This inspector is not guarantee to always set up an lifestyle type. - If nothing could be found it wont touch the model. In this case is up to - the kernel to establish a default lifestyle for components. - - - - - Searches for the lifestyle in the configuration and, if unsuccessful - look for the lifestyle attribute in the implementation type. - - - - - Reads the attribute "lifestyle" associated with the - component configuration and tries to convert to - enum type. - - - - - Check if the type expose one of the lifestyle attributes - defined in Castle.Model namespace. - - - - - Base for inspectors that want configuration associated with methods. - For each child a is created - and added to ComponentModel's methods collection - - - Implementors should override the return - the name of the node to be inspected. For example: - - - - - ]]> - - - - - - This implementation of - collects all potential writable public properties exposed by the component - implementation and populates the model with them. - The Kernel might be able to set some of these properties when the component - is requested. - - - - - Initializes a new instance of the class. - - - - - Adds the properties as optional dependencies of this component. - - - - - - - Represents the collection of information and - meta information collected about a component. - - - - Extended properties - - - Dependencies the kernel must resolve - - - All available constructors - - - All potential properties that can be setted by the kernel - - - Steps of lifecycle - - - External parameters - - - Interceptors associated - - - /// Custom dependencies/// - - - - Constructs a ComponentModel - - - - - Requires the selected property dependencies. - - The property selector. - - - - Requires the property dependencies of type . - - The dependency type. - - - - Sets or returns the component key - - - - - Gets or sets the service exposed. - - The service. - - - - Gets or sets the component implementation. - - The implementation. - - - - Gets or sets a value indicating whether the component requires generic arguments. - - - true if generic arguments are required; otherwise, false. - - - - - Gets or sets the extended properties. - - The extended properties. - - - - Gets the constructors candidates. - - The constructors. - - - - Gets the properties set. - - The properties. - - - - Gets or sets the configuration. - - The configuration. - - - - Gets the lifecycle steps. - - The lifecycle steps. - - - - Gets or sets the lifestyle type. - - The type of the lifestyle. - - - - Gets or sets the strategy for - inspecting public properties - on the components - - - - - Gets or sets the custom lifestyle. - - The custom lifestyle. - - - - Gets or sets the custom component activator. - - The custom component activator. - - - - Gets the interceptors. - - The interceptors. - - - - Gets the parameter collection. - - The parameters. - - - - Dependencies are kept within constructors and - properties. Others dependencies must be - registered here, so the kernel (as a matter - of fact the handler) can check them - - - - - Gets the custom dependencies. - - The custom dependencies. - - - - Represents a constructor of the component - that the container can use to initialize it properly. - - - - - Initializes a new instance of the class. - - The constructor info. - The dependencies. - - - - Gets the ConstructorInfo (from reflection). - - The constructor. - - - - Gets the dependencies this constructor candidate exposes. - - The dependencies. - - - - Collection of - - - - - Gets the fewer arguments candidate. - - The fewer arguments candidate. - - - - Collection of . - - - - - Represents an reference to a Interceptor component. - - - - - Represents obtained just in time object. - - - - - - Resolves object referenced by this reference, optionally using provided . - If object is resolved from the kernel, the should be used to guard - against against cyclic dependencies. - - - - - - - - If the reference introduces dependency on a component, should return for that dependency, otherwise null. - - - - - - - Initializes a new instance of the class. - - The component key. - - - - Initializes a new instance of the class. - - Type of the service. - - - - Gets an for the component key. - - The component key. - The - - - - Gets an for the service. - - The service. - The - - - - Gets an for the service. - - The service type. - The - - - - Collection of - - - - - Adds the specified interceptor as the first. - - The interceptor. - - - - Adds the interceptor to the end of the interceptors list if it does not exist already. - - The interceptor reference. - - - - Adds the specified interceptor as the last. - - The interceptor. - - - - Inserts the specified interceptor at the specified index. - - The index. - The interceptor. - - - - Adds the specified item. - - The interceptor. - - - - Returns an enumerator that can iterate through a collection. - - - An - that can be used to iterate through the collection. - - - - - Gets a value indicating whether this instance has interceptors. - - - true if this instance has interceptors; otherwise, false. - - - - - Gets the number of - elements contained in the . - - - - - - Represents a collection of ordered lifecycle concerns. - - - - - Returns all concerns for the commission phase - - - - - - Returns all concerns for the decommission phase - - - - - - Gets a value indicating whether this instance has commission steps. - - - true if this instance has commission steps; otherwise, false. - - - - - Gets a value indicating whether this instance has decommission steps. - - - true if this instance has decommission steps; otherwise, false. - - - - - Represents meta information associated with a method - (not yet defined) - - - - - Initializes a new instance of the class. - - The config node. - - - - Gets the config node. - - The config node. - - - - Collection of - - - - - Gets the method info2 model. - - The method info2 model. - - - - Represents a parameter. Usually the parameter - comes from the external world, ie, an external configuration. - - - - - Initializes a new instance of the class. - - The name. - The value. - - - - Initializes a new instance of the class. - - The name. - The value. - - - - Gets the name. - - The name. - - - - Gets the value. - - The value. - - - - Gets the config value. - - The config value. - - - - Collection of - - - - - Adds the specified name. - - The name. - The value. - - - - Adds the specified name. - - The name. - The config node. - - - - Determines whether this collection contains the specified key. - - The key. - - true if yes; otherwise, false. - - - - - Adds the specified key. - - - Not implemented - - The key. - The value. - - - - Clears this instance. - - - Not implemented - - - - - Removes the specified key. - - The key. - - Not implemented - - - - - Copy the content to the specified array - - target array - target index - - Not implemented - - - - - Returns an enumerator that can iterate through a collection. - - - An - that can be used to iterate through the collection. - - - - - Gets the keys. - - The keys. - - Not implemented - - - - - Gets the values. - - The values. - - Not implemented - - - - - Gets a value indicating whether this instance is read only. - - - true if this instance is read only; otherwise, false. - - - - - Gets a value indicating whether this instance is fixed size. - - - true if this instance is fixed size; otherwise, false. - - - - - Gets the with the specified key. - - - - - - Gets the count. - - The count. - - - - Gets the sync root. - - The sync root. - - - - Gets a value indicating whether this instance is synchronized. - - - true if this instance is synchronized; otherwise, false. - - - - - Represents a property and the respective dependency. - - - - - Initializes a new instance of the class. - - The property info. - The dependency. - - - - Gets the property. - - The property. - - - - Gets the dependency. - - The dependency. - - - - Collection of - - - - - Finds a PropertySet the by PropertyInfo. - - The info. - - - - - Reference to component obtained from a container. - - - - - - Select the appropriate interceptors based on the application specific - business logic - - - - - Determine whatever the specified has interceptors. - The selector should only return true from this method if it has determined that is - a model that it would likely add interceptors to. - - The model - Whatever this selector is likely to add interceptors to the specified model - - - - Select the appropriate interceptor references. - The interceptor references aren't necessarily registered in the model.Intereceptors - - The model to select the interceptors for - The interceptors selected by previous selectors in the pipeline or if this is the first interceptor in the pipeline. - The interceptor for this model (in the current context) or a null reference - - If the selector is not interested in modifying the interceptors for this model, it - should return and the next selector in line would be executed. - If the selector wants no interceptors to be used it can either return null or empty array. - However next interceptor in line is free to override this choice. - - - - - Represents a reference to an existing object. - - - - - - Defines the contract used by the kernel - to obtain proxies for components. The implementor - must return a proxied instance that dispatch - the invocation to the registered interceptors in the model - - - - - Implementors must create a proxy based on - the information exposed by ComponentModel - - The kernel instance - The component model - The component instance to be proxy (only required in some cases) - array of parameters to the constructor (if any) - The creation context - proxy instance - - - - Implementor should check the component model - and determine if the caller must pass on the component - instance to the proxy - - The kernel instance - The component model - true if an instance must be passed to - - - - Add the selector to the list of selectors that can affect interceptor's decisions - in the container. - - - - - Determines whatever we need to create a proxy for this model - - - - - - - This is a placeholder implementation of . - - - The decision to supply no implementation for - is supported by the fact that the MicroKernel should be a thin - assembly with the minimal set of features, although extensible. - Providing the support for this interface would obligate - the user to import another assembly, even if the large majority of - simple cases, no use use of interceptors will take place. - If you want to use however, see the Windsor container. - - - - - Holds the keys used by the proxy factories. - - - - - Key used to supply custom proxy options. - - - - - Represents options to configure proxies. - - - - - Initializes a new instance of the class. - - - - - - Adds the additional interfaces to proxy. - - The interfaces. - - - - Adds the additional mix ins to integrate. - - The mix ins. - - - - Adds the additional mix in to integrate. - - The mix in. - - - - Equals the specified obj. - - The obj. - true if equal. - - - - Gets the hash code. - - - - - - Gets the additional interfaces to proxy. - - The interfaces. - - - - Determines if the proxied component can change targets. - - - - - Determines if the interface proxied component should inherit - from - - - - - Gets or sets the proxy hook. - - - - - Gets the mix ins to integrate. - - The interfaces. - - - - Determines if the proxied component uses a target. - - - - - Gets or sets the interceptor selector. - - - - - Determines if the proxied component should only include - the service interface. - - - - - Helper support for proxy configuration. - - - - - Obtains the associated with the . - - The component model. - true if the options should be created if not present. - The associated proxy options for the component model. - - - - Constructs the descriptor with name and value. - - The attribute name. - The attribute value. - - - - Constructs the descriptor with name. - - The component. - The attribute name. - - - - Builds the with value. - - The attribute value. - The - - - - Factory for creating objects. - - - - - Creates a component registration for the - - Type of the service. - The component registration. - - - - Creates a component registration for the - - Types of the service. - The component registration.B - - - - Creates a component registration for the - - Types of the service. - The component registration.B - - - - Creates a component registration for the service type. - - The service type. - The component registration. - - - - Create a component registration for an existing - - The component model. - The component registration. - - - - Determines if the component is a Castle component, that is - if it has a . - - true if the service is a Castle Component. - - This method is usually used as argument for method. - - - - - Creates a predicate to check if a component is in a namespace. - - The namespace. - true if the component type is in the namespace. - - - - Creates a predicate to check if a component is in a namespace. - - The namespace. - If set to true, will also include types from subnamespaces. - true if the component type is in the namespace. - - - - Creates a predicate to check if a component shares a namespace with another. - - The component type to test namespace against. - true if the component is in the same namespace. - - - - Creates a predicate to check if a component shares a namespace with another. - - The component type to test namespace against. - If set to true, will also include types from subnamespaces. - true if the component is in the same namespace. - - - - Creates a predicate to check if a component shares a namespace with another. - - The component type to test namespace against. - true if the component is in the same namespace. - - - - Creates a predicate to check if a component shares a namespace with another. - - The component type to test namespace against. - If set to true, will also include types from subnamespaces. - true if the component is in the same namespace. - - - - Determines if the component service is already registered. - - The kernel. - The component model. - true if the service is already registered. - - - - Creates a component registration for the service types. - - The primary service type. - The forwarded type. - The component registration. - - - - Creates a component registration for the service types. - - The primary service type. - The first forwarded type. - The second forwarded type. - The component registration. - - - - Creates a component registration for the service types. - - The primary service type. - The first forwarded type. - The second forwarded type. - The third forwarded type. - The component registration. - - - - Creates a component registration for the service types. - - The primary service type. - The first forwarded type. - The second forwarded type. - The third forwarded type. - The fourth forwarded type. - The component registration. - - - - Inserts a new named argument with given key. If an argument for this name already exists, it will be overwritten. - - - - - Inserts a new typed argument with given type. If an argument for this type already exists, it will be overwritten. - - - - - Inserts a new typed argument with given type. If an argument for this type already exists, it will be overwritten. - - - - - Inserts a set of typed arguments. Property names of the anonymous type will be used as key. - - - - - Inserts a set of typed arguments. Actual type of the arguments will be used as key. - - - - - Delegate to filter component registration. - - The kernel. - The component model. - true if accepted. - - - - Registration for a single type as a component with the kernel. - - You can create a new registration with the factory. - - The service type - - - - The contract for all registrations with the kernel. - - - - - Performs the registration in the . - - The kernel. - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the class - with an existing . - - - - - Marks the components with one or more actors. - - The component actors. - - - - - Set a custom which creates and destroys the component. - - - - - - Adds the attribute descriptor. - - The key. - The value. - - - - - Adds the descriptor. - - The descriptor. - - - - - Creates an attribute descriptor. - - The attribute key. - - - - - Apply more complex configuration to this component registration. - - The config nodes. - - - - - Apply more complex configuration to this component registration. - - The configuration . - - - - - Obsolete, use instead. - - The dependencies. - - - - - Obsolete, use instead. - - The dependencies. - - - - - Obsolete, use instead. - - The dependencies. - - - - - Specify custom dependencies using or . - - You can pass s to specify the components - this component should be resolved with. - - The dependencies. - - - - - Uses a dictionary of key/value pairs, to specify custom dependencies. - - Use to specify the components - this component should be resolved with. - - The dependencies. - - - - - Uses an (anonymous) object as a dictionary, to specify custom dependencies. - - Use to specify the components - this component should be resolved with. - - The dependencies. - - - - - Allows custom dependencies to by defined dyncamically. - - The delegate used for providing dynamic parameters. - - - - - Allows custom dependencies to by defined dynamically with releasing capability. - - The delegate used for providing dynamic parameters. - - - - - Allows custom dependencies to by defined dynamically with releasing capability. - - The delegate used for providing dynamic parameters. - - - Use when resolving components from in order to detect cycles. - - - - - Sets for this component. - - The extended properties. - - - - - Sets for this component. - - The extendend properties as key/value pairs. - - - - - Registers the service types on behalf of this component. - - The types to forward. - - - - - Registers the service types on behalf of this component. - - The forwarded type. - The component registration. - - - - Registers the service types on behalf of this component. - - The first forwarded type. - The second forwarded type. - The component registration. - - - - Registers the service types on behalf of this component. - - The first forwarded type. - The second forwarded type. - The third forwarded type. - The component registration. - - - - Registers the service types on behalf of this component. - - The first forwarded type. - The second forwarded type. - The third forwarded type. - The fourth forwarded type. - The component registration. - - - - Registers the service types on behalf of this component. - - The types to forward. - - - - - Assigns a conditional predication which must be satisfied. - - The component will only be registered into the kernel - if this predicate is satisfied (or not assigned at all). - - The predicate to satisfy. - - - - - Sets the concrete type that implements the service to . - - If not set, the will be used as the implementation for this component. - - The type that is the implementation for the service. - - - - - Sets the concrete type that implements the service to . - - If not set, the will be used as the implementation for this component. - - The type that is the implementation for the service. - - - - - Assigns an existing instance as the component for this registration. - - The component instance. - - - - - Set the interceptors for this component. - - The interceptors. - - - - - Set the interceptors for this component. - - The interceptors. - - - - - Set the interceptor for this component. - - - - - - Set the interceptor for this component. - - - - - - Set the interceptor for this component. - - - - - - Change the name of this registration. - This will be the key for the component in the kernel. - - If not set, the of the - will be used as the key to register the component. - - The name of this registration. - - - - - Stores a set of which will be invoked when the component - is created and before it's returned from the container. - - A set of actions to be executed right after the component is created and before it's returned from the container. - - - - With the overwrite. - - - - - - Set configuration parameters with string or values. - - The parameters. - - - - - Sets the interceptor selector for this component. - - - - - - - Sets the interceptor selector for this component. - - - - - - - Override (some of) the services that this component needs. - Use to create an override. - - Each key represents the service dependency of this component, for example the name of a constructor argument or a property. - The corresponding value is the key of an other component registered to the kernel, and is used to resolve the dependency. - - To specify dependencies which are not services, use - - The service overrides. - - - - - Override (some of) the services that this component needs, using a dictionary. - - Each key represents the service dependency of this component, for example the name of a constructor argument or a property. - The corresponding value is the key of an other component registered to the kernel, and is used to resolve the dependency. - - To specify dependencies which are not services, use - - The service overrides. - - - - - Override (some of) the services that this component needs, using an (anonymous) object as a dictionary. - - Each key represents the service dependency of this component, for example the name of a constructor argument or a property. - The corresponding value is the key of an other component registered to the kernel, and is used to resolve the dependency. - - To specify dependencies which are not services, use - - The service overrides. - - - - - Assigns a conditional predication which must not be satisfied. - - The component will only be registered into the kernel - if this predicate is not satisfied (or not assigned at all). - - The predicate not to satisfy. - - - - - Uses a factory to instantiate the component - - Factory type. This factory has to be registered in the kernel. - Implementation type. - Factory invocation - - - - - Uses a factory method to instantiate the component. - - Implementation type - Factory method - - - - - Uses a factory method to instantiate the component. - - Implementation type - Factory method - - - - - Uses a factory method to instantiate the component. - - Implementation type - Factory method - - - - - Uses a factory method to instantiate the component. - - Implementation type - Factory method - - - - - Registers this component with the . - - The kernel. - - - - Gets the forwarded service types on behalf of this component. - - Add more types to forward using . - - The types of the forwarded services. - - - - The concrete type that implements the service. - - To set the implementation, use . - - The implementation of the service. - - - - Set the lifestyle of this component. - For example singleton and transient (also known as 'factory'). - - The with lifestyle. - - - - The name of the component. Will become the key for the component in the kernel. - - To set the name, use . - - If not set, the of the - will be used as the key to register the component. - - The name. - - - - Set proxy for this component. - - The proxy. - - - - The type of the service, the same as . - - This is the first type passed to . - - The type of the service. - - - - A non-generic . - - You can create a new registration with the factory. - - - - - Represents a configuration child. - - - - - Applies the configuration node. - - The configuration. - - - - Represents a configuration attribute. - - - - - Applies the configuration node. - - The configuration. - - - - Create a with name. - - The attribute name. - The new - - - - Represents a named attribute. - - - - - Builds the with name/value. - - The attribute value. - The new - - - - Builds the with name/value. - - The attribute value. - The new - - - - Represents a configuration child. - - - - - Create a with name. - - The child name. - The new - - - - Represents a named child. - - - - - Builds the with name/value. - - The child value. - The new - - - - Builds the with name/value. - - The child value. - The new - - - - Builds the with name/config. - - The child configuration. - The new - - - - Builds the with name/config. - - The child nodes. - The new - - - - Applies the configuration node. - - The configuration. - - - - Represents a simple child node. - - - - - Applies the configuration node. - - The configuration. - - - - Represents a complex child node. - - - - - Applies the configuration node. - - The configuration. - - - - Represents a compound child node. - - - - - Applies the configuration node. - - The configuration. - - - - The contract to install components in the container. - - - - - Performs the installation in the . - - The container. - The configuration store. - - - - Adds the actions to ExtendedProperties. - - - - - - Sets the lifestyle to the specified . - - The type. - - - - - Assign a custom lifestyle type, that implements . - - Type of the custom lifestyle. - - - - - Assign a custom lifestyle type, that implements . - - The type of the custom lifestyle - - - - - Represents a configuration parameter. - - - - - Create a with key. - - The parameter key. - The new - - - - Gets the parameter key. - - - - - Gets the parameter value. - - - - - Gets the parameter configuration. - - - - - Represents a parameter key. - - - - - Builds the with key/value. - - The parameter value. - The new - - - - Builds the with key/config. - - The parameter configuration. - The new - - - - The parameter key name. - - - - - Represents a key/value pair. - - - - - Create a with key. - - The property key. - The new - - - - Create a with key. - - The property key. - The new - - - - Create a with key. - - The property key. - The new - - - - Gets the property key. - - - - - Gets the property value. - - - - - Represents a property key. - - - - - Builds the with key/value. - - The property value. - The new - - - - Builds a service override using other component registered with given as value for dependency with given . - - - - - - - Builds a service override using other component registered with given and no explicit name, as value for dependency with given . - - - - - - Builds a service override using other component registered with given and no explicit name, as value for dependency with given . - - - - - - The property key key. - - - - - Represents a service override. - - - - - Creates a with key. - - The service override key. - The new - - - - Creates a with key. - - The service override key. - The new - - - - Creates a with key. - - The service override key. - The new - - - - Gets the optional value type specifier. - - - - - Represents a service override key. - - - - - Builds the with key/value. - - The service override value. - The new - - - - Builds the with key/values. - - The service override values. - The new - - - - Builds the with key/values. - - The service override values. - The new - The value type. - - - - Builds the with key/values. - - The service override values. - The new - - - - Builds the with key/values. - - The service override values. - The new - The value type. - - - - Describes a set of components to register in the kernel. - - - - - Describes all the types based on basedOn. - - The base type. - - - - - Describes all the types based on type T. - - The base type. - - - - - Describes any types that are supplied. - - - - - - Prepares to register types from an assembly. - - The assembly name. - The corresponding - - - - Prepares to register types from an assembly. - - The assembly. - The corresponding - - - - Prepares to register types from an assembly containing the type. - - The type belonging to the assembly. - The corresponding - - - - Prepares to register types from an assembly containing the type. - - The type belonging to the assembly. - The corresponding - - - - Prepares to register types from the assembly containing the code invoking this method. - - The corresponding - - - - Prepares to register types from assemblies found in a given directory that meet additional optional restrictions. - - - - - - - Prepares to register types from a list of types. - - The list of types. - The corresponding - - - - Prepares to register types from a list of types. - - The list of types. - The corresponding - - - - Prepares to register types from a list of types. - - The list of types. - The corresponding - - - - Describes a related group of components to register in the kernel. - - - - - Prepares to register types from an assembly. - - The assembly name. - The corresponding - - - - Prepares to register types from an assembly. - - The assembly. - The corresponding - - - - Prepares to register types from a list of types. - - The list of types. - The corresponding - - - - Prepares to register types from a list of types. - - The list of types. - The corresponding - - - - Prepares to register types from a list of types. - - The list of types. - The corresponding - - - - Describes a configuration. - - - - - Initializes a new instance of the ConfigureDescriptor. - - The - The configuration action. - - - - Initializes a new instance of the ConfigureDescriptor. - - The - The base type to match. - The configuration action. - - - - Allows customized configurations of each matching type. - - The configuration action. - - - - - Allows customized configurations of each matching type. - - The configuration action. - - - - - Allows customized configurations of each matching type that is - assignable to . - - The type assignable from. - The configuration action. - - - - - Allows customized configurations of each matching type that is - assignable to . - - The type assignable from. - The configuration action. - - - - - Performs the component configuration. - - The component registration. - - - - Selects a set of types from an assembly. - - - - - Describes the source of types to register. - - - - - Allows a type to be registered multiple times. - - - - - Returns the descriptor for accepting a type. - - The base type. - The descriptor for the type. - - - - Returns the descriptor for accepting a type. - - The base type. - The descriptor for the type. - - - - Returns the descriptor for accepting any type from given solutions. - - - - - - Returns the descriptor for accepting a type based on a condition. - - The accepting condition. - The descriptor for the type. - - - - Selects an existing set of types to register. - - - - - Describes how to select a types service. - - - - - Uses the base type matched on. - - - - - - Uses the type itself. - - - - - - Uses all interfaces implemented by the type (or its base types) as well as their base interfaces. - - - - - - Uses all interfaces that have names matched by implementation type name. - Matches Foo to IFoo, SuperFooExtended to IFoo and IFooExtended etc - - - - - - Uses the first interface of a type. This method has non-deterministic behavior when type implements more than one interface! - - - - - - Uses to lookup the sub interface. - For example: if you have IService and - IProductService : ISomeInterface, IService, ISomeOtherInterface. - When you call FromInterface(typeof(IService)) then IProductService - will be used. Useful when you want to register _all_ your services - and but not want to specify all of them. - - - - - - - Uses base type to lookup the sub interface. - - - - - - Assigns a custom service selection strategy. - - - - - - - Assigns the supplied service types. - - - - - - - This is a workaround for a CLR bug in - which GetInterfaces() returns interfaces - with no implementations. - - Type of the service. - - - - - Delegate for custom registration configuration. - - The component registration. - Not used. - - - - Describes how to register a group of related types. - - - - - Initializes a new instance of the BasedOnDescriptor. - - - - - Allows a type to be registered multiple times. - - - - - Returns the descriptor for accepting a new type. - - The base type. - The descriptor for the type. - - - - Returns the descriptor for accepting a new type. - - The base type. - The descriptor for the type. - - - - Allows customized configurations of each matching type. - - The configuration action. - - - - - Allows customized configurations of each matching type. - - The configuration action. - - - - - Allows customized configurations of each matching type that is - assignable to - - . - - The type assignable from. - The configuration action. - - - - - Allows customized configurations of each matching type that is - assignable to - - . - - The type assignable from. - The configuration action. - - - - - Assigns a conditional predication which must be satisfied. - - The predicate to satisfy. - - - - - Assigns a conditional predication which must not be satisfied. - - The predicate not to satisify. - - - - - Returns the descriptor for accepting a type based on a condition. - - The accepting condition. - The descriptor for the type. - - - - Gets the type all types must be based on. - - - - - Gets the service descriptor. - - - - - Policy managing lifetime of components, and in particular their release process. - - - - - Only tracks components that have decommission steps - registered or have pooled lifestyle. - - - - - No tracking of component instances are made. - - - - - Default implementation for . - This implementation is quite simple, but still should be useful - for 99% of situations. - - - - - Implementors should use a strategy to obtain - valid references to properties and/or services - requested in the dependency model. - - - - - This method is called with a delegate for firing the - IKernelEvents.DependencyResolving event. - - kernel - The delegate used to fire the event - - - - Registers a sub resolver instance - - The subresolver instance - - - - Unregisters a sub resolver instance previously registered - - The subresolver instance - - - - Initializes this instance with the specified dependency delegate. - - kernel - The dependency delegate. - - - - Registers a sub resolver instance - - The subresolver instance - - - - Unregisters a sub resolver instance previously registered - - The subresolver instance - - - - Returns true if the resolver is able to satisfy the specified dependency. - - Creation context, which is a resolver itself - Parent resolver - Model of the component that is requesting the dependency - The dependency model - - true - if the dependency can be satisfied - - - - Try to resolve the dependency by checking the parameters in - the model or checking the Kernel for the requested service. - - - The dependency resolver has the following precedence order: - - - The dependency is checked within the - - - - - The dependency is checked within the - - instance for the component - - - The dependency is checked within the registered - - s - - - Finally the resolver tries the normal flow - which is using the configuration - or other component to satisfy the dependency - - - - Creation context, which is a resolver itself - Parent resolver - Model of the component that is requesting the dependency - The dependency model - The dependency resolved value or null - - - - Extracts the component name from the a ref strings which is - ${something} - - - - - - - - This method rebuild the context for the parameter type. - Naive implementation. - - - - - Summary description for DependencyResolverException. - - - - - Initializes a new instance of the class. - - The message. - The inner exception. - - - - Initializes a new instance of the class. - - The message. - - - - Initializes a new instance of the class. - - The object that holds the serialized object data. - The contextual information about the source or destination. - - - - Handle dependencies of services in the format of typed arrays. - - - This is a complimentary implementation - that is capable of satisfying dependencies of services as typed arrays. - - Note that it will take precedence over service override for arrays defined - on the configuration. - - - - In order to install the resolver: - - var kernel = new DefaultKernel(); - kernel.Resolver.AddSubResolver(new ArrayResolver(kernel)); - - - - To use it, assuming that IService is on the container: - - - - public class Component - { - public Component(IService[] services) - { - } - } - - - - - - More generic alternative to and . - It supports arrays as well as any generic interface type assignable from arrays. - - - The collection instance that is provided is read only, even for interfaces like - - - - - Handle dependencies of services in the format of generic IList. - - - This is a complimentary implementation - that is capable of satisfying dependencies of services generic IList. - - Note that it will take precedence over service override for lists defined - on the configuration. - - - - In order to install the resolver: - - var kernel = new DefaultKernel(); - kernel.Resolver.AddSubResolver(new ListResolver(kernel)); - - - - To use it, assuming that IService is on the container: - - - - public class Component - { - public Component(IList<IService> services) - { - } - } - - - - - - A subsystem is used by the MicroKernel to deal - with a specific concern. - - - - - Initializes the subsystem - - - - - - Should perform the termination - of the subsystem instance. - - - - - This implementation of - does not try to obtain an external configuration by any means. - Its only purpose is to serve as a base class for subclasses - that might obtain the configuration node from anywhere. - - - - - The contract used by the kernel to obtain - external configuration for the components and - facilities. - - - - - Associates a configuration node with a facility key - - item key - Configuration node - - - - Associates a configuration node with a component key - - item key - Configuration node - - - - Associates a configuration node with a bootstrap component key - - item key - Configuration node - - - - Adds the child container configuration. - - The container's name. - The config. - - - - Returns the configuration node associated with - the specified child container key. Should return null - if no association exists. - - item key - - - - - Returns the configuration node associated with - the specified facility key. Should return null - if no association exists. - - item key - - - - - Returns the configuration node associated with - the specified component key. Should return null - if no association exists. - - item key - - - - - Returns the configuration node associated with - the specified component key. Should return null - if no association exists. - - item key - - - - - Returns all configuration nodes for facilities - - - - - - Returns all configuration nodes for components - - - - - - Returns all configuration nodes for installers - - - - - - Returns all configuration nodes for bootstrap components - - - - - - Gets the child containers configuration nodes. - - - - - - - - - - - - - - Initializes a new instance of the class. - - - - - Associates a configuration node with a facility key - - item key - Configuration node - - - - Associates a configuration node with a component key - - item key - Configuration node - - - - Associates a configuration node with a bootstrap component key - - - - - Adds the child container configuration. - - The key. - The config. - - - - Returns the configuration node associated with - the specified facility key. Should return null - if no association exists. - - item key - - - - - Returns the configuration node associated with - the specified child container key. Should return null - if no association exists. - - item key - - - - - Returns the configuration node associated with - the specified component key. Should return null - if no association exists. - - item key - - - - - Returns the configuration node associated with - the specified component key. Should return null - if no association exists. - - - - - - - Returns all configuration nodes for facilities - - - - - - Returns all configuration nodes for bootstrap components - - - - - - Returns all configuration nodes for child containers - - - - - - Returns all configuration nodes for components - - - - - - Base implementation of - - - - - Implements a conversion logic to a type of a - set of types. - - - - - Returns true if this instance of ITypeConverter - is able to handle the specified type. - - - - - - - Returns true if this instance of ITypeConverter - is able to handle the specified type with the specified - configuration - - - - - - - - Should perform the conversion from the - string representation specified to the type - specified. - - - - - - - - Should perform the conversion from the - configuration node specified to the type - specified. - - - - - - - - Returns true if this instance of ITypeConverter - is able to handle the specified type with the specified - configuration - - - - - - The default behavior is to just pass it to the normal CanHadnleType - peeking into the configuration is used for some advanced functionality - - - - - Summary description for ConverterException. - - - - - Initializes a new instance of the class. - - The message. - - - - Initializes a new instance of the class. - - The message. - The inner exception. - - - - Initializes a new instance of the class. - - The object that holds the serialized object data. - The contextual information about the source or destination. - - - - Looks for a on the type to be converted. - If found, the TypeConverter defined by the attribute is used to perform the conversion. - - - - - Marker interface that signals that a converter - depends on IKernel to be able to perform - the conversion. - - - - - Attempts to utilize an existing for conversion - - - - - Creates the target type instance. - - The type. - The configuration. - - - - - Chooses the first non default constructor. Throws an exception if more than - one non default constructor is found - - - The chosen constructor, or null if none was found - - - - Converts the constructor parameters. - - The constructor. - The configuration. - - - - - Converts the property values. - - The instance. - The type. - The configuration. - - - - Finds the child (case insensitive). - - The config. - The name. - - - - - Gets the conversion manager. - - The conversion manager. - - - - Converts a string representation to an enum value - - - - - Initializes a new instance of the class. - - - - - This interface is needed because we want to isolate ourself from - the generic parameters, so we can work type safe inside the implementations, - and still call from non generic types outside. - - - - - Implements all standard conversions. - - - - - Convert a type name to a Type instance. - - - - - Declares a type as being convertible by a and optionally defines the converter to be used - - - - - Defines the to be used to convert the type - - - - - Defines the to be used to convert the type - - - - - - Composition of all available conversion managers - - - - - Establish a composition interface and a subsystem. - Implementors should delegate the conversion to - a instance of a type converter. - - - - - Register a type converter instance. - - - - - - Method finds the next biggest node - It assumes Add puts lesser nodes on the right - - - - Node's left - - - Node's right - - - Node's parent - - - DA Linked List - - - - Creates a ComponentName using a name pattern like - "service:key=value,key2=value2" - - Complete name - - - - Creates a ComponentName with specified service and - properties. - - Service name - Property list. - - - - Serialization constructor. - - - - - - - Parses the full name extracting the service and properties. - - Full name. - - - - Sets up the service. Can be empty but can't be null. - - - - - - Parses and validate a properties list string like - "key=value,key2=value2" and so on. - - Property list. - - - - Validates a properties IDictionary. - - Property list. - - - - Default implementation. - Keeps services map as a simple hash table. - Keeps key map as a list dictionary to maintain order. - Does not support a query string. - - - - - Contract for SubSystem that wishes to keep and coordinate - component registration. - - - - - Register a new component resolver that can take part in the decision - making about which handler to resolve - - - - - Returns true if there is a component registered - for the specified key - - - - - - - Returns true if there is a component registered - for the specified service - - - - - - - Return s where components are compatible - with the specified service. - - - - - - - Returns the associated with - the specified key. - - - - - - - Returns the associated with - the specified service. - - - - - Returns the associated with - the specified key with the service type. - - It is expected that this will be used mainly to resolve a generic service - by its key. - - - - - - Returns an array of that - satisfies the specified query. - - - - - - - Returns an array of associated with - the specified service. - - - - - - - Returns all registered. - - - - - - List of handler by key - - - - - List of handler by service - - - - - Implementors should register the key and service pointing - to the specified handler - - - - - - - Unregister the handler by the given key - - - - - - Unregister the handler by the given service - - - - - - Returns the number of components registered. - - - - - Associates a with - the specified service - - - - - Associates a with - the specified key - - - - - Map(String, IHandler) to map component keys - to - Items in this dictionary are sorted in insertion order. - - - - - Map(Type, IHandler) to map a service - to . - If there is more than a single service of the type, only the first - registered services is stored in this dictionary. - It serve as a fast lookup for the common case of having a single handler for - a type. - - - - - Initializes a new instance of the class. - - - - - Implementors of this interface allow to extend the way the container perform - component resolution based on some application specific business logic. - - - This is the sibling interface to . - This is dealing strictly with root components, while the is dealing with - dependent components. - - - - - Whatever the selector has an opinion about resolving a component with the - specified service and key. - - The service key - can be null - The service interface that we want to resolve - - - - Select the appropriate handler from the list of defined handlers. - The returned handler should be a member from the array. - - The service key - can be null - The service interface that we want to resolve - The defined handlers - The selected handler, or null - - - - When requesting a component by service, KeySearchNamingSubSystem first - determines if more than one component has been registered for that service. - If not, Default resolution occurs. If so, all of the registered keys for - that service are processed through the provided Predicate to determine which - key to use for service resolution. If no Predicate matches, the default - resolution occurs. - - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the class. - - The key predicate. - - - - Registers the given handler with the give key. - - The key. - The handler. - - - - Unregisters the handler associated with the given key - - The key. - - - - Unregisters the handler associated with the given service - - The service. - - - - Executes the Predicate against all keys for the registered service to - determine which component to return. - - The service. - - - - - Alternative implementation. - Extends the default implementation replacing the - key support with a more complete ComponentName. Supports - queries. - - - The user must register components using the following construction - - service:properties - - Where properties is a list of key value pairs (comma separated). Example: - - protocol:secure=true,version=1.2 - - The user can then query for components using the same construction: - - protocol:secure=true - - Or to return all: - - protocol:* - - - - - - Pendent - - - - - An implementation of a should - be able to return instances of - for a given resource identifier. - - - - - Holds the keys used by Kernel to register/request - a subsystem. - - - - - Key used for the configuration store subsystem - - - - - Key used for the conversion manager - - - - - Key used for the naming subsystem - - - - - Key used for the resource subsystem - - - - - Compares if the reference of two objects are equals. - - - - - Summary description for ReferenceExpressionUtil. - - - - - Integrates the to the System.ComponentModel - and System.ComponentMode.Design infrastructure. - - - - - - - - This interface should be implemented by classes - that are available in a bigger context, exposing - the container to different areas in the same application. - - For example, in Web application, the (global) HttpApplication - subclasses should implement this interface to expose - the configured container - - - - - - Custom activator to create the instance on demand. - - - - - Implementation of . - Do not support configuration inheritance. - - - - - Interpreter of a specific language to describe - configuration nodes in a hierarchical manner. - - - - - Should obtain the contents from the resource, - interpret it and populate the - accordingly. - - - - - - - Gets or sets the name of the environment. - - The name of the environment. - - - - Exposes the reference to - which the interpreter is likely to hold - - - - - Provides common methods for those who wants - to implement - - - - - Should obtain the contents from the resource, - interpret it and populate the - accordingly. - - - - - - - Exposes the reference to - which the interpreter is likely to hold - - - - - - Gets or sets the name of the environment. - - The name of the environment. - - - - Reads the configuration from a XmlFile. Sample structure: - - <configuration> - <facilities> - <facility id="myfacility"> - - </facility> - </facilities> - - <components> - <component id="component1"> - - </component> - </components> - </configuration> - - - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the class. - - The filename. - - - - Initializes a new instance of the class. - - The source. - - - - Gets or sets the kernel. - - The kernel. - - - - Initializes a new instance of the class. - - Name of the environment. - - - - Initializes a new instance of the class. - - Name of the environment. - The resource sub system. - - - - Processes the element. - - The element. - - - - - Processes the element. - - The element. - - - - - Make a shallow copy of the nodeList. - - The nodeList to be copied. - - - - - Accepts the specified node. - Check if node has the same name as the processor and the node.NodeType - is in the AcceptNodeTypes List - - The node. - - - - - Convert and return child parameter into an XmlElement - An exception will be throw in case the child node cannot be converted - - Parent node - Node to be converted - child node as XmlElement - - - - - - - - - - - - attributeValue - - propertyValue - - - - - - - Processes the specified node list. - - The node list. - The engine. - - - - Processes element attributes. - if the attribute is include will append to the element - all contents from the file. - if the attribute has a property reference the reference will be - expanded - - The element. - - - - - Properties names can contain a-zA-Z0-9_. - i.e. #!{ my_node_name } || #{ my.node.name } - spaces are trimmed - - - - - Processes the string. - - The node. - The value. - The context. - - - - Accepts the specified node. - Check if node has the same name as the processor and the node.NodeType - is in the AcceptNodeTypes List - NOTE: since the BatchRegistrationFacility already uses an include - element we will distinguish between both by looking for the presence of an uri attribute - we should revisit this later by using xml-namespaces - - The node. - - - - - - - - - - - - - attributeValue - - propertyValue - - - - - - - Pendent - - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the class. - - Name of the environment. - The resource sub system. - - - - Initializes a new instance of the class. - - - - - Gets the environment information (name). Implementors should - use to define their environments and how those affect the configuration. - - - - - Gets the name of the environment. - - - - - - Installs all the components from the App.Config file. - - - - - - Installs all the component from the xml configuration file. - - The xml configuration file. - - - - - Installs all the component from the xml configuration. - - The xml configuration resource. - - - - - Delegate to provide environment name. - - The environment name. - - - - Initializes a new instance of the ConfigurationInstaller class. - - - - - Sets the configuration environment name. - - The environment name. - - - - - Set the configuration environment strategy. - - The environment strategy. - - - - - Default implementation. - - - - - Installs the components and facilities based on the - information on the configuration store. - - - - - Perform installation. - - Target container - Configuration store - - - - Perform installation. - - Target container - Configuration store - - - - Scans the assembly containing specified type for types implementing , instantiates them and returns so that can install them. - - - - - - Scans the assembly containing specified type for types implementing , instantiates using given and returns so that can install them. - - - - - - Scans the assembly containing specified type for types implementing , instantiates them and returns so that can install them. - - - - - - Scans the assembly containing specified type for types implementing , instantiates using given and returns so that can install them. - - - - - - Scans the specified assembly with specified name for types implementing , instantiates them and returns so that can install them. - - - - - - Scans the specified assembly with specified name for types implementing , instantiates using given and returns so that can install them. - - - - - - Scans the assembly with specified name for types implementing , instantiates them and returns so that can install them. - - - - - - Scans the assembly with specified name for types implementing , instantiates using given and returns so that can install them. - - - - - - Scans assembly that contains code calling this method for types implementing , - instantiates them and returns so that can install them. - - - - - - Scans assembly that contains code calling this method for types implementing , instantiates using given and returns so that can install them. - - - - - - Scans assemblies in directory specified by for types implementing , instantiates and returns so that can install them. - - - - - - - Scans assemblies in directory specified by for types implementing , instantiates using given and returns so that can install them. - - - - - - - - Helper class used by to filter/order and instantiate implementations - - - - - Performs custom instantiation of given - - - Default implementation uses public parameterless constructor to create the instance. - - - - - Performs custom filtering/ordering of given set of types. - - Set of concrete class types implementing interface. - Transformed . - Default implementation simply returns types passed into it. - - - - The IWindsorContainer interface exposes all the - functionality the Windsor implements. - - - - - Registers a subcontainer. The components exposed - by this container will be accessible from subcontainers. - - - - - - Registers a facility within the container. - - The key by which the gets indexed. - The to add to the container. - - - - Creates and adds an facility to the container. - - The facility type. - - - - - - Creates and adds an facility to the container. - - The facility type. - - The callback for creation. - - - - - Creates and adds an facility to the container. - - The facility type. - - The callback for creation. - - - - - Creates and adds an facility to the container. - - The facility type. - - - - - Creates and adds an facility to the container. - - The facility type. - The callback for creation. - - - - - Creates and adds an facility to the container. - - The facility type. - The callback for creation. - - - - - Gets a child container instance by name. - - The container's name. - The child container instance or null - - - - Installs the components provided by the s - with the . - The component installers. - The container. - - - - - Registers the components provided by the s - with the . - - Create a new registration using .For() or . - - - - container.Register(Component.For<IService>().ImplementedBy<DefaultService>()); - - - The component registrations. - The container. - - - - Releases a component instance - - - - - - Remove a child container - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the service - - - - - - - Returns a component instance by the service - - - - - - - - Returns a component instance by the service - - - - - - - - Returns a component instance by the service - - Service type - The component instance - - - - Returns a component instance by the service - - Service type - - The component instance - - - - Returns a component instance by the service - - Service type - - The component instance - - - - Returns a component instance by the key - - Component's key - Service type - The Component instance - - - - Returns a component instance by the key - - Service type - Component's key - - The Component instance - - - - Returns a component instance by the key - - Service type - Component's key - - The Component instance - - - - Returns a component instance by the key - - - - - - - - - Returns a component instance by the key - - - - - - - - - Resolve all valid components that match this type. - - The service type - - - - Resolve all valid components that match this service - the service to match - - - - - Resolve all valid components that match this service - the service to match - Arguments to resolve the service - - - - - Resolve all valid components that match this service - the service to match - Arguments to resolve the service - - - - - Resolve all valid components that match this type. - The service type - Arguments to resolve the service - - - - - Resolve all valid components that match this type. - The service type - Arguments to resolve the service - - - - - Returns the inner instance of the MicroKernel - - - - - Gets the container's name - - - Only useful when child containers are being used - - The container's name. - - - - Gets or sets the parent container if this instance - is a sub container. - - - - - Obtains the interceptors associated with the component. - - The kernel instance - The component model - The creation context - interceptors array - - - - This implementation of relies - on DynamicProxy to expose proxy capabilities. - - - Note that only virtual methods can be intercepted in a - concrete class. However, if the component - was registered with a service interface, we proxy - the interface and the methods don't need to be virtual, - - - - - Constructs a DefaultProxyFactory - - - - - Creates the proxy for the supplied component. - - The kernel. - The target. - The model. - The constructor arguments. - The creation context - The component proxy. - - - - Determines if the component requires a target instance for proxying. - - The kernel. - The model. - true if an instance is required. - - - - Implementation of - which delegates to implementation. - - - - - Constructs a container without any external - configuration reference - - - - - Constructs a container using the specified - implementation. - - The instance of an implementation. - - - - Constructs a container using the specified - implementation. - - The instance of an implementation. - - - - Initializes a new instance of the class. - - The interpreter. - The environment info. - - - - Initializes a new instance of the class using a - xml file to configure it. - - Equivalent to the use of new WindsorContainer(new XmlInterpreter(xmlFile)) - - - The XML file. - - - - Constructs a container using the specified - implementation. Rarely used. - - - This constructs sets the Kernel.ProxyFactory property to - Proxy.DefaultProxyFactory - - Kernel instance - Installer instance - - - - Constructs a container using the specified - implementation. Rarely used. - - - This constructs sets the Kernel.ProxyFactory property to - Proxy.DefaultProxyFactory - - Container's name - Kernel instance - Installer instance - - - - Constructs with a given . - - A instance of an . - - - - Constructs a container assigning a parent container - before starting the dependency resolution. - - The instance of an - The instance of an implementation - - - - Initializes a new instance of the class. - - The container's name. - The parent. - The interpreter. - - - - Executes Dispose on underlying - - - - - Gets the service object of the specified type. - - - A service object of type serviceType. - - An object that specifies the type of service object to get. - - - - Gets the service object of the specified type. - - - A service object of type serviceType. - - - - - Registers a subcontainer. The components exposed - by this container will be accessible from subcontainers. - - - - - - Registers a facility within the kernel. - - - - - - - Creates and adds an facility to the container. - - The facility type. - - - - - - Creates and adds an facility to the container. - - The facility type. - - The callback for creation. - - - - - Creates and adds an facility to the container. - - The facility type. - - The callback for creation. - - - - - Creates and adds an facility to the container. - - The facility type. - - - - - Creates and adds an facility to the container. - - The facility type. - The callback for creation. - - - - - Creates and adds an facility to the container. - - The facility type. - The callback for creation. - - - - - Gets a child container instance by name. - - The container's name. - The child container instance or null - - - - Installs the components provided by the s - with the . - The component installers. - The container. - - - - - Registers the components described by the s - with the . - The component registrations. - The container. - - - - - Releases a component instance - - - - - - Removes (unregisters) a subcontainer. The components exposed by this container - will no longer be accessible to the child container. - - - - - - Returns a component instance by the service - - - - - - - - Returns a component instance by the service - - - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the service - - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the key - - - - - - - - - Returns a component instance by the key - - - - - - - - - Returns a component instance by the service - - - - - - - - Returns a component instance by the service - - - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the key - - - - - - - - Returns a component instance by the service - - - - - - - Returns a component instance by the key - - - - - - - Resolve all valid components that match this type. - - The service type - - - - Resolve all valid components that match this type. - The service type - Arguments to resolve the service - - - - - Resolve all valid components that match this type. - The service type - Arguments to resolve the service - - - - - Returns the inner instance of the MicroKernel - - - - - Gets the container's name - - - Only useful when child containers are being used - - The container's name. - - - - Gets or sets the parent container if this instance - is a sub container. - - - - - Implementation of that assumes ownership of the - wrapped . If this adapter is disposed, the underlying - is diposed as well. - - - - - Implementation of that does not assume ownership of the - wrapped . - - - - - Constructs an initial ContainerWrapper. - - The to adapt. - - - - Constructs an initial ContainerWrapper. - - The to adapt. - The parent . - - - - Adds the specified to the at the end of the list. - - The to add. - - - - Adds the specified to the at the end of the list, - and assigns a name to the component. - - The to add. - The unique, case-insensitive name to assign to the component, or null. - - - - Removes a component from the . - - The to remove - - - - Gets the service object of the specified type. - - The type of service. - An object implementing service, or null. - - - - Adds the specified service to the service container. - - The type of service to add. - The instance of the service to add. - - - - Adds the specified service to the service container. - - The type of service to add. - A callback object that is used to create the service. - - - - Adds the specified service to the service container, and optionally - promotes the service to any parent service containers. - - The type of service to add. - The instance of the service to add. - true to promote this request to any parent service containers. - - - - Adds the specified service to the service container, and optionally - promotes the service to parent service containers. - - The type of service to add. - A callback object that is used to create the service. - true to promote this request to any parent service containers. - - - - Removes the specified service type from the service container. - - The type of service to remove. - - - - Removes the specified service type from the service container, - and optionally promotes the service to parent service containers. - - The type of service to remove. - true to promote this request to any parent service containers. - - - - Determines if the service type represents an intrinsic service. - - The type of service to remove. - true if the service type is an intrinsic service. - - - - Determines if the specified service type exists in the service container. - - The type of service to remove. - true if the service type exists. - - - - Releases the resources used by the component. - - - - - Releases the resources used by the component. - - true if disposing. - - - - Gets or sets the associated with the . - - - - - Event that notifies the disposal of the . - - - - - Gets all the components in the . - - - - - Gets the adapted - - - - - Constructs a default ContainerAdapter. - - - - - Constructs a chained ContainerAdapter. - - The parent . - - - - Constructs an initial ContainerAdapter. - - The to adapt. - - - - Constructs an initial ContainerAdapter. - - The to adapt. - The parent . - -
-
diff --git a/Redist/Castle/Castle.Windsor.dll b/Redist/Castle/Castle.Windsor.dll deleted file mode 100644 index 6a85bd24d..000000000 Binary files a/Redist/Castle/Castle.Windsor.dll and /dev/null differ diff --git a/Redist/Oracle/x64/Oracle.DataAccess.dll b/Redist/Oracle/x64/Oracle.DataAccess.dll new file mode 100644 index 000000000..389947e01 Binary files /dev/null and b/Redist/Oracle/x64/Oracle.DataAccess.dll differ diff --git a/Source/Aspects/CounterAspect.cs b/Source/Aspects/CounterAspect.cs index 4786b5ed8..24eb4c5f5 100644 --- a/Source/Aspects/CounterAspect.cs +++ b/Source/Aspects/CounterAspect.cs @@ -16,8 +16,8 @@ public class CounterAspect : Interceptor public override void Init(CallMethodInfo info, string configString) { base.Init(info, configString); - - _counters.Add(_counter = CreateCounter(info) ?? CreateCounterInternal(info)); + + _counters.Add(_counter = CreateCounter(info) ?? CreateCounterInternal(info)); } private MethodCallCounter _counter; diff --git a/Source/BLToolkit.4.csproj b/Source/BLToolkit.4.csproj index 1e4760c52..6a584459e 100644 --- a/Source/BLToolkit.4.csproj +++ b/Source/BLToolkit.4.csproj @@ -172,6 +172,9 @@ DataProviderBase.cs + + DataProviderBase.cs + @@ -196,28 +199,29 @@ + - - - + - + + - - + - + + Component + @@ -544,6 +548,8 @@ + + diff --git a/Source/BLToolkit.CP.4.csproj b/Source/BLToolkit.CP.4.csproj index 24f93488d..125270a05 100644 --- a/Source/BLToolkit.CP.4.csproj +++ b/Source/BLToolkit.CP.4.csproj @@ -197,23 +197,24 @@ - + - - + + Component + @@ -510,6 +511,8 @@ + + diff --git a/Source/BLToolkit.Data.4.csproj b/Source/BLToolkit.Data.4.csproj index eaca190e5..897d6a281 100644 --- a/Source/BLToolkit.Data.4.csproj +++ b/Source/BLToolkit.Data.4.csproj @@ -258,23 +258,24 @@ - + - - + + Component + diff --git a/Source/BLToolkit.SL.4.csproj b/Source/BLToolkit.SL.4.csproj index d55d2d550..52b020a54 100644 --- a/Source/BLToolkit.SL.4.csproj +++ b/Source/BLToolkit.SL.4.csproj @@ -110,7 +110,6 @@ - diff --git a/Source/BLToolkit.mono.csproj b/Source/BLToolkit.mono.csproj index d06b1c493..cc71dc941 100644 --- a/Source/BLToolkit.mono.csproj +++ b/Source/BLToolkit.mono.csproj @@ -159,9 +159,13 @@ + + + + @@ -170,6 +174,7 @@ + @@ -199,6 +204,7 @@ + diff --git a/Source/Data/DataProvider/DataProviderBase.cs b/Source/Data/DataProvider/DataProviderBase.cs index f5a053fd6..8acf77382 100644 --- a/Source/Data/DataProvider/DataProviderBase.cs +++ b/Source/Data/DataProvider/DataProviderBase.cs @@ -396,29 +396,40 @@ public void Dispose() #endregion #region Implementation of IDataRecord - - public string GetName (int i) { return DataReader.GetName (i); } - public string GetDataTypeName(int i) { return DataReader.GetDataTypeName(i); } - public Type GetFieldType (int i) { return DataReader.GetFieldType (i); } - // GetValue method is virtual since it can be overridden by some data provider - // (For instance, OdbDataProvider uses special methodes for clob data fetching) - public virtual object GetValue (int i) { return DataReader.GetValue (i); } - public int GetValues (object[] values) { return DataReader.GetValues (values); } - public int GetOrdinal (string name) { return DataReader.GetOrdinal (name); } - public bool GetBoolean (int i) { return DataReader.GetBoolean (i); } - public byte GetByte (int i) { return DataReader.GetByte (i); } - public char GetChar (int i) { return DataReader.GetChar (i); } - public Guid GetGuid (int i) { return DataReader.GetGuid (i); } - public short GetInt16 (int i) { return DataReader.GetInt16 (i); } - public int GetInt32 (int i) { return DataReader.GetInt32 (i); } - public long GetInt64 (int i) { return DataReader.GetInt64 (i); } - public float GetFloat (int i) { return DataReader.GetFloat (i); } - public double GetDouble (int i) { return DataReader.GetDouble (i); } - public string GetString (int i) { return DataReader.GetString (i); } - public decimal GetDecimal (int i) { return DataReader.GetDecimal (i); } - public DateTime GetDateTime (int i) { return DataReader.GetDateTime (i); } - public IDataReader GetData (int i) { return DataReader.GetData (i); } - public bool IsDBNull (int i) { return DataReader.IsDBNull (i); } + + public string GetName (int i) { return DataReader.GetName (i); } + public string GetDataTypeName(int i) { return DataReader.GetDataTypeName(i); } + public Type GetFieldType (int i) { return DataReader.GetFieldType (i); } + + /// + /// GetValue method is virtual since it can be overridden by some data provider + /// (For instance, OdbDataProvider uses special methodes for clob data fetching) + /// + /// + /// + public virtual object GetValue (int i) + { + return DataReader.GetValue (i); + } + public int GetValues (object[] values) { return DataReader.GetValues (values); } + public int GetOrdinal (string name) { return DataReader.GetOrdinal (name); } + public bool GetBoolean (int i) { return DataReader.GetBoolean (i); } + public byte GetByte (int i) { return DataReader.GetByte (i); } + public char GetChar (int i) { return DataReader.GetChar (i); } + public Guid GetGuid (int i) { return DataReader.GetGuid (i); } + public short GetInt16 (int i) { return DataReader.GetInt16 (i); } + public int GetInt32 (int i) { return DataReader.GetInt32 (i); } + public long GetInt64 (int i) { return DataReader.GetInt64 (i); } + public float GetFloat (int i) { return DataReader.GetFloat (i); } + public double GetDouble (int i) { return DataReader.GetDouble (i); } + public string GetString (int i) { return DataReader.GetString (i); } + public decimal GetDecimal (int i) { return DataReader.GetDecimal (i); } + public DateTime GetDateTime (int i) + { + return DataReader.GetDateTime (i); + } + public IDataReader GetData (int i) { return DataReader.GetData (i); } + public bool IsDBNull (int i) { return DataReader.IsDBNull (i); } public int FieldCount { get { return DataReader.FieldCount; } } @@ -440,7 +451,10 @@ public long GetChars(int i, long fieldoffset, char[] buffer, int bufferoffset, i #region Implementation of IDataReader public void Close () { DataReader.Close (); } - public DataTable GetSchemaTable() { return DataReader.GetSchemaTable(); } + public DataTable GetSchemaTable() + { + return DataReader.GetSchemaTable(); + } public bool NextResult () { return DataReader.NextResult (); } public bool Read () { return DataReader.Read (); } public int Depth { get { return DataReader.Depth; } } @@ -467,25 +481,25 @@ protected DataReaderEx(T rd) : base(rd) #endregion #region InsertBatch - - public virtual int InsertBatchWithIdentity( - DbManager db, - string insertText, - IEnumerable collection, - MemberMapper[] members, - int maxBatchSize, - DbManager.ParameterProvider getParameters) - { - throw new NotImplementedException("Insert batch with identity is not implemented!"); - } + + public virtual int InsertBatchWithIdentity( + DbManager db, + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + DbManager.ParameterProvider getParameters) + { + throw new NotImplementedException("Insert batch with identity is not implemented!"); + } public virtual int InsertBatch( - DbManager db, - string insertText, - IEnumerable collection, - MemberMapper[] members, - int maxBatchSize, - DbManager.ParameterProvider getParameters) + DbManager db, + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + DbManager.ParameterProvider getParameters) { db.SetCommand(insertText); return db.ExecuteForEach(collection, members, maxBatchSize, getParameters); @@ -493,13 +507,15 @@ public virtual int InsertBatch( #endregion - protected int ExecuteSqlList(DbManager db, IEnumerable sqlList) + protected int ExecuteSqlList(DbManager db, IEnumerable sqlList, List parameters) { var cnt = 0; foreach (string sql in sqlList) { - cnt += db.SetCommand(sql).ExecuteNonQuery(); + cnt += db + .SetCommand(sql, parameters.Count > 0 ? parameters.ToArray() : null) + .ExecuteNonQuery(); } return cnt; diff --git a/Source/Data/DataProvider/DataProviderInterpreterBase.cs b/Source/Data/DataProvider/DataProviderInterpreterBase.cs index 949448d8e..191e2e249 100644 --- a/Source/Data/DataProvider/DataProviderInterpreterBase.cs +++ b/Source/Data/DataProvider/DataProviderInterpreterBase.cs @@ -1,19 +1,24 @@ -using System.Collections.Generic; +#region + +using System.Collections.Generic; using System.Data; +using System.Data.Linq; using BLToolkit.Mapping; +#endregion + namespace BLToolkit.Data.DataProvider { /// - /// BasicSqlProvider equivalent for the non-linq DAL + /// BasicSqlProvider equivalent for the non-linq DAL /// public abstract class DataProviderInterpreterBase { public virtual void SetParameterValue(IDbDataParameter parameter, object value) { - if (value is System.Data.Linq.Binary) + if (value is Binary) { - var arr = ((System.Data.Linq.Binary)value).ToArray(); + var arr = ((Binary) value).ToArray(); parameter.Value = arr; parameter.DbType = DbType.Binary; @@ -24,11 +29,13 @@ public virtual void SetParameterValue(IDbDataParameter parameter, object value) } public virtual List GetInsertBatchSqlList( - string insertText, - IEnumerable collection, - MemberMapper[] members, - int maxBatchSize, - bool withIdentity) + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + bool withIdentity, + DbManager db, + List parameters) { return new List(); } @@ -38,6 +45,11 @@ public virtual string GetSequenceQuery(string sequenceName) return null; } + public virtual DbType GetParameterDbType(DbType dbType) + { + return dbType; + } + public virtual string NextSequenceQuery(string sequenceName) { return null; @@ -47,5 +59,10 @@ public virtual string GetReturningInto(string columnName) { return null; } + + public abstract void SetCollectionIds( + DbManager db, + IEnumerable members, + IEnumerable collection); } } \ No newline at end of file diff --git a/Source/Data/DataProvider/EnumerableExtensions.cs b/Source/Data/DataProvider/EnumerableExtensions.cs new file mode 100644 index 000000000..ff73608a3 --- /dev/null +++ b/Source/Data/DataProvider/EnumerableExtensions.cs @@ -0,0 +1,25 @@ +using System.Collections.Generic; +using System.Linq; + +namespace BLToolkit.Data.DataProvider +{ + public static class EnumerableExtensions + { + public static IEnumerable> ToPages(this IEnumerable source, int pageSize) + { + var page = new List(pageSize); + foreach (var x in source) + { + page.Add(x); + if (page.Count < pageSize) continue; + + yield return page; + page = new List(pageSize); + } + + // Last page + if (page.Any()) + yield return page; + } + } +} \ No newline at end of file diff --git a/Source/Data/DataProvider/GenericDataProvider.cs b/Source/Data/DataProvider/GenericDataProvider.cs index 57aef0a0d..033ae2f8f 100644 --- a/Source/Data/DataProvider/GenericDataProvider.cs +++ b/Source/Data/DataProvider/GenericDataProvider.cs @@ -5,6 +5,7 @@ using System.Transactions; using BLToolkit.Data.DataProvider.Interpreters; using BLToolkit.Data.Sql.SqlProvider; +using BLToolkit.Emit; namespace BLToolkit.Data.DataProvider { @@ -24,7 +25,9 @@ public GenericDataProvider(string providerName) { _factory = DbProviderFactories.GetFactory(providerName); } - + + // When Provider is Oracle, we should call the OdpDataProvider typeTable mapping initialization + switch (Name) { case ProviderFullName.Oracle: @@ -91,11 +94,46 @@ public override ISqlProvider CreateSqlProvider() } } + private object _nVarchar2EnumValue; +#if !DATA + private SetHandler _oracleDbTypeSetHandler; +#endif + public override void SetParameterValue(IDbDataParameter parameter, object value) { + if (Name == ProviderFullName.Oracle) + { + if (value is string) + { + // We need NVarChar2 in order to insert UTF8 string values. The default Odp VarChar2 dbtype doesnt work + // with UTF8 values. Note : Microsoft oracle client uses NVarChar value by default. + + if (_nVarchar2EnumValue == null) + { + const string typeName = "Oracle.DataAccess.Client.OracleDbType"; + + var nvarCharType = parameter.GetType().Assembly.GetType(typeName); + var enumValue = Enum.Parse(nvarCharType, "NVarchar2"); + _nVarchar2EnumValue = enumValue; + +#if !DATA + _oracleDbTypeSetHandler = FunctionFactory.Il.CreateSetHandler(parameter.GetType(), "OracleDbType"); +#endif + } +#if !DATA + _oracleDbTypeSetHandler(parameter, _nVarchar2EnumValue); +#endif + } + } + _dataProviderInterpreter.SetParameterValue(parameter, value); } + public override DbType GetParameterDbType(DbType dbType) + { + return _dataProviderInterpreter.GetParameterDbType(dbType); + } + public override string GetSequenceQuery(string sequenceName) { return _dataProviderInterpreter.GetSequenceQuery(sequenceName); @@ -148,10 +186,12 @@ public override int InsertBatchWithIdentity( { if (db.UseQueryText && Name == ProviderFullName.Oracle) { - List sqlList = _dataProviderInterpreter.GetInsertBatchSqlList(insertText, collection, members, maxBatchSize, true); - return ExecuteSqlList(db, sqlList); + var parameters = new List(); + List sqlList = _dataProviderInterpreter.GetInsertBatchSqlList(insertText, collection, members, maxBatchSize, true, db, parameters); + return ExecuteSqlList(db, sqlList, parameters); } - return base.InsertBatchWithIdentity(db, insertText, collection, members, maxBatchSize, getParameters); + + throw new NotImplementedException("Insert batch with identity is not implemented! If you use the GenericDataProvider and Oracle make sure to set UseQueryText to true"); } public override int InsertBatch( @@ -166,10 +206,11 @@ public override int InsertBatch( { if (db.UseQueryText) { - List sqlList = _dataProviderInterpreter.GetInsertBatchSqlList(insertText, collection, members, maxBatchSize, false); - return ExecuteSqlList(db, sqlList); + var parameters = new List(); + List sqlList = _dataProviderInterpreter.GetInsertBatchSqlList(insertText, collection, members, maxBatchSize, false, db, parameters); + return ExecuteSqlList(db, sqlList, parameters); } - throw new NotSupportedException("Set UseQueryText = true on the current generic data provider!"); + throw new NotSupportedException("Set UseQueryText = true on the current generic data provider!"); } return base.InsertBatch(db, insertText, collection, members, maxBatchSize, getParameters); } diff --git a/Source/Data/DataProvider/Interpreters/OracleDataProviderInterpreter.cs b/Source/Data/DataProvider/Interpreters/OracleDataProviderInterpreter.cs index 2ff0a41be..183895b63 100644 --- a/Source/Data/DataProvider/Interpreters/OracleDataProviderInterpreter.cs +++ b/Source/Data/DataProvider/Interpreters/OracleDataProviderInterpreter.cs @@ -1,4 +1,6 @@ -using System; +#region + +using System; using System.Collections.Generic; using System.Data; using System.Linq; @@ -7,37 +9,284 @@ using BLToolkit.DataAccess; using BLToolkit.Mapping; +#endregion + namespace BLToolkit.Data.DataProvider.Interpreters { public class OracleDataProviderInterpreter : DataProviderInterpreterBase { + public override DbType GetParameterDbType(DbType dbType) + { + /* + * In the OracleParameter class, DbType, OracleDbType, and Value properties are linked. Specifying the value of any of these properties infers the value of one or more of the other properties. + */ + + /*See how the DbType values map to OracleDbType + * In the OracleParameter class, specifying the value of DbType infers the value of OracleDbType +AnsiString => Varchar2 +Binary => Raw +Byte => Byte +Boolean => Value does not fall within the expected range. +Currency => Value does not fall within the expected range. +Date => Date +DateTime => TimeStamp +Decimal => Decimal +Double => Double +Guid => Value does not fall within the expected range. +Int16 => Int16 +Int32 => Int32 +Int64 => Int64 +Object => Object +SByte => Value does not fall within the expected range. +Single => Single +String => Varchar2 +Time => TimeStamp +UInt16 => Value does not fall within the expected range. +UInt32 => Value does not fall within the expected range. +UInt64 => Value does not fall within the expected range. +VarNumeric => Value does not fall within the expected range. +AnsiStringFixedLength => Char +StringFixedLength => Char +Xml => Specified argument was out of the range of valid values. +DateTime2 => Specified argument was out of the range of valid values. +DateTimeOffset => Specified argument was out of the range of valid values. + * */ + + /*See how the OracleDbType values map to DbType + * In the OracleParameter class, specifying the value of OracleDbType infers the value of DbType +BFile => Object +Blob => Object +Byte => Byte +Char => StringFixedLength +Clob => Object +Date => Date +Decimal => Decimal +Double => Double +Long => String +LongRaw => Binary +Int16 => Int16 +Int32 => Int32 +Int64 => Int64 +IntervalDS => Object +IntervalYM => Int64 +NClob => Object +NChar => StringFixedLength +NVarchar2 => String +Raw => Binary +RefCursor => Object +Single => Single +TimeStamp => DateTime +TimeStampLTZ => DateTime +TimeStampTZ => DateTime +Varchar2 => String +XmlType => String +Array => Object +Object => Object +Ref => Object +BinaryDouble => Double +BinaryFloat => Single + */ + switch (dbType) + { + case DbType.UInt16: + return DbType.Int16; + case DbType.DateTime2: + return DbType.DateTime; + + // TODO Add the other cases ... + + default: + return base.GetParameterDbType(dbType); + } + } + public override void SetParameterValue(IDbDataParameter parameter, object value) { + if (null != value) + { + if (value is Guid) + { + // Fix Oracle.Net bug #6: guid type is not handled + // + value = ((Guid) value).ToByteArray(); + } + else if (parameter.DbType == DbType.Date && value is DateTime) + { + var dt = (DateTime)value; + value = new DateTime(dt.Year, dt.Month, dt.Day, 0, 0, 0, 0, dt.Kind); + } + else if (parameter.DbType == DbType.DateTime && value is DateTime) + { + var dt = (DateTime)value; + value = new DateTime(dt.Year, dt.Month, dt.Day, dt.Hour, dt.Minute, dt.Second, 0, dt.Kind); + } + //// This case is treated in OracleParameterWrap set method of Value property + //else if (value is Array && !(value is byte[] || value is char[])) + //{ + // _oracleParameter.CollectionType = OracleCollectionType.PLSQLAssociativeArray; + //} + else if (value is IConvertible) + { + var convertible = (IConvertible) value; + var typeCode = convertible.GetTypeCode(); + + switch (typeCode) + { + case TypeCode.Boolean: + // Fix Oracle.Net bug #7: bool type is handled wrong + // + value = convertible.ToByte(null); + break; + + case TypeCode.SByte: + case TypeCode.UInt16: + case TypeCode.UInt32: + case TypeCode.UInt64: + // Fix Oracle.Net bug #8: some integer types are handled wrong + // + value = convertible.ToDecimal(null); + break; + + // Fix Oracle.Net bug #10: zero-length string can not be converted to + // ORAXML type, but null value can be. + // + case TypeCode.String: + if (((string) value).Length == 0) + value = null; + break; + + default: + // Fix Oracle.Net bug #5: Enum type is not handled + // + if (value is Enum) + { + // Convert a Enum value to it's underlying type. + // + value = System.Convert.ChangeType(value, typeCode); + } + break; + } + } + } + if (value is TimeSpan) { - parameter.Value = ((TimeSpan)value).ToString(); + parameter.Value = ((TimeSpan) value).ToString(); } else base.SetParameterValue(parameter, value); } public override List GetInsertBatchSqlList( - string insertText, - IEnumerable collection, - MemberMapper[] members, - int maxBatchSize, - bool withIdentity) + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + bool withIdentity, + DbManager db, + List parameters) { - //return GetInsertBatchSqlListWithInsertAll(insertText, collection, members, maxBatchSize); - return GetInsertBatchSqlListUnionAll(insertText, collection, members, maxBatchSize, withIdentity); + //const InsertBatchMethod method = InsertBatchMethod.InsertAllWithPks; + const InsertBatchMethod method = InsertBatchMethod.UnionAll; + switch (method) + { + case InsertBatchMethod.InsertAllWithPks: + SetCollectionIds(db, members, collection); + return GetInsertBatchSqlListWithInsertAllWithPks(insertText, collection, members, maxBatchSize, db, parameters); + break; + case InsertBatchMethod.InsertAll: + // Note : Can this work? + return GetInsertBatchSqlListWithInsertAll(insertText, collection, members, maxBatchSize, db.MappingSchema); + break; + case InsertBatchMethod.UnionAll: + default: + return GetInsertBatchSqlListUnionAll(insertText, collection, members, maxBatchSize, withIdentity, db.MappingSchema); + } + } + + public override string GetSequenceQuery(string sequenceName) + { + return string.Format("SELECT {0}.NEXTVAL FROM DUAL", sequenceName); + } + + public override string NextSequenceQuery(string sequenceName) + { + return string.Format("{0}.NEXTVAL", sequenceName); + } + + public override string GetReturningInto(string columnName) + { + return string.Format("returning {0} into :IDENTITY_PARAMETER", columnName); + } + + public override void SetCollectionIds( + DbManager db, + IEnumerable members, + IEnumerable collection) + { + MemberMapper primaryKeyMapper = null; + SequenceKeyGenerator keyGenerator = null; + + foreach (var mapper in members) + { + keyGenerator = mapper.MapMemberInfo.KeyGenerator as SequenceKeyGenerator; + if (keyGenerator != null) + { + primaryKeyMapper = mapper; + break; + } + } + + if (primaryKeyMapper == null) + throw new Exception("The class mapping should contain a pk column!"); + + var rowCount = collection.Count(); + var sequenceIds = ReserveSequenceValues(db, rowCount, NextSequenceQuery(keyGenerator.Sequence)); + + int i = 0; + foreach (var element in collection) + { + primaryKeyMapper.SetInt64(element, sequenceIds[i]); + i++; + } + } + + #region Private methods + + private List ReserveSequenceValues(DbManager db, int count, string sequenceName) + { + //var sql2 = new StringBuilder("SELECT level," + sequenceName + " Id from DUAL connect by level <= " + count); + + //db.SetCommand(sql2.ToString()); + + //return db.ExecuteScalarList(); + + var results = new List(); + + foreach (var page in Enumerable.Range(1, count).ToPages(1000)) + { + var sql = new StringBuilder("SELECT " + sequenceName + " FROM ("); + for (int i = 1; i < page.Count(); i++) + sql.Append("SELECT 0 FROM DUAL UNION ALL "); + + sql.Append("SELECT 0 FROM DUAL)"); + + db.SetCommand(sql.ToString()); + + var result = db.ExecuteScalarList(); + results.AddRange(result); + } + + return results; } private List GetInsertBatchSqlListUnionAll( - string insertText, - IEnumerable collection, - MemberMapper[] members, - int maxBatchSize, - bool withIdentity) + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + bool withIdentity, + MappingSchema mappingSchema) { var sp = new OracleSqlProvider(); var n = 0; @@ -48,12 +297,12 @@ private List GetInsertBatchSqlListUnionAll( var valuesQuery = insertText.Substring(indexValuesWord + 9); var indexEndValuesQuery = valuesQuery.IndexOf(")"); valuesQuery = valuesQuery.Substring(0, indexEndValuesQuery) - .Replace("\r", "") - .Replace("\n", "") - .Replace("\t", ""); + .Replace("\r", "") + .Replace("\n", "") + .Replace("\t", ""); // 1 = Number of primary keys generated by sequence - var valuesWihtoutSequence = withIdentity ? valuesQuery.Substring(valuesQuery.IndexOf(",") + 1) : valuesQuery; + var valuesWithoutSequence = withIdentity ? valuesQuery.Substring(valuesQuery.IndexOf(",") + 1) : valuesQuery; var sb = new StringBuilder(initQuery); sb.Append(" SELECT "); @@ -79,15 +328,25 @@ private List GetInsertBatchSqlListUnionAll( var value = member.GetValue(item); + if (value != null && value.GetType().IsEnum) + value = mappingSchema.MapEnumToValue(value, true); + if (value is DateTime?) - value = ((DateTime?)value).Value; + value = ((DateTime?) value).Value; + + //if (value is string && ((string)value).Length >= 2000) + //{ + // var par = db.Parameter("p" + ++pn, value); + // parameters.Add(par); + // sb.Append(":" + par.ParameterName); + //} sp.BuildValue(sbItem, value); values.Add(sbItem + " " + member.Name); } - sb.AppendFormat(valuesWihtoutSequence, values.ToArray()); + sb.AppendFormat(valuesWithoutSequence, values.ToArray()); sb.Append(" FROM DUAL"); isFirstValues = false; @@ -111,11 +370,114 @@ private List GetInsertBatchSqlListUnionAll( return sqlList; } + private List GetInsertBatchSqlListWithInsertAllWithPks( + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + DbManager db, + List parameters) + { + MappingSchema mappingSchema = db.MappingSchema; + + var queries = new List(); + + var sb = new StringBuilder(); + var sp = new OracleSqlProvider(); + var pn = 0; + var n = 0; + var cnt = 0; + var str = "\t" + insertText + .Substring(0, insertText.IndexOf(") VALUES (")) + .Substring(7) + .Replace("\r", "") + .Replace("\n", "") + .Replace("\t", " ") + .Replace("( ", "(") + //.Replace(" ", " ") + + ") VALUES ("; + + foreach (var item in collection) + { + if (sb.Length == 0) + sb.AppendLine("INSERT ALL"); + + sb.Append(str); + + foreach (var member in members) + { + var value = member.GetValue(item); + + if (value != null && value.GetType().IsEnum) + value = mappingSchema.MapEnumToValue(value, true); + + if (value is Nullable) + value = ((DateTime?) value).Value; + + if (value is DateTime) + { + var dt = (DateTime) value; + sb.Append(string.Format("to_timestamp('{0:dd.MM.yyyy HH:mm:ss.ffffff}', 'DD.MM.YYYY HH24:MI:SS.FF6')", dt)); + } + else if (value is string && ((string)value).Length >= 2000) + { + var par = db.Parameter("p" + ++pn, value); + parameters.Add(par); + sb.Append(":" + par.ParameterName); + } + else + sp.BuildValue(sb, value); + + sb.Append(", "); + } + + sb.Length -= 2; + sb.AppendLine(")"); + + n++; + + if (n >= maxBatchSize) + { + sb.AppendLine("SELECT * FROM dual"); + + var sql = sb.ToString(); + + if (DbManager.TraceSwitch.TraceInfo) + DbManager.WriteTraceLine("\n" + sql.Replace("\r", ""), DbManager.TraceSwitch.DisplayName); + + queries.Add(sql); + + parameters.Clear(); + pn = 0; + n = 0; + sb.Length = 0; + } + } + + if (n > 0) + { + sb.AppendLine("SELECT * FROM dual"); + + var sql = sb.ToString(); + + if (DbManager.TraceSwitch.TraceInfo) + DbManager.WriteTraceLine("\n" + sql.Replace("\r", ""), DbManager.TraceSwitch.DisplayName); + + queries.Add(sql); + } + + return queries; + } + + /// + /// Note : Can this work? + /// private List GetInsertBatchSqlListWithInsertAll( - string insertText, - IEnumerable collection, - MemberMapper[] members, - int maxBatchSize) + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + MappingSchema mappingSchema) { var sb = new StringBuilder(); var sp = new OracleSqlProvider(); @@ -128,11 +490,11 @@ private List GetInsertBatchSqlListWithInsertAll( sb.AppendLine("INSERT ALL"); string strItem = "\t" + insertText - .Replace("INSERT INTO", "INTO") - .Replace("\r", "") - .Replace("\n", "") - .Replace("\t", " ") - .Replace("( ", "("); + .Replace("INSERT INTO", "INTO") + .Replace("\r", "") + .Replace("\n", "") + .Replace("\t", " ") + .Replace("( ", "("); var values = new List(); foreach (var member in members) @@ -148,10 +510,20 @@ private List GetInsertBatchSqlListWithInsertAll( { var value = member.GetValue(item); + if (value != null && value.GetType().IsEnum) + value = mappingSchema.MapEnumToValue(value, true); + if (value is DateTime?) - value = ((DateTime?)value).Value; + value = ((DateTime?) value).Value; - sp.BuildValue(sbItem, value); + if (value is DateTime) + { + var dt = (DateTime) value; + //sb.Append(string.Format("to_timestamp('{0:dd.MM.yyyy HH:mm:ss.ffffff}', 'DD.MM.YYYY HH24:MI:SS.FF6')", dt)); + sp.BuildValue(sbItem, string.Format("to_timestamp('{0:dd.MM.yyyy HH:mm:ss.ffffff}', 'DD.MM.YYYY HH24:MI:SS.FF6')", dt)); + } + else + sp.BuildValue(sbItem, value); values.Add(sbItem.ToString()); } @@ -185,19 +557,13 @@ private List GetInsertBatchSqlListWithInsertAll( return sqlList; } - public override string GetSequenceQuery(string sequenceName) - { - return string.Format("SELECT {0}.NEXTVAL FROM DUAL", sequenceName); - } - - public override string NextSequenceQuery(string sequenceName) - { - return string.Format("{0}.NEXTVAL", sequenceName); - } + #endregion - public override string GetReturningInto(string columnName) + private enum InsertBatchMethod { - return string.Format("returning {0} into :IDENTITY_PARAMETER", columnName); + UnionAll, + InsertAll, + InsertAllWithPks, } } } \ No newline at end of file diff --git a/Source/Data/DataProvider/Interpreters/SqliteDataProviderInterpreter.cs b/Source/Data/DataProvider/Interpreters/SqliteDataProviderInterpreter.cs index 088e2ba83..ceca58d71 100644 --- a/Source/Data/DataProvider/Interpreters/SqliteDataProviderInterpreter.cs +++ b/Source/Data/DataProvider/Interpreters/SqliteDataProviderInterpreter.cs @@ -1,4 +1,6 @@ +using System.Collections.Generic; using System.Data; +using BLToolkit.Mapping; namespace BLToolkit.Data.DataProvider.Interpreters { @@ -11,5 +13,10 @@ public override void SetParameterValue(IDbDataParameter parameter, object value) base.SetParameterValue(parameter, value); } + + public override void SetCollectionIds(DbManager db, IEnumerable members, IEnumerable collection) + { + throw new System.NotImplementedException(); + } } } \ No newline at end of file diff --git a/Source/Data/DataProvider/OdpDataProvider.cs b/Source/Data/DataProvider/OdpDataProvider.cs index 0a8c609dd..3c856eec2 100644 --- a/Source/Data/DataProvider/OdpDataProvider.cs +++ b/Source/Data/DataProvider/OdpDataProvider.cs @@ -1,1708 +1,1837 @@ -// Odp.Net Data Provider. -// http://www.oracle.com/technology/tech/windows/odpnet/index.html -// -using System; -using System.Collections; -using System.Collections.Generic; -using System.Data; -using System.Data.Common; -using System.Globalization; -using System.IO; -using System.Linq; -using System.Reflection; -using System.Text; -using System.Xml; - -using BLToolkit.Aspects; -using BLToolkit.Common; -using BLToolkit.Mapping; -using BLToolkit.Reflection; - -#if MANAGED -using Oracle.ManagedDataAccess.Client; -using Oracle.ManagedDataAccess.Types; -#else -using Oracle.DataAccess.Client; -using Oracle.DataAccess.Types; -#endif - -namespace BLToolkit.Data.DataProvider -{ - using Sql.SqlProvider; - using BLToolkit.Data.Sql; - - /// - /// Implements access to the Data Provider for Oracle. - /// - /// - /// See the method to find an example. - /// - /// AddDataManager Method -#if !MANAGED - public class OdpDataProvider : DataProviderBase - { - public OdpDataProvider() - { - MappingSchema = new OdpMappingSchema(); - } - - public const string NameString = DataProvider.ProviderName.Oracle; - - private const string DbTypeTableName = "Oracle.DataAccess.Client.OraDb_DbTypeTable"; - - static OdpDataProvider() - { -#else - public class OdpManagedDataProvider : DataProviderBase - { - public OdpManagedDataProvider() - { - MappingSchema = new OdpMappingSchema(); - } - - public const string NameString = DataProvider.ProviderName.OracleManaged; - - private const string DbTypeTableName = "Oracle.ManagedDataAccess.Client.OraDb_DbTypeTable"; - - static OdpManagedDataProvider() - { -#endif - // Fix Oracle.Net bug #1: Array types are not handled. - // - var oraDbDbTypeTableType = typeof(OracleParameter).Assembly.GetType(DbTypeTableName); - - if (null != oraDbDbTypeTableType) - { - var typeTable = (Hashtable)oraDbDbTypeTableType.InvokeMember( - "s_table", BindingFlags.Static | BindingFlags.NonPublic | BindingFlags.GetField, - null, null, Type.EmptyTypes); - - if (null != typeTable) - { - typeTable[typeof(DateTime[])] = OracleDbType.TimeStamp; - typeTable[typeof(Int16[])] = OracleDbType.Int16; - typeTable[typeof(Int32[])] = OracleDbType.Int32; - typeTable[typeof(Int64[])] = OracleDbType.Int64; - typeTable[typeof(Single[])] = OracleDbType.Single; - typeTable[typeof(Double[])] = OracleDbType.Double; - typeTable[typeof(Decimal[])] = OracleDbType.Decimal; - typeTable[typeof(TimeSpan[])] = OracleDbType.IntervalDS; - typeTable[typeof(String[])] = OracleDbType.Varchar2; - typeTable[typeof(OracleBFile[])] = OracleDbType.BFile; - typeTable[typeof(OracleBinary[])] = OracleDbType.Raw; - typeTable[typeof(OracleBlob[])] = OracleDbType.Blob; - typeTable[typeof(OracleClob[])] = OracleDbType.Clob; - typeTable[typeof(OracleDate[])] = OracleDbType.Date; - typeTable[typeof(OracleDecimal[])] = OracleDbType.Decimal; - typeTable[typeof(OracleIntervalDS[])] = OracleDbType.IntervalDS; - typeTable[typeof(OracleIntervalYM[])] = OracleDbType.IntervalYM; - typeTable[typeof(OracleRefCursor[])] = OracleDbType.RefCursor; - typeTable[typeof(OracleString[])] = OracleDbType.Varchar2; - typeTable[typeof(OracleTimeStamp[])] = OracleDbType.TimeStamp; - typeTable[typeof(OracleTimeStampLTZ[])]= OracleDbType.TimeStampLTZ; - typeTable[typeof(OracleTimeStampTZ[])] = OracleDbType.TimeStampTZ; -#if !MANAGED - typeTable[typeof(OracleXmlType[])] = OracleDbType.XmlType; -#endif - - typeTable[typeof(Boolean)] = OracleDbType.Byte; - typeTable[typeof(Guid)] = OracleDbType.Raw; - typeTable[typeof(SByte)] = OracleDbType.Decimal; - typeTable[typeof(UInt16)] = OracleDbType.Decimal; - typeTable[typeof(UInt32)] = OracleDbType.Decimal; - typeTable[typeof(UInt64)] = OracleDbType.Decimal; - - typeTable[typeof(Boolean[])] = OracleDbType.Byte; - typeTable[typeof(Guid[])] = OracleDbType.Raw; - typeTable[typeof(SByte[])] = OracleDbType.Decimal; - typeTable[typeof(UInt16[])] = OracleDbType.Decimal; - typeTable[typeof(UInt32[])] = OracleDbType.Decimal; - typeTable[typeof(UInt64[])] = OracleDbType.Decimal; - - typeTable[typeof(Boolean?)] = OracleDbType.Byte; - typeTable[typeof(Guid?)] = OracleDbType.Raw; - typeTable[typeof(SByte?)] = OracleDbType.Decimal; - typeTable[typeof(UInt16?)] = OracleDbType.Decimal; - typeTable[typeof(UInt32?)] = OracleDbType.Decimal; - typeTable[typeof(UInt64?)] = OracleDbType.Decimal; - typeTable[typeof(DateTime?[])] = OracleDbType.TimeStamp; - typeTable[typeof(Int16?[])] = OracleDbType.Int16; - typeTable[typeof(Int32?[])] = OracleDbType.Int32; - typeTable[typeof(Int64?[])] = OracleDbType.Int64; - typeTable[typeof(Single?[])] = OracleDbType.Single; - typeTable[typeof(Double?[])] = OracleDbType.Double; - typeTable[typeof(Decimal?[])] = OracleDbType.Decimal; - typeTable[typeof(TimeSpan?[])] = OracleDbType.IntervalDS; - typeTable[typeof(Boolean?[])] = OracleDbType.Byte; - typeTable[typeof(Guid?[])] = OracleDbType.Raw; - typeTable[typeof(SByte?[])] = OracleDbType.Decimal; - typeTable[typeof(UInt16?[])] = OracleDbType.Decimal; - typeTable[typeof(UInt32?[])] = OracleDbType.Decimal; - typeTable[typeof(UInt64?[])] = OracleDbType.Decimal; - - typeTable[typeof(XmlReader)] = OracleDbType.XmlType; - typeTable[typeof(XmlDocument)] = OracleDbType.XmlType; - typeTable[typeof(MemoryStream)] = OracleDbType.Blob; - typeTable[typeof(XmlReader[])] = OracleDbType.XmlType; - typeTable[typeof(XmlDocument[])] = OracleDbType.XmlType; - typeTable[typeof(MemoryStream[])] = OracleDbType.Blob; - } - } - } - - /// - /// Creates the database connection object. - /// - /// - /// See the method to find an example. - /// - /// AddDataManager Method - /// The database connection object. - public override IDbConnection CreateConnectionObject() - { - return new OracleConnection(); - } - - public override IDbCommand CreateCommandObject(IDbConnection connection) - { - var oraConnection = connection as OracleConnection; - - if (null != oraConnection) - { - var oraCommand = oraConnection.CreateCommand(); - - // Fix Oracle.Net bug #2: Empty arrays can not be sent to the server. - // - oraCommand.BindByName = true; - - return oraCommand; - } - - return base.CreateCommandObject(connection); - } - - public override void SetParameterValue(IDbDataParameter parameter, object value) - { - base.SetParameterValue(parameter, value); - - // strings and byte arrays larger than 4000 bytes may be handled improperly - if (parameter is OracleParameterWrap) - { - const int ThresholdSize = 4000; - if (value is string && Encoding.UTF8.GetBytes((string)value).Length > ThresholdSize) - { - ((OracleParameterWrap)parameter).OracleParameter.OracleDbType = OracleDbType.Clob; - } - else if (value is byte[] && ((byte[])value).Length > ThresholdSize) - { - ((OracleParameterWrap)parameter).OracleParameter.OracleDbType = OracleDbType.Blob; - } - } - } - - public override IDbDataParameter CloneParameter(IDbDataParameter parameter) - { - var oraParameter = (parameter is OracleParameterWrap)? - (parameter as OracleParameterWrap).OracleParameter: parameter as OracleParameter; - - if (null != oraParameter) - { - var oraParameterClone = (OracleParameter)oraParameter.Clone(); - - // Fix Oracle.Net bug #3: CollectionType property is not cloned. - // - oraParameterClone.CollectionType = oraParameter.CollectionType; - - // Fix Oracle.Net bug #8423178 - // See http://forums.oracle.com/forums/thread.jspa?threadID=975902&tstart=0 - // - if (oraParameterClone.OracleDbType == OracleDbType.RefCursor) - { - // Set OracleDbType to itself to reset m_bSetDbType and m_bOracleDbTypeExSet - // - oraParameterClone.OracleDbType = OracleDbType.RefCursor; - } - - return OracleParameterWrap.CreateInstance(oraParameterClone); - } - - return base.CloneParameter(parameter); - } - - public override void SetUserDefinedType(IDbDataParameter parameter, string typeName) - { - var oraParameter = (parameter is OracleParameterWrap) ? - (parameter as OracleParameterWrap).OracleParameter : parameter as OracleParameter; - - if (oraParameter == null) - throw new ArgumentException("OracleParameter expected.", "parameter"); - - oraParameter.UdtTypeName = typeName; - } - - /// - /// Creates the data adapter object. - /// - /// - /// See the method to find an example. - /// - /// AddDataManager Method - /// A data adapter object. - public override DbDataAdapter CreateDataAdapterObject() - { - return new OracleDataAdapter(); - } - - /// - /// Populates the specified IDbCommand object's Parameters collection with - /// parameter information for the stored procedure specified in the IDbCommand. - /// - /// - /// See the method to find an example. - /// - /// AddDataManager Method - /// The IDbCommand referencing the stored procedure for which the parameter - /// information is to be derived. The derived parameters will be populated into - /// the Parameters of this command. - public override bool DeriveParameters(IDbCommand command) - { - var oraCommand = command as OracleCommand; - - if (null != oraCommand) - { - try - { - OracleCommandBuilder.DeriveParameters(oraCommand); - } - catch (Exception ex) - { - // Make Oracle less laconic. - // - throw new DataException(string.Format("{0}\nCommandText: {1}", ex.Message, oraCommand.CommandText), ex); - } - - return true; - } - - return false; - } - - /// - /// Open an into the given object - /// - /// an to perform GetDataReader() on - /// The into the returned by GetDataReader() - public override IDataReader GetRefCursorDataReader(object refCursor) - { - var oracleRefCursor = refCursor as OracleRefCursor; - - if (oracleRefCursor == null) - throw new ArgumentException("Argument must be of type 'OracleRefCursor'", "refCursor"); - - return oracleRefCursor.GetDataReader(); - } - - public override object Convert(object value, ConvertType convertType) - { - switch (convertType) - { - case ConvertType.NameToCommandParameter: - case ConvertType.NameToSprocParameter: - return ParameterPrefix == null? value: ParameterPrefix + value; - - case ConvertType.SprocParameterToName: - var name = (string)value; - - if (name.Length > 0) - { - if (name[0] == ':') - return name.Substring(1); - - if (ParameterPrefix != null && - name.ToUpper(CultureInfo.InvariantCulture).StartsWith(ParameterPrefix)) - { - return name.Substring(ParameterPrefix.Length); - } - } - - break; - - case ConvertType.ExceptionToErrorNumber: - if (value is OracleException) - return ((OracleException)value).Number; - break; - } - - return SqlProvider.Convert(value, convertType); - } - - public override void PrepareCommand(ref CommandType commandType, ref string commandText, ref IDbDataParameter[] commandParameters) - { - base.PrepareCommand(ref commandType, ref commandText, ref commandParameters); - - if (commandType == CommandType.Text) - { - // Fix Oracle bug #11 '\r' is not a valid character! - // - commandText = commandText.Replace('\r', ' '); - } - } - - public override void AttachParameter(IDbCommand command, IDbDataParameter parameter) - { - var oraParameter = (parameter is OracleParameterWrap)? - (parameter as OracleParameterWrap).OracleParameter: parameter as OracleParameter; - - if (null != oraParameter) - { - if (oraParameter.CollectionType == OracleCollectionType.PLSQLAssociativeArray) - { - if (oraParameter.Direction == ParameterDirection.Input - || oraParameter.Direction == ParameterDirection.InputOutput) - { - var ar = oraParameter.Value as Array; - - if (null != ar && !(ar is byte[] || ar is char[])) - { - oraParameter.Size = ar.Length; - - if (oraParameter.DbType == DbType.String - && oraParameter.Direction == ParameterDirection.InputOutput) - { - var arrayBindSize = new int[oraParameter.Size]; - - for (var i = 0; i < oraParameter.Size; ++i) - { - arrayBindSize[i] = 1024; - } - - oraParameter.ArrayBindSize = arrayBindSize; - } - } - - if (oraParameter.Size == 0) - { - // Skip this parameter. - // Fix Oracle.Net bug #2: Empty arrays can not be sent to the server. - // - return; - } - - if (oraParameter.Value is Stream[]) - { - var streams = (Stream[]) oraParameter.Value; - - for (var i = 0; i < oraParameter.Size; ++i) - { - if (streams[i] is OracleBFile || streams[i] is OracleBlob || streams[i] is OracleClob -#if !MANAGED - || streams[i] is OracleXmlStream -#endif - ) - { - // Known Oracle type. - // - continue; - } - - streams[i] = CopyStream(streams[i], (OracleCommand)command); - } - } - else if (oraParameter.Value is XmlDocument[]) - { - var xmlDocuments = (XmlDocument[]) oraParameter.Value; - var values = new object[oraParameter.Size]; - - switch (oraParameter.OracleDbType) - { - case OracleDbType.XmlType: -#if !MANAGED - for (var i = 0; i < oraParameter.Size; ++i) - { - values[i] = xmlDocuments[i].DocumentElement == null? - (object) DBNull.Value: - new OracleXmlType((OracleConnection)command.Connection, xmlDocuments[i]); - } - - oraParameter.Value = values; - break; -#else - throw new NotSupportedException(); -#endif - // Fix Oracle.Net bug #9: XmlDocument.ToString() returns System.Xml.XmlDocument, - // so m_value.ToString() is not enought. - // - case OracleDbType.Clob: - case OracleDbType.NClob: - case OracleDbType.Varchar2: - case OracleDbType.NVarchar2: - case OracleDbType.Char: - case OracleDbType.NChar: - for (var i = 0; i < oraParameter.Size; ++i) - { - values[i] = xmlDocuments[i].DocumentElement == null? - (object) DBNull.Value: - xmlDocuments[i].InnerXml; - } - - oraParameter.Value = values; - - break; - - // Or convert to bytes if need. - // - case OracleDbType.Blob: - case OracleDbType.BFile: - case OracleDbType.Raw: - case OracleDbType.Long: - case OracleDbType.LongRaw: - for (var i = 0; i < oraParameter.Size; ++i) - { - if (xmlDocuments[i].DocumentElement == null) - values[i] = DBNull.Value; - else - using (var s = new MemoryStream()) - { - xmlDocuments[i].Save(s); - values[i] = s.GetBuffer(); - } - } - - oraParameter.Value = values; - - break; - } - } - } - else if (oraParameter.Direction == ParameterDirection.Output) - { - // Fix Oracle.Net bug #4: ArrayBindSize must be explicitly specified. - // - if (oraParameter.DbType == DbType.String) - { - oraParameter.Size = 1024; - var arrayBindSize = new int[oraParameter.Size]; - for (var i = 0; i < oraParameter.Size; ++i) - { - arrayBindSize[i] = 1024; - } - - oraParameter.ArrayBindSize = arrayBindSize; - } - else - { - oraParameter.Size = 32767; - } - } - } - else if (oraParameter.Value is Stream) - { - var stream = (Stream) oraParameter.Value; - - if (!(stream is OracleBFile) && !(stream is OracleBlob) && - !(stream is OracleClob) -#if !MANAGED - && !(stream is OracleXmlStream) -#endif - ) - { - oraParameter.Value = CopyStream(stream, (OracleCommand)command); - } - } - else if (oraParameter.Value is Byte[]) - { - var bytes = (Byte[]) oraParameter.Value; - - if (bytes.Length > 32000) - { - oraParameter.Value = CopyStream(bytes, (OracleCommand)command); - } - } - else if (oraParameter.Value is XmlDocument) - { - var xmlDocument = (XmlDocument)oraParameter.Value; - if (xmlDocument.DocumentElement == null) - oraParameter.Value = DBNull.Value; - else - { - - switch (oraParameter.OracleDbType) - { - case OracleDbType.XmlType: -#if !MANAGED - oraParameter.Value = new OracleXmlType((OracleConnection)command.Connection, xmlDocument); - break; -#else - throw new NotSupportedException(); -#endif - - // Fix Oracle.Net bug #9: XmlDocument.ToString() returns System.Xml.XmlDocument, - // so m_value.ToString() is not enought. - // - case OracleDbType.Clob: - case OracleDbType.NClob: - case OracleDbType.Varchar2: - case OracleDbType.NVarchar2: - case OracleDbType.Char: - case OracleDbType.NChar: - using (TextWriter w = new StringWriter()) - { - xmlDocument.Save(w); - oraParameter.Value = w.ToString(); - } - break; - - // Or convert to bytes if need. - // - case OracleDbType.Blob: - case OracleDbType.BFile: - case OracleDbType.Raw: - case OracleDbType.Long: - case OracleDbType.LongRaw: - using (var s = new MemoryStream()) - { - xmlDocument.Save(s); - oraParameter.Value = s.GetBuffer(); - } - break; - } - } - } - - parameter = oraParameter; - } - - base.AttachParameter(command, parameter); - } - - private static Stream CopyStream(Stream stream, OracleCommand cmd) - { - return CopyStream(Common.Convert.ToByteArray(stream), cmd); - } - - private static Stream CopyStream(Byte[] bytes, OracleCommand cmd) - { - var ret = new OracleBlob(cmd.Connection); - ret.Write(bytes, 0, bytes.Length); - return ret; - } - - public override bool IsValueParameter(IDbDataParameter parameter) - { - var oraParameter = (parameter is OracleParameterWrap)? - (parameter as OracleParameterWrap).OracleParameter: parameter as OracleParameter; - - if (null != oraParameter) - { - if (oraParameter.OracleDbType == OracleDbType.RefCursor - && oraParameter.Direction == ParameterDirection.Output) - { - // Ignore out ref cursors, while out parameters of other types are o.k. - return false; - } - } - - return base.IsValueParameter(parameter); - } - - public override IDbDataParameter CreateParameterObject(IDbCommand command) - { - var parameter = base.CreateParameterObject(command); - - if (parameter is OracleParameter) - parameter = OracleParameterWrap.CreateInstance(parameter as OracleParameter); - - return parameter; - } - - public override IDbDataParameter GetParameter(IDbCommand command, NameOrIndexParameter nameOrIndex) - { - var parameter = base.GetParameter(command, nameOrIndex); - - if (parameter is OracleParameter) - parameter = OracleParameterWrap.CreateInstance(parameter as OracleParameter); - - return parameter; - } - - /// - /// Returns connection type. - /// - /// - /// See the method to find an example. - /// - /// AddDataManager Method - /// An instance of the class. - public override Type ConnectionType - { - get { return typeof(OracleConnection); } - } - - /// - /// Returns the data provider name. - /// - /// - /// See the method to find an example. - /// - /// AddDataProvider Method - /// Data provider name. - public override string Name - { - get { return NameString; } - } - - public override int MaxBatchSize - { - get { return 0; } - } - - public override int ExecuteArray(IDbCommand command, int iterations) - { - var cmd = (OracleCommand)command; - var oracleParameters = cmd.Parameters.OfType().ToArray(); - var oldCollectionTypes = oracleParameters.Select(p => p.CollectionType).ToArray(); - - try - { - foreach (var p in oracleParameters) - { - p.CollectionType = OracleCollectionType.None; - } - - cmd.ArrayBindCount = iterations; - return cmd.ExecuteNonQuery(); - } - finally - { - foreach (var p in oracleParameters.Zip(oldCollectionTypes, (p, t) => new { Param = p, CollectionType = t })) - { - p.Param.CollectionType = p.CollectionType; - } - - cmd.ArrayBindCount = 0; - } - } - - public override ISqlProvider CreateSqlProvider() - { - return new OracleSqlProvider(); - } - - public override IDataReader GetDataReader(MappingSchema schema, IDataReader dataReader) - { - return dataReader is OracleDataReader ? - new OracleDataReaderEx((OracleDataReader)dataReader) : - base.GetDataReader(schema, dataReader); - } - - class OracleDataReaderEx: DataReaderEx - { - public OracleDataReaderEx(OracleDataReader rd) - : base(rd) - { - } - - public override DateTimeOffset GetDateTimeOffset(int i) - { - var ts = DataReader.GetOracleTimeStampTZ(i); - return new DateTimeOffset(ts.Value, ts.GetTimeZoneOffset()); - } - } - - private string _parameterPrefix = "P"; - public string ParameterPrefix - { - get { return _parameterPrefix; } - set - { - _parameterPrefix = string.IsNullOrEmpty(value)? null: - value.ToUpper(CultureInfo.InvariantCulture); - } - } - - /// - /// One time initialization from a configuration file. - /// - /// Provider specific attributes. - public override void Configure(System.Collections.Specialized.NameValueCollection attributes) - { - var val = attributes["ParameterPrefix"]; - if (val != null) - ParameterPrefix = val; - - base.Configure(attributes); - } - - #region Inner types - - public class OdpMappingSchema : MappingSchema - { - public override DataReaderMapper CreateDataReaderMapper(IDataReader dataReader) - { - return new OracleDataReaderMapper(this, dataReader); - } - - public override DataReaderMapper CreateDataReaderMapper( - IDataReader dataReader, - NameOrIndexParameter nip) - { - return new OracleScalarDataReaderMapper(this, dataReader, nip); - } - - public override Reflection.Extension.ExtensionList Extensions - { - get { return Map.DefaultSchema.Extensions; } - set { Map.DefaultSchema.Extensions = value; } - } - - #region Convert - - #region Primitive Types - - [CLSCompliant(false)] - public override SByte ConvertToSByte(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultSByteNullValue: (SByte)oraDecimal.Value; - } - - return base.ConvertToSByte(value); - } - - public override Int16 ConvertToInt16(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultInt16NullValue: oraDecimal.ToInt16(); - } - - return base.ConvertToInt16(value); - } - - public override Int32 ConvertToInt32(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultInt32NullValue: oraDecimal.ToInt32(); - } - - return base.ConvertToInt32(value); - } - - public override Int64 ConvertToInt64(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultInt64NullValue: oraDecimal.ToInt64(); - } - - return base.ConvertToInt64(value); - } - - public override Byte ConvertToByte(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultByteNullValue: oraDecimal.ToByte(); - } - - return base.ConvertToByte(value); - } - - [CLSCompliant(false)] - public override UInt16 ConvertToUInt16(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultUInt16NullValue: (UInt16)oraDecimal.Value; - } - - return base.ConvertToUInt16(value); - } - - [CLSCompliant(false)] - public override UInt32 ConvertToUInt32(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultUInt32NullValue: (UInt32)oraDecimal.Value; - } - - return base.ConvertToUInt32(value); - } - - [CLSCompliant(false)] - public override UInt64 ConvertToUInt64(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultUInt64NullValue: (UInt64)oraDecimal.Value; - } - - return base.ConvertToUInt64(value); - } - - public override Single ConvertToSingle(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultSingleNullValue: oraDecimal.ToSingle(); - } - - return base.ConvertToSingle(value); - } - - public override Double ConvertToDouble(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultDoubleNullValue: oraDecimal.ToDouble(); - } - - return base.ConvertToDouble(value); - } - - public override Boolean ConvertToBoolean(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultBooleanNullValue: (oraDecimal.Value != 0); - } - - return base.ConvertToBoolean(value); - } - - public override DateTime ConvertToDateTime(object value) - { - if (value is OracleDate) - { - var oraDate = (OracleDate)value; - return oraDate.IsNull? DefaultDateTimeNullValue: oraDate.Value; - } - - return base.ConvertToDateTime(value); - } - - public override Decimal ConvertToDecimal(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? DefaultDecimalNullValue: oraDecimal.Value; - } - - return base.ConvertToDecimal(value); - } - - public override Guid ConvertToGuid(object value) - { - if (value is OracleString) - { - var oraString = (OracleString)value; - return oraString.IsNull? DefaultGuidNullValue: new Guid(oraString.Value); - } - - if (value is OracleBlob) - { - using (var oraBlob = (OracleBlob)value) - return oraBlob.IsNull? DefaultGuidNullValue: new Guid(oraBlob.Value); - } - - return base.ConvertToGuid(value); - } - - public override String ConvertToString(object value) - { - if (value is OracleString) - { - var oraString = (OracleString)value; - return oraString.IsNull? DefaultStringNullValue: oraString.Value; - } -#if !MANAGED - if (value is OracleXmlType) - { - var oraXmlType = (OracleXmlType)value; - return oraXmlType.IsNull ? DefaultStringNullValue : oraXmlType.Value; - } -#endif - if (value is OracleClob) - { - using (var oraClob = (OracleClob)value) - return oraClob.IsNull? DefaultStringNullValue: oraClob.Value; - } - - return base.ConvertToString(value); - } - -#if !MANAGED - public override Stream ConvertToStream(object value) - { - if (value is OracleXmlType) - { - var oraXml = (OracleXmlType)value; - return oraXml.IsNull? DefaultStreamNullValue: oraXml.GetStream(); - } - - return base.ConvertToStream(value); - } - - public override XmlReader ConvertToXmlReader(object value) - { - if (value is OracleXmlType) - { - var oraXml = (OracleXmlType)value; - return oraXml.IsNull? DefaultXmlReaderNullValue: oraXml.GetXmlReader(); - } - - return base.ConvertToXmlReader(value); - } - - public override XmlDocument ConvertToXmlDocument(object value) - { - if (value is OracleXmlType) - { - var oraXml = (OracleXmlType)value; - return oraXml.IsNull? DefaultXmlDocumentNullValue: oraXml.GetXmlDocument(); - } - - return base.ConvertToXmlDocument(value); - } -#endif - - public override Byte[] ConvertToByteArray(object value) - { - if (value is OracleBlob) - { - using (var oraBlob = (OracleBlob)value) - return oraBlob.IsNull? null: oraBlob.Value; - } - - if (value is OracleBinary) - { - var oraBinary = (OracleBinary)value; - return oraBinary.IsNull? null: oraBinary.Value; - } - - if (value is OracleBFile) - { - var oraBFile = (OracleBFile)value; - return oraBFile.IsNull? null: oraBFile.Value; - } - - return base.ConvertToByteArray(value); - } - - public override Char[] ConvertToCharArray(object value) - { - if (value is OracleString) - { - var oraString = (OracleString)value; - return oraString.IsNull? null: oraString.Value.ToCharArray(); - } - - if (value is OracleClob) - { - using (var oraClob = (OracleClob)value) - return oraClob.IsNull? null: oraClob.Value.ToCharArray(); - } - - return base.ConvertToCharArray(value); - } - - #endregion - - #region Nullable Types - - [CLSCompliant(false)] - public override SByte? ConvertToNullableSByte(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (SByte?)oraDecimal.Value; - } - - return base.ConvertToNullableSByte(value); - } - - public override Int16? ConvertToNullableInt16(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Int16?)oraDecimal.ToInt16(); - } - - return base.ConvertToNullableInt16(value); - } - - public override Int32? ConvertToNullableInt32(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Int32?)oraDecimal.ToInt32(); - } - - return base.ConvertToNullableInt32(value); - } - - public override Int64? ConvertToNullableInt64(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Int64?)oraDecimal.ToInt64(); - } - - return base.ConvertToNullableInt64(value); - } - - public override Byte? ConvertToNullableByte(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Byte?)oraDecimal.ToByte(); - } - - return base.ConvertToNullableByte(value); - } - - [CLSCompliant(false)] - public override UInt16? ConvertToNullableUInt16(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (UInt16?)oraDecimal.Value; - } - - return base.ConvertToNullableUInt16(value); - } - - [CLSCompliant(false)] - public override UInt32? ConvertToNullableUInt32(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (UInt32?)oraDecimal.Value; - } - - return base.ConvertToNullableUInt32(value); - } - - [CLSCompliant(false)] - public override UInt64? ConvertToNullableUInt64(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (UInt64?)oraDecimal.Value; - } - - return base.ConvertToNullableUInt64(value); - } - - public override Single? ConvertToNullableSingle(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Single?)oraDecimal.ToSingle(); - } - - return base.ConvertToNullableSingle(value); - } - - public override Double? ConvertToNullableDouble(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Double?)oraDecimal.ToDouble(); - } - - return base.ConvertToNullableDouble(value); - } - - public override Boolean? ConvertToNullableBoolean(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Boolean?)(oraDecimal.Value != 0); - } - - return base.ConvertToNullableBoolean(value); - } - - public override DateTime? ConvertToNullableDateTime(object value) - { - if (value is OracleDate) - { - var oraDate = (OracleDate)value; - return oraDate.IsNull? null: (DateTime?)oraDate.Value; - } - - return base.ConvertToNullableDateTime(value); - } - - public override Decimal? ConvertToNullableDecimal(object value) - { - if (value is OracleDecimal) - { - var oraDecimal = (OracleDecimal)value; - return oraDecimal.IsNull? null: (Decimal?)oraDecimal.Value; - } - - return base.ConvertToNullableDecimal(value); - } - - public override Guid? ConvertToNullableGuid(object value) - { - if (value is OracleString) - { - var oraString = (OracleString)value; - return oraString.IsNull? null: (Guid?)new Guid(oraString.Value); - } - - if (value is OracleBlob) - { - using (var oraBlob = (OracleBlob)value) - return oraBlob.IsNull? null: (Guid?)new Guid(oraBlob.Value); - } - - return base.ConvertToNullableGuid(value); - } - - #endregion - - #endregion - - public override object MapValueToEnum(object value, Type type) - { - if (value is OracleString) - { - var oracleValue = (OracleString)value; - value = oracleValue.IsNull? null: oracleValue.Value; - } - else if (value is OracleDecimal) - { - var oracleValue = (OracleDecimal)value; - if (oracleValue.IsNull) - value = null; - else - value = oracleValue.Value; - } - - return base.MapValueToEnum(value, type); - } - - public override object MapValueToEnum(object value, MemberAccessor ma) - { - if (value is OracleString) - { - var oracleValue = (OracleString)value; - value = oracleValue.IsNull ? null : oracleValue.Value; - } - else if (value is OracleDecimal) - { - var oracleValue = (OracleDecimal)value; - if (oracleValue.IsNull) - value = null; - else - value = oracleValue.Value; - } - - return base.MapValueToEnum(value, ma); - } - - public override object ConvertChangeType(object value, Type conversionType) - { - // Handle OracleDecimal with IsNull == true case - // - return base.ConvertChangeType(IsNull(value)? null: value, conversionType); - } - - public override bool IsNull(object value) - { - // ODP 10 does not expose this interface to public. - // - // return value is INullable && ((INullable)value).IsNull; - - return - value is OracleDecimal? ((OracleDecimal) value).IsNull: - value is OracleString? ((OracleString) value).IsNull: - value is OracleDate? ((OracleDate) value).IsNull: - value is OracleTimeStamp? ((OracleTimeStamp) value).IsNull: - value is OracleTimeStampTZ? ((OracleTimeStampTZ) value).IsNull: - value is OracleTimeStampLTZ? ((OracleTimeStampLTZ)value).IsNull: -#if !MANAGED - value is OracleXmlType? ((OracleXmlType) value).IsNull: -#endif - value is OracleBlob? ((OracleBlob) value).IsNull: - value is OracleClob? ((OracleClob) value).IsNull: - value is OracleBFile? ((OracleBFile) value).IsNull: - value is OracleBinary? ((OracleBinary) value).IsNull: - value is OracleIntervalDS? ((OracleIntervalDS) value).IsNull: - value is OracleIntervalYM? ((OracleIntervalYM) value).IsNull: - base.IsNull(value); - } - } - - // TODO: implement via IDataReaderEx / DataReaderEx - // - public class OracleDataReaderMapper : DataReaderMapper - { - public OracleDataReaderMapper(MappingSchema mappingSchema, IDataReader dataReader) - : base(mappingSchema, dataReader) - { - _dataReader = dataReader is OracleDataReaderEx? - ((OracleDataReaderEx)dataReader).DataReader: - (OracleDataReader)dataReader; - } - - private readonly OracleDataReader _dataReader; - - public override Type GetFieldType(int index) - { - var fieldType = _dataReader.GetProviderSpecificFieldType(index); - - if (fieldType != typeof(OracleBlob) -#if !MANAGED - && fieldType != typeof(OracleXmlType) -#endif - ) - fieldType = _dataReader.GetFieldType(index); - - return fieldType; - } - - public override object GetValue(object o, int index) - { - var fieldType = _dataReader.GetProviderSpecificFieldType(index); - -#if !MANAGED - if (fieldType == typeof(OracleXmlType)) - { - var xml = _dataReader.GetOracleXmlType(index); - return MappingSchema.ConvertToXmlDocument(xml); - } -#endif - if (fieldType == typeof(OracleBlob)) - { - var blob = _dataReader.GetOracleBlob(index); - return MappingSchema.ConvertToStream(blob); - } - - return _dataReader.IsDBNull(index)? null: - _dataReader.GetValue(index); - } - - public override Boolean GetBoolean(object o, int index) { return MappingSchema.ConvertToBoolean(GetValue(o, index)); } - public override Char GetChar (object o, int index) { return MappingSchema.ConvertToChar (GetValue(o, index)); } - public override Guid GetGuid (object o, int index) { return MappingSchema.ConvertToGuid (GetValue(o, index)); } - - [CLSCompliant(false)] - public override SByte GetSByte (object o, int index) { return (SByte)_dataReader.GetDecimal(index); } - [CLSCompliant(false)] - public override UInt16 GetUInt16 (object o, int index) { return (UInt16)_dataReader.GetDecimal(index); } - [CLSCompliant(false)] - public override UInt32 GetUInt32 (object o, int index) { return (UInt32)_dataReader.GetDecimal(index); } - [CLSCompliant(false)] - public override UInt64 GetUInt64 (object o, int index) { return (UInt64)_dataReader.GetDecimal(index); } - - public override Decimal GetDecimal(object o, int index) { return OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(index), 28).Value; } - - public override Boolean? GetNullableBoolean(object o, int index) { return MappingSchema.ConvertToNullableBoolean(GetValue(o, index)); } - public override Char? GetNullableChar (object o, int index) { return MappingSchema.ConvertToNullableChar (GetValue(o, index)); } - public override Guid? GetNullableGuid (object o, int index) { return MappingSchema.ConvertToNullableGuid (GetValue(o, index)); } - - [CLSCompliant(false)] - public override SByte? GetNullableSByte (object o, int index) { return _dataReader.IsDBNull(index)? null: (SByte?)_dataReader.GetDecimal(index); } - [CLSCompliant(false)] - public override UInt16? GetNullableUInt16 (object o, int index) { return _dataReader.IsDBNull(index)? null: (UInt16?)_dataReader.GetDecimal(index); } - [CLSCompliant(false)] - public override UInt32? GetNullableUInt32 (object o, int index) { return _dataReader.IsDBNull(index)? null: (UInt32?)_dataReader.GetDecimal(index); } - [CLSCompliant(false)] - public override UInt64? GetNullableUInt64 (object o, int index) { return _dataReader.IsDBNull(index)? null: (UInt64?)_dataReader.GetDecimal(index); } - - public override Decimal? GetNullableDecimal(object o, int index) { return _dataReader.IsDBNull(index)? (decimal?)null: OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(index), 28).Value; } - } - - public class OracleScalarDataReaderMapper : ScalarDataReaderMapper - { - private readonly OracleDataReader _dataReader; - - public OracleScalarDataReaderMapper( - MappingSchema mappingSchema, - IDataReader dataReader, - NameOrIndexParameter nameOrIndex) - : base(mappingSchema, dataReader, nameOrIndex) - { - _dataReader = dataReader is OracleDataReaderEx? - ((OracleDataReaderEx)dataReader).DataReader: - (OracleDataReader)dataReader; - - _fieldType = _dataReader.GetProviderSpecificFieldType(Index); - - if (_fieldType != typeof(OracleBlob) -#if !MANAGED - && _fieldType != typeof(OracleXmlType) -#endif - ) - _fieldType = _dataReader.GetFieldType(Index); - } - - private readonly Type _fieldType; - - public override Type GetFieldType(int index) - { - return _fieldType; - } - - public override object GetValue(object o, int index) - { -#if !MANAGED - if (_fieldType == typeof(OracleXmlType)) - { - var xml = _dataReader.GetOracleXmlType(Index); - return MappingSchema.ConvertToXmlDocument(xml); - } -#endif - if (_fieldType == typeof(OracleBlob)) - { - var blob = _dataReader.GetOracleBlob(Index); - return MappingSchema.ConvertToStream(blob); - } - - return _dataReader.IsDBNull(index)? null: - _dataReader.GetValue(Index); - } - - public override Boolean GetBoolean(object o, int index) { return MappingSchema.ConvertToBoolean(GetValue(o, Index)); } - public override Char GetChar (object o, int index) { return MappingSchema.ConvertToChar (GetValue(o, Index)); } - public override Guid GetGuid (object o, int index) { return MappingSchema.ConvertToGuid (GetValue(o, Index)); } - - [CLSCompliant(false)] - public override SByte GetSByte (object o, int index) { return (SByte)_dataReader.GetDecimal(Index); } - [CLSCompliant(false)] - public override UInt16 GetUInt16 (object o, int index) { return (UInt16)_dataReader.GetDecimal(Index); } - [CLSCompliant(false)] - public override UInt32 GetUInt32 (object o, int index) { return (UInt32)_dataReader.GetDecimal(Index); } - [CLSCompliant(false)] - public override UInt64 GetUInt64 (object o, int index) { return (UInt64)_dataReader.GetDecimal(Index); } - - public override Decimal GetDecimal(object o, int index) { return OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(Index), 28).Value; } - - public override Boolean? GetNullableBoolean(object o, int index) { return MappingSchema.ConvertToNullableBoolean(GetValue(o, Index)); } - public override Char? GetNullableChar (object o, int index) { return MappingSchema.ConvertToNullableChar (GetValue(o, Index)); } - public override Guid? GetNullableGuid (object o, int index) { return MappingSchema.ConvertToNullableGuid (GetValue(o, Index)); } - - [CLSCompliant(false)] - public override SByte? GetNullableSByte (object o, int index) { return _dataReader.IsDBNull(index)? null: (SByte?)_dataReader.GetDecimal(Index); } - [CLSCompliant(false)] - public override UInt16? GetNullableUInt16 (object o, int index) { return _dataReader.IsDBNull(index)? null: (UInt16?)_dataReader.GetDecimal(Index); } - [CLSCompliant(false)] - public override UInt32? GetNullableUInt32 (object o, int index) { return _dataReader.IsDBNull(index)? null: (UInt32?)_dataReader.GetDecimal(Index); } - [CLSCompliant(false)] - public override UInt64? GetNullableUInt64 (object o, int index) { return _dataReader.IsDBNull(index)? null: (UInt64?)_dataReader.GetDecimal(Index); } - - public override Decimal? GetNullableDecimal(object o, int index) { return _dataReader.IsDBNull(index)? (decimal?)null: OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(Index), 28).Value; } - } - - [Mixin(typeof(IDbDataParameter), "_oracleParameter")] - [Mixin(typeof(IDataParameter), "_oracleParameter")] - [Mixin(typeof(IDisposable), "_oracleParameter")] - [Mixin(typeof(ICloneable), "_oracleParameter")] - [CLSCompliant(false)] - public abstract class OracleParameterWrap - { - protected OracleParameter _oracleParameter; - public OracleParameter OracleParameter - { - get { return _oracleParameter; } - } - - public static IDbDataParameter CreateInstance(OracleParameter oraParameter) - { - var wrap = TypeAccessor.CreateInstanceEx(); - - wrap._oracleParameter = oraParameter; - - return (IDbDataParameter)wrap; - } - - public override string ToString() - { - return _oracleParameter.ToString(); - } - - /// - ///Gets or sets the value of the parameter. - /// - /// - ///An that is the value of the parameter. - ///The default value is null. - /// - protected object Value - { -#if CONVERTORACLETYPES - [MixinOverride] - get - { - object value = _oracleParameter.Value; - if (value is OracleBinary) - { - OracleBinary oracleValue = (OracleBinary)value; - return oracleValue.IsNull? null: oracleValue.Value; - } - if (value is OracleDate) - { - OracleDate oracleValue = (OracleDate)value; - if (oracleValue.IsNull) - return null; - return oracleValue.Value; - } - if (value is OracleDecimal) - { - OracleDecimal oracleValue = (OracleDecimal)value; - if (oracleValue.IsNull) - return null; - return oracleValue.Value; - } - if (value is OracleIntervalDS) - { - OracleIntervalDS oracleValue = (OracleIntervalDS)value; - if (oracleValue.IsNull) - return null; - return oracleValue.Value; - } - if (value is OracleIntervalYM) - { - OracleIntervalYM oracleValue = (OracleIntervalYM)value; - if (oracleValue.IsNull) - return null; - return oracleValue.Value; - } - if (value is OracleString) - { - OracleString oracleValue = (OracleString)value; - return oracleValue.IsNull? null: oracleValue.Value; - } - if (value is OracleTimeStamp) - { - OracleTimeStamp oracleValue = (OracleTimeStamp)value; - if (oracleValue.IsNull) - return null; - return oracleValue.Value; - } - if (value is OracleTimeStampLTZ) - { - OracleTimeStampLTZ oracleValue = (OracleTimeStampLTZ)value; - if (oracleValue.IsNull) - return null; - return oracleValue.Value; - } - if (value is OracleTimeStampTZ) - { - OracleTimeStampTZ oracleValue = (OracleTimeStampTZ)value; - if (oracleValue.IsNull) - return null; - return oracleValue.Value; - } - if (value is OracleXmlType) - { - OracleXmlType oracleValue = (OracleXmlType)value; - return oracleValue.IsNull? null: oracleValue.Value; - } - - return value; - } -#endif - [MixinOverride] - set - { - if (null != value) - { - if (value is Guid) - { - // Fix Oracle.Net bug #6: guid type is not handled - // - value = ((Guid)value).ToByteArray(); - } - else if (value is Array && !(value is byte[] || value is char[])) - { - _oracleParameter.CollectionType = OracleCollectionType.PLSQLAssociativeArray; - } - else if (value is IConvertible) - { - var convertible = (IConvertible)value; - var typeCode = convertible.GetTypeCode(); - - switch (typeCode) - { - case TypeCode.Boolean: - // Fix Oracle.Net bug #7: bool type is handled wrong - // - value = convertible.ToByte(null); - break; - - case TypeCode.SByte: - case TypeCode.UInt16: - case TypeCode.UInt32: - case TypeCode.UInt64: - // Fix Oracle.Net bug #8: some integer types are handled wrong - // - value = convertible.ToDecimal(null); - break; - - // Fix Oracle.Net bug #10: zero-length string can not be converted to - // ORAXML type, but null value can be. - // - case TypeCode.String: - if (((string)value).Length == 0) - value = null; - break; - - default: - // Fix Oracle.Net bug #5: Enum type is not handled - // - if (value is Enum) - { - // Convert a Enum value to it's underlying type. - // - value = System.Convert.ChangeType(value, typeCode); - } - break; - } - } - } - - _oracleParameter.Value = value; - } - } - } - - #endregion - - #region InsertBatch - - public override int InsertBatch( - DbManager db, - string insertText, - IEnumerable collection, - MemberMapper[] members, - int maxBatchSize, - DbManager.ParameterProvider getParameters) - { - var sb = new StringBuilder(); - var sp = new OracleSqlProvider(); - var pn = 0; - var n = 0; - var cnt = 0; - var str = "\t" + insertText - .Substring(0, insertText.IndexOf(") VALUES (")) - .Substring(7) - .Replace("\r", "") - .Replace("\n", "") - .Replace("\t", " ") - .Replace("( ", "(") - //.Replace(" ", " ") - + ") VALUES ("; - - var parameters = new List(); - - foreach (var item in collection) - { - if (sb.Length == 0) - sb.AppendLine("INSERT ALL"); - - sb.Append(str); - - foreach (var member in members) - { - var value = member.GetValue(item); - - if (value != null && value.GetType().IsEnum) - value = MappingSchema.MapEnumToValue(value, true); - - if (value is Nullable) - value = ((DateTime?)value).Value; - - if (value is DateTime) - { - var dt = (DateTime)value; - sb.Append(string.Format("to_timestamp('{0:dd.MM.yyyy HH:mm:ss.ffffff}', 'DD.MM.YYYY HH24:MI:SS.FF6')", dt)); - } - else if (value is string && ((string)value).Length >= 2000) +// Odp.Net Data Provider. +// http://www.oracle.com/technology/tech/windows/odpnet/index.html +// +using System; +using System.Collections; +using System.Collections.Generic; +using System.Data; +using System.Data.Common; +using System.Globalization; +using System.IO; +using System.Linq; +using System.Reflection; +using System.Text; +using System.Xml; + +using BLToolkit.Aspects; +using BLToolkit.Common; +using BLToolkit.Data.DataProvider.Interpreters; +using BLToolkit.Mapping; +using BLToolkit.Reflection; + +#if MANAGED +using Oracle.ManagedDataAccess.Client; +using Oracle.ManagedDataAccess.Types; +#else +using Oracle.DataAccess.Client; +using Oracle.DataAccess.Types; +#endif + +namespace BLToolkit.Data.DataProvider +{ + using Sql.SqlProvider; + + /// + /// Implements access to the Data Provider for Oracle. + /// + /// + /// See the method to find an example. + /// + /// AddDataManager Method +#if !MANAGED + public class OdpDataProvider : DataProviderBase + { + private readonly DataProviderInterpreterBase _interpreterBase; + + public OdpDataProvider() + { + MappingSchema = new OdpMappingSchema(); + _interpreterBase = new OracleDataProviderInterpreter(); + } + + public const string NameString = DataProvider.ProviderName.Oracle; + + private const string DbTypeTableName = "Oracle.DataAccess.Client.OraDb_DbTypeTable"; + + static OdpDataProvider() + { +#else + public class OdpManagedDataProvider : DataProviderBase + { + private readonly DataProviderInterpreterBase _interpreterBase; + + public OdpManagedDataProvider() + { + MappingSchema = new OdpMappingSchema(); + _interpreterBase = new OracleDataProviderInterpreter(); + } + + public const string NameString = DataProvider.ProviderName.OracleManaged; + + private const string DbTypeTableName = "Oracle.ManagedDataAccess.Client.OraDb_DbTypeTable"; + + static OdpManagedDataProvider() + { +#endif + // Fix Oracle.Net bug #1: Array types are not handled. + // + var oraDbDbTypeTableType = typeof(OracleParameter).Assembly.GetType(DbTypeTableName); + + if (null != oraDbDbTypeTableType) + { + var typeTable = (Hashtable)oraDbDbTypeTableType.InvokeMember( + "s_table", BindingFlags.Static | BindingFlags.NonPublic | BindingFlags.GetField, + null, null, Type.EmptyTypes); + + if (null != typeTable) + { + typeTable[typeof(DateTime[])] = OracleDbType.TimeStamp; + typeTable[typeof(Int16[])] = OracleDbType.Int16; + typeTable[typeof(Int32[])] = OracleDbType.Int32; + typeTable[typeof(Int64[])] = OracleDbType.Int64; + typeTable[typeof(Single[])] = OracleDbType.Single; + typeTable[typeof(Double[])] = OracleDbType.Double; + typeTable[typeof(Decimal[])] = OracleDbType.Decimal; + typeTable[typeof(TimeSpan[])] = OracleDbType.IntervalDS; + typeTable[typeof(String[])] = OracleDbType.Varchar2; + typeTable[typeof(OracleBFile[])] = OracleDbType.BFile; + typeTable[typeof(OracleBinary[])] = OracleDbType.Raw; + typeTable[typeof(OracleBlob[])] = OracleDbType.Blob; + typeTable[typeof(OracleClob[])] = OracleDbType.Clob; + typeTable[typeof(OracleDate[])] = OracleDbType.Date; + typeTable[typeof(OracleDecimal[])] = OracleDbType.Decimal; + typeTable[typeof(OracleIntervalDS[])] = OracleDbType.IntervalDS; + typeTable[typeof(OracleIntervalYM[])] = OracleDbType.IntervalYM; + typeTable[typeof(OracleRefCursor[])] = OracleDbType.RefCursor; + typeTable[typeof(OracleString[])] = OracleDbType.Varchar2; + typeTable[typeof(OracleTimeStamp[])] = OracleDbType.TimeStamp; + typeTable[typeof(OracleTimeStampLTZ[])] = OracleDbType.TimeStampLTZ; + typeTable[typeof(OracleTimeStampTZ[])] = OracleDbType.TimeStampTZ; +#if !MANAGED + typeTable[typeof(OracleXmlType[])] = OracleDbType.XmlType; +#endif + + typeTable[typeof(Boolean)] = OracleDbType.Byte; + typeTable[typeof(Guid)] = OracleDbType.Raw; + typeTable[typeof(SByte)] = OracleDbType.Decimal; + typeTable[typeof(UInt16)] = OracleDbType.Decimal; + typeTable[typeof(UInt32)] = OracleDbType.Decimal; + typeTable[typeof(UInt64)] = OracleDbType.Decimal; + + typeTable[typeof(Boolean[])] = OracleDbType.Byte; + typeTable[typeof(Guid[])] = OracleDbType.Raw; + typeTable[typeof(SByte[])] = OracleDbType.Decimal; + typeTable[typeof(UInt16[])] = OracleDbType.Decimal; + typeTable[typeof(UInt32[])] = OracleDbType.Decimal; + typeTable[typeof(UInt64[])] = OracleDbType.Decimal; + + typeTable[typeof(Boolean?)] = OracleDbType.Byte; + typeTable[typeof(Guid?)] = OracleDbType.Raw; + typeTable[typeof(SByte?)] = OracleDbType.Decimal; + typeTable[typeof(UInt16?)] = OracleDbType.Decimal; + typeTable[typeof(UInt32?)] = OracleDbType.Decimal; + typeTable[typeof(UInt64?)] = OracleDbType.Decimal; + typeTable[typeof(DateTime?[])] = OracleDbType.TimeStamp; + typeTable[typeof(Int16?[])] = OracleDbType.Int16; + typeTable[typeof(Int32?[])] = OracleDbType.Int32; + typeTable[typeof(Int64?[])] = OracleDbType.Int64; + typeTable[typeof(Single?[])] = OracleDbType.Single; + typeTable[typeof(Double?[])] = OracleDbType.Double; + typeTable[typeof(Decimal?[])] = OracleDbType.Decimal; + typeTable[typeof(TimeSpan?[])] = OracleDbType.IntervalDS; + typeTable[typeof(Boolean?[])] = OracleDbType.Byte; + typeTable[typeof(Guid?[])] = OracleDbType.Raw; + typeTable[typeof(SByte?[])] = OracleDbType.Decimal; + typeTable[typeof(UInt16?[])] = OracleDbType.Decimal; + typeTable[typeof(UInt32?[])] = OracleDbType.Decimal; + typeTable[typeof(UInt64?[])] = OracleDbType.Decimal; + + typeTable[typeof(XmlReader)] = OracleDbType.XmlType; + typeTable[typeof(XmlDocument)] = OracleDbType.XmlType; + typeTable[typeof(MemoryStream)] = OracleDbType.Blob; + typeTable[typeof(XmlReader[])] = OracleDbType.XmlType; + typeTable[typeof(XmlDocument[])] = OracleDbType.XmlType; + typeTable[typeof(MemoryStream[])] = OracleDbType.Blob; + } + } + } + + /// + /// Creates the database connection object. + /// + /// + /// See the method to find an example. + /// + /// AddDataManager Method + /// The database connection object. + public override IDbConnection CreateConnectionObject() + { + return new OracleConnection(); + } + + public override IDbCommand CreateCommandObject(IDbConnection connection) + { + var oraConnection = connection as OracleConnection; + + if (null != oraConnection) + { + var oraCommand = oraConnection.CreateCommand(); + + // Fix Oracle.Net bug #2: Empty arrays can not be sent to the server. + // + oraCommand.BindByName = true; + + return oraCommand; + } + + return base.CreateCommandObject(connection); + } + + public override void SetParameterValue(IDbDataParameter parameter, object value) + { + // We need NVarChar2 in order to insert UTF8 string values. The default Odp VarChar2 dbtype doesnt work + // with UTF8 values. Note : Microsoft oracle client uses NVarChar value by default. + +// ReSharper disable once SuspiciousTypeConversion.Global + var wrap = parameter as OracleParameterWrap; + if (wrap != null && value is string) + wrap.OracleParameter.OracleDbType = OracleDbType.NVarchar2; + + _interpreterBase.SetParameterValue(parameter, value); + + // strings and byte arrays larger than 4000 bytes may be handled improperly + if (wrap != null) + { + const int thresholdSize = 4000; + if (value is string && Encoding.UTF8.GetBytes((string)value).Length > thresholdSize) + { + wrap.OracleParameter.OracleDbType = OracleDbType.Clob; + } + else if (value is byte[] && ((byte[])value).Length > thresholdSize) + { + wrap.OracleParameter.OracleDbType = OracleDbType.Blob; + } + } + } + + public override IDbDataParameter CloneParameter(IDbDataParameter parameter) + { + var oraParameter = (parameter is OracleParameterWrap)? + (parameter as OracleParameterWrap).OracleParameter: parameter as OracleParameter; + + if (null != oraParameter) + { + var oraParameterClone = (OracleParameter)oraParameter.Clone(); + + // Fix Oracle.Net bug #3: CollectionType property is not cloned. + // + oraParameterClone.CollectionType = oraParameter.CollectionType; + + // Fix Oracle.Net bug #8423178 + // See http://forums.oracle.com/forums/thread.jspa?threadID=975902&tstart=0 + // + if (oraParameterClone.OracleDbType == OracleDbType.RefCursor) + { + // Set OracleDbType to itself to reset m_bSetDbType and m_bOracleDbTypeExSet + // + oraParameterClone.OracleDbType = OracleDbType.RefCursor; + } + + return OracleParameterWrap.CreateInstance(oraParameterClone); + } + + return base.CloneParameter(parameter); + } + + public override void SetUserDefinedType(IDbDataParameter parameter, string typeName) + { + var oraParameter = (parameter is OracleParameterWrap) ? + (parameter as OracleParameterWrap).OracleParameter : parameter as OracleParameter; + + if (oraParameter == null) + throw new ArgumentException("OracleParameter expected.", "parameter"); + + oraParameter.UdtTypeName = typeName; + } + + /// + /// Creates the data adapter object. + /// + /// + /// See the method to find an example. + /// + /// AddDataManager Method + /// A data adapter object. + public override DbDataAdapter CreateDataAdapterObject() + { + return new OracleDataAdapter(); + } + + /// + /// Populates the specified IDbCommand object's Parameters collection with + /// parameter information for the stored procedure specified in the IDbCommand. + /// + /// + /// See the method to find an example. + /// + /// AddDataManager Method + /// The IDbCommand referencing the stored procedure for which the parameter + /// information is to be derived. The derived parameters will be populated into + /// the Parameters of this command. + public override bool DeriveParameters(IDbCommand command) + { + var oraCommand = command as OracleCommand; + + if (null != oraCommand) + { + try + { + OracleCommandBuilder.DeriveParameters(oraCommand); + } + catch (Exception ex) + { + // Make Oracle less laconic. + // + throw new DataException(string.Format("{0}\nCommandText: {1}", ex.Message, oraCommand.CommandText), ex); + } + + return true; + } + + return false; + } + + /// + /// Open an into the given object + /// + /// an to perform GetDataReader() on + /// The into the returned by GetDataReader() + public override IDataReader GetRefCursorDataReader(object refCursor) + { + OracleRefCursor oracleRefCursor = refCursor as OracleRefCursor; + if (oracleRefCursor == null) + { + throw new ArgumentException("Argument must be of type 'OracleRefCursor'", "refCursor"); + } + return oracleRefCursor.GetDataReader(); + } + + public override object Convert(object value, ConvertType convertType) + { + switch (convertType) + { + case ConvertType.NameToQueryParameter: + var qname = (string)value; + + // + // Avoid "ORA-00972: identifier is too long" error + // Cause error : You tried to reference a table, cluster, view, index, synonym, tablespace, or username with a value that was longer than 30 characters. + // Resolution : Names for tables, clusters, views, indexes, synonyms, tablespaces, and usernames must be 30 characters or less. + // You must shorten the name to no more than 30 characters for these objects. + // + if (qname.Length > 30) + { + qname = qname.Substring(0, 30); + return SqlProvider.Convert(qname, convertType); + } + return SqlProvider.Convert(value, convertType); + + case ConvertType.NameToCommandParameter: + case ConvertType.NameToSprocParameter: + return ParameterPrefix == null ? value : ParameterPrefix + value; + + case ConvertType.SprocParameterToName: + var name = (string)value; + + if (name.Length > 0) + { + if (name[0] == ':') + return name.Substring(1); + + if (ParameterPrefix != null && + name.ToUpper(CultureInfo.InvariantCulture).StartsWith(ParameterPrefix)) + { + return name.Substring(ParameterPrefix.Length); + } + } + + break; + + case ConvertType.ExceptionToErrorNumber: + if (value is OracleException) + return ((OracleException)value).Number; + break; + } + + return SqlProvider.Convert(value, convertType); + } + + public override void PrepareCommand(ref CommandType commandType, ref string commandText, ref IDbDataParameter[] commandParameters) + { + base.PrepareCommand(ref commandType, ref commandText, ref commandParameters); + + if (commandType == CommandType.Text) + { + // Fix Oracle bug #11 '\r' is not a valid character! + // + commandText = commandText.Replace('\r', ' '); + } + } + + public override void AttachParameter(IDbCommand command, IDbDataParameter parameter) + { + var oraParameter = (parameter is OracleParameterWrap) ? + (parameter as OracleParameterWrap).OracleParameter : parameter as OracleParameter; + + if (null != oraParameter) + { + if (oraParameter.CollectionType == OracleCollectionType.PLSQLAssociativeArray) + { + if (oraParameter.Direction == ParameterDirection.Input + || oraParameter.Direction == ParameterDirection.InputOutput) + { + var ar = oraParameter.Value as Array; + + if (null != ar && !(ar is byte[] || ar is char[])) + { + oraParameter.Size = ar.Length; + + if (oraParameter.DbType == DbType.String + && oraParameter.Direction == ParameterDirection.InputOutput) + { + var arrayBindSize = new int[oraParameter.Size]; + + for (var i = 0; i < oraParameter.Size; ++i) + { + arrayBindSize[i] = 1024; + } + + oraParameter.ArrayBindSize = arrayBindSize; + } + } + + if (oraParameter.Size == 0) + { + // Skip this parameter. + // Fix Oracle.Net bug #2: Empty arrays can not be sent to the server. + // + return; + } + + if (oraParameter.Value is Stream[]) + { + var streams = (Stream[])oraParameter.Value; + + for (var i = 0; i < oraParameter.Size; ++i) + { + if (streams[i] is OracleBFile || streams[i] is OracleBlob || streams[i] is OracleClob +#if !MANAGED + || streams[i] is OracleXmlStream +#endif + ) + { + // Known Oracle type. + // + continue; + } + + streams[i] = CopyStream(streams[i], (OracleCommand)command); + } + } + else if (oraParameter.Value is XmlDocument[]) + { + var xmlDocuments = (XmlDocument[])oraParameter.Value; + var values = new object[oraParameter.Size]; + + switch (oraParameter.OracleDbType) + { + case OracleDbType.XmlType: +#if !MANAGED + for (var i = 0; i < oraParameter.Size; ++i) + { + values[i] = xmlDocuments[i].DocumentElement == null ? + (object)DBNull.Value : + new OracleXmlType((OracleConnection)command.Connection, xmlDocuments[i]); + } + + oraParameter.Value = values; + + break; + +#else + throw new NotSupportedException(); +#endif + + // Fix Oracle.Net bug #9: XmlDocument.ToString() returns System.Xml.XmlDocument, + // so m_value.ToString() is not enought. + // + case OracleDbType.Clob: + case OracleDbType.NClob: + case OracleDbType.Varchar2: + case OracleDbType.NVarchar2: + case OracleDbType.Char: + case OracleDbType.NChar: + for (var i = 0; i < oraParameter.Size; ++i) + { + values[i] = xmlDocuments[i].DocumentElement == null ? + (object)DBNull.Value : + xmlDocuments[i].InnerXml; + } + + oraParameter.Value = values; + + break; + + // Or convert to bytes if need. + // + case OracleDbType.Blob: + case OracleDbType.BFile: + case OracleDbType.Raw: + case OracleDbType.Long: + case OracleDbType.LongRaw: + for (var i = 0; i < oraParameter.Size; ++i) + { + if (xmlDocuments[i].DocumentElement == null) + values[i] = DBNull.Value; + else + using (var s = new MemoryStream()) + { + xmlDocuments[i].Save(s); + values[i] = s.GetBuffer(); + } + } + + oraParameter.Value = values; + + break; + } + } + } + else if (oraParameter.Direction == ParameterDirection.Output) + { + // Fix Oracle.Net bug #4: ArrayBindSize must be explicitly specified. + // + if (oraParameter.DbType == DbType.String) + { + oraParameter.Size = 1024; + var arrayBindSize = new int[oraParameter.Size]; + for (var i = 0; i < oraParameter.Size; ++i) + { + arrayBindSize[i] = 1024; + } + + oraParameter.ArrayBindSize = arrayBindSize; + } + else + { + oraParameter.Size = 32767; + } + } + } + else if (oraParameter.Value is Stream) + { + var stream = (Stream)oraParameter.Value; + + if (!(stream is OracleBFile) && !(stream is OracleBlob) && + !(stream is OracleClob) +#if !MANAGED + && !(stream is OracleXmlStream) +#endif + ) + { + oraParameter.Value = CopyStream(stream, (OracleCommand)command); + } + } + else if (oraParameter.Value is Byte[]) + { + var bytes = (Byte[])oraParameter.Value; + + if (bytes.Length > 32000) + { + oraParameter.Value = CopyStream(bytes, (OracleCommand)command); + } + } + else if (oraParameter.Value is XmlDocument) + { + var xmlDocument = (XmlDocument)oraParameter.Value; + if (xmlDocument.DocumentElement == null) + oraParameter.Value = DBNull.Value; + else + { + + switch (oraParameter.OracleDbType) + { + case OracleDbType.XmlType: +#if !MANAGED + oraParameter.Value = new OracleXmlType((OracleConnection)command.Connection, xmlDocument); + break; +#else + throw new NotSupportedException(); +#endif + + // Fix Oracle.Net bug #9: XmlDocument.ToString() returns System.Xml.XmlDocument, + // so m_value.ToString() is not enought. + // + case OracleDbType.Clob: + case OracleDbType.NClob: + case OracleDbType.Varchar2: + case OracleDbType.NVarchar2: + case OracleDbType.Char: + case OracleDbType.NChar: + using (TextWriter w = new StringWriter()) + { + xmlDocument.Save(w); + oraParameter.Value = w.ToString(); + } + break; + + // Or convert to bytes if need. + // + case OracleDbType.Blob: + case OracleDbType.BFile: + case OracleDbType.Raw: + case OracleDbType.Long: + case OracleDbType.LongRaw: + using (var s = new MemoryStream()) + { + xmlDocument.Save(s); + oraParameter.Value = s.GetBuffer(); + } + break; + } + } + } + + parameter = oraParameter; + } + + base.AttachParameter(command, parameter); + } + + public override DbType GetParameterDbType(DbType dbType) + { + return _interpreterBase.GetParameterDbType(dbType); + } + + private static Stream CopyStream(Stream stream, OracleCommand cmd) + { + return CopyStream(Common.Convert.ToByteArray(stream), cmd); + } + + private static Stream CopyStream(Byte[] bytes, OracleCommand cmd) + { + var ret = new OracleBlob(cmd.Connection); + ret.Write(bytes, 0, bytes.Length); + return ret; + } + + public override bool IsValueParameter(IDbDataParameter parameter) + { + var oraParameter = (parameter is OracleParameterWrap) ? + (parameter as OracleParameterWrap).OracleParameter : parameter as OracleParameter; + + if (null != oraParameter) + { + if (oraParameter.OracleDbType == OracleDbType.RefCursor + && oraParameter.Direction == ParameterDirection.Output) + { + // Ignore out ref cursors, while out parameters of other types are o.k. + return false; + } + } + + return base.IsValueParameter(parameter); + } + + public override string GetSequenceQuery(string sequenceName) + { + return _interpreterBase.GetSequenceQuery(sequenceName); + } + + public override string NextSequenceQuery(string sequenceName) + { + return _interpreterBase.NextSequenceQuery(sequenceName); + } + + public override string GetReturningInto(string columnName) + { + return _interpreterBase.GetReturningInto(columnName); + } + + public override IDbDataParameter CreateParameterObject(IDbCommand command) + { + var parameter = base.CreateParameterObject(command); + + if (parameter is OracleParameter) + parameter = OracleParameterWrap.CreateInstance(parameter as OracleParameter); + + return parameter; + } + + public override IDbDataParameter GetParameter(IDbCommand command, NameOrIndexParameter nameOrIndex) + { + var parameter = base.GetParameter(command, nameOrIndex); + + if (parameter is OracleParameter) + parameter = OracleParameterWrap.CreateInstance(parameter as OracleParameter); + + return parameter; + } + + /// + /// Returns connection type. + /// + /// + /// See the method to find an example. + /// + /// AddDataManager Method + /// An instance of the class. + public override Type ConnectionType + { + get { return typeof(OracleConnection); } + } + + /// + /// Returns the data provider name. + /// + /// + /// See the method to find an example. + /// + /// AddDataProvider Method + /// Data provider name. + public override string Name + { + get { return NameString; } + } + + public override int MaxBatchSize + { + get { return 0; } + } + + public override ISqlProvider CreateSqlProvider() + { + return new OracleSqlProvider(); + } + + public override int ExecuteArray(IDbCommand command, int iterations) + { + var cmd = (OracleCommand)command; + var oracleParameters = cmd.Parameters.OfType().ToArray(); + var oldCollectionTypes = oracleParameters.Select(p => p.CollectionType).ToArray(); + + try + { + foreach (var p in oracleParameters) + { + p.CollectionType = OracleCollectionType.None; + } + + cmd.ArrayBindCount = iterations; + return cmd.ExecuteNonQuery(); + } + finally + { + foreach (var p in oracleParameters.Zip(oldCollectionTypes, (p, t) => new { Param = p, CollectionType = t })) + { + p.Param.CollectionType = p.CollectionType; + } + + cmd.ArrayBindCount = 0; + } + } + + public override IDataReader GetDataReader(MappingSchema schema, IDataReader dataReader) + { + return dataReader is OracleDataReader ? + new OracleDataReaderEx((OracleDataReader)dataReader) : + base.GetDataReader(schema, dataReader); + } + + class OracleDataReaderEx : DataReaderEx + { + public OracleDataReaderEx(OracleDataReader rd) + : base(rd) + { + } + + public override object GetValue(int i) + { + string dataTypeName = GetDataTypeName(i); + if (dataTypeName == "Clob") + { + OracleClob clob = DataReader.GetOracleClob(i); + if (!clob.IsNull) + { + return clob; + //byte[] b = new byte[clob.Length]; + ////Read data from database + //clob.Read(b, 0, (int)clob.Length); + + //return b; + //return clob.Value; + } + else + return null; + } + else + return base.GetValue(i); + } + + public override DateTimeOffset GetDateTimeOffset(int i) + { + var ts = DataReader.GetOracleTimeStampTZ(i); + return new DateTimeOffset(ts.Value, ts.GetTimeZoneOffset()); + } + } + + private string _parameterPrefix = "P"; + public string ParameterPrefix + { + get { return _parameterPrefix; } + set + { + _parameterPrefix = string.IsNullOrEmpty(value) ? null : + value.ToUpper(CultureInfo.InvariantCulture); + } + } + + /// + /// One time initialization from a configuration file. + /// + /// Provider specific attributes. + public override void Configure(System.Collections.Specialized.NameValueCollection attributes) + { + var val = attributes["ParameterPrefix"]; + if (val != null) + ParameterPrefix = val; + + base.Configure(attributes); + } + + #region Inner types + + public class OdpMappingSchema : MappingSchema + { + public override DataReaderMapper CreateDataReaderMapper(IDataReader dataReader) + { + return new OracleDataReaderMapper(this, dataReader); + } + + public override DataReaderMapper CreateDataReaderMapper( + IDataReader dataReader, + NameOrIndexParameter nip) + { + return new OracleScalarDataReaderMapper(this, dataReader, nip); + } + + public override Reflection.Extension.ExtensionList Extensions + { + get { return Map.DefaultSchema.Extensions; } + set { Map.DefaultSchema.Extensions = value; } + } + + #region Convert + + #region Primitive Types + + [CLSCompliant(false)] + public override SByte ConvertToSByte(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultSByteNullValue : (SByte)oraDecimal.Value; + } + + return base.ConvertToSByte(value); + } + + public override Int16 ConvertToInt16(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultInt16NullValue : oraDecimal.ToInt16(); + } + + return base.ConvertToInt16(value); + } + + public override Int32 ConvertToInt32(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultInt32NullValue : oraDecimal.ToInt32(); + } + + return base.ConvertToInt32(value); + } + + public override Int64 ConvertToInt64(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultInt64NullValue : oraDecimal.ToInt64(); + } + + return base.ConvertToInt64(value); + } + + public override Byte ConvertToByte(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultByteNullValue : oraDecimal.ToByte(); + } + + return base.ConvertToByte(value); + } + + [CLSCompliant(false)] + public override UInt16 ConvertToUInt16(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultUInt16NullValue : (UInt16)oraDecimal.Value; + } + + return base.ConvertToUInt16(value); + } + + [CLSCompliant(false)] + public override UInt32 ConvertToUInt32(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultUInt32NullValue : (UInt32)oraDecimal.Value; + } + + return base.ConvertToUInt32(value); + } + + [CLSCompliant(false)] + public override UInt64 ConvertToUInt64(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultUInt64NullValue : (UInt64)oraDecimal.Value; + } + + return base.ConvertToUInt64(value); + } + + public override Single ConvertToSingle(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultSingleNullValue : oraDecimal.ToSingle(); + } + + return base.ConvertToSingle(value); + } + + public override Double ConvertToDouble(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultDoubleNullValue : oraDecimal.ToDouble(); + } + + return base.ConvertToDouble(value); + } + + public override Boolean ConvertToBoolean(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultBooleanNullValue : (oraDecimal.Value != 0); + } + + return base.ConvertToBoolean(value); + } + + public override DateTime ConvertToDateTime(object value) + { + if (value is OracleDate) + { + var oraDate = (OracleDate)value; + return oraDate.IsNull ? DefaultDateTimeNullValue : oraDate.Value; + } + + return base.ConvertToDateTime(value); + } + + public override Decimal ConvertToDecimal(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? DefaultDecimalNullValue : oraDecimal.Value; + } + + return base.ConvertToDecimal(value); + } + + public override Guid ConvertToGuid(object value) + { + if (value is OracleString) + { + var oraString = (OracleString)value; + return oraString.IsNull ? DefaultGuidNullValue : new Guid(oraString.Value); + } + + if (value is OracleBlob) + { + using (var oraBlob = (OracleBlob) value) + return oraBlob.IsNull ? DefaultGuidNullValue : new Guid(oraBlob.Value); + } + + return base.ConvertToGuid(value); + } + + public override String ConvertToString(object value) + { + if (value is OracleString) + { + var oraString = (OracleString)value; + return oraString.IsNull ? DefaultStringNullValue : oraString.Value; + } +#if !MANAGED + if (value is OracleXmlType) + { + var oraXmlType = (OracleXmlType)value; + return oraXmlType.IsNull ? DefaultStringNullValue : oraXmlType.Value; + } +#endif + if (value is OracleClob) + { + using (var oraClob = (OracleClob) value) + return oraClob.IsNull ? DefaultStringNullValue : oraClob.Value; + } + + return base.ConvertToString(value); + } + +#if !MANAGED + public override Stream ConvertToStream(object value) + { + if (value is OracleXmlType) + { + var oraXml = (OracleXmlType)value; + return oraXml.IsNull ? DefaultStreamNullValue : oraXml.GetStream(); + } + + return base.ConvertToStream(value); + } + + public override XmlReader ConvertToXmlReader(object value) + { + if (value is OracleXmlType) + { + var oraXml = (OracleXmlType)value; + return oraXml.IsNull ? DefaultXmlReaderNullValue : oraXml.GetXmlReader(); + } + + return base.ConvertToXmlReader(value); + } + + public override XmlDocument ConvertToXmlDocument(object value) + { + if (value is OracleXmlType) + { + var oraXml = (OracleXmlType)value; + return oraXml.IsNull ? DefaultXmlDocumentNullValue : oraXml.GetXmlDocument(); + } + + return base.ConvertToXmlDocument(value); + } +#endif + + public override Byte[] ConvertToByteArray(object value) + { + if (value is OracleBlob) + { + using (var oraBlob = (OracleBlob) value) + return oraBlob.IsNull ? null : oraBlob.Value; + } + + if (value is OracleBinary) + { + var oraBinary = (OracleBinary)value; + return oraBinary.IsNull ? null : oraBinary.Value; + } + + if (value is OracleBFile) + { + var oraBFile = (OracleBFile)value; + return oraBFile.IsNull ? null : oraBFile.Value; + } + + return base.ConvertToByteArray(value); + } + + public override Char[] ConvertToCharArray(object value) + { + if (value is OracleString) + { + var oraString = (OracleString)value; + return oraString.IsNull ? null : oraString.Value.ToCharArray(); + } + + if (value is OracleClob) + { + using (var oraClob = (OracleClob) value) + return oraClob.IsNull ? null : oraClob.Value.ToCharArray(); + } + + return base.ConvertToCharArray(value); + } + + #endregion + + #region Nullable Types + + [CLSCompliant(false)] + public override SByte? ConvertToNullableSByte(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (SByte?)oraDecimal.Value; + } + + return base.ConvertToNullableSByte(value); + } + + public override Int16? ConvertToNullableInt16(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Int16?)oraDecimal.ToInt16(); + } + + return base.ConvertToNullableInt16(value); + } + + public override Int32? ConvertToNullableInt32(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Int32?)oraDecimal.ToInt32(); + } + + return base.ConvertToNullableInt32(value); + } + + public override Int64? ConvertToNullableInt64(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Int64?)oraDecimal.ToInt64(); + } + + return base.ConvertToNullableInt64(value); + } + + public override Byte? ConvertToNullableByte(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Byte?)oraDecimal.ToByte(); + } + + return base.ConvertToNullableByte(value); + } + + [CLSCompliant(false)] + public override UInt16? ConvertToNullableUInt16(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (UInt16?)oraDecimal.Value; + } + + return base.ConvertToNullableUInt16(value); + } + + [CLSCompliant(false)] + public override UInt32? ConvertToNullableUInt32(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (UInt32?)oraDecimal.Value; + } + + return base.ConvertToNullableUInt32(value); + } + + [CLSCompliant(false)] + public override UInt64? ConvertToNullableUInt64(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (UInt64?)oraDecimal.Value; + } + + return base.ConvertToNullableUInt64(value); + } + + public override Single? ConvertToNullableSingle(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Single?)oraDecimal.ToSingle(); + } + + return base.ConvertToNullableSingle(value); + } + + public override Double? ConvertToNullableDouble(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Double?)oraDecimal.ToDouble(); + } + + return base.ConvertToNullableDouble(value); + } + + public override Boolean? ConvertToNullableBoolean(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Boolean?)(oraDecimal.Value != 0); + } + + return base.ConvertToNullableBoolean(value); + } + + public override DateTime? ConvertToNullableDateTime(object value) + { + if (value is OracleDate) + { + var oraDate = (OracleDate)value; + return oraDate.IsNull ? null : (DateTime?)oraDate.Value; + } + + return base.ConvertToNullableDateTime(value); + } + + public override Decimal? ConvertToNullableDecimal(object value) + { + if (value is OracleDecimal) + { + var oraDecimal = (OracleDecimal)value; + return oraDecimal.IsNull ? null : (Decimal?)oraDecimal.Value; + } + + return base.ConvertToNullableDecimal(value); + } + + public override Guid? ConvertToNullableGuid(object value) + { + if (value is OracleString) + { + var oraString = (OracleString)value; + return oraString.IsNull ? null : (Guid?)new Guid(oraString.Value); + } + + if (value is OracleBlob) + { + var oraBlob = (OracleBlob)value; + return oraBlob.IsNull ? null : (Guid?)new Guid(oraBlob.Value); + } + + return base.ConvertToNullableGuid(value); + } + + #endregion + + #endregion + + public override object MapValueToEnum(object value, Type type) + { + if (value is OracleString) + { + var oracleValue = (OracleString)value; + value = oracleValue.IsNull ? null : oracleValue.Value; + } + else if (value is OracleDecimal) + { + var oracleValue = (OracleDecimal)value; + if (oracleValue.IsNull) + value = null; + else + value = oracleValue.Value; + } + + return base.MapValueToEnum(value, type); + } + + public override object ConvertChangeType(object value, Type conversionType) + { + // Handle OracleDecimal with IsNull == true case + // + return base.ConvertChangeType(IsNull(value) ? null : value, conversionType); + } + + public override bool IsNull(object value) + { + // ODP 10 does not expose this interface to public. + // + // return value is INullable && ((INullable)value).IsNull; + + return + value is OracleDecimal ? ((OracleDecimal)value).IsNull : + value is OracleString ? ((OracleString)value).IsNull : + value is OracleDate ? ((OracleDate)value).IsNull : + value is OracleTimeStamp ? ((OracleTimeStamp)value).IsNull : + value is OracleTimeStampTZ ? ((OracleTimeStampTZ)value).IsNull : + value is OracleTimeStampLTZ ? ((OracleTimeStampLTZ)value).IsNull : +#if !MANAGED + value is OracleXmlType ? ((OracleXmlType)value).IsNull : +#endif + value is OracleBlob ? ((OracleBlob)value).IsNull : + value is OracleClob ? ((OracleClob)value).IsNull : + value is OracleBFile ? ((OracleBFile)value).IsNull : + value is OracleBinary ? ((OracleBinary)value).IsNull : + value is OracleIntervalDS ? ((OracleIntervalDS)value).IsNull : + value is OracleIntervalYM ? ((OracleIntervalYM)value).IsNull : + base.IsNull(value); + } + } + + // TODO: implement via IDataReaderEx / DataReaderEx + // + public class OracleDataReaderMapper : DataReaderMapper + { + public OracleDataReaderMapper(MappingSchema mappingSchema, IDataReader dataReader) + : base(mappingSchema, dataReader) + { + _dataReader = dataReader is OracleDataReaderEx ? + ((OracleDataReaderEx)dataReader).DataReader : + (OracleDataReader)dataReader; + } + + private readonly OracleDataReader _dataReader; + + public override Type GetFieldType(int index) + { + var fieldType = _dataReader.GetProviderSpecificFieldType(index); + + if (fieldType != typeof(OracleBlob) +#if !MANAGED + && fieldType != typeof(OracleXmlType) +#endif + ) + fieldType = _dataReader.GetFieldType(index); + + return fieldType; + } + + public override object GetValue(object o, int index) + { + var fieldType = _dataReader.GetProviderSpecificFieldType(index); + +#if !MANAGED + if (fieldType == typeof(OracleXmlType)) + { + var xml = _dataReader.GetOracleXmlType(index); + return MappingSchema.ConvertToXmlDocument(xml); + } +#endif + if (fieldType == typeof(OracleBlob)) + { + var blob = _dataReader.GetOracleBlob(index); + return MappingSchema.ConvertToStream(blob); + } + + return _dataReader.IsDBNull(index) ? null : + _dataReader.GetValue(index); + } + + public override Boolean GetBoolean(object o, int index) { return MappingSchema.ConvertToBoolean(GetValue(o, index)); } + public override Char GetChar(object o, int index) { return MappingSchema.ConvertToChar(GetValue(o, index)); } + public override Guid GetGuid(object o, int index) { return MappingSchema.ConvertToGuid(GetValue(o, index)); } + + [CLSCompliant(false)] + public override SByte GetSByte(object o, int index) { return (SByte)_dataReader.GetDecimal(index); } + [CLSCompliant(false)] + public override UInt16 GetUInt16(object o, int index) { return (UInt16)_dataReader.GetDecimal(index); } + [CLSCompliant(false)] + public override UInt32 GetUInt32(object o, int index) { return (UInt32)_dataReader.GetDecimal(index); } + [CLSCompliant(false)] + public override UInt64 GetUInt64(object o, int index) { return (UInt64)_dataReader.GetDecimal(index); } + + public override Decimal GetDecimal(object o, int index) { return OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(index), 28).Value; } + + public override Boolean? GetNullableBoolean(object o, int index) { return MappingSchema.ConvertToNullableBoolean(GetValue(o, index)); } + public override Char? GetNullableChar(object o, int index) { return MappingSchema.ConvertToNullableChar(GetValue(o, index)); } + public override Guid? GetNullableGuid(object o, int index) { return MappingSchema.ConvertToNullableGuid(GetValue(o, index)); } + + [CLSCompliant(false)] + public override SByte? GetNullableSByte(object o, int index) { return _dataReader.IsDBNull(index) ? null : (SByte?)_dataReader.GetDecimal(index); } + [CLSCompliant(false)] + public override UInt16? GetNullableUInt16(object o, int index) { return _dataReader.IsDBNull(index) ? null : (UInt16?)_dataReader.GetDecimal(index); } + [CLSCompliant(false)] + public override UInt32? GetNullableUInt32(object o, int index) { return _dataReader.IsDBNull(index) ? null : (UInt32?)_dataReader.GetDecimal(index); } + [CLSCompliant(false)] + public override UInt64? GetNullableUInt64(object o, int index) { return _dataReader.IsDBNull(index) ? null : (UInt64?)_dataReader.GetDecimal(index); } + + public override Decimal? GetNullableDecimal(object o, int index) { return _dataReader.IsDBNull(index) ? (decimal?)null : OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(index), 28).Value; } + } + + public class OracleScalarDataReaderMapper : ScalarDataReaderMapper + { + private readonly OracleDataReader _dataReader; + + public OracleScalarDataReaderMapper( + MappingSchema mappingSchema, + IDataReader dataReader, + NameOrIndexParameter nameOrIndex) + : base(mappingSchema, dataReader, nameOrIndex) + { + _dataReader = dataReader is OracleDataReaderEx ? + ((OracleDataReaderEx)dataReader).DataReader : + (OracleDataReader)dataReader; + + _fieldType = _dataReader.GetProviderSpecificFieldType(Index); + + if (_fieldType != typeof(OracleBlob) +#if !MANAGED + && _fieldType != typeof(OracleXmlType) +#endif + ) + _fieldType = _dataReader.GetFieldType(Index); + } + + private readonly Type _fieldType; + + public override Type GetFieldType(int index) + { + return _fieldType; + } + + public override object GetValue(object o, int index) + { +#if !MANAGED + if (_fieldType == typeof(OracleXmlType)) + { + var xml = _dataReader.GetOracleXmlType(Index); + return MappingSchema.ConvertToXmlDocument(xml); + } +#endif + if (_fieldType == typeof(OracleBlob)) + { + var blob = _dataReader.GetOracleBlob(Index); + return MappingSchema.ConvertToStream(blob); + } + + return _dataReader.IsDBNull(index) ? null : + _dataReader.GetValue(Index); + } + + public override Boolean GetBoolean(object o, int index) { return MappingSchema.ConvertToBoolean(GetValue(o, Index)); } + public override Char GetChar(object o, int index) { return MappingSchema.ConvertToChar(GetValue(o, Index)); } + public override Guid GetGuid(object o, int index) { return MappingSchema.ConvertToGuid(GetValue(o, Index)); } + + [CLSCompliant(false)] + public override SByte GetSByte(object o, int index) { return (SByte)_dataReader.GetDecimal(Index); } + [CLSCompliant(false)] + public override UInt16 GetUInt16(object o, int index) { return (UInt16)_dataReader.GetDecimal(Index); } + [CLSCompliant(false)] + public override UInt32 GetUInt32(object o, int index) { return (UInt32)_dataReader.GetDecimal(Index); } + [CLSCompliant(false)] + public override UInt64 GetUInt64(object o, int index) { return (UInt64)_dataReader.GetDecimal(Index); } + + public override Decimal GetDecimal(object o, int index) { return OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(Index), 28).Value; } + + public override Boolean? GetNullableBoolean(object o, int index) { return MappingSchema.ConvertToNullableBoolean(GetValue(o, Index)); } + public override Char? GetNullableChar(object o, int index) { return MappingSchema.ConvertToNullableChar(GetValue(o, Index)); } + public override Guid? GetNullableGuid(object o, int index) { return MappingSchema.ConvertToNullableGuid(GetValue(o, Index)); } + + [CLSCompliant(false)] + public override SByte? GetNullableSByte(object o, int index) { return _dataReader.IsDBNull(index) ? null : (SByte?)_dataReader.GetDecimal(Index); } + [CLSCompliant(false)] + public override UInt16? GetNullableUInt16(object o, int index) { return _dataReader.IsDBNull(index) ? null : (UInt16?)_dataReader.GetDecimal(Index); } + [CLSCompliant(false)] + public override UInt32? GetNullableUInt32(object o, int index) { return _dataReader.IsDBNull(index) ? null : (UInt32?)_dataReader.GetDecimal(Index); } + [CLSCompliant(false)] + public override UInt64? GetNullableUInt64(object o, int index) { return _dataReader.IsDBNull(index) ? null : (UInt64?)_dataReader.GetDecimal(Index); } + + public override Decimal? GetNullableDecimal(object o, int index) { return _dataReader.IsDBNull(index) ? (decimal?)null : OracleDecimal.SetPrecision(_dataReader.GetOracleDecimal(Index), 28).Value; } + } + + [Mixin(typeof(IDbDataParameter), "_oracleParameter")] + [Mixin(typeof(IDataParameter), "_oracleParameter")] + [Mixin(typeof(IDisposable), "_oracleParameter")] + [Mixin(typeof(ICloneable), "_oracleParameter")] + [CLSCompliant(false)] + public abstract class OracleParameterWrap + { + protected OracleParameter _oracleParameter; + public OracleParameter OracleParameter + { + get { return _oracleParameter; } + } + + public static IDbDataParameter CreateInstance(OracleParameter oraParameter) + { + var wrap = TypeAccessor.CreateInstanceEx(); + + wrap._oracleParameter = oraParameter; + + return (IDbDataParameter)wrap; + } + + public override string ToString() + { + return _oracleParameter.ToString(); + } + + /// + ///Gets or sets the value of the parameter. + /// + /// + ///An that is the value of the parameter. + ///The default value is null. + /// + protected object Value + { +#if CONVERTORACLETYPES + [MixinOverride] + get + { + object value = _oracleParameter.Value; + if (value is OracleBinary) { - var par = db.Parameter("p" + ++pn, value); - parameters.Add(par); - sb.Append(":" + par.ParameterName); - } - else - sp.BuildValue(sb, value); - - sb.Append(", "); - } - - sb.Length -= 2; - sb.AppendLine(")"); - - n++; - - if (n >= maxBatchSize) - { - sb.AppendLine("SELECT * FROM dual"); - - var sql = sb.ToString(); - - if (DbManager.TraceSwitch.TraceInfo) - DbManager.WriteTraceLine("\n" + sql.Replace("\r", ""), DbManager.TraceSwitch.DisplayName); - - cnt += db - .SetCommand(sql, parameters.Count > 0 ? parameters.ToArray() : null) - .ExecuteNonQuery(); - - parameters.Clear(); - pn = 0; - n = 0; - sb.Length = 0; - } - } - - if (n > 0) - { - sb.AppendLine("SELECT * FROM dual"); - - var sql = sb.ToString(); - - if (DbManager.TraceSwitch.TraceInfo) - DbManager.WriteTraceLine("\n" + sql.Replace("\r", ""), DbManager.TraceSwitch.DisplayName); - - cnt += db - .SetCommand(sql, parameters.Count > 0 ? parameters.ToArray() : null) - .ExecuteNonQuery(); - } - - return cnt; - } - - #endregion - } -} + OracleBinary oracleValue = (OracleBinary)value; + return oracleValue.IsNull? null: oracleValue.Value; + } + if (value is OracleDate) + { + OracleDate oracleValue = (OracleDate)value; + if (oracleValue.IsNull) + return null; + return oracleValue.Value; + } + if (value is OracleDecimal) + { + OracleDecimal oracleValue = (OracleDecimal)value; + if (oracleValue.IsNull) + return null; + return oracleValue.Value; + } + if (value is OracleIntervalDS) + { + OracleIntervalDS oracleValue = (OracleIntervalDS)value; + if (oracleValue.IsNull) + return null; + return oracleValue.Value; + } + if (value is OracleIntervalYM) + { + OracleIntervalYM oracleValue = (OracleIntervalYM)value; + if (oracleValue.IsNull) + return null; + return oracleValue.Value; + } + if (value is OracleString) + { + OracleString oracleValue = (OracleString)value; + return oracleValue.IsNull? null: oracleValue.Value; + } + if (value is OracleTimeStamp) + { + OracleTimeStamp oracleValue = (OracleTimeStamp)value; + if (oracleValue.IsNull) + return null; + return oracleValue.Value; + } + if (value is OracleTimeStampLTZ) + { + OracleTimeStampLTZ oracleValue = (OracleTimeStampLTZ)value; + if (oracleValue.IsNull) + return null; + return oracleValue.Value; + } + if (value is OracleTimeStampTZ) + { + OracleTimeStampTZ oracleValue = (OracleTimeStampTZ)value; + if (oracleValue.IsNull) + return null; + return oracleValue.Value; + } + if (value is OracleXmlType) + { + OracleXmlType oracleValue = (OracleXmlType)value; + return oracleValue.IsNull? null: oracleValue.Value; + } + + return value; + } +#endif + [MixinOverride] + set + { + if (null != value) + { + if (value is Array && !(value is byte[] || value is char[])) + { + _oracleParameter.CollectionType = OracleCollectionType.PLSQLAssociativeArray; + } + } + + _oracleParameter.Value = value; + } + } + } + + #endregion + + #region InsertBatch + + public override int InsertBatch( + DbManager db, + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + DbManager.ParameterProvider getParameters) + { + if (db.UseQueryText) + { + // Called if UseQuery false or out of a transaction scope + _interpreterBase.SetCollectionIds(db, members, collection); + + var parameters = new List(); + List sqlList = _interpreterBase.GetInsertBatchSqlList(insertText, collection, members, maxBatchSize, false, db, parameters); + return ExecuteSqlList(db, sqlList, parameters); + } + +#if !MANAGED + return OracleInsertBulk(db, insertText, collection, members, 1000); +#else + throw new NotImplementedException("OracleInsertBulk not supported on OdpManagedDataProvider!"); +#endif + } + + public override int InsertBatchWithIdentity( + DbManager db, + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize, + DbManager.ParameterProvider getParameters) + { + /* + * OracleBulkCopy doesn't support transaction for all the records, it only support transaction for batches if UseInternalTransaction is specified. + * If BatchSize > 0 and the UseInternalTransaction bulk copy option is specified, each batch of the bulk copy operation occurs within a transaction. + * If the connection used to perform the bulk copy operation is already part of a transaction, an InvalidOperationException exception is raised. + * If BatchSize > 0 and the UseInternalTransaction option is not specified, rows are sent to the database in batches of size BatchSize, but no transaction-related action is taken. + */ + + if (db.UseQueryText || db.Transaction != null) + { + var parameters = new List(); + List sqlList = _interpreterBase.GetInsertBatchSqlList(insertText, collection, members, 100, true, db, parameters); + return ExecuteSqlList(db, sqlList, parameters); + } + +#if !MANAGED + // Called if UseQuery false or out of a transaction scope + _interpreterBase.SetCollectionIds(db, members, collection); + + return OracleInsertBulk(db, insertText, collection, members, 1000); +#else + throw new NotImplementedException("OracleInsertBulk not supported on OdpManagedDataProvider!"); +#endif + } + +#if !MANAGED + + private int OracleInsertBulk( + DbManager db, + string insertText, + IEnumerable collection, + MemberMapper[] members, + int maxBatchSize) + { + + var idx = insertText.IndexOf('\n'); + var tbl = insertText.Substring(0, idx).Substring("INSERT INTO ".Length).TrimEnd('\r'); + var rd = new BulkCopyReader(members, collection); + var bc = new OracleBulkCopy((OracleConnection)db.Connection) + { + BatchSize = maxBatchSize, + DestinationTableName = tbl, + }; + + foreach (var memberMapper in members) + bc.ColumnMappings.Add(new OracleBulkCopyColumnMapping(memberMapper.Ordinal, memberMapper.Name)); + + bc.WriteToServer(rd); + + return rd.Count; + } +#endif + + #endregion + + class BulkCopyReader : IDataReader + { + readonly MemberMapper[] _members; + readonly IEnumerable _collection; + readonly IEnumerator _enumerator; + + public int Count; + + public BulkCopyReader(MemberMapper[] members, IEnumerable collection) + { + _members = members; + _collection = collection; + _enumerator = _collection.GetEnumerator(); + } + + #region Implementation of IDisposable + + public void Dispose() + { + } + + #endregion + + #region Implementation of IDataRecord + + public string GetName(int i) + { + return _members[i].Name; + } + + public Type GetFieldType(int i) + { + if (_members[i].Type.IsGenericType && _members[i].Type.GetGenericTypeDefinition() == typeof(Nullable<>)) + return Nullable.GetUnderlyingType(_members[i].Type); + else + return _members[i].Type; + } + + public object GetValue(int i) + { + var value = _members[i].GetValue(_enumerator.Current); + + return value ?? DBNull.Value; + } + + public int FieldCount + { + get { return _members.Length; } + } + + public long GetBytes(int i, long fieldOffset, byte[] buffer, int bufferoffset, int length) + { + throw new NotImplementedException(); + } + + public long GetChars(int i, long fieldoffset, char[] buffer, int bufferoffset, int length) + { + throw new NotImplementedException(); + } + + public string GetDataTypeName(int i) { throw new NotImplementedException(); } + public int GetValues(object[] values) { throw new NotImplementedException(); } + public int GetOrdinal(string name) { throw new NotImplementedException(); } + public bool GetBoolean(int i) { throw new NotImplementedException(); } + public byte GetByte(int i) { throw new NotImplementedException(); } + public char GetChar(int i) { throw new NotImplementedException(); } + public Guid GetGuid(int i) { throw new NotImplementedException(); } + public short GetInt16(int i) { throw new NotImplementedException(); } + public int GetInt32(int i) { throw new NotImplementedException(); } + public long GetInt64(int i) { throw new NotImplementedException(); } + public float GetFloat(int i) { throw new NotImplementedException(); } + public double GetDouble(int i) { throw new NotImplementedException(); } + public string GetString(int i) { throw new NotImplementedException(); } + public decimal GetDecimal(int i) { throw new NotImplementedException(); } + public DateTime GetDateTime(int i) { throw new NotImplementedException(); } + public IDataReader GetData(int i) { throw new NotImplementedException(); } + public bool IsDBNull(int i) { throw new NotImplementedException(); } + + object IDataRecord.this[int i] + { + get { throw new NotImplementedException(); } + } + + object IDataRecord.this[string name] + { + get { throw new NotImplementedException(); } + } + + #endregion + + #region Implementation of IDataReader + + public void Close() + { + throw new NotImplementedException(); + } + + public DataTable GetSchemaTable() + { + throw new NotImplementedException(); + } + + public bool NextResult() + { + throw new NotImplementedException(); + } + + public bool Read() + { + var b = _enumerator.MoveNext(); + + if (b) + Count++; + + return b; + } + + public int Depth + { + get { throw new NotImplementedException(); } + } + + public bool IsClosed + { + get { throw new NotImplementedException(); } + } + + public int RecordsAffected + { + get { throw new NotImplementedException(); } + } + + #endregion + } + } + +} diff --git a/Source/Data/DataProvider/OracleHelper.cs b/Source/Data/DataProvider/OracleHelper.cs deleted file mode 100644 index 2c5c202c4..000000000 --- a/Source/Data/DataProvider/OracleHelper.cs +++ /dev/null @@ -1,250 +0,0 @@ -using System; -using System.Data; -using System.Diagnostics; -using System.Globalization; -using System.Text.RegularExpressions; - -namespace BLToolkit.Data.DataProvider -{ - public static class OracleHelper - { - #region Text - - /// - /// If value is null or empty, return NULL or the value converted for Oracle SQL query - /// - /// Text - /// Text converted for oracle query - public static string SqlConvertString(string value) - { - if (!string.IsNullOrEmpty(value)) - { - value = value.Replace("'", "''"); - value = value.Replace("&", "' || '&' || '"); - - return "'" + value + "'"; - } - - return string.IsNullOrWhiteSpace(value) ? "NULL" : value; - } - - #endregion - - #region Date & Time - - /// - /// Convert DateTime to TO_DATE('value','YYYYMMDD') - /// - /// Date - /// Date converted for oracle query - public static string SqlConvertDate(DateTime value) - { - return string.Format("TO_DATE('{0}','YYYYMMDD')", value.ToString("yyyyMMdd")); - } - - /// - /// Convert DateTime to TO_DATE('value','YYYYMMDDHH24MISS') - /// - /// DateTime - /// DateTime converted for oracle query - public static string SqlConvertDateTime(DateTime value) - { - return string.Format("TO_DATE('{0}','YYYYMMDDHH24MISS')", value.ToString("yyyyMMddHHmmss")); - } - - /// - /// Convert DateTime to TO_TIMESTAMP('value','YYYYMMDDHH24MISSFF3') - /// - /// DateTime - /// DateTime converted for oracle query - public static string SqlConvertTimeStamp(DateTime value) - { - return string.Format("TO_TIMESTAMP('{0}','YYYYMMDDHH24MISSFF3')", value.ToString("yyyyMMddHHmmssfff")); - } - - /// - /// Convert DateTime to TO_CHAR(TO_DATE('value','YYYYMMDD'))) - /// - /// DateTime - /// DateTime converted for oracle query - public static string SqlConvertDateToChar(DateTime value) - { - return string.Format("TO_CHAR(TO_DATE('{0}','YYYYMMDD'))", value.ToString("yyyyMMdd")); - } - - #endregion - - #region Connection string - - /// - /// Generate the minimum connection string. The connection string looks like - /// Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = server)(PORT = port)))(CONNECT_DATA = (SID = sid)));User Id=username;Password=password; - /// - /// Username - /// Password - /// Server name - /// Database SID - /// Port of the server. Default value is 1521 - /// Default connection string - public static string GetFullConnectionString(string userName, string password, string server, string sid, int port = 1521) - { - return - string.Format( - "Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = {0})(PORT = {1})))(CONNECT_DATA = (SID = {2})));User Id={3};Password={4};", - server, port, sid, userName, password); - } - - /// - /// Generate the minimum connection string. The connection string looks like - /// Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = server)(PORT = port)))(CONNECT_DATA = (SID = sid)));User Id=username;Password=password;Pooling=False; - /// - /// Username - /// Password - /// Server name - /// Database SID - /// Port of the server. Default value is 1521 - /// Default connection string - public static string GetFullConnectionStringWithoutPooling(string userName, string password, string server, string sid, int port = 1521) - { - return - string.Format( - "Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = {0})(PORT = {1})))(CONNECT_DATA = (SID = {2})));User Id={3};Password={4};Pooling=False;", - server, port, sid, userName, password); - } - - /// - /// Generate the minimum connection string. The connection string looks like - /// Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = server)(PORT = port)))(CONNECT_DATA = (SID = sid)));User Id=username;Password=password;Connection Timeout=timeout; - /// - /// Username - /// Password - /// Server name - /// Database SID - /// Port of the server. Default value is 1521 - /// Default connection string - public static string GetFullConnectionString(string userName, string password, string server, string sid, - TimeSpan timeOut, int port = 1521) - { - return - string.Format( - "Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = {0})(PORT = {1})))(CONNECT_DATA = (SID = {2})));User Id={3};Password={4};Connection Timeout={5};", - server, port, sid, userName, password, (int)timeOut.TotalSeconds); - } - - /// - /// Generate the minimum connection string. The connection string looks like - /// Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = server)(PORT = port)))(CONNECT_DATA = (SID = sid)));User Id=username;Password=password;Connection Timeout=timeout;Pooling=False; - /// - /// Username - /// Password - /// Server name - /// Database SID - /// Port of the server. Default value is 1521 - /// Default connection string - public static string GetFullConnectionStringWithoutPooling(string userName, string password, string server, string sid, - TimeSpan timeOut, int port = 1521) - { - return - string.Format( - "Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = {0})(PORT = {1})))(CONNECT_DATA = (SID = {2})));User Id={3};Password={4};Connection Timeout={5};Pooling=False;", - server, port, sid, userName, password, (int)timeOut.TotalSeconds); - } - - /// - /// Generate the minimum connection string. The connection string looks like - /// Data Source=(DESCRIPTION = (ADDRESS_LIST = (ADDRESS = (PROTOCOL = TCP)(HOST = server)(PORT = port)))(CONNECT_DATA = (SID = sid)));User Id=username;Password=password;Connection Timeout=timeout; - /// - /// Username - /// Password - /// Server name - /// Database SID - /// Port of the server. Default value is 1521 - /// Default connection string - public static string GetFullConnectionString(string userName, string password, string server, string sid, int timeOutInSecond, int port = 1521) - { - return GetFullConnectionString(userName, password, server, sid, TimeSpan.FromSeconds(timeOutInSecond), port); - } - - #endregion - - public static string Interpret(IDbCommand poCommand) - { - if (poCommand.Parameters.Count == 0) - return poCommand.CommandText; - - var oRegex = new Regex(@"(?'[^']+')|(?:[a-zA-Z0-9_]+)"); - MatchCollection oMatchCollection = oRegex.Matches(poCommand.CommandText); - - string strQuery = poCommand.CommandText + " "; - int matchCount = 0; - - for (int i = 0; i < oMatchCollection.Count; i++) - { - if (oMatchCollection[i].Groups["string"].Success) - continue; - - string strParameter = oMatchCollection[i].Groups["Parameters"].Captures[0].Value; - - var param = (IDbDataParameter)poCommand.Parameters[matchCount]; - if (param.Value is DateTime) - { - var dt = (DateTime)param.Value; - - strQuery = strQuery.Replace(strParameter + " ", - dt.Date == dt - ? SqlConvertDate(dt) + " " - : SqlConvertDateTime(dt) + " "); - } - else if (param.Value is string) - strQuery = strQuery.Replace(strParameter, SqlConvertString(param.Value.ToString()) + " "); - else if (param.Value is Int16) - strQuery = strQuery.Replace(strParameter, ((Int16)param.Value).ToString(CultureInfo.InvariantCulture) + " "); - else if (param.Value is Int32) - strQuery = strQuery.Replace(strParameter, ((Int32)param.Value).ToString(CultureInfo.InvariantCulture) + " "); - else if (param.Value is Int64) - strQuery = strQuery.Replace(strParameter, ((Int64)param.Value).ToString(CultureInfo.InvariantCulture) + " "); - else if (param.Value is decimal) - strQuery = strQuery.Replace(strParameter, ((decimal)param.Value).ToString(CultureInfo.InvariantCulture) + " "); - else if (param.Value is float) - strQuery = strQuery.Replace(strParameter, ((float)param.Value).ToString(CultureInfo.InvariantCulture) + " "); - else if (param.Value is double) - strQuery = strQuery.Replace(strParameter, ((double)param.Value).ToString(CultureInfo.InvariantCulture) + " "); - else if (param.Value is TimeSpan) - strQuery = strQuery.Replace(strParameter, "'" + ((TimeSpan)param.Value).ToString() + "' "); - else - throw new NotImplementedException(param.Value.GetType() + " is not implemented yet."); - - matchCount++; - } - - if (matchCount != poCommand.Parameters.Count) - { - // ReSharper disable InvocationIsSkipped - Debug.WriteLine( - "Number of parameters in query is not equals to number of parameters set in the command object " + - poCommand.CommandText); - // ReSharper restore InvocationIsSkipped - var msg = - "Number of parameters in query is not equals to number of parameters set in the command object : " + poCommand.CommandText + "\r\n" + - "Query params :\r\n"; - - foreach (Match match in oMatchCollection) - { - msg += "\t" + match.Value + "\r\n"; - } - - msg += "\nCommand params :\r\n"; - - foreach (IDataParameter param in poCommand.Parameters) - { - msg += "\t" + param.ParameterName + " = " + Convert.ToString(param) + "\r\n"; - } - - throw new Exception(msg); - } - - return strQuery; - } - - } -} \ No newline at end of file diff --git a/Source/Data/DataProvider/ProviderName.cs b/Source/Data/DataProvider/ProviderName.cs index 24349c33b..6bcf1b131 100644 --- a/Source/Data/DataProvider/ProviderName.cs +++ b/Source/Data/DataProvider/ProviderName.cs @@ -21,7 +21,7 @@ public static class ProviderName public const string SQLite = "SQLite"; public const string Sybase = "Sybase"; } - + public static class ProviderFullName { public const string DB2 = "IBM.Data.DB2"; @@ -36,6 +36,6 @@ public static class ProviderFullName public const string PostgreSQL = "Npgsql"; public const string SqlCe = "System.Data.SqlServerCe"; public const string SQLite = "System.Data.SQLite"; - public const string Sybase = "Sybase.Data.AseClient"; + public const string Sybase = "Sybase.Data.AseClient"; } } diff --git a/Source/Data/DataProvider/SqlDataProviderBase.cs b/Source/Data/DataProvider/SqlDataProviderBase.cs index 9384602df..61b286713 100644 --- a/Source/Data/DataProvider/SqlDataProviderBase.cs +++ b/Source/Data/DataProvider/SqlDataProviderBase.cs @@ -254,7 +254,7 @@ public override int InsertBatch( var idx = insertText.IndexOf('\n'); var tbl = insertText.Substring(0, idx).Substring("INSERT INTO ".Length).TrimEnd('\r'); var rd = new BulkCopyReader(members, collection); - var bc = new SqlBulkCopy((SqlConnection)db.Connection) + var bc = new SqlBulkCopy((SqlConnection)db.Connection, SqlBulkCopyOptions.Default, (SqlTransaction)db.Transaction) { BatchSize = maxBatchSize, DestinationTableName = tbl, diff --git a/Source/Data/DbConnectionFactory.cs b/Source/Data/DbConnectionFactory.cs index 018df8874..f036acb1a 100644 --- a/Source/Data/DbConnectionFactory.cs +++ b/Source/Data/DbConnectionFactory.cs @@ -1,4 +1,7 @@ -using BLToolkit.Data.DataProvider; +using System.Collections.Generic; +using BLToolkit.Common; +using BLToolkit.Data.DataProvider; +using BLToolkit.Data.Sql; namespace BLToolkit.Data { @@ -16,9 +19,70 @@ public DbManager CreateDbManager() public virtual DbManager CreateDbManager(DataProviderBase provider, string connectionString) { - return new DbManager(provider, connectionString); + return new MyDbManager(provider, connectionString); } #endregion } + + public class MyDbManager : DbManager + { + public MyDbManager(DataProviderBase provider, string connectionString) : base(provider, connectionString) + { + } + + public override BLToolkit.Data.Sql.SqlQuery ProcessQuery(BLToolkit.Data.Sql.SqlQuery sqlQuery) + { + return base.ProcessQuery(sqlQuery); + + if (sqlQuery.IsInsert && sqlQuery.Insert.Into.Name == "Parent") + { + var expr = + new QueryVisitor().Find(sqlQuery.Insert, e => + { + if (e.ElementType == QueryElementType.SetExpression) + { + var se = (BLToolkit.Data.Sql.SqlQuery.SetExpression)e; + return ((SqlField)se.Column).Name == "ParentID"; + } + + return false; + }) as BLToolkit.Data.Sql.SqlQuery.SetExpression; + + if (expr != null) + { + var value = ConvertTo.From(((IValueContainer)expr.Expression).Value); + + if (value == 555) + { + var tableName = "Parent1"; + var dic = new Dictionary(); + + sqlQuery = new QueryVisitor().Convert(sqlQuery, e => + { + if (e.ElementType == QueryElementType.SqlTable) + { + var oldTable = (SqlTable)e; + + if (oldTable.Name == "Parent") + { + var newTable = new SqlTable(oldTable) { Name = tableName, PhysicalName = tableName }; + + foreach (var field in oldTable.Fields.Values) + dic.Add(field, newTable.Fields[field.Name]); + + return newTable; + } + } + + IQueryElement ex; + return dic.TryGetValue(e, out ex) ? ex : null; + }); + } + } + } + + return sqlQuery; + } + } } \ No newline at end of file diff --git a/Source/Data/DbManager.Config.cs b/Source/Data/DbManager.Config.cs index a0c5136ba..a4ead044b 100644 --- a/Source/Data/DbManager.Config.cs +++ b/Source/Data/DbManager.Config.cs @@ -6,6 +6,8 @@ using System.Data.SqlClient; using System.Diagnostics; using System.Linq; +using BLToolkit.Data.Linq; +using BLToolkit.DataAccess; namespace BLToolkit.Data { @@ -620,6 +622,30 @@ public static void AddDataProvider(DataProviderBase dataProvider) } } + public static void SetMappingTypeSequence(string sequenceName) + { + foreach (var providerBase in _dataProviderNameList.Values) + { + if (providerBase.MappingSchema != null) + { + providerBase.MappingSchema.SetMappingTypeSequence(typeof(T), sequenceName); + } + } + Query.ClearCache(); + SqlQueryBase.ClearCache(); + } + + public static void SetMappingTypeOwner(string ownerName) + { + foreach (var providerBase in _dataProviderNameList.Values) + { + if (providerBase.MappingSchema != null) + providerBase.MappingSchema.MetadataProvider.SetOwnerName(typeof(T), ownerName); + } + Query.ClearCache(); + SqlQueryBase.ClearCache(); + } + /// /// Adds a new data provider witch a specified name. /// diff --git a/Source/Data/DbManager.Linq.cs b/Source/Data/DbManager.Linq.cs index 896c75de3..aa490c793 100644 --- a/Source/Data/DbManager.Linq.cs +++ b/Source/Data/DbManager.Linq.cs @@ -80,11 +80,12 @@ PreparedQuery GetCommand(IQueryContext query) } var sqlProvider = DataProvider.CreateSqlProvider(); + sqlProvider.UseQueryText = UseQueryText; var cc = sqlProvider.CommandCount(sql); var sb = new StringBuilder(); - var commands = new string[cc]; + var commands = new string[cc]; for (var i = 0; i < cc; i++) { @@ -106,13 +107,16 @@ PreparedQuery GetCommand(IQueryContext query) }; } - protected virtual SqlQuery ProcessQuery(SqlQuery sqlQuery) + public virtual SqlQuery ProcessQuery(SqlQuery sqlQuery) { return sqlQuery; } void GetParameters(IQueryContext query, PreparedQuery pq) { + if (UseQueryText) + return; + var parameters = query.GetParameters(); if (parameters.Length == 0 && pq.SqlParameters.Count == 0) @@ -157,12 +161,15 @@ void AddParameter(ICollection parms, string name, SqlParameter if (value != null) { - if (parm.DbType == DbType.Object) - parms.Add(Parameter(name, value)); - else if (parm.DbSize == 0) - parms.Add(Parameter(name, value, parm.DbType)); - else - parms.Add(Parameter(name, value, parm.DbType, parm.DbSize)); + if (parm.DbType == DbType.Object) + { + parm.DbType = DataProvider.GetDbType(parm.SystemType); + parms.Add(Parameter(name, value)); + } + else if (parm.DbSize == 0) + parms.Add(Parameter(name, value, parm.DbType)); + else + parms.Add(Parameter(name, value, parm.DbType, parm.DbSize)); } else { @@ -252,9 +259,9 @@ IDataReader IDataContext.ExecuteReader(object query) { var pq = (PreparedQuery)query; - SetCommand(pq.Commands[0], pq.Parameters); + SetCommand(pq.Commands[0], pq.Parameters); - var now = default(DateTime); + var now = default(DateTime); if (TraceSwitch.TraceInfo) now = DateTime.Now; diff --git a/Source/Data/DbManager.cs b/Source/Data/DbManager.cs index c61429726..3a839762d 100644 --- a/Source/Data/DbManager.cs +++ b/Source/Data/DbManager.cs @@ -625,12 +625,15 @@ private IDataReader ExecuteReaderInternal(CommandBehavior commandBehavior) return ExecuteOperation( OperationType.ExecuteReader, () => - _dataProvider.GetDataReader(_mappingSchema, SelectCommand.ExecuteReader(commandBehavior))); + { + var dataReader = _dataProvider.GetDataReader(SelectCommand, commandBehavior); + return _dataProvider.GetDataReader(_mappingSchema, dataReader); + }); } private int ExecuteNonQueryInternal() { - return ExecuteOperation(OperationType.ExecuteNonQuery, SelectCommand.ExecuteNonQuery); + return ExecuteOperation(OperationType.ExecuteNonQuery, SelectCommand.ExecuteNonQuery); } #endregion @@ -2618,19 +2621,19 @@ internal int ExecuteForEach(IEnumerable collection, MemberMapper[] members IDbDataParameter p; if ((value == null || value == DBNull.Value) && (dbType == DbType.Binary || type == typeof(byte[])) || - type == typeof(System.Data.Linq.Binary)) + type == typeof(System.Data.Linq.Binary)) { p = Parameter(baseParameters[i].ParameterName + nRows, DBNull.Value, DbType.Binary); } else { if (value != null && value.GetType().IsEnum) - value = MappingSchema.MapEnumToValue(value, true); - + value = MappingSchema.MapEnumToValue(value, true); + p = value != null ? Parameter(baseParameters[i].ParameterName + nRows, value) : Parameter(baseParameters[i].ParameterName + nRows, DBNull.Value, members[i].GetDbType()); - } + } parameters.Add(p); hasValue.Add(value != null); @@ -4439,8 +4442,9 @@ private T ExecuteOperation(OperationType operationType, Func operation) } catch (Exception ex) { - if (res is IDisposable) - ((IDisposable)res).Dispose(); + var disposable = res as IDisposable; + if (disposable != null) + (disposable).Dispose(); HandleOperationException(operationType, ex); throw; diff --git a/Source/Data/Linq/Builder/ExpressionBuilder.SqlBuilder.cs b/Source/Data/Linq/Builder/ExpressionBuilder.SqlBuilder.cs index 303fb8e1d..87958ee3f 100644 --- a/Source/Data/Linq/Builder/ExpressionBuilder.SqlBuilder.cs +++ b/Source/Data/Linq/Builder/ExpressionBuilder.SqlBuilder.cs @@ -1,687 +1,687 @@ -using System; -using System.Collections; -using System.Collections.Generic; -using System.Linq; -using System.Linq.Expressions; -using System.Reflection; -using System.Text; - -namespace BLToolkit.Data.Linq.Builder -{ - using BLToolkit.Linq; - using Common; - using Data.Sql; - using Mapping; - using Reflection; - - partial class ExpressionBuilder - { - #region Build Where - - public IBuildContext BuildWhere(IBuildContext parent, IBuildContext sequence, LambdaExpression condition, bool checkForSubQuery) - { - var makeHaving = false; - var prevParent = sequence.Parent; - - var ctx = new ExpressionContext(parent, sequence, condition); - var expr = ConvertExpression(condition.Body.Unwrap()); - - if (checkForSubQuery && CheckSubQueryForWhere(ctx, expr, out makeHaving)) - { - ReplaceParent(ctx, prevParent); - - sequence = new SubQueryContext(sequence); - prevParent = sequence.Parent; - - ctx = new ExpressionContext(parent, sequence, condition); - } - - BuildSearchCondition( - ctx, - expr, - makeHaving ? - ctx.SqlQuery.Having.SearchCondition.Conditions : - ctx.SqlQuery.Where. SearchCondition.Conditions); - - ReplaceParent(ctx, prevParent); - - return sequence; - } - - bool CheckSubQueryForWhere(IBuildContext context, Expression expression, out bool makeHaving) - { - var makeSubQuery = false; - var isHaving = false; - var isWhere = false; - - expression.Visit(expr => - { - if (_subQueryExpressions != null && _subQueryExpressions.Contains(expr)) - { - makeSubQuery = true; - isWhere = true; - return false; - } - +using System; +using System.Collections; +using System.Collections.Generic; +using System.Linq; +using System.Linq.Expressions; +using System.Reflection; +using System.Text; + +namespace BLToolkit.Data.Linq.Builder +{ + using BLToolkit.Linq; + using Common; + using Data.Sql; + using Mapping; + using Reflection; + + partial class ExpressionBuilder + { + #region Build Where + + public IBuildContext BuildWhere(IBuildContext parent, IBuildContext sequence, LambdaExpression condition, bool checkForSubQuery) + { + var makeHaving = false; + var prevParent = sequence.Parent; + + var ctx = new ExpressionContext(parent, sequence, condition); + var expr = ConvertExpression(condition.Body.Unwrap()); + + if (checkForSubQuery && CheckSubQueryForWhere(ctx, expr, out makeHaving)) + { + ReplaceParent(ctx, prevParent); + + sequence = new SubQueryContext(sequence); + prevParent = sequence.Parent; + + ctx = new ExpressionContext(parent, sequence, condition); + } + + BuildSearchCondition( + ctx, + expr, + makeHaving ? + ctx.SqlQuery.Having.SearchCondition.Conditions : + ctx.SqlQuery.Where. SearchCondition.Conditions); + + ReplaceParent(ctx, prevParent); + + return sequence; + } + + bool CheckSubQueryForWhere(IBuildContext context, Expression expression, out bool makeHaving) + { + var makeSubQuery = false; + var isHaving = false; + var isWhere = false; + + expression.Visit(expr => + { + if (_subQueryExpressions != null && _subQueryExpressions.Contains(expr)) + { + makeSubQuery = true; + isWhere = true; + return false; + } + var stopWalking = false; - - switch (expr.NodeType) - { - case ExpressionType.MemberAccess: - { - var ma = (MemberExpression)expr; - + + switch (expr.NodeType) + { + case ExpressionType.MemberAccess: + { + var ma = (MemberExpression)expr; + if (TypeHelper.IsNullableValueMember(ma.Member) || TypeHelper.IsNullableHasValueMember(ma.Member)) - break; - - if (SqlProvider.ConvertMember(ma.Member) == null) - { - var ctx = GetContext(context, expr); - - if (ctx != null) - { - if (ctx.IsExpression(expr, 0, RequestFor.Expression).Result) - makeSubQuery = true; - stopWalking = true; - } - } - - isWhere = true; - - break; - } - - case ExpressionType.Call: - { - var e = (MethodCallExpression)expr; - - if (e.Method.DeclaringType == typeof(Enumerable) && e.Method.Name != "Contains") - return isHaving = true; - - isWhere = true; - - break; - } - - case ExpressionType.Parameter: - { - var ctx = GetContext(context, expr); - - if (ctx != null) - { - if (ctx.IsExpression(expr, 0, RequestFor.Expression).Result) - makeSubQuery = true; - stopWalking = true; - } - - isWhere = true; - - break; - } - } - - return !stopWalking; - }); - - makeHaving = isHaving && !isWhere; - return makeSubQuery || isHaving && isWhere; - } - - #endregion - - #region BuildTake - - public void BuildTake(IBuildContext context, ISqlExpression expr) - { - var sql = context.SqlQuery; - - sql.Select.Take(expr); - - SqlProvider.SqlQuery = sql; - - if (sql.Select.SkipValue != null && SqlProvider.IsTakeSupported && !SqlProvider.IsSkipSupported) - { - if (context.SqlQuery.Select.SkipValue is SqlParameter && sql.Select.TakeValue is SqlValue) - { - var skip = (SqlParameter)sql.Select.SkipValue; - var parm = (SqlParameter)sql.Select.SkipValue.Clone(new Dictionary(), _ => true); - - parm.SetTakeConverter((int)((SqlValue)sql.Select.TakeValue).Value); - - sql.Select.Take(parm); - - var ep = (from pm in CurrentSqlParameters where pm.SqlParameter == skip select pm).First(); - - ep = new ParameterAccessor - { - Expression = ep.Expression, - Accessor = ep.Accessor, - SqlParameter = parm - }; - - CurrentSqlParameters.Add(ep); - } - else - sql.Select.Take(Convert( - context, - new SqlBinaryExpression(typeof(int), sql.Select.SkipValue, "+", sql.Select.TakeValue, Precedence.Additive))); - } - - if (!SqlProvider.TakeAcceptsParameter) - { - var p = sql.Select.TakeValue as SqlParameter; - - if (p != null) - p.IsQueryParameter = false; - } - } - - #endregion - - #region SubQueryToSql - - public IBuildContext GetSubQuery(IBuildContext context, MethodCallExpression expr) - { - var info = new BuildInfo(context, expr, new SqlQuery { ParentSql = context.SqlQuery }); - var ctx = BuildSequence(info); - - if (ctx.SqlQuery.Select.Columns.Count == 0 && - (ctx.IsExpression(null, 0, RequestFor.Expression).Result || - ctx.IsExpression(null, 0, RequestFor.Field). Result)) - { - ctx.ConvertToIndex(null, 0, ConvertFlags.Field); - } - - return ctx; - } - - internal ISqlExpression SubQueryToSql(IBuildContext context, MethodCallExpression expression) - { - var sequence = GetSubQuery(context, expression); - var subSql = sequence.GetSubQuery(context); - - if (subSql != null) - return subSql; - - var query = context.SqlQuery; - var subQuery = sequence.SqlQuery; - - // This code should be moved to context. - // - if (!query.GroupBy.IsEmpty && !subQuery.Where.IsEmpty) - { - var fromGroupBy = sequence.SqlQuery.Properties - .OfType>() - .Where(p => p.Item1 == "from_group_by" && p.Item2 == context.SqlQuery) - .Any(); - - if (fromGroupBy) - { - if (subQuery.Select.Columns.Count == 1 && - subQuery.Select.Columns[0].Expression.ElementType == QueryElementType.SqlFunction && - subQuery.GroupBy.IsEmpty && !subQuery.Select.HasModifier && !subQuery.HasUnion && - subQuery.Where.SearchCondition.Conditions.Count == 1) - { - var cond = subQuery.Where.SearchCondition.Conditions[0]; - - if (cond.Predicate.ElementType == QueryElementType.ExprExprPredicate && query.GroupBy.Items.Count == 1 || - cond.Predicate.ElementType == QueryElementType.SearchCondition && - query.GroupBy.Items.Count == ((SqlQuery.SearchCondition)cond.Predicate).Conditions.Count) - { - var func = (SqlFunction)subQuery.Select.Columns[0].Expression; - - if (CountBuilder.MethodNames.Contains(func.Name)) - return SqlFunction.CreateCount(func.SystemType, query); - } - } - } - } - - return sequence.SqlQuery; - } - - #endregion - - #region IsSubQuery - - bool IsSubQuery(IBuildContext context, MethodCallExpression call) - { - if (call.IsQueryable()) - { - var info = new BuildInfo(context, call, new SqlQuery { ParentSql = context.SqlQuery }); - - if (!IsSequence(info)) - return false; - - var arg = call.Arguments[0]; - - if (AggregationBuilder.MethodNames.Contains(call.Method.Name)) - while (arg.NodeType == ExpressionType.Call && ((MethodCallExpression) arg).Method.Name == "Select") - arg = ((MethodCallExpression)arg).Arguments[0]; - - var mc = arg as MethodCallExpression; - - while (mc != null) - { - if (!mc.IsQueryable()) - return GetTableFunctionAttribute(mc.Method) != null; - - mc = mc.Arguments[0] as MethodCallExpression; - } - - return arg.NodeType == ExpressionType.Call || IsSubQuerySource(context, arg); - } - - return false; - } - - bool IsSubQuerySource(IBuildContext context, Expression expr) - { - if (expr == null) - return false; - - var ctx = GetContext(context, expr); - - if (ctx != null && ctx.IsExpression(expr, 0, RequestFor.Object).Result) - return true; - - while (expr != null && expr.NodeType == ExpressionType.MemberAccess) - expr = ((MemberExpression)expr).Expression; - - return expr != null && expr.NodeType == ExpressionType.Constant; - } - - bool IsGroupJoinSource(IBuildContext context, MethodCallExpression call) - { - if (!call.IsQueryable() || CountBuilder.MethodNames.Contains(call.Method.Name)) - return false; - - Expression expr = call; - - while (expr.NodeType == ExpressionType.Call) - expr = ((MethodCallExpression)expr).Arguments[0]; - - var ctx = GetContext(context, expr); - - return ctx != null && ctx.IsExpression(expr, 0, RequestFor.GroupJoin).Result; - } - - #endregion - - #region ConvertExpression - - interface IConvertHelper - { - Expression ConvertNull(MemberExpression expression); - } - - class ConvertHelper : IConvertHelper - where T : struct - { - public Expression ConvertNull(MemberExpression expression) - { - return Expression.Call( - null, - ReflectionHelper.Expressor.MethodExpressor(p => Sql.ConvertNullable(p)), - expression.Expression); - } - } - - Expression ConvertExpression(Expression expression) - { - return expression.Convert2(e => - { - if (CanBeConstant(e) || CanBeCompiled(e)) - return new ExpressionHelper.ConvertInfo(e, true); - - switch (e.NodeType) - { - case ExpressionType.New: - { - var ex = ConvertNew((NewExpression)e); - if (ex != null) - return new ExpressionHelper.ConvertInfo(ConvertExpression(ex)); - break; - } - - case ExpressionType.Call: - { - var cm = ConvertMethod((MethodCallExpression)e); - if (cm != null) - return new ExpressionHelper.ConvertInfo(ConvertExpression(cm)); - break; - } - - case ExpressionType.MemberAccess: - { - var ma = (MemberExpression)e; - var l = SqlProvider.ConvertMember(ma.Member); - - if (l != null) - { - var body = l.Body.Unwrap(); - var expr = body.Convert(wpi => wpi.NodeType == ExpressionType.Parameter ? ma.Expression : wpi); - - if (expr.Type != e.Type) - expr = new ChangeTypeExpression(expr, e.Type); - - return new ExpressionHelper.ConvertInfo(ConvertExpression(expr)); - } - - if (TypeHelper.IsNullableValueMember(ma.Member)) - { - var ntype = typeof(ConvertHelper<>).MakeGenericType(ma.Type); - var helper = (IConvertHelper)Activator.CreateInstance(ntype); - var expr = helper.ConvertNull(ma); - - return new ExpressionHelper.ConvertInfo(ConvertExpression(expr)); - } - - if (ma.Member.DeclaringType == typeof(TimeSpan)) - { - switch (ma.Expression.NodeType) - { - case ExpressionType.Subtract : - case ExpressionType.SubtractChecked: - - Sql.DateParts datePart; - - switch (ma.Member.Name) - { - case "TotalMilliseconds" : datePart = Sql.DateParts.Millisecond; break; - case "TotalSeconds" : datePart = Sql.DateParts.Second; break; - case "TotalMinutes" : datePart = Sql.DateParts.Minute; break; - case "TotalHours" : datePart = Sql.DateParts.Hour; break; - case "TotalDays" : datePart = Sql.DateParts.Day; break; - default : return new ExpressionHelper.ConvertInfo(e); - } - - var ex = (BinaryExpression)ma.Expression; - var method = ReflectionHelper.Expressor.MethodExpressor( - _ => Sql.DateDiff(Sql.DateParts.Day, DateTime.MinValue, DateTime.MinValue)); - - var call = - Expression.Convert( - Expression.Call( - null, - method, - Expression.Constant(datePart), - Expression.Convert(ex.Right, typeof(DateTime?)), - Expression.Convert(ex.Left, typeof(DateTime?))), - typeof(double)); - - return new ExpressionHelper.ConvertInfo(ConvertExpression(call)); - } - } - - break; - } - } - - return new ExpressionHelper.ConvertInfo(e); - }); - } - - Expression ConvertMethod(MethodCallExpression pi) - { - var l = SqlProvider.ConvertMember(pi.Method); - return l == null ? null : ConvertMethod(pi, l); - } - - static Expression ConvertMethod(MethodCallExpression pi, LambdaExpression lambda) - { - var ef = lambda.Body.Unwrap(); - var parms = new Dictionary(lambda.Parameters.Count); - var pn = pi.Method.IsStatic ? 0 : -1; - - foreach (var p in lambda.Parameters) - parms.Add(p.Name, pn++); - - var pie = ef.Convert(wpi => - { - if (wpi.NodeType == ExpressionType.Parameter) - { - int n; - if (parms.TryGetValue(((ParameterExpression)wpi).Name, out n)) - return n < 0 ? pi.Object : pi.Arguments[n]; - } - - return wpi; - }); - - if (pi.Method.ReturnType != pie.Type) - pie = new ChangeTypeExpression(pie, pi.Method.ReturnType); - - return pie; - } - - Expression ConvertNew(NewExpression pi) - { - var lambda = SqlProvider.ConvertMember(pi.Constructor); - - if (lambda != null) - { - var ef = lambda.Body.Unwrap(); - var parms = new Dictionary(lambda.Parameters.Count); - var pn = 0; - - foreach (var p in lambda.Parameters) - parms.Add(p.Name, pn++); - - return ef.Convert(wpi => - { - if (wpi.NodeType == ExpressionType.Parameter) - { - var pe = (ParameterExpression)wpi; - var n = parms[pe.Name]; - return pi.Arguments[n]; - } - - return wpi; - }); - } - - return null; - } - - #endregion - - #region BuildExpression - - public SqlInfo[] ConvertExpressions(IBuildContext context, Expression expression, ConvertFlags queryConvertFlag) - { - expression = ConvertExpression(expression); - - switch (expression.NodeType) - { - case ExpressionType.New : - { - var expr = (NewExpression)expression; - -// ReSharper disable ConditionIsAlwaysTrueOrFalse -// ReSharper disable HeuristicUnreachableCode - if (expr.Members == null) - return Array.Empty; -// ReSharper restore HeuristicUnreachableCode -// ReSharper restore ConditionIsAlwaysTrueOrFalse - - return expr.Arguments - .Select((arg,i) => - { - var mi = expr.Members[i]; - if (mi is MethodInfo) - mi = TypeHelper.GetPropertyByMethod((MethodInfo)mi); - - return ConvertExpressions(context, arg, queryConvertFlag).Select(si => si.Clone(mi)); - }) - .SelectMany(si => si) - .ToArray(); - } - - case ExpressionType.MemberInit : - { - var expr = (MemberInitExpression)expression; - var dic = TypeAccessor.GetAccessor(expr.Type) - .Select((m,i) => new { m, i }) - .ToDictionary(_ => _.m.MemberInfo, _ => _.i); - - return expr.Bindings - .Where (b => b is MemberAssignment) - .Cast() - .OrderBy(b => dic[b.Member]) - .Select (a => - { - var mi = a.Member; - if (mi is MethodInfo) - mi = TypeHelper.GetPropertyByMethod((MethodInfo)mi); - - return ConvertExpressions(context, a.Expression, queryConvertFlag).Select(si => si.Clone(mi)); - }) - .SelectMany(si => si) - .ToArray(); - } - } - - var ctx = GetContext(context, expression); - - if (ctx != null && ctx.IsExpression(expression, 0, RequestFor.Object).Result) - return ctx.ConvertToSql(expression, 0, queryConvertFlag); - + break; + + if (SqlProvider.ConvertMember(ma.Member) == null) + { + var ctx = GetContext(context, expr); + + if (ctx != null) + { + if (ctx.IsExpression(expr, 0, RequestFor.Expression).Result) + makeSubQuery = true; + stopWalking = true; + } + } + + isWhere = true; + + break; + } + + case ExpressionType.Call: + { + var e = (MethodCallExpression)expr; + + if (e.Method.DeclaringType == typeof(Enumerable) && e.Method.Name != "Contains") + return isHaving = true; + + isWhere = true; + + break; + } + + case ExpressionType.Parameter: + { + var ctx = GetContext(context, expr); + + if (ctx != null) + { + if (ctx.IsExpression(expr, 0, RequestFor.Expression).Result) + makeSubQuery = true; + stopWalking = true; + } + + isWhere = true; + + break; + } + } + + return !stopWalking; + }); + + makeHaving = isHaving && !isWhere; + return makeSubQuery || isHaving && isWhere; + } + + #endregion + + #region BuildTake + + public void BuildTake(IBuildContext context, ISqlExpression expr) + { + var sql = context.SqlQuery; + + sql.Select.Take(expr); + + SqlProvider.SqlQuery = sql; + + if (sql.Select.SkipValue != null && SqlProvider.IsTakeSupported && !SqlProvider.IsSkipSupported) + { + if (context.SqlQuery.Select.SkipValue is SqlParameter && sql.Select.TakeValue is SqlValue) + { + var skip = (SqlParameter)sql.Select.SkipValue; + var parm = (SqlParameter)sql.Select.SkipValue.Clone(new Dictionary(), _ => true); + + parm.SetTakeConverter((int)((SqlValue)sql.Select.TakeValue).Value); + + sql.Select.Take(parm); + + var ep = (from pm in CurrentSqlParameters where pm.SqlParameter == skip select pm).First(); + + ep = new ParameterAccessor + { + Expression = ep.Expression, + Accessor = ep.Accessor, + SqlParameter = parm + }; + + CurrentSqlParameters.Add(ep); + } + else + sql.Select.Take(Convert( + context, + new SqlBinaryExpression(typeof(int), sql.Select.SkipValue, "+", sql.Select.TakeValue, Precedence.Additive))); + } + + if (!SqlProvider.TakeAcceptsParameter) + { + var p = sql.Select.TakeValue as SqlParameter; + + if (p != null) + p.IsQueryParameter = false; + } + } + + #endregion + + #region SubQueryToSql + + public IBuildContext GetSubQuery(IBuildContext context, MethodCallExpression expr) + { + var info = new BuildInfo(context, expr, new SqlQuery { ParentSql = context.SqlQuery }); + var ctx = BuildSequence(info); + + if (ctx.SqlQuery.Select.Columns.Count == 0 && + (ctx.IsExpression(null, 0, RequestFor.Expression).Result || + ctx.IsExpression(null, 0, RequestFor.Field). Result)) + { + ctx.ConvertToIndex(null, 0, ConvertFlags.Field); + } + + return ctx; + } + + internal ISqlExpression SubQueryToSql(IBuildContext context, MethodCallExpression expression) + { + var sequence = GetSubQuery(context, expression); + var subSql = sequence.GetSubQuery(context); + + if (subSql != null) + return subSql; + + var query = context.SqlQuery; + var subQuery = sequence.SqlQuery; + + // This code should be moved to context. + // + if (!query.GroupBy.IsEmpty && !subQuery.Where.IsEmpty) + { + var fromGroupBy = sequence.SqlQuery.Properties + .OfType>() + .Where(p => p.Item1 == "from_group_by" && p.Item2 == context.SqlQuery) + .Any(); + + if (fromGroupBy) + { + if (subQuery.Select.Columns.Count == 1 && + subQuery.Select.Columns[0].Expression.ElementType == QueryElementType.SqlFunction && + subQuery.GroupBy.IsEmpty && !subQuery.Select.HasModifier && !subQuery.HasUnion && + subQuery.Where.SearchCondition.Conditions.Count == 1) + { + var cond = subQuery.Where.SearchCondition.Conditions[0]; + + if (cond.Predicate.ElementType == QueryElementType.ExprExprPredicate && query.GroupBy.Items.Count == 1 || + cond.Predicate.ElementType == QueryElementType.SearchCondition && + query.GroupBy.Items.Count == ((SqlQuery.SearchCondition)cond.Predicate).Conditions.Count) + { + var func = (SqlFunction)subQuery.Select.Columns[0].Expression; + + if (CountBuilder.MethodNames.Contains(func.Name)) + return SqlFunction.CreateCount(func.SystemType, query); + } + } + } + } + + return sequence.SqlQuery; + } + + #endregion + + #region IsSubQuery + + bool IsSubQuery(IBuildContext context, MethodCallExpression call) + { + if (call.IsQueryable()) + { + var info = new BuildInfo(context, call, new SqlQuery { ParentSql = context.SqlQuery }); + + if (!IsSequence(info)) + return false; + + var arg = call.Arguments[0]; + + if (AggregationBuilder.MethodNames.Contains(call.Method.Name)) + while (arg.NodeType == ExpressionType.Call && ((MethodCallExpression) arg).Method.Name == "Select") + arg = ((MethodCallExpression)arg).Arguments[0]; + + var mc = arg as MethodCallExpression; + + while (mc != null) + { + if (!mc.IsQueryable()) + return GetTableFunctionAttribute(mc.Method) != null; + + mc = mc.Arguments[0] as MethodCallExpression; + } + + return arg.NodeType == ExpressionType.Call || IsSubQuerySource(context, arg); + } + + return false; + } + + bool IsSubQuerySource(IBuildContext context, Expression expr) + { + if (expr == null) + return false; + + var ctx = GetContext(context, expr); + + if (ctx != null && ctx.IsExpression(expr, 0, RequestFor.Object).Result) + return true; + + while (expr != null && expr.NodeType == ExpressionType.MemberAccess) + expr = ((MemberExpression)expr).Expression; + + return expr != null && expr.NodeType == ExpressionType.Constant; + } + + bool IsGroupJoinSource(IBuildContext context, MethodCallExpression call) + { + if (!call.IsQueryable() || CountBuilder.MethodNames.Contains(call.Method.Name)) + return false; + + Expression expr = call; + + while (expr.NodeType == ExpressionType.Call) + expr = ((MethodCallExpression)expr).Arguments[0]; + + var ctx = GetContext(context, expr); + + return ctx != null && ctx.IsExpression(expr, 0, RequestFor.GroupJoin).Result; + } + + #endregion + + #region ConvertExpression + + interface IConvertHelper + { + Expression ConvertNull(MemberExpression expression); + } + + class ConvertHelper : IConvertHelper + where T : struct + { + public Expression ConvertNull(MemberExpression expression) + { + return Expression.Call( + null, + ReflectionHelper.Expressor.MethodExpressor(p => Sql.ConvertNullable(p)), + expression.Expression); + } + } + + Expression ConvertExpression(Expression expression) + { + return expression.Convert2(e => + { + if (CanBeConstant(e) || CanBeCompiled(e)) + return new ExpressionHelper.ConvertInfo(e, true); + + switch (e.NodeType) + { + case ExpressionType.New: + { + var ex = ConvertNew((NewExpression)e); + if (ex != null) + return new ExpressionHelper.ConvertInfo(ConvertExpression(ex)); + break; + } + + case ExpressionType.Call: + { + var cm = ConvertMethod((MethodCallExpression)e); + if (cm != null) + return new ExpressionHelper.ConvertInfo(ConvertExpression(cm)); + break; + } + + case ExpressionType.MemberAccess: + { + var ma = (MemberExpression)e; + var l = SqlProvider.ConvertMember(ma.Member); + + if (l != null) + { + var body = l.Body.Unwrap(); + var expr = body.Convert(wpi => wpi.NodeType == ExpressionType.Parameter ? ma.Expression : wpi); + + if (expr.Type != e.Type) + expr = new ChangeTypeExpression(expr, e.Type); + + return new ExpressionHelper.ConvertInfo(ConvertExpression(expr)); + } + + if (TypeHelper.IsNullableValueMember(ma.Member)) + { + var ntype = typeof(ConvertHelper<>).MakeGenericType(ma.Type); + var helper = (IConvertHelper)Activator.CreateInstance(ntype); + var expr = helper.ConvertNull(ma); + + return new ExpressionHelper.ConvertInfo(ConvertExpression(expr)); + } + + if (ma.Member.DeclaringType == typeof(TimeSpan)) + { + switch (ma.Expression.NodeType) + { + case ExpressionType.Subtract : + case ExpressionType.SubtractChecked: + + Sql.DateParts datePart; + + switch (ma.Member.Name) + { + case "TotalMilliseconds" : datePart = Sql.DateParts.Millisecond; break; + case "TotalSeconds" : datePart = Sql.DateParts.Second; break; + case "TotalMinutes" : datePart = Sql.DateParts.Minute; break; + case "TotalHours" : datePart = Sql.DateParts.Hour; break; + case "TotalDays" : datePart = Sql.DateParts.Day; break; + default : return new ExpressionHelper.ConvertInfo(e); + } + + var ex = (BinaryExpression)ma.Expression; + var method = ReflectionHelper.Expressor.MethodExpressor( + _ => Sql.DateDiff(Sql.DateParts.Day, DateTime.MinValue, DateTime.MinValue)); + + var call = + Expression.Convert( + Expression.Call( + null, + method, + Expression.Constant(datePart), + Expression.Convert(ex.Right, typeof(DateTime?)), + Expression.Convert(ex.Left, typeof(DateTime?))), + typeof(double)); + + return new ExpressionHelper.ConvertInfo(ConvertExpression(call)); + } + } + + break; + } + } + + return new ExpressionHelper.ConvertInfo(e); + }); + } + + Expression ConvertMethod(MethodCallExpression pi) + { + var l = SqlProvider.ConvertMember(pi.Method); + return l == null ? null : ConvertMethod(pi, l); + } + + static Expression ConvertMethod(MethodCallExpression pi, LambdaExpression lambda) + { + var ef = lambda.Body.Unwrap(); + var parms = new Dictionary(lambda.Parameters.Count); + var pn = pi.Method.IsStatic ? 0 : -1; + + foreach (var p in lambda.Parameters) + parms.Add(p.Name, pn++); + + var pie = ef.Convert(wpi => + { + if (wpi.NodeType == ExpressionType.Parameter) + { + int n; + if (parms.TryGetValue(((ParameterExpression)wpi).Name, out n)) + return n < 0 ? pi.Object : pi.Arguments[n]; + } + + return wpi; + }); + + if (pi.Method.ReturnType != pie.Type) + pie = new ChangeTypeExpression(pie, pi.Method.ReturnType); + + return pie; + } + + Expression ConvertNew(NewExpression pi) + { + var lambda = SqlProvider.ConvertMember(pi.Constructor); + + if (lambda != null) + { + var ef = lambda.Body.Unwrap(); + var parms = new Dictionary(lambda.Parameters.Count); + var pn = 0; + + foreach (var p in lambda.Parameters) + parms.Add(p.Name, pn++); + + return ef.Convert(wpi => + { + if (wpi.NodeType == ExpressionType.Parameter) + { + var pe = (ParameterExpression)wpi; + var n = parms[pe.Name]; + return pi.Arguments[n]; + } + + return wpi; + }); + } + + return null; + } + + #endregion + + #region BuildExpression + + public SqlInfo[] ConvertExpressions(IBuildContext context, Expression expression, ConvertFlags queryConvertFlag) + { + expression = ConvertExpression(expression); + + switch (expression.NodeType) + { + case ExpressionType.New : + { + var expr = (NewExpression)expression; + +// ReSharper disable ConditionIsAlwaysTrueOrFalse +// ReSharper disable HeuristicUnreachableCode + if (expr.Members == null) + return Array.Empty; +// ReSharper restore HeuristicUnreachableCode +// ReSharper restore ConditionIsAlwaysTrueOrFalse + + return expr.Arguments + .Select((arg,i) => + { + var mi = expr.Members[i]; + if (mi is MethodInfo) + mi = TypeHelper.GetPropertyByMethod((MethodInfo)mi); + + return ConvertExpressions(context, arg, queryConvertFlag).Select(si => si.Clone(mi)); + }) + .SelectMany(si => si) + .ToArray(); + } + + case ExpressionType.MemberInit : + { + var expr = (MemberInitExpression)expression; + var dic = TypeAccessor.GetAccessor(expr.Type) + .Select((m,i) => new { m, i }) + .ToDictionary(_ => _.m.MemberInfo, _ => _.i); + + return expr.Bindings + .Where (b => b is MemberAssignment) + .Cast() + .OrderBy(b => dic[b.Member]) + .Select (a => + { + var mi = a.Member; + if (mi is MethodInfo) + mi = TypeHelper.GetPropertyByMethod((MethodInfo)mi); + + return ConvertExpressions(context, a.Expression, queryConvertFlag).Select(si => si.Clone(mi)); + }) + .SelectMany(si => si) + .ToArray(); + } + } + + var ctx = GetContext(context, expression); + + if (ctx != null && ctx.IsExpression(expression, 0, RequestFor.Object).Result) + return ctx.ConvertToSql(expression, 0, queryConvertFlag); + return new[] { new SqlInfo { Sql = ConvertToSql(context, expression, false) } }; - } - - public ISqlExpression ConvertToSqlExpression(IBuildContext context, Expression expression, bool convertEnum) - { - var expr = ConvertExpression(expression); - return ConvertToSql(context, expr, false, convertEnum); - } - -#if FW3 - public ISqlExpression ConvertToSql(IBuildContext context, Expression expression, bool unwrap) - { - return ConvertToSql(context, expression, unwrap, true); - } -#endif - - public ISqlExpression ConvertToSql(IBuildContext context, Expression expression, bool unwrap, bool convertEnum -#if !FW3 - = true -#endif - ) - { - if (CanBeConstant(expression)) - return BuildConstant(expression, convertEnum); - - if (CanBeCompiled(expression)) - return BuildParameter(expression).SqlParameter; - - if (unwrap) - expression = expression.Unwrap(); - - switch (expression.NodeType) - { - case ExpressionType.AndAlso : - case ExpressionType.OrElse : - case ExpressionType.Not : - case ExpressionType.Equal : - case ExpressionType.NotEqual : - case ExpressionType.GreaterThan : - case ExpressionType.GreaterThanOrEqual : - case ExpressionType.LessThan : - case ExpressionType.LessThanOrEqual : - { - var condition = new SqlQuery.SearchCondition(); - BuildSearchCondition(context, expression, condition.Conditions); - return condition; - } - - case ExpressionType.And : - case ExpressionType.Or : - { - if (expression.Type == typeof(bool)) - goto case ExpressionType.AndAlso; - goto case ExpressionType.Add; - } - - case ExpressionType.Add : - case ExpressionType.AddChecked : - case ExpressionType.Divide : - case ExpressionType.ExclusiveOr : - case ExpressionType.Modulo : - case ExpressionType.Multiply : - case ExpressionType.MultiplyChecked : - case ExpressionType.Power : - case ExpressionType.Subtract : - case ExpressionType.SubtractChecked : - case ExpressionType.Coalesce : - { - var e = (BinaryExpression)expression; + } + + public ISqlExpression ConvertToSqlExpression(IBuildContext context, Expression expression, bool convertEnum) + { + var expr = ConvertExpression(expression); + return ConvertToSql(context, expr, false, convertEnum); + } + +#if FW3 + public ISqlExpression ConvertToSql(IBuildContext context, Expression expression, bool unwrap) + { + return ConvertToSql(context, expression, unwrap, true); + } +#endif + + public ISqlExpression ConvertToSql(IBuildContext context, Expression expression, bool unwrap, bool convertEnum +#if !FW3 + = true +#endif + ) + { + if (CanBeConstant(expression)) + return BuildConstant(expression, convertEnum); + + if (CanBeCompiled(expression)) + return BuildParameter(expression).SqlParameter; + + if (unwrap) + expression = expression.Unwrap(); + + switch (expression.NodeType) + { + case ExpressionType.AndAlso : + case ExpressionType.OrElse : + case ExpressionType.Not : + case ExpressionType.Equal : + case ExpressionType.NotEqual : + case ExpressionType.GreaterThan : + case ExpressionType.GreaterThanOrEqual : + case ExpressionType.LessThan : + case ExpressionType.LessThanOrEqual : + { + var condition = new SqlQuery.SearchCondition(); + BuildSearchCondition(context, expression, condition.Conditions); + return condition; + } + + case ExpressionType.And : + case ExpressionType.Or : + { + if (expression.Type == typeof(bool)) + goto case ExpressionType.AndAlso; + goto case ExpressionType.Add; + } + + case ExpressionType.Add : + case ExpressionType.AddChecked : + case ExpressionType.Divide : + case ExpressionType.ExclusiveOr : + case ExpressionType.Modulo : + case ExpressionType.Multiply : + case ExpressionType.MultiplyChecked : + case ExpressionType.Power : + case ExpressionType.Subtract : + case ExpressionType.SubtractChecked : + case ExpressionType.Coalesce : + { + var e = (BinaryExpression)expression; var l = ConvertToSql(context, e.Left, false); var r = ConvertToSql(context, e.Right, false); - var t = e.Type; - - switch (expression.NodeType) - { - case ExpressionType.Add : - case ExpressionType.AddChecked : return Convert(context, new SqlBinaryExpression(t, l, "+", r, Precedence.Additive)); - case ExpressionType.And : return Convert(context, new SqlBinaryExpression(t, l, "&", r, Precedence.Bitwise)); - case ExpressionType.Divide : return Convert(context, new SqlBinaryExpression(t, l, "/", r, Precedence.Multiplicative)); - case ExpressionType.ExclusiveOr : return Convert(context, new SqlBinaryExpression(t, l, "^", r, Precedence.Bitwise)); - case ExpressionType.Modulo : return Convert(context, new SqlBinaryExpression(t, l, "%", r, Precedence.Multiplicative)); - case ExpressionType.Multiply: - case ExpressionType.MultiplyChecked : return Convert(context, new SqlBinaryExpression(t, l, "*", r, Precedence.Multiplicative)); - case ExpressionType.Or : return Convert(context, new SqlBinaryExpression(t, l, "|", r, Precedence.Bitwise)); - case ExpressionType.Power : return Convert(context, new SqlFunction(t, "Power", l, r)); - case ExpressionType.Subtract : - case ExpressionType.SubtractChecked : return Convert(context, new SqlBinaryExpression(t, l, "-", r, Precedence.Subtraction)); - case ExpressionType.Coalesce : - { - if (r is SqlFunction) - { - var c = (SqlFunction)r; - - if (c.Name == "Coalesce") - { - var parms = new ISqlExpression[c.Parameters.Length + 1]; - - parms[0] = l; - c.Parameters.CopyTo(parms, 1); - - return Convert(context, new SqlFunction(t, "Coalesce", parms)); - } - } - - return Convert(context, new SqlFunction(t, "Coalesce", l, r)); - } - } - - break; - } - - case ExpressionType.UnaryPlus : - case ExpressionType.Negate : - case ExpressionType.NegateChecked : - { - var e = (UnaryExpression)expression; + var t = e.Type; + + switch (expression.NodeType) + { + case ExpressionType.Add : + case ExpressionType.AddChecked : return Convert(context, new SqlBinaryExpression(t, l, "+", r, Precedence.Additive)); + case ExpressionType.And : return Convert(context, new SqlBinaryExpression(t, l, "&", r, Precedence.Bitwise)); + case ExpressionType.Divide : return Convert(context, new SqlBinaryExpression(t, l, "/", r, Precedence.Multiplicative)); + case ExpressionType.ExclusiveOr : return Convert(context, new SqlBinaryExpression(t, l, "^", r, Precedence.Bitwise)); + case ExpressionType.Modulo : return Convert(context, new SqlBinaryExpression(t, l, "%", r, Precedence.Multiplicative)); + case ExpressionType.Multiply: + case ExpressionType.MultiplyChecked : return Convert(context, new SqlBinaryExpression(t, l, "*", r, Precedence.Multiplicative)); + case ExpressionType.Or : return Convert(context, new SqlBinaryExpression(t, l, "|", r, Precedence.Bitwise)); + case ExpressionType.Power : return Convert(context, new SqlFunction(t, "Power", l, r)); + case ExpressionType.Subtract : + case ExpressionType.SubtractChecked : return Convert(context, new SqlBinaryExpression(t, l, "-", r, Precedence.Subtraction)); + case ExpressionType.Coalesce : + { + if (r is SqlFunction) + { + var c = (SqlFunction)r; + + if (c.Name == "Coalesce") + { + var parms = new ISqlExpression[c.Parameters.Length + 1]; + + parms[0] = l; + c.Parameters.CopyTo(parms, 1); + + return Convert(context, new SqlFunction(t, "Coalesce", parms)); + } + } + + return Convert(context, new SqlFunction(t, "Coalesce", l, r)); + } + } + + break; + } + + case ExpressionType.UnaryPlus : + case ExpressionType.Negate : + case ExpressionType.NegateChecked : + { + var e = (UnaryExpression)expression; var o = ConvertToSql(context, e.Operand, false); - var t = e.Type; - - switch (expression.NodeType) - { - case ExpressionType.UnaryPlus : return o; - case ExpressionType.Negate : - case ExpressionType.NegateChecked : - return Convert(context, new SqlBinaryExpression(t, new SqlValue(-1), "*", o, Precedence.Multiplicative)); - } - - break; - } - - case ExpressionType.Convert : - case ExpressionType.ConvertChecked : - { - var e = (UnaryExpression)expression; + var t = e.Type; + + switch (expression.NodeType) + { + case ExpressionType.UnaryPlus : return o; + case ExpressionType.Negate : + case ExpressionType.NegateChecked : + return Convert(context, new SqlBinaryExpression(t, new SqlValue(-1), "*", o, Precedence.Multiplicative)); + } + + break; + } + + case ExpressionType.Convert : + case ExpressionType.ConvertChecked : + { + var e = (UnaryExpression)expression; var o = ConvertToSql(context, e.Operand, false); if (e.Method == null && e.IsLifted) @@ -712,584 +712,584 @@ public ISqlExpression ConvertToSql(IBuildContext context, Expression expression, var s = ConvertToSql(context, e.Test, false); var t = ConvertToSql(context, e.IfTrue, false); var f = ConvertToSql(context, e.IfFalse, false); - - if (f is SqlFunction) - { - var c = (SqlFunction)f; - - if (c.Name == "CASE") - { - var parms = new ISqlExpression[c.Parameters.Length + 2]; - - parms[0] = s; - parms[1] = t; - c.Parameters.CopyTo(parms, 2); - - return Convert(context, new SqlFunction(e.Type, "CASE", parms)); - } - } - - return Convert(context, new SqlFunction(e.Type, "CASE", s, t, f)); - } - - case ExpressionType.MemberAccess : - { - var ma = (MemberExpression)expression; - var attr = GetFunctionAttribute(ma.Member); - - if (attr != null) - return Convert(context, attr.GetExpression(ma.Member)); - - var ctx = GetContext(context, expression); - - if (ctx != null) - { - var sql = ctx.ConvertToSql(expression, 0, ConvertFlags.Field); - - switch (sql.Length) - { - case 0 : break; - case 1 : return sql[0].Sql; - default : throw new InvalidOperationException(); - } - } - - break; - } - - case ExpressionType.Parameter : - { - var ctx = GetContext(context, expression); - - if (ctx != null) - { - var sql = ctx.ConvertToSql(expression, 0, ConvertFlags.Field); - - switch (sql.Length) - { - case 0 : break; - case 1 : return sql[0].Sql; - default : throw new InvalidOperationException(); - } - } - - break; - } - - case ExpressionType.Call : - { - var e = (MethodCallExpression)expression; - - if (e.IsQueryable()) - { - if (IsSubQuery(context, e)) - return SubQueryToSql(context, e); - - if (CountBuilder.MethodNames.Concat(AggregationBuilder.MethodNames).Contains(e.Method.Name)) - { - var ctx = GetContext(context, expression); - - if (ctx != null) - { - var sql = ctx.ConvertToSql(expression, 0, ConvertFlags.Field); - - if (sql.Length != 1) - throw new InvalidOperationException(); - - return sql[0].Sql; - } - - break; - } - - return SubQueryToSql(context, e); - } - - var attr = GetFunctionAttribute(e.Method); - - if (attr != null) - { - var parms = new List(); - - if (e.Object != null) + + if (f is SqlFunction) + { + var c = (SqlFunction)f; + + if (c.Name == "CASE") + { + var parms = new ISqlExpression[c.Parameters.Length + 2]; + + parms[0] = s; + parms[1] = t; + c.Parameters.CopyTo(parms, 2); + + return Convert(context, new SqlFunction(e.Type, "CASE", parms)); + } + } + + return Convert(context, new SqlFunction(e.Type, "CASE", s, t, f)); + } + + case ExpressionType.MemberAccess : + { + var ma = (MemberExpression)expression; + var attr = GetFunctionAttribute(ma.Member); + + if (attr != null) + return Convert(context, attr.GetExpression(ma.Member)); + + var ctx = GetContext(context, expression); + + if (ctx != null) + { + var sql = ctx.ConvertToSql(expression, 0, ConvertFlags.Field); + + switch (sql.Length) + { + case 0 : break; + case 1 : return sql[0].Sql; + default : throw new InvalidOperationException(); + } + } + + break; + } + + case ExpressionType.Parameter : + { + var ctx = GetContext(context, expression); + + if (ctx != null) + { + var sql = ctx.ConvertToSql(expression, 0, ConvertFlags.Field); + + switch (sql.Length) + { + case 0 : break; + case 1 : return sql[0].Sql; + default : throw new InvalidOperationException(); + } + } + + break; + } + + case ExpressionType.Call : + { + var e = (MethodCallExpression)expression; + + if (e.IsQueryable()) + { + if (IsSubQuery(context, e)) + return SubQueryToSql(context, e); + + if (CountBuilder.MethodNames.Concat(AggregationBuilder.MethodNames).Contains(e.Method.Name)) + { + var ctx = GetContext(context, expression); + + if (ctx != null) + { + var sql = ctx.ConvertToSql(expression, 0, ConvertFlags.Field); + + if (sql.Length != 1) + throw new InvalidOperationException(); + + return sql[0].Sql; + } + + break; + } + + return SubQueryToSql(context, e); + } + + var attr = GetFunctionAttribute(e.Method); + + if (attr != null) + { + var parms = new List(); + + if (e.Object != null) parms.Add(ConvertToSql(context, e.Object, false)); - + parms.AddRange(e.Arguments.Select(t => ConvertToSql(context, t, false))); - - return Convert(context, attr.GetExpression(e.Method, parms.ToArray())); - } - - break; - } - - case ExpressionType.Invoke : - { - var pi = (InvocationExpression)expression; - var ex = pi.Expression; - - if (ex.NodeType == ExpressionType.Quote) - ex = ((UnaryExpression)ex).Operand; - - if (ex.NodeType == ExpressionType.Lambda) - { - var l = (LambdaExpression)ex; - var dic = new Dictionary(); - - for (var i = 0; i < l.Parameters.Count; i++) - dic.Add(l.Parameters[i], pi.Arguments[i]); - - var pie = l.Body.Convert(wpi => - { - Expression ppi; - return dic.TryGetValue(wpi, out ppi) ? ppi : wpi; - }); - + + return Convert(context, attr.GetExpression(e.Method, parms.ToArray())); + } + + break; + } + + case ExpressionType.Invoke : + { + var pi = (InvocationExpression)expression; + var ex = pi.Expression; + + if (ex.NodeType == ExpressionType.Quote) + ex = ((UnaryExpression)ex).Operand; + + if (ex.NodeType == ExpressionType.Lambda) + { + var l = (LambdaExpression)ex; + var dic = new Dictionary(); + + for (var i = 0; i < l.Parameters.Count; i++) + dic.Add(l.Parameters[i], pi.Arguments[i]); + + var pie = l.Body.Convert(wpi => + { + Expression ppi; + return dic.TryGetValue(wpi, out ppi) ? ppi : wpi; + }); + return ConvertToSql(context, pie, false); - } - - break; - } - - case ExpressionType.TypeIs : - { - var condition = new SqlQuery.SearchCondition(); - BuildSearchCondition(context, expression, condition.Conditions); - return condition; - } - - case (ExpressionType)ChangeTypeExpression.ChangeTypeType : + } + + break; + } + + case ExpressionType.TypeIs : + { + var condition = new SqlQuery.SearchCondition(); + BuildSearchCondition(context, expression, condition.Conditions); + return condition; + } + + case (ExpressionType)ChangeTypeExpression.ChangeTypeType : return ConvertToSql(context, ((ChangeTypeExpression)expression).Expression, false); - } - - if (expression.Type == typeof(bool) && _convertedPredicates.Add(expression)) - { - var predicate = ConvertPredicate(context, expression); - _convertedPredicates.Remove(expression); - if (predicate != null) - return new SqlQuery.SearchCondition(new SqlQuery.Condition(false, predicate)); - } - - throw new LinqException("'{0}' cannot be converted to SQL.", expression); - } - - readonly HashSet _convertedPredicates = new HashSet(); - - #endregion - - #region IsServerSideOnly - - bool IsServerSideOnly(Expression expr) - { - switch (expr.NodeType) - { - case ExpressionType.MemberAccess: - { - var ex = (MemberExpression)expr; - var l = SqlProvider.ConvertMember(ex.Member); - - if (l != null) - return IsServerSideOnly(l.Body.Unwrap()); - - var attr = GetFunctionAttribute(ex.Member); - return attr != null && attr.ServerSideOnly; - } - - case ExpressionType.Call: - { - var e = (MethodCallExpression)expr; - - if (e.Method.DeclaringType == typeof(Enumerable)) - { - if (CountBuilder.MethodNames.Concat(AggregationBuilder.MethodNames).Contains(e.Method.Name)) - return IsQueryMember(e.Arguments[0]); - } - else if (e.Method.DeclaringType == typeof(Queryable)) - { - switch (e.Method.Name) - { - case "Any" : - case "All" : - case "Contains" : return true; - } - } - else - { - var l = SqlProvider.ConvertMember(e.Method); - - if (l != null) - return l.Body.Unwrap().Find(IsServerSideOnly) != null; - - var attr = GetFunctionAttribute(e.Method); - return attr != null && attr.ServerSideOnly; - } - - break; - } - } - - return false; - } - - static bool IsQueryMember(Expression expr) - { - if (expr != null) switch (expr.NodeType) - { - case ExpressionType.Parameter : return true; - case ExpressionType.MemberAccess : return IsQueryMember(((MemberExpression)expr).Expression); - case ExpressionType.Call : - { - var call = (MethodCallExpression)expr; - - if (call.Method.DeclaringType == typeof(Queryable)) - return true; - - if (call.Method.DeclaringType == typeof(Enumerable) && call.Arguments.Count > 0) - return IsQueryMember(call.Arguments[0]); - - return IsQueryMember(call.Object); - } - } - - return false; - } - - #endregion - - #region CanBeConstant - - bool CanBeConstant(Expression expr) - { - return null == expr.Find(ex => - { - if (ex is BinaryExpression || ex is UnaryExpression /*|| ex.NodeType == ExpressionType.Convert*/) - return false; - - switch (ex.NodeType) - { - case ExpressionType.Constant : - { - var c = (ConstantExpression)ex; - - if (c.Value == null || ExpressionHelper.IsConstant(ex.Type)) - return false; - - break; - } - - case ExpressionType.MemberAccess : - { - var ma = (MemberExpression)ex; - - if (ExpressionHelper.IsConstant(ma.Member.DeclaringType) || TypeHelper.IsNullableValueMember(ma.Member)) - return false; - - break; - } - - case ExpressionType.Call : - { - var mc = (MethodCallExpression)ex; - - if (ExpressionHelper.IsConstant(mc.Method.DeclaringType) || mc.Method.DeclaringType == typeof(object)) - return false; - - var attr = GetFunctionAttribute(mc.Method); - - if (attr != null && !attr.ServerSideOnly) - return false; - - break; - } - } - - return true; - }); - } - - #endregion - - #region CanBeCompiled - - bool CanBeCompiled(Expression expr) - { - return null == expr.Find(ex => - { - if (IsServerSideOnly(ex)) - return true; - - switch (ex.NodeType) - { - case ExpressionType.Parameter : - return ex != ParametersParam; - - case ExpressionType.MemberAccess : - { - var attr = GetFunctionAttribute(((MemberExpression)ex).Member); - return attr != null && attr.ServerSideOnly; - } - - case ExpressionType.Call : - { - var attr = GetFunctionAttribute(((MethodCallExpression)ex).Method); - return attr != null && attr.ServerSideOnly; - } - } - - return false; - }); - } - - #endregion - - #region Build Constant - - readonly Dictionary _constants = new Dictionary(); - - SqlValue BuildConstant(Expression expr, bool convertEnum) - { - SqlValue value; - - if (_constants.TryGetValue(expr, out value)) - return value; - - var lambda = Expression.Lambda>(Expression.Convert(expr, typeof(object))); - var v = lambda.Compile()(); - - if (v != null && convertEnum && v.GetType().IsEnum) + } + + if (expression.Type == typeof(bool) && _convertedPredicates.Add(expression)) + { + var predicate = ConvertPredicate(context, expression); + _convertedPredicates.Remove(expression); + if (predicate != null) + return new SqlQuery.SearchCondition(new SqlQuery.Condition(false, predicate)); + } + + throw new LinqException("'{0}' cannot be converted to SQL.", expression); + } + + readonly HashSet _convertedPredicates = new HashSet(); + + #endregion + + #region IsServerSideOnly + + bool IsServerSideOnly(Expression expr) + { + switch (expr.NodeType) { - var attrs = v.GetType().GetCustomAttributes(typeof(SqlEnumAttribute), true); + case ExpressionType.MemberAccess: + { + var ex = (MemberExpression)expr; + var l = SqlProvider.ConvertMember(ex.Member); + + if (l != null) + return IsServerSideOnly(l.Body.Unwrap()); + + var attr = GetFunctionAttribute(ex.Member); + return attr != null && attr.ServerSideOnly; + } + + case ExpressionType.Call: + { + var e = (MethodCallExpression)expr; + + if (e.Method.DeclaringType == typeof(Enumerable)) + { + if (CountBuilder.MethodNames.Concat(AggregationBuilder.MethodNames).Contains(e.Method.Name)) + return IsQueryMember(e.Arguments[0]); + } + else if (e.Method.DeclaringType == typeof(Queryable)) + { + switch (e.Method.Name) + { + case "Any" : + case "All" : + case "Contains" : return true; + } + } + else + { + var l = SqlProvider.ConvertMember(e.Method); - v = Map.EnumToValue(v, attrs.Length == 0); + if (l != null) + return l.Body.Unwrap().Find(IsServerSideOnly) != null; + + var attr = GetFunctionAttribute(e.Method); + return attr != null && attr.ServerSideOnly; + } + + break; + } } - - value = new SqlValue(v); - - _constants.Add(expr, value); - - return value; - } - - #endregion - - #region Build Parameter - - readonly Dictionary _parameters = new Dictionary(); - - public readonly HashSet AsParameters = new HashSet(); - - ParameterAccessor BuildParameter(Expression expr) - { - ParameterAccessor p; - - if (_parameters.TryGetValue(expr, out p)) - return p; - - string name = null; - - var newExpr = ReplaceParameter(_expressionAccessors, expr, nm => name = nm); - var mapper = Expression.Lambda>( - Expression.Convert(newExpr, typeof(object)), - new [] { ExpressionParam, ParametersParam }); - - p = new ParameterAccessor - { - Expression = expr, - Accessor = mapper.Compile(), - SqlParameter = new SqlParameter(expr.Type, name, null, MappingSchema) - }; - - _parameters.Add(expr, p); - CurrentSqlParameters.Add(p); - - return p; - } - - Expression ReplaceParameter(IDictionary expressionAccessors, Expression expression, Action setName) - { - return expression.Convert(expr => - { - if (expr.NodeType == ExpressionType.Constant) - { - var c = (ConstantExpression)expr; - - if (!ExpressionHelper.IsConstant(expr.Type) || AsParameters.Contains(c)) - { - Expression val; - - if (expressionAccessors.TryGetValue(expr, out val)) - { - expr = Expression.Convert(val, expr.Type); - - if (expression.NodeType == ExpressionType.MemberAccess) - { - var ma = (MemberExpression)expression; - setName(ma.Member.Name); - } - } - } - } - - return expr; - }); - } - - #endregion - - #region Predicate Converter - - ISqlPredicate ConvertPredicate(IBuildContext context, Expression expression) - { - switch (expression.NodeType) + + return false; + } + + static bool IsQueryMember(Expression expr) + { + if (expr != null) switch (expr.NodeType) + { + case ExpressionType.Parameter : return true; + case ExpressionType.MemberAccess : return IsQueryMember(((MemberExpression)expr).Expression); + case ExpressionType.Call : + { + var call = (MethodCallExpression)expr; + + if (call.Method.DeclaringType == typeof(Queryable)) + return true; + + if (call.Method.DeclaringType == typeof(Enumerable) && call.Arguments.Count > 0) + return IsQueryMember(call.Arguments[0]); + + return IsQueryMember(call.Object); + } + } + + return false; + } + + #endregion + + #region CanBeConstant + + bool CanBeConstant(Expression expr) + { + return null == expr.Find(ex => + { + if (ex is BinaryExpression || ex is UnaryExpression /*|| ex.NodeType == ExpressionType.Convert*/) + return false; + + switch (ex.NodeType) + { + case ExpressionType.Constant : + { + var c = (ConstantExpression)ex; + + if (c.Value == null || ExpressionHelper.IsConstant(ex.Type)) + return false; + + break; + } + + case ExpressionType.MemberAccess : + { + var ma = (MemberExpression)ex; + + if (ExpressionHelper.IsConstant(ma.Member.DeclaringType) || TypeHelper.IsNullableValueMember(ma.Member)) + return false; + + break; + } + + case ExpressionType.Call : + { + var mc = (MethodCallExpression)ex; + + if (ExpressionHelper.IsConstant(mc.Method.DeclaringType) || mc.Method.DeclaringType == typeof(object)) + return false; + + var attr = GetFunctionAttribute(mc.Method); + + if (attr != null && !attr.ServerSideOnly) + return false; + + break; + } + } + + return true; + }); + } + + #endregion + + #region CanBeCompiled + + bool CanBeCompiled(Expression expr) + { + return null == expr.Find(ex => + { + if (IsServerSideOnly(ex)) + return true; + + switch (ex.NodeType) + { + case ExpressionType.Parameter : + return ex != ParametersParam; + + case ExpressionType.MemberAccess : + { + var attr = GetFunctionAttribute(((MemberExpression)ex).Member); + return attr != null && attr.ServerSideOnly; + } + + case ExpressionType.Call : + { + var attr = GetFunctionAttribute(((MethodCallExpression)ex).Method); + return attr != null && attr.ServerSideOnly; + } + } + + return false; + }); + } + + #endregion + + #region Build Constant + + readonly Dictionary _constants = new Dictionary(); + + SqlValue BuildConstant(Expression expr, bool convertEnum) + { + SqlValue value; + + if (_constants.TryGetValue(expr, out value)) + return value; + + var lambda = Expression.Lambda>(Expression.Convert(expr, typeof(object))); + var v = lambda.Compile()(); + + if (v != null && convertEnum && v.GetType().IsEnum) { - case ExpressionType.Equal : - case ExpressionType.NotEqual : - case ExpressionType.GreaterThan : - case ExpressionType.GreaterThanOrEqual : - case ExpressionType.LessThan : - case ExpressionType.LessThanOrEqual : - { - var e = (BinaryExpression)expression; - return ConvertCompare(context, expression.NodeType, e.Left, e.Right); - } - - case ExpressionType.Call : - { - var e = (MethodCallExpression)expression; - - ISqlPredicate predicate = null; - - if (e.Method.Name == "Equals" && e.Object != null && e.Arguments.Count == 1) - return ConvertCompare(context, ExpressionType.Equal, e.Object, e.Arguments[0]); - - if (e.Method.DeclaringType == typeof(string)) - { - switch (e.Method.Name) - { - case "Contains" : predicate = ConvertLikePredicate(context, e, "%", "%"); break; - case "StartsWith" : predicate = ConvertLikePredicate(context, e, "", "%"); break; - case "EndsWith" : predicate = ConvertLikePredicate(context, e, "%", ""); break; - } - } - else if (e.Method.Name == "Contains") - { - if (e.Method.DeclaringType == typeof(Enumerable) || - TypeHelper.IsSameOrParent(typeof(IList), e.Method.DeclaringType) || - TypeHelper.IsSameOrParent(typeof(ICollection<>), e.Method.DeclaringType)) - { - predicate = ConvertInPredicate(context, e); - } - } - else if (e.Method.Name == "ContainsValue" && TypeHelper.IsSameOrParent(typeof(Dictionary<,>), e.Method.DeclaringType)) - { - var args = TypeHelper.GetGenericArguments(e.Method.DeclaringType, typeof(Dictionary<,>)); - var minf = EnumerableMethods - .First(m => m.Name == "Contains" && m.GetParameters().Length == 2) - .MakeGenericMethod(args[1]); - - var expr = Expression.Call( - minf, - Expression.PropertyOrField(e.Object, "Values"), - e.Arguments[0]); - - predicate = ConvertInPredicate(context, expr); - } - else if (e.Method.Name == "ContainsKey" && TypeHelper.IsSameOrParent(typeof(IDictionary<,>), e.Method.DeclaringType)) - { - var args = TypeHelper.GetGenericArguments(e.Method.DeclaringType, typeof(IDictionary<,>)); - var minf = EnumerableMethods - .First(m => m.Name == "Contains" && m.GetParameters().Length == 2) - .MakeGenericMethod(args[0]); - - var expr = Expression.Call( - minf, - Expression.PropertyOrField(e.Object, "Keys"), - e.Arguments[0]); + var attrs = v.GetType().GetCustomAttributes(typeof(SqlEnumAttribute), true); - predicate = ConvertInPredicate(context, expr); - } -#if !SILVERLIGHT - else if (e.Method == ReflectionHelper.Functions.String.Like11) predicate = ConvertLikePredicate(context, e); - else if (e.Method == ReflectionHelper.Functions.String.Like12) predicate = ConvertLikePredicate(context, e); -#endif - else if (e.Method == ReflectionHelper.Functions.String.Like21) predicate = ConvertLikePredicate(context, e); - else if (e.Method == ReflectionHelper.Functions.String.Like22) predicate = ConvertLikePredicate(context, e); - - if (predicate != null) - return Convert(context, predicate); - - break; - } + v = Map.EnumToValue(v, attrs.Length == 0); + } - case ExpressionType.Conditional : - return Convert(context, - new SqlQuery.Predicate.ExprExpr( + value = new SqlValue(v); + + _constants.Add(expr, value); + + return value; + } + + #endregion + + #region Build Parameter + + readonly Dictionary _parameters = new Dictionary(); + + public readonly HashSet AsParameters = new HashSet(); + + ParameterAccessor BuildParameter(Expression expr) + { + ParameterAccessor p; + + if (_parameters.TryGetValue(expr, out p)) + return p; + + string name = null; + + var newExpr = ReplaceParameter(_expressionAccessors, expr, nm => name = nm); + var mapper = Expression.Lambda>( + Expression.Convert(newExpr, typeof(object)), + new [] { ExpressionParam, ParametersParam }); + + p = new ParameterAccessor + { + Expression = expr, + Accessor = mapper.Compile(), + SqlParameter = new SqlParameter(expr.Type, name, null, MappingSchema) + }; + + _parameters.Add(expr, p); + CurrentSqlParameters.Add(p); + + return p; + } + + Expression ReplaceParameter(IDictionary expressionAccessors, Expression expression, Action setName) + { + return expression.Convert(expr => + { + if (expr.NodeType == ExpressionType.Constant) + { + var c = (ConstantExpression)expr; + + if (!ExpressionHelper.IsConstant(expr.Type) || AsParameters.Contains(c)) + { + Expression val; + + if (expressionAccessors.TryGetValue(expr, out val)) + { + expr = Expression.Convert(val, expr.Type); + + if (expression.NodeType == ExpressionType.MemberAccess) + { + var ma = (MemberExpression)expression; + setName(ma.Member.Name); + } + } + } + } + + return expr; + }); + } + + #endregion + + #region Predicate Converter + + ISqlPredicate ConvertPredicate(IBuildContext context, Expression expression) + { + switch (expression.NodeType) + { + case ExpressionType.Equal : + case ExpressionType.NotEqual : + case ExpressionType.GreaterThan : + case ExpressionType.GreaterThanOrEqual : + case ExpressionType.LessThan : + case ExpressionType.LessThanOrEqual : + { + var e = (BinaryExpression)expression; + return ConvertCompare(context, expression.NodeType, e.Left, e.Right); + } + + case ExpressionType.Call : + { + var e = (MethodCallExpression)expression; + + ISqlPredicate predicate = null; + + if (e.Method.Name == "Equals" && e.Object != null && e.Arguments.Count == 1) + return ConvertCompare(context, ExpressionType.Equal, e.Object, e.Arguments[0]); + + if (e.Method.DeclaringType == typeof(string)) + { + switch (e.Method.Name) + { + case "Contains" : predicate = ConvertLikePredicate(context, e, "%", "%"); break; + case "StartsWith" : predicate = ConvertLikePredicate(context, e, "", "%"); break; + case "EndsWith" : predicate = ConvertLikePredicate(context, e, "%", ""); break; + } + } + else if (e.Method.Name == "Contains") + { + if (e.Method.DeclaringType == typeof(Enumerable) || + TypeHelper.IsSameOrParent(typeof(IList), e.Method.DeclaringType) || + TypeHelper.IsSameOrParent(typeof(ICollection<>), e.Method.DeclaringType)) + { + predicate = ConvertInPredicate(context, e); + } + } + else if (e.Method.Name == "ContainsValue" && TypeHelper.IsSameOrParent(typeof(Dictionary<,>), e.Method.DeclaringType)) + { + var args = TypeHelper.GetGenericArguments(e.Method.DeclaringType, typeof(Dictionary<,>)); + var minf = EnumerableMethods + .First(m => m.Name == "Contains" && m.GetParameters().Length == 2) + .MakeGenericMethod(args[1]); + + var expr = Expression.Call( + minf, + Expression.PropertyOrField(e.Object, "Values"), + e.Arguments[0]); + + predicate = ConvertInPredicate(context, expr); + } + else if (e.Method.Name == "ContainsKey" && TypeHelper.IsSameOrParent(typeof(IDictionary<,>), e.Method.DeclaringType)) + { + var args = TypeHelper.GetGenericArguments(e.Method.DeclaringType, typeof(IDictionary<,>)); + var minf = EnumerableMethods + .First(m => m.Name == "Contains" && m.GetParameters().Length == 2) + .MakeGenericMethod(args[0]); + + var expr = Expression.Call( + minf, + Expression.PropertyOrField(e.Object, "Keys"), + e.Arguments[0]); + + predicate = ConvertInPredicate(context, expr); + } +#if !SILVERLIGHT + else if (e.Method == ReflectionHelper.Functions.String.Like11) predicate = ConvertLikePredicate(context, e); + else if (e.Method == ReflectionHelper.Functions.String.Like12) predicate = ConvertLikePredicate(context, e); +#endif + else if (e.Method == ReflectionHelper.Functions.String.Like21) predicate = ConvertLikePredicate(context, e); + else if (e.Method == ReflectionHelper.Functions.String.Like22) predicate = ConvertLikePredicate(context, e); + + if (predicate != null) + return Convert(context, predicate); + + break; + } + + case ExpressionType.Conditional : + return Convert(context, + new SqlQuery.Predicate.ExprExpr( ConvertToSql(context, expression, false), - SqlQuery.Predicate.Operator.Equal, - new SqlValue(true))); - - case ExpressionType.MemberAccess : - { - var e = (MemberExpression)expression; - - if (e.Member.Name == "HasValue" && - e.Member.DeclaringType.IsGenericType && - e.Member.DeclaringType.GetGenericTypeDefinition() == typeof(Nullable<>)) - { + SqlQuery.Predicate.Operator.Equal, + new SqlValue(true))); + + case ExpressionType.MemberAccess : + { + var e = (MemberExpression)expression; + + if (e.Member.Name == "HasValue" && + e.Member.DeclaringType.IsGenericType && + e.Member.DeclaringType.GetGenericTypeDefinition() == typeof(Nullable<>)) + { var expr = ConvertToSql(context, e.Expression, false); - return Convert(context, new SqlQuery.Predicate.IsNull(expr, true)); - } - - break; - } - - case ExpressionType.TypeIs: - { - var e = (TypeBinaryExpression)expression; - var ctx = GetContext(context, e.Expression); - - if (ctx != null && ctx.IsExpression(e.Expression, 0, RequestFor.Table).Result) - return MakeIsPredicate(ctx, e); - - break; - } - } - + return Convert(context, new SqlQuery.Predicate.IsNull(expr, true)); + } + + break; + } + + case ExpressionType.TypeIs: + { + var e = (TypeBinaryExpression)expression; + var ctx = GetContext(context, e.Expression); + + if (ctx != null && ctx.IsExpression(e.Expression, 0, RequestFor.Table).Result) + return MakeIsPredicate(ctx, e); + + break; + } + } + var ex = ConvertToSql(context, expression, false); - - if (SqlExpression.NeedsEqual(ex)) - return Convert(context, new SqlQuery.Predicate.ExprExpr(ex, SqlQuery.Predicate.Operator.Equal, new SqlValue(true))); - - return Convert(context, new SqlQuery.Predicate.Expr(ex)); - } - - #region ConvertCompare - - ISqlPredicate ConvertCompare(IBuildContext context, ExpressionType nodeType, Expression left, Expression right) - { - if (left.NodeType == ExpressionType.Convert && left.Type == typeof(int) && right.NodeType == ExpressionType.Constant) - { - var conv = (UnaryExpression)left; - - if (conv.Operand.Type == typeof(char)) - { - left = conv.Operand; - right = Expression.Constant(ConvertTo.From(((ConstantExpression)right).Value)); - } - } - - if (right.NodeType == ExpressionType.Convert && right.Type == typeof(int) && left.NodeType == ExpressionType.Constant) - { - var conv = (UnaryExpression)right; - - if (conv.Operand.Type == typeof(char)) - { - right = conv.Operand; - left = Expression.Constant(ConvertTo.From(((ConstantExpression)left).Value)); - } - } - - #region special case for char? - + + if (SqlExpression.NeedsEqual(ex)) + return Convert(context, new SqlQuery.Predicate.ExprExpr(ex, SqlQuery.Predicate.Operator.Equal, new SqlValue(true))); + + return Convert(context, new SqlQuery.Predicate.Expr(ex)); + } + + #region ConvertCompare + + ISqlPredicate ConvertCompare(IBuildContext context, ExpressionType nodeType, Expression left, Expression right) + { + if (left.NodeType == ExpressionType.Convert && left.Type == typeof(int) && right.NodeType == ExpressionType.Constant) + { + var conv = (UnaryExpression)left; + + if (conv.Operand.Type == typeof(char)) + { + left = conv.Operand; + right = Expression.Constant(ConvertTo.From(((ConstantExpression)right).Value)); + } + } + + if (right.NodeType == ExpressionType.Convert && right.Type == typeof(int) && left.NodeType == ExpressionType.Constant) + { + var conv = (UnaryExpression)right; + + if (conv.Operand.Type == typeof(char)) + { + right = conv.Operand; + left = Expression.Constant(ConvertTo.From(((ConstantExpression)left).Value)); + } + } + + #region special case for char? + // if (left.NodeType == ExpressionType.Convert && left.Type == typeof(int?) && right.NodeType == ExpressionType.Convert) // { // var convLeft = left as UnaryExpression; @@ -1301,981 +1301,986 @@ ISqlPredicate ConvertCompare(IBuildContext context, ExpressionType nodeType, Exp // right = Expression.Constant(ConvertTo.From(((ConstantExpression)convRight.Operand).Value)); // } // } - - #endregion - - switch (nodeType) - { - case ExpressionType.Equal : - case ExpressionType.NotEqual : - - var p = ConvertObjectComparison(nodeType, context, left, context, right); - if (p != null) - return p; - - p = ConvertObjectNullComparison(context, left, right, nodeType == ExpressionType.Equal); - if (p != null) - return p; - - p = ConvertObjectNullComparison(context, right, left, nodeType == ExpressionType.Equal); - if (p != null) - return p; - - if (left.NodeType == ExpressionType.New || right.NodeType == ExpressionType.New) - { - p = ConvertNewObjectComparison(context, nodeType, left, right); - if (p != null) - return p; - } - - break; - } - - SqlQuery.Predicate.Operator op; - - switch (nodeType) - { - case ExpressionType.Equal : op = SqlQuery.Predicate.Operator.Equal; break; - case ExpressionType.NotEqual : op = SqlQuery.Predicate.Operator.NotEqual; break; - case ExpressionType.GreaterThan : op = SqlQuery.Predicate.Operator.Greater; break; - case ExpressionType.GreaterThanOrEqual: op = SqlQuery.Predicate.Operator.GreaterOrEqual; break; - case ExpressionType.LessThan : op = SqlQuery.Predicate.Operator.Less; break; - case ExpressionType.LessThanOrEqual : op = SqlQuery.Predicate.Operator.LessOrEqual; break; - default: throw new InvalidOperationException(); - } - - if (left.NodeType == ExpressionType.Convert || right.NodeType == ExpressionType.Convert + + #endregion + + switch (nodeType) + { + case ExpressionType.Equal : + case ExpressionType.NotEqual : + + var p = ConvertObjectComparison(nodeType, context, left, context, right); + if (p != null) + return p; + + p = ConvertObjectNullComparison(context, left, right, nodeType == ExpressionType.Equal); + if (p != null) + return p; + + p = ConvertObjectNullComparison(context, right, left, nodeType == ExpressionType.Equal); + if (p != null) + return p; + + if (left.NodeType == ExpressionType.New || right.NodeType == ExpressionType.New) + { + p = ConvertNewObjectComparison(context, nodeType, left, right); + if (p != null) + return p; + } + + break; + } + + SqlQuery.Predicate.Operator op; + + switch (nodeType) + { + case ExpressionType.Equal : op = SqlQuery.Predicate.Operator.Equal; break; + case ExpressionType.NotEqual : op = SqlQuery.Predicate.Operator.NotEqual; break; + case ExpressionType.GreaterThan : op = SqlQuery.Predicate.Operator.Greater; break; + case ExpressionType.GreaterThanOrEqual: op = SqlQuery.Predicate.Operator.GreaterOrEqual; break; + case ExpressionType.LessThan : op = SqlQuery.Predicate.Operator.Less; break; + case ExpressionType.LessThanOrEqual : op = SqlQuery.Predicate.Operator.LessOrEqual; break; + default: throw new InvalidOperationException(); + } + + if (left.NodeType == ExpressionType.Convert || right.NodeType == ExpressionType.Convert || left.NodeType == ExpressionType.MemberAccess || right.NodeType == ExpressionType.MemberAccess) - { - var p = ConvertEnumConversion(context, left, op, right); - if (p != null) - return p; - } - + { + var p = ConvertEnumConversion(context, left, op, right); + if (p != null) + return p; + } + var l = ConvertToSql(context, left, false); - var r = ConvertToSql(context, right, true); - - switch (nodeType) - { - case ExpressionType.Equal : - case ExpressionType.NotEqual: - - if (!context.SqlQuery.IsParameterDependent && (l is SqlParameter || r is SqlParameter) && l.CanBeNull() && r.CanBeNull()) - context.SqlQuery.IsParameterDependent = true; - - // | (SqlQuery(Select([]) as q), SqlValue(null)) - // | (SqlValue(null), SqlQuery(Select([]) as q)) => - - SqlQuery q = - l.ElementType == QueryElementType.SqlQuery && - r.ElementType == QueryElementType.SqlValue && - ((SqlValue)r).Value == null && - ((SqlQuery)l).Select.Columns.Count == 0 ? - (SqlQuery)l : - r.ElementType == QueryElementType.SqlQuery && - l.ElementType == QueryElementType.SqlValue && - ((SqlValue)l).Value == null && - ((SqlQuery)r).Select.Columns.Count == 0 ? - (SqlQuery)r : - null; - - if (q != null) - { - q.Select.Columns.Add(new SqlQuery.Column(q, new SqlValue(1))); - } - - break; - } - - if (l is SqlQuery.SearchCondition) - l = Convert(context, new SqlFunction(typeof(bool), "CASE", l, new SqlValue(true), new SqlValue(false))); - - if (r is SqlQuery.SearchCondition) - r = Convert(context, new SqlFunction(typeof(bool), "CASE", r, new SqlValue(true), new SqlValue(false))); - - return Convert(context, new SqlQuery.Predicate.ExprExpr(l, op, r)); - } - - #endregion - - #region ConvertEnumConversion - - ISqlPredicate ConvertEnumConversion(IBuildContext context, Expression left, SqlQuery.Predicate.Operator op, Expression right) - { - Expression value; - Expression operand; - - if (left is MemberExpression) - { - operand = left; - value = right; - } - else if (left.NodeType == ExpressionType.Convert && ((UnaryExpression)left).Operand is MemberExpression) - { - operand = ((UnaryExpression)left).Operand; - value = right; - } - else if (right is MemberExpression) - { - operand = right; - value = left; - } - else if (right.NodeType == ExpressionType.Convert && ((UnaryExpression)right).Operand is MemberExpression) - { - operand = ((UnaryExpression)right).Operand; - value = left; - } - else if (left.NodeType == ExpressionType.Convert) - { - operand = ((UnaryExpression)left).Operand; - value = right; - } - else - { - operand = ((UnaryExpression)right).Operand; - value = left; - } - - var type = operand.Type; - - if (!TypeHelper.IsEnumOrNullableEnum(type)) - return null; - - var dic = new Dictionary(); - - var nullValue = MappingSchema.GetNullValue(type); - - if (nullValue != null) - dic.Add(nullValue, null); - - var mapValues = MappingSchema.GetMapValues(type); - - if (mapValues != null) - foreach (var mv in mapValues) - if (!dic.ContainsKey(mv.OrigValue)) - dic.Add(mv.OrigValue, mv.MapValues[0]); - - switch (value.NodeType) - { - case ExpressionType.Constant: - { - var name = Enum.GetName(type, ((ConstantExpression)value).Value); - -// ReSharper disable ConditionIsAlwaysTrueOrFalse -// ReSharper disable HeuristicUnreachableCode - if (name == null) - return null; -// ReSharper restore HeuristicUnreachableCode -// ReSharper restore ConditionIsAlwaysTrueOrFalse - - var origValue = Enum.Parse(type, name, false); - var mapValue = origValue; - - if (!(operand is MemberExpression)) - { - if (!dic.TryGetValue(origValue, out mapValue)) - return null; - } - - ISqlExpression l, r; - - SqlValue sqlValue; - - if (left.NodeType == ExpressionType.Convert) - { + var r = ConvertToSql(context, right, true); + + if (l is SqlField && r is SqlParameter) + { + ((SqlParameter) r).DbType = ((SqlField) l).MemberMapper.DbType; + } + + switch (nodeType) + { + case ExpressionType.Equal : + case ExpressionType.NotEqual: + + if (!context.SqlQuery.IsParameterDependent && (l is SqlParameter || r is SqlParameter) && l.CanBeNull() && r.CanBeNull()) + context.SqlQuery.IsParameterDependent = true; + + // | (SqlQuery(Select([]) as q), SqlValue(null)) + // | (SqlValue(null), SqlQuery(Select([]) as q)) => + + SqlQuery q = + l.ElementType == QueryElementType.SqlQuery && + r.ElementType == QueryElementType.SqlValue && + ((SqlValue)r).Value == null && + ((SqlQuery)l).Select.Columns.Count == 0 ? + (SqlQuery)l : + r.ElementType == QueryElementType.SqlQuery && + l.ElementType == QueryElementType.SqlValue && + ((SqlValue)l).Value == null && + ((SqlQuery)r).Select.Columns.Count == 0 ? + (SqlQuery)r : + null; + + if (q != null) + { + q.Select.Columns.Add(new SqlQuery.Column(q, new SqlValue(1))); + } + + break; + } + + if (l is SqlQuery.SearchCondition) + l = Convert(context, new SqlFunction(typeof(bool), "CASE", l, new SqlValue(true), new SqlValue(false))); + + if (r is SqlQuery.SearchCondition) + r = Convert(context, new SqlFunction(typeof(bool), "CASE", r, new SqlValue(true), new SqlValue(false))); + + return Convert(context, new SqlQuery.Predicate.ExprExpr(l, op, r)); + } + + #endregion + + #region ConvertEnumConversion + + ISqlPredicate ConvertEnumConversion(IBuildContext context, Expression left, SqlQuery.Predicate.Operator op, Expression right) + { + Expression value; + Expression operand; + + if (left is MemberExpression) + { + operand = left; + value = right; + } + else if (left.NodeType == ExpressionType.Convert && ((UnaryExpression)left).Operand is MemberExpression) + { + operand = ((UnaryExpression)left).Operand; + value = right; + } + else if (right is MemberExpression) + { + operand = right; + value = left; + } + else if (right.NodeType == ExpressionType.Convert && ((UnaryExpression)right).Operand is MemberExpression) + { + operand = ((UnaryExpression)right).Operand; + value = left; + } + else if (left.NodeType == ExpressionType.Convert) + { + operand = ((UnaryExpression)left).Operand; + value = right; + } + else + { + operand = ((UnaryExpression)right).Operand; + value = left; + } + + var type = operand.Type; + + if (!TypeHelper.IsEnumOrNullableEnum(type)) + return null; + + var dic = new Dictionary(); + + var nullValue = MappingSchema.GetNullValue(type); + + if (nullValue != null) + dic.Add(nullValue, null); + + var mapValues = MappingSchema.GetMapValues(type); + + if (mapValues != null) + foreach (var mv in mapValues) + if (!dic.ContainsKey(mv.OrigValue)) + dic.Add(mv.OrigValue, mv.MapValues[0]); + + switch (value.NodeType) + { + case ExpressionType.Constant: + { + var name = Enum.GetName(type, ((ConstantExpression)value).Value); + +// ReSharper disable ConditionIsAlwaysTrueOrFalse +// ReSharper disable HeuristicUnreachableCode + if (name == null) + return null; +// ReSharper restore HeuristicUnreachableCode +// ReSharper restore ConditionIsAlwaysTrueOrFalse + + var origValue = Enum.Parse(type, name, false); + var mapValue = origValue; + + if (!(operand is MemberExpression)) + { + if (!dic.TryGetValue(origValue, out mapValue)) + return null; + } + + ISqlExpression l, r; + + SqlValue sqlValue; + + if (left.NodeType == ExpressionType.Convert) + { l = ConvertToSql(context, operand, false); - r = sqlValue = new SqlValue(mapValue); - } - else - { + r = sqlValue = new SqlValue(mapValue); + } + else + { r = ConvertToSql(context, operand, false); - l = sqlValue = new SqlValue(mapValue); - } - - if (operand is MemberExpression) - { - var me = (MemberExpression)operand; - var memberAccessor = TypeAccessor.GetAccessor(me.Member.DeclaringType)[me.Member.Name]; - sqlValue.SetEnumConverter(memberAccessor, MappingSchema); - } - - - return Convert(context, new SqlQuery.Predicate.ExprExpr(l, op, r)); - } - - case ExpressionType.Convert: - { - value = ((UnaryExpression)value).Operand; - + l = sqlValue = new SqlValue(mapValue); + } + + if (operand is MemberExpression) + { + var me = (MemberExpression)operand; + var memberAccessor = TypeAccessor.GetAccessor(me.Member.DeclaringType)[me.Member.Name]; + sqlValue.SetEnumConverter(memberAccessor, MappingSchema); + } + + + return Convert(context, new SqlQuery.Predicate.ExprExpr(l, op, r)); + } + + case ExpressionType.Convert: + { + value = ((UnaryExpression)value).Operand; + var l = ConvertToSql(context, operand, false, false); var r = ConvertToSql(context, value, false, false); + + MemberAccessor memberAccessor = null; + + if (operand is MemberExpression) + { + // is it even possible that operand is not MemberExpression? + // if no, then we can remove this two last uses of SetEnumConverter(type, map) + // and other depending code + // At least currently there is no test coverage for this method and I didn't + // manage to create such test + var me = (MemberExpression)operand; + memberAccessor = TypeAccessor.GetAccessor(me.Member.DeclaringType)[me.Member.Name]; + } + + if (l is SqlValueBase) + { + if (memberAccessor != null) + { + ((SqlValueBase)l).SetEnumConverter(memberAccessor, MappingSchema); + } + else + { + ((SqlValueBase)l).SetEnumConverter(type, MappingSchema); + } + } - MemberAccessor memberAccessor = null; - - if (operand is MemberExpression) - { - // is it even possible that operand is not MemberExpression? - // if no, then we can remove this two last uses of SetEnumConverter(type, map) - // and other depending code - // At least currently there is no test coverage for this method and I didn't - // manage to create such test - var me = (MemberExpression)operand; - memberAccessor = TypeAccessor.GetAccessor(me.Member.DeclaringType)[me.Member.Name]; - } - - if (l is SqlValueBase) - { - if (memberAccessor != null) - { - ((SqlValueBase)l).SetEnumConverter(memberAccessor, MappingSchema); - } - else - { - ((SqlValueBase)l).SetEnumConverter(type, MappingSchema); - } - } - - if (r is SqlValueBase) - { - if (memberAccessor != null) - { - ((SqlValueBase)r).SetEnumConverter(memberAccessor, MappingSchema); - } - else - { - ((SqlValueBase)r).SetEnumConverter(type, MappingSchema); - } - } - - return Convert(context, new SqlQuery.Predicate.ExprExpr(l, op, r)); - } - } - - return null; - } - - #endregion - - #region ConvertObjectNullComparison - - ISqlPredicate ConvertObjectNullComparison(IBuildContext context, Expression left, Expression right, bool isEqual) - { - if (right.NodeType == ExpressionType.Constant && ((ConstantExpression)right).Value == null) - { - if (left.NodeType == ExpressionType.MemberAccess || left.NodeType == ExpressionType.Parameter) - { - var ctx = GetContext(context, left); - - if (ctx != null && ctx.IsExpression(left, 0, RequestFor.Object).Result || - left.NodeType == ExpressionType.Parameter && ctx.IsExpression(left, 0, RequestFor.Field).Result) - { - return new SqlQuery.Predicate.Expr(new SqlValue(!isEqual)); - } - } - } - - return null; - } - - #endregion - - #region ConvertObjectComparison - - public ISqlPredicate ConvertObjectComparison( - ExpressionType nodeType, - IBuildContext leftContext, - Expression left, - IBuildContext rightContext, - Expression right) - { - var qsl = GetContext(leftContext, left); - var qsr = GetContext(rightContext, right); - - var sl = qsl != null && qsl.IsExpression(left, 0, RequestFor.Object).Result; - var sr = qsr != null && qsr.IsExpression(right, 0, RequestFor.Object).Result; - - bool isNull; - SqlInfo[] lcols; - - var rmembers = new Dictionary(new MemberInfoComparer()); - - if (sl == false && sr == false) - { - var lmembers = new Dictionary(new MemberInfoComparer()); - - if (!ProcessProjection(lmembers, left) && !ProcessProjection(rmembers, right)) - return null; - - if (lmembers.Count == 0) - { - var r = right; - right = left; - left = r; - - var c = rightContext; - rightContext = leftContext; - leftContext = c; - - var q = qsr; - qsl = q; - - sr = false; - - var lm = lmembers; - lmembers = rmembers; - rmembers = lm; - } - - isNull = right is ConstantExpression && ((ConstantExpression)right).Value == null; + if (r is SqlValueBase) + { + if (memberAccessor != null) + { + ((SqlValueBase)r).SetEnumConverter(memberAccessor, MappingSchema); + } + else + { + ((SqlValueBase)r).SetEnumConverter(type, MappingSchema); + } + } + + return Convert(context, new SqlQuery.Predicate.ExprExpr(l, op, r)); + } + } + + return null; + } + + #endregion + + #region ConvertObjectNullComparison + + ISqlPredicate ConvertObjectNullComparison(IBuildContext context, Expression left, Expression right, bool isEqual) + { + if (right.NodeType == ExpressionType.Constant && ((ConstantExpression)right).Value == null) + { + if (left.NodeType == ExpressionType.MemberAccess || left.NodeType == ExpressionType.Parameter) + { + var ctx = GetContext(context, left); + + if (ctx != null && ctx.IsExpression(left, 0, RequestFor.Object).Result || + left.NodeType == ExpressionType.Parameter && ctx.IsExpression(left, 0, RequestFor.Field).Result) + { + return new SqlQuery.Predicate.Expr(new SqlValue(!isEqual)); + } + } + } + + return null; + } + + #endregion + + #region ConvertObjectComparison + + public ISqlPredicate ConvertObjectComparison( + ExpressionType nodeType, + IBuildContext leftContext, + Expression left, + IBuildContext rightContext, + Expression right) + { + var qsl = GetContext(leftContext, left); + var qsr = GetContext(rightContext, right); + + var sl = qsl != null && qsl.IsExpression(left, 0, RequestFor.Object).Result; + var sr = qsr != null && qsr.IsExpression(right, 0, RequestFor.Object).Result; + + bool isNull; + SqlInfo[] lcols; + + var rmembers = new Dictionary(new MemberInfoComparer()); + + if (sl == false && sr == false) + { + var lmembers = new Dictionary(new MemberInfoComparer()); + + if (!ProcessProjection(lmembers, left) && !ProcessProjection(rmembers, right)) + return null; + + if (lmembers.Count == 0) + { + var r = right; + right = left; + left = r; + + var c = rightContext; + rightContext = leftContext; + leftContext = c; + + var q = qsr; + qsl = q; + + sr = false; + + var lm = lmembers; + lmembers = rmembers; + rmembers = lm; + } + + isNull = right is ConstantExpression && ((ConstantExpression)right).Value == null; lcols = lmembers.Select(m => new SqlInfo(m.Key) { Sql = ConvertToSql(leftContext, m.Value, false) }).ToArray(); - } - else - { - if (sl == false) - { - var r = right; - right = left; - left = r; - - var c = rightContext; - rightContext = leftContext; - leftContext = c; - - var q = qsr; - qsl = q; - - sr = false; - } - - isNull = right is ConstantExpression && ((ConstantExpression)right).Value == null; - lcols = qsl.ConvertToSql(left, 0, ConvertFlags.Key); - - if (!sr) - ProcessProjection(rmembers, right); - } - - if (lcols.Length == 0) - return null; - - var condition = new SqlQuery.SearchCondition(); - - foreach (var lcol in lcols) - { - if (lcol.Members.Count == 0) - throw new InvalidOperationException(); - - ISqlExpression rcol = null; - - var lmember = lcol.Members[lcol.Members.Count - 1]; - - if (sr) - { - var info = rightContext.ConvertToSql(Expression.MakeMemberAccess(right, lmember), 0, ConvertFlags.Field).Single(); - rcol = info.Sql; - } - else - { - if (rmembers.Count != 0) - { - var info = rightContext.ConvertToSql(rmembers[lmember], 0, ConvertFlags.Field)[0]; - rcol = info.Sql; - } - } - - var rex = - isNull ? - new SqlValue(right.Type, null) : - rcol ?? GetParameter(right, lmember); - - var predicate = Convert(leftContext, new SqlQuery.Predicate.ExprExpr( - lcol.Sql, - nodeType == ExpressionType.Equal ? SqlQuery.Predicate.Operator.Equal : SqlQuery.Predicate.Operator.NotEqual, - rex)); - - condition.Conditions.Add(new SqlQuery.Condition(false, predicate)); - } - - if (nodeType == ExpressionType.NotEqual) - foreach (var c in condition.Conditions) - c.IsOr = true; - - return condition; - } - - ISqlPredicate ConvertNewObjectComparison(IBuildContext context, ExpressionType nodeType, Expression left, Expression right) - { - left = FindExpression(left); - right = FindExpression(right); - - var condition = new SqlQuery.SearchCondition(); - - if (left.NodeType != ExpressionType.New) - { - var temp = left; - left = right; - right = temp; - } - - var newRight = right as NewExpression; - var newExpr = (NewExpression)left; - -// ReSharper disable ConditionIsAlwaysTrueOrFalse -// ReSharper disable HeuristicUnreachableCode - if (newExpr.Members == null) - return null; -// ReSharper restore HeuristicUnreachableCode -// ReSharper restore ConditionIsAlwaysTrueOrFalse - - for (var i = 0; i < newExpr.Arguments.Count; i++) - { + } + else + { + if (sl == false) + { + var r = right; + right = left; + left = r; + + var c = rightContext; + rightContext = leftContext; + leftContext = c; + + var q = qsr; + qsl = q; + + sr = false; + } + + isNull = right is ConstantExpression && ((ConstantExpression)right).Value == null; + lcols = qsl.ConvertToSql(left, 0, ConvertFlags.Key); + + if (!sr) + ProcessProjection(rmembers, right); + } + + if (lcols.Length == 0) + return null; + + var condition = new SqlQuery.SearchCondition(); + + foreach (var lcol in lcols) + { + if (lcol.Members.Count == 0) + throw new InvalidOperationException(); + + ISqlExpression rcol = null; + + var lmember = lcol.Members[lcol.Members.Count - 1]; + + if (sr) + { + var info = rightContext.ConvertToSql(Expression.MakeMemberAccess(right, lmember), 0, ConvertFlags.Field).Single(); + rcol = info.Sql; + } + else + { + if (rmembers.Count != 0) + { + var info = rightContext.ConvertToSql(rmembers[lmember], 0, ConvertFlags.Field)[0]; + rcol = info.Sql; + } + } + + var rex = + isNull ? + new SqlValue(right.Type, null) : + rcol ?? GetParameter(right, lmember); + + var predicate = Convert(leftContext, new SqlQuery.Predicate.ExprExpr( + lcol.Sql, + nodeType == ExpressionType.Equal ? SqlQuery.Predicate.Operator.Equal : SqlQuery.Predicate.Operator.NotEqual, + rex)); + + condition.Conditions.Add(new SqlQuery.Condition(false, predicate)); + } + + if (nodeType == ExpressionType.NotEqual) + foreach (var c in condition.Conditions) + c.IsOr = true; + + return condition; + } + + ISqlPredicate ConvertNewObjectComparison(IBuildContext context, ExpressionType nodeType, Expression left, Expression right) + { + left = FindExpression(left); + right = FindExpression(right); + + var condition = new SqlQuery.SearchCondition(); + + if (left.NodeType != ExpressionType.New) + { + var temp = left; + left = right; + right = temp; + } + + var newRight = right as NewExpression; + var newExpr = (NewExpression)left; + +// ReSharper disable ConditionIsAlwaysTrueOrFalse +// ReSharper disable HeuristicUnreachableCode + if (newExpr.Members == null) + return null; +// ReSharper restore HeuristicUnreachableCode +// ReSharper restore ConditionIsAlwaysTrueOrFalse + + for (var i = 0; i < newExpr.Arguments.Count; i++) + { var lex = ConvertToSql(context, newExpr.Arguments[i], false); - var rex = - newRight != null ? + var rex = + newRight != null ? ConvertToSql(context, newRight.Arguments[i], false) : - GetParameter(right, newExpr.Members[i]); - - var predicate = Convert(context, - new SqlQuery.Predicate.ExprExpr( - lex, - nodeType == ExpressionType.Equal ? SqlQuery.Predicate.Operator.Equal : SqlQuery.Predicate.Operator.NotEqual, - rex)); - - condition.Conditions.Add(new SqlQuery.Condition(false, predicate)); - } - - if (nodeType == ExpressionType.NotEqual) - foreach (var c in condition.Conditions) - c.IsOr = true; - - return condition; - } - - ISqlExpression GetParameter(Expression ex, MemberInfo member) - { - if (member is MethodInfo) - member = TypeHelper.GetPropertyByMethod((MethodInfo)member); - - var par = ReplaceParameter(_expressionAccessors, ex, _ => {}); - var expr = Expression.MakeMemberAccess(par.Type == typeof(object) ? Expression.Convert(par, member.DeclaringType) : par, member); - var mapper = Expression.Lambda>( - Expression.Convert(expr, typeof(object)), - new [] { ExpressionParam, ParametersParam }); - - var p = new ParameterAccessor - { - Expression = expr, - Accessor = mapper.Compile(), - SqlParameter = new SqlParameter(expr.Type, member.Name, null, MappingSchema) - }; - - _parameters.Add(expr, p); - CurrentSqlParameters.Add(p); - - return p.SqlParameter; - } - - static Expression FindExpression(Expression expr) - { - var ret = expr.Find(pi => - { - switch (pi.NodeType) - { - case ExpressionType.Convert : - { - var e = (UnaryExpression)expr; - - return - e.Operand.NodeType == ExpressionType.ArrayIndex && - ((BinaryExpression)e.Operand).Left == ParametersParam; - } - - case ExpressionType.MemberAccess : - case ExpressionType.New : - return true; - } - - return false; - }); - - if (ret == null) - throw new InvalidOperationException(); - - return ret; - } - - #endregion - - #region ConvertInPredicate - - private ISqlPredicate ConvertInPredicate(IBuildContext context, MethodCallExpression expression) - { - var e = expression; - var argIndex = e.Object != null ? 0 : 1; - var arr = e.Object ?? e.Arguments[0]; - var arg = e.Arguments[argIndex]; - - ISqlExpression expr = null; - - var ctx = GetContext(context, arg); - - if (ctx is TableBuilder.TableContext && - ctx.SqlQuery != context.SqlQuery && - ctx.IsExpression(arg, 0, RequestFor.Object).Result) - { - expr = ctx.SqlQuery; - } - - if (expr == null) - { - var sql = ConvertExpressions(context, arg, ConvertFlags.Key); - - if (sql.Length == 1 && sql[0].Members.Count == 0) - expr = sql[0].Sql; - else - expr = new SqlExpression( - '\x1' + string.Join(",", sql.Select(s => s.Members[s.Members.Count - 1].Name).ToArray()), - sql.Select(s => s.Sql).ToArray()); + GetParameter(right, newExpr.Members[i]); + + var predicate = Convert(context, + new SqlQuery.Predicate.ExprExpr( + lex, + nodeType == ExpressionType.Equal ? SqlQuery.Predicate.Operator.Equal : SqlQuery.Predicate.Operator.NotEqual, + rex)); + + condition.Conditions.Add(new SqlQuery.Condition(false, predicate)); } - MemberAccessor memberAccessor = null; + if (nodeType == ExpressionType.NotEqual) + foreach (var c in condition.Conditions) + c.IsOr = true; + + return condition; + } + + ISqlExpression GetParameter(Expression ex, MemberInfo member) + { + if (member is MethodInfo) + member = TypeHelper.GetPropertyByMethod((MethodInfo)member); + + var par = ReplaceParameter(_expressionAccessors, ex, _ => {}); + var expr = Expression.MakeMemberAccess(par.Type == typeof(object) ? Expression.Convert(par, member.DeclaringType) : par, member); + var mapper = Expression.Lambda>( + Expression.Convert(expr, typeof(object)), + new [] { ExpressionParam, ParametersParam }); + + var p = new ParameterAccessor + { + Expression = expr, + Accessor = mapper.Compile(), + SqlParameter = new SqlParameter(expr.Type, member.Name, null, MappingSchema) + }; + + _parameters.Add(expr, p); + CurrentSqlParameters.Add(p); - if (arg is MemberExpression) + return p.SqlParameter; + } + + static Expression FindExpression(Expression expr) + { + var ret = expr.Find(pi => { - var me = (MemberExpression)arg; - if (TypeHelper.IsEnumOrNullableEnum(me.Type)) + switch (pi.NodeType) { - memberAccessor = TypeAccessor.GetAccessor(me.Member.DeclaringType)[me.Member.Name]; + case ExpressionType.Convert : + { + var e = (UnaryExpression)expr; + + return + e.Operand.NodeType == ExpressionType.ArrayIndex && + ((BinaryExpression)e.Operand).Left == ParametersParam; + } + + case ExpressionType.MemberAccess : + case ExpressionType.New : + return true; } + + return false; + }); + + if (ret == null) + throw new InvalidOperationException(); + + return ret; + } + + #endregion + + #region ConvertInPredicate + + private ISqlPredicate ConvertInPredicate(IBuildContext context, MethodCallExpression expression) + { + var e = expression; + var argIndex = e.Object != null ? 0 : 1; + var arr = e.Object ?? e.Arguments[0]; + var arg = e.Arguments[argIndex]; + + ISqlExpression expr = null; + + var ctx = GetContext(context, arg); + + if (ctx is TableBuilder.TableContext && + ctx.SqlQuery != context.SqlQuery && + ctx.IsExpression(arg, 0, RequestFor.Object).Result) + { + expr = ctx.SqlQuery; } - - switch (arr.NodeType) - { - case ExpressionType.NewArrayInit : - { - var newArr = (NewArrayExpression)arr; - - if (newArr.Expressions.Count == 0) - return new SqlQuery.Predicate.Expr(new SqlValue(false)); - - var exprs = new ISqlExpression[newArr.Expressions.Count]; + + if (expr == null) + { + var sql = ConvertExpressions(context, arg, ConvertFlags.Key); + + if (sql.Length == 1 && sql[0].Members.Count == 0) + expr = sql[0].Sql; + else + expr = new SqlExpression( + '\x1' + string.Join(",", sql.Select(s => s.Members[s.Members.Count - 1].Name).ToArray()), + sql.Select(s => s.Sql).ToArray()); + } + + MemberAccessor memberAccessor = null; - for (var i = 0; i < newArr.Expressions.Count; i++) - { + if (arg is MemberExpression) + { + var me = (MemberExpression)arg; + if (TypeHelper.IsEnumOrNullableEnum(me.Type)) + { + memberAccessor = TypeAccessor.GetAccessor(me.Member.DeclaringType)[me.Member.Name]; + } + } + + switch (arr.NodeType) + { + case ExpressionType.NewArrayInit : + { + var newArr = (NewArrayExpression)arr; + + if (newArr.Expressions.Count == 0) + return new SqlQuery.Predicate.Expr(new SqlValue(false)); + + var exprs = new ISqlExpression[newArr.Expressions.Count]; + + for (var i = 0; i < newArr.Expressions.Count; i++) + { exprs[i] = ConvertToSql(context, newArr.Expressions[i], false, false); - if (memberAccessor != null && exprs[i] is SqlValue) - { - ((SqlValue)exprs[i]).SetEnumConverter(memberAccessor, MappingSchema); - } - } - - return new SqlQuery.Predicate.InList(expr, false, exprs); - } - - default : - - if (CanBeCompiled(arr)) - { - var p = BuildParameter(arr).SqlParameter; + if (memberAccessor != null && exprs[i] is SqlValue) + { + ((SqlValue)exprs[i]).SetEnumConverter(memberAccessor, MappingSchema); + } + } + + return new SqlQuery.Predicate.InList(expr, false, exprs); + } + + default : + + if (CanBeCompiled(arr)) + { + var p = BuildParameter(arr).SqlParameter; p.IsQueryParameter = false; - if (memberAccessor != null) - { - p.SetEnumConverter(memberAccessor, MappingSchema); + if (memberAccessor != null) + { + p.SetEnumConverter(memberAccessor, MappingSchema); } - return new SqlQuery.Predicate.InList(expr, false, p); - } - - break; - } - - throw new LinqException("'{0}' cannot be converted to SQL.", expression); - } - - #endregion - - #region LIKE predicate - - ISqlPredicate ConvertLikePredicate(IBuildContext context, MethodCallExpression expression, string start, string end) - { - var e = expression; + return new SqlQuery.Predicate.InList(expr, false, p); + } + + break; + } + + throw new LinqException("'{0}' cannot be converted to SQL.", expression); + } + + #endregion + + #region LIKE predicate + + ISqlPredicate ConvertLikePredicate(IBuildContext context, MethodCallExpression expression, string start, string end) + { + var e = expression; var o = ConvertToSql(context, e.Object, false); var a = ConvertToSql(context, e.Arguments[0], false); - - if (a is SqlValue) - { - var value = ((SqlValue)a).Value; - - if (value == null) - throw new LinqException("NULL cannot be used as a LIKE predicate parameter."); - - return value.ToString().IndexOfAny(new[] { '%', '_' }) < 0? - new SqlQuery.Predicate.Like(o, false, new SqlValue(start + value + end), null): - new SqlQuery.Predicate.Like(o, false, new SqlValue(start + EscapeLikeText(value.ToString()) + end), new SqlValue('~')); - } - - if (a is SqlParameter) - { - var p = (SqlParameter)a; - var ep = (from pm in CurrentSqlParameters where pm.SqlParameter == p select pm).First(); - - ep = new ParameterAccessor - { - Expression = ep.Expression, - Accessor = ep.Accessor, - SqlParameter = new SqlParameter(ep.Expression.Type, p.Name, p.Value, GetLikeEscaper(start, end)) - }; - - CurrentSqlParameters.Add(ep); - - return new SqlQuery.Predicate.Like(o, false, ep.SqlParameter, new SqlValue('~')); - } - - var mi = ReflectionHelper.Expressor.MethodExpressor(_ => _.Replace("", "")); - var ex = - Expression.Call( - Expression.Call( - Expression.Call( - e.Arguments[0], - mi, Expression.Constant("~"), Expression.Constant("~~")), - mi, Expression.Constant("%"), Expression.Constant("~%")), - mi, Expression.Constant("_"), Expression.Constant("~_")); - + + if (a is SqlValue) + { + var value = ((SqlValue)a).Value; + + if (value == null) + throw new LinqException("NULL cannot be used as a LIKE predicate parameter."); + + return value.ToString().IndexOfAny(new[] { '%', '_' }) < 0? + new SqlQuery.Predicate.Like(o, false, new SqlValue(start + value + end), null): + new SqlQuery.Predicate.Like(o, false, new SqlValue(start + EscapeLikeText(value.ToString()) + end), new SqlValue('~')); + } + + if (a is SqlParameter) + { + var p = (SqlParameter)a; + var ep = (from pm in CurrentSqlParameters where pm.SqlParameter == p select pm).First(); + + ep = new ParameterAccessor + { + Expression = ep.Expression, + Accessor = ep.Accessor, + SqlParameter = new SqlParameter(ep.Expression.Type, p.Name, p.Value, GetLikeEscaper(start, end)) + }; + + CurrentSqlParameters.Add(ep); + + return new SqlQuery.Predicate.Like(o, false, ep.SqlParameter, new SqlValue('~')); + } + + var mi = ReflectionHelper.Expressor.MethodExpressor(_ => _.Replace("", "")); + var ex = + Expression.Call( + Expression.Call( + Expression.Call( + e.Arguments[0], + mi, Expression.Constant("~"), Expression.Constant("~~")), + mi, Expression.Constant("%"), Expression.Constant("~%")), + mi, Expression.Constant("_"), Expression.Constant("~_")); + var expr = ConvertToSql(context, ConvertExpression(ex), false); - - if (!string.IsNullOrEmpty(start)) - expr = new SqlBinaryExpression(typeof(string), new SqlValue("%"), "+", expr); - - if (!string.IsNullOrEmpty(end)) - expr = new SqlBinaryExpression(typeof(string), expr, "+", new SqlValue("%")); - - return new SqlQuery.Predicate.Like(o, false, expr, new SqlValue('~')); - } - - ISqlPredicate ConvertLikePredicate(IBuildContext context, MethodCallExpression expression) - { - var e = expression; + + if (!string.IsNullOrEmpty(start)) + expr = new SqlBinaryExpression(typeof(string), new SqlValue("%"), "+", expr); + + if (!string.IsNullOrEmpty(end)) + expr = new SqlBinaryExpression(typeof(string), expr, "+", new SqlValue("%")); + + return new SqlQuery.Predicate.Like(o, false, expr, new SqlValue('~')); + } + + ISqlPredicate ConvertLikePredicate(IBuildContext context, MethodCallExpression expression) + { + var e = expression; var a1 = ConvertToSql(context, e.Arguments[0], false); var a2 = ConvertToSql(context, e.Arguments[1], false); - - ISqlExpression a3 = null; - - if (e.Arguments.Count == 3) + + ISqlExpression a3 = null; + + if (e.Arguments.Count == 3) a3 = ConvertToSql(context, e.Arguments[2], false); - - return new SqlQuery.Predicate.Like(a1, false, a2, a3); - } - - static string EscapeLikeText(string text) - { - if (text.IndexOfAny(new[] { '%', '_' }) < 0) - return text; - - var builder = new StringBuilder(text.Length); - - foreach (var ch in text) - { - switch (ch) - { - case '%': - case '_': - case '~': - builder.Append('~'); - break; - } - - builder.Append(ch); - } - - return builder.ToString(); - } - - static Converter GetLikeEscaper(string start, string end) - { - return value => value == null? null: start + EscapeLikeText(value.ToString()) + end; - } - - #endregion - - #region MakeIsPredicate - - internal ISqlPredicate MakeIsPredicate(TableBuilder.TableContext table, Type typeOperand) - { - if (typeOperand == table.ObjectType && !table.InheritanceMapping.Any(m => m.Type == typeOperand)) - return Convert(table, new SqlQuery.Predicate.Expr(new SqlValue(true))); - - return MakeIsPredicate( - table, table.InheritanceMapping, table.InheritanceDiscriminators, typeOperand, - name => table.SqlTable.Fields.Values.First(f => f.Name == name)); - } - - internal ISqlPredicate MakeIsPredicate( - IBuildContext context, - List inheritanceMapping, - List inheritanceDiscriminators, - Type toType, - Func getSql) - { - var mapping = inheritanceMapping - .Select((m,i) => new { m, i }) - .Where ( m => m.m.Type == toType && !m.m.IsDefault) - .ToList(); - - switch (mapping.Count) - { - case 0 : - { - var cond = new SqlQuery.SearchCondition(); - - foreach (var m in inheritanceMapping.Select((m,i) => new { m, i }).Where(m => !m.m.IsDefault)) - { - cond.Conditions.Add( - new SqlQuery.Condition( - false, - Convert(context, - new SqlQuery.Predicate.ExprExpr( - getSql(inheritanceDiscriminators[m.i]), - SqlQuery.Predicate.Operator.NotEqual, - new SqlValue(m.m.Code))))); - } - - return cond; - } - - case 1 : - return Convert(context, - new SqlQuery.Predicate.ExprExpr( - getSql(inheritanceDiscriminators[mapping[0].i]), - SqlQuery.Predicate.Operator.Equal, - new SqlValue(mapping[0].m.Code))); - - default: - { - var cond = new SqlQuery.SearchCondition(); - - foreach (var m in mapping) - { - cond.Conditions.Add( - new SqlQuery.Condition( - false, - Convert(context, - new SqlQuery.Predicate.ExprExpr( - getSql(inheritanceDiscriminators[m.i]), - SqlQuery.Predicate.Operator.Equal, - new SqlValue(m.m.Code))), - true)); - } - - return cond; - } - } - } - - ISqlPredicate MakeIsPredicate(IBuildContext context, TypeBinaryExpression expression) - { - var typeOperand = expression.TypeOperand; - var table = new TableBuilder.TableContext(this, new BuildInfo((IBuildContext)null, Expression.Constant(null), new SqlQuery()), typeOperand); - - if (typeOperand == table.ObjectType && !table.InheritanceMapping.Any(m => m.Type == typeOperand)) - return Convert(table, new SqlQuery.Predicate.Expr(new SqlValue(true))); - - var mapping = table.InheritanceMapping.Select((m,i) => new { m, i }).Where(m => m.m.Type == typeOperand && !m.m.IsDefault).ToList(); - var isEqual = true; - - if (mapping.Count == 0) - { - mapping = table.InheritanceMapping.Select((m,i) => new { m, i }).Where(m => !m.m.IsDefault).ToList(); - isEqual = false; - } - - Expression expr = null; - - foreach (var m in mapping) - { - var field = table.SqlTable.Fields[table.InheritanceDiscriminators[m.i]]; - var ttype = field.MemberMapper.MemberAccessor.TypeAccessor.OriginalType; - var obj = expression.Expression; - - if (obj.Type != ttype) - obj = Expression.Convert(expression.Expression, ttype); - - var left = Expression.PropertyOrField(obj, field.Name); - var code = m.m.Code; - - if (code == null) - code = TypeHelper.GetDefaultValue(left.Type); - else if (left.Type != code.GetType()) - code = MappingSchema.ConvertChangeType(code, left.Type); - - Expression right = Expression.Constant(code, left.Type); - - var e = isEqual ? Expression.Equal(left, right) : Expression.NotEqual(left, right); - - expr = expr != null ? Expression.AndAlso(expr, e) : e; - } - - return ConvertPredicate(context, expr); - } - - #endregion - - #endregion - - #region Search Condition Builder - - void BuildSearchCondition(IBuildContext context, Expression expression, List conditions) - { - switch (expression.NodeType) - { - case ExpressionType.And : - case ExpressionType.AndAlso : - { - var e = (BinaryExpression)expression; - - BuildSearchCondition(context, e.Left, conditions); - BuildSearchCondition(context, e.Right, conditions); - - break; - } - - case ExpressionType.Or : - case ExpressionType.OrElse : - { - var e = (BinaryExpression)expression; - var orCondition = new SqlQuery.SearchCondition(); - - BuildSearchCondition(context, e.Left, orCondition.Conditions); - orCondition.Conditions[orCondition.Conditions.Count - 1].IsOr = true; - BuildSearchCondition(context, e.Right, orCondition.Conditions); - - conditions.Add(new SqlQuery.Condition(false, orCondition)); - - break; - } - - case ExpressionType.Not : - { - var e = expression as UnaryExpression; - var notCondition = new SqlQuery.SearchCondition(); - - BuildSearchCondition(context, e.Operand, notCondition.Conditions); - - if (notCondition.Conditions.Count == 1 && notCondition.Conditions[0].Predicate is SqlQuery.Predicate.NotExpr) - { - var p = notCondition.Conditions[0].Predicate as SqlQuery.Predicate.NotExpr; - p.IsNot = !p.IsNot; - conditions.Add(notCondition.Conditions[0]); - } - else - conditions.Add(new SqlQuery.Condition(true, notCondition)); - - break; - } - - default : - var predicate = ConvertPredicate(context, expression); - - if (predicate is SqlQuery.Predicate.Expr) - { - var expr = ((SqlQuery.Predicate.Expr)predicate).Expr1; - - if (expr.ElementType == QueryElementType.SearchCondition) - { - var sc = (SqlQuery.SearchCondition)expr; - - if (sc.Conditions.Count == 1) - { - conditions.Add(sc.Conditions[0]); - break; - } - } - } - - conditions.Add(new SqlQuery.Condition(false, predicate)); - - break; - } - } - - #endregion - - #region CanBeTranslatedToSql - - bool CanBeTranslatedToSql(IBuildContext context, Expression expr, bool canBeCompiled) - { - List ignoredMembers = null; - - return null == expr.Find(pi => - { - if (ignoredMembers != null) - { - if (pi != ignoredMembers[ignoredMembers.Count - 1]) - throw new InvalidOperationException(); - - if (ignoredMembers.Count == 1) - ignoredMembers = null; - else - ignoredMembers.RemoveAt(ignoredMembers.Count - 1); - - return false; + + return new SqlQuery.Predicate.Like(a1, false, a2, a3); + } + + static string EscapeLikeText(string text) + { + if (text.IndexOfAny(new[] { '%', '_' }) < 0) + return text; + + var builder = new StringBuilder(text.Length); + + foreach (var ch in text) + { + switch (ch) + { + case '%': + case '_': + case '~': + builder.Append('~'); + break; + } + + builder.Append(ch); + } + + return builder.ToString(); + } + + static Converter GetLikeEscaper(string start, string end) + { + return value => value == null? null: start + EscapeLikeText(value.ToString()) + end; + } + + #endregion + + #region MakeIsPredicate + + internal ISqlPredicate MakeIsPredicate(TableBuilder.TableContext table, Type typeOperand) + { + if (typeOperand == table.ObjectType && !table.InheritanceMapping.Any(m => m.Type == typeOperand)) + return Convert(table, new SqlQuery.Predicate.Expr(new SqlValue(true))); + + return MakeIsPredicate( + table, table.InheritanceMapping, table.InheritanceDiscriminators, typeOperand, + name => table.SqlTable.Fields.Values.First(f => f.Name == name)); + } + + internal ISqlPredicate MakeIsPredicate( + IBuildContext context, + List inheritanceMapping, + List inheritanceDiscriminators, + Type toType, + Func getSql) + { + var mapping = inheritanceMapping + .Select((m,i) => new { m, i }) + .Where ( m => m.m.Type == toType && !m.m.IsDefault) + .ToList(); + + switch (mapping.Count) + { + case 0 : + { + var cond = new SqlQuery.SearchCondition(); + + foreach (var m in inheritanceMapping.Select((m,i) => new { m, i }).Where(m => !m.m.IsDefault)) + { + cond.Conditions.Add( + new SqlQuery.Condition( + false, + Convert(context, + new SqlQuery.Predicate.ExprExpr( + getSql(inheritanceDiscriminators[m.i]), + SqlQuery.Predicate.Operator.NotEqual, + new SqlValue(m.m.Code))))); + } + + return cond; + } + + case 1 : + return Convert(context, + new SqlQuery.Predicate.ExprExpr( + getSql(inheritanceDiscriminators[mapping[0].i]), + SqlQuery.Predicate.Operator.Equal, + new SqlValue(mapping[0].m.Code))); + + default: + { + var cond = new SqlQuery.SearchCondition(); + + foreach (var m in mapping) + { + cond.Conditions.Add( + new SqlQuery.Condition( + false, + Convert(context, + new SqlQuery.Predicate.ExprExpr( + getSql(inheritanceDiscriminators[m.i]), + SqlQuery.Predicate.Operator.Equal, + new SqlValue(m.m.Code))), + true)); + } + + return cond; + } + } + } + + ISqlPredicate MakeIsPredicate(IBuildContext context, TypeBinaryExpression expression) + { + var typeOperand = expression.TypeOperand; + var table = new TableBuilder.TableContext(this, new BuildInfo((IBuildContext)null, Expression.Constant(null), new SqlQuery()), typeOperand); + + if (typeOperand == table.ObjectType && !table.InheritanceMapping.Any(m => m.Type == typeOperand)) + return Convert(table, new SqlQuery.Predicate.Expr(new SqlValue(true))); + + var mapping = table.InheritanceMapping.Select((m,i) => new { m, i }).Where(m => m.m.Type == typeOperand && !m.m.IsDefault).ToList(); + var isEqual = true; + + if (mapping.Count == 0) + { + mapping = table.InheritanceMapping.Select((m,i) => new { m, i }).Where(m => !m.m.IsDefault).ToList(); + isEqual = false; + } + + Expression expr = null; + + foreach (var m in mapping) + { + var field = table.SqlTable.Fields[table.InheritanceDiscriminators[m.i]]; + var ttype = field.MemberMapper.MemberAccessor.TypeAccessor.OriginalType; + var obj = expression.Expression; + + if (obj.Type != ttype) + obj = Expression.Convert(expression.Expression, ttype); + + var left = Expression.PropertyOrField(obj, field.Name); + var code = m.m.Code; + + if (code == null) + code = TypeHelper.GetDefaultValue(left.Type); + else if (left.Type != code.GetType()) + code = MappingSchema.ConvertChangeType(code, left.Type); + + Expression right = Expression.Constant(code, left.Type); + + var e = isEqual ? Expression.Equal(left, right) : Expression.NotEqual(left, right); + + expr = expr != null ? Expression.AndAlso(expr, e) : e; + } + + return ConvertPredicate(context, expr); + } + + #endregion + + #endregion + + #region Search Condition Builder + + void BuildSearchCondition(IBuildContext context, Expression expression, List conditions) + { + switch (expression.NodeType) + { + case ExpressionType.And : + case ExpressionType.AndAlso : + { + var e = (BinaryExpression)expression; + + BuildSearchCondition(context, e.Left, conditions); + BuildSearchCondition(context, e.Right, conditions); + + break; + } + + case ExpressionType.Or : + case ExpressionType.OrElse : + { + var e = (BinaryExpression)expression; + var orCondition = new SqlQuery.SearchCondition(); + + BuildSearchCondition(context, e.Left, orCondition.Conditions); + orCondition.Conditions[orCondition.Conditions.Count - 1].IsOr = true; + BuildSearchCondition(context, e.Right, orCondition.Conditions); + + conditions.Add(new SqlQuery.Condition(false, orCondition)); + + break; + } + + case ExpressionType.Not : + { + var e = expression as UnaryExpression; + var notCondition = new SqlQuery.SearchCondition(); + + BuildSearchCondition(context, e.Operand, notCondition.Conditions); + + if (notCondition.Conditions.Count == 1 && notCondition.Conditions[0].Predicate is SqlQuery.Predicate.NotExpr) + { + var p = notCondition.Conditions[0].Predicate as SqlQuery.Predicate.NotExpr; + p.IsNot = !p.IsNot; + conditions.Add(notCondition.Conditions[0]); + } + else + conditions.Add(new SqlQuery.Condition(true, notCondition)); + + break; + } + + default : + var predicate = ConvertPredicate(context, expression); + + if (predicate is SqlQuery.Predicate.Expr) + { + var expr = ((SqlQuery.Predicate.Expr)predicate).Expr1; + + if (expr.ElementType == QueryElementType.SearchCondition) + { + var sc = (SqlQuery.SearchCondition)expr; + + if (sc.Conditions.Count == 1) + { + conditions.Add(sc.Conditions[0]); + break; + } + } + } + + conditions.Add(new SqlQuery.Condition(false, predicate)); + + break; + } + } + + #endregion + + #region CanBeTranslatedToSql + + bool CanBeTranslatedToSql(IBuildContext context, Expression expr, bool canBeCompiled) + { + List ignoredMembers = null; + + return null == expr.Find(pi => + { + if (ignoredMembers != null) + { + if (pi != ignoredMembers[ignoredMembers.Count - 1]) + throw new InvalidOperationException(); + + if (ignoredMembers.Count == 1) + ignoredMembers = null; + else + ignoredMembers.RemoveAt(ignoredMembers.Count - 1); + + return false; } - switch (pi.NodeType) - { - case ExpressionType.MemberAccess : - { - var ma = (MemberExpression)pi; - var attr = GetFunctionAttribute(ma.Member); - - if (attr == null && !TypeHelper.IsNullableValueMember(ma.Member)) - { - if (canBeCompiled) - { - var ctx = GetContext(context, pi); - - if (ctx == null) - return !CanBeCompiled(pi); - - if (ctx.IsExpression(pi, 0, RequestFor.Object).Result) - return !CanBeCompiled(pi); - - ignoredMembers = ma.Expression.GetMembers(); - } - } - - break; - } - - case ExpressionType.Parameter : - { + switch (pi.NodeType) + { + case ExpressionType.MemberAccess : + { + var ma = (MemberExpression)pi; + var attr = GetFunctionAttribute(ma.Member); + + if (attr == null && !TypeHelper.IsNullableValueMember(ma.Member)) + { + if (canBeCompiled) + { + var ctx = GetContext(context, pi); + + if (ctx == null) + return !CanBeCompiled(pi); + + if (ctx.IsExpression(pi, 0, RequestFor.Object).Result) + return !CanBeCompiled(pi); + + ignoredMembers = ma.Expression.GetMembers(); + } + } + + break; + } + + case ExpressionType.Parameter : + { var ctx = GetContext(context, pi); if (ctx == null) if (canBeCompiled) return !CanBeCompiled(pi); - break; - } - - case ExpressionType.Call : - { - var e = (MethodCallExpression)pi; - - if (e.Method.DeclaringType != typeof(Enumerable)) - { - var attr = GetFunctionAttribute(e.Method); - - if (attr == null && canBeCompiled) - return !CanBeCompiled(pi); - } - - break; - } - - case ExpressionType.TypeIs : return canBeCompiled; - case ExpressionType.TypeAs : - case ExpressionType.New : return true; - - case ExpressionType.NotEqual : + break; + } + + case ExpressionType.Call : + { + var e = (MethodCallExpression)pi; + + if (e.Method.DeclaringType != typeof(Enumerable)) + { + var attr = GetFunctionAttribute(e.Method); + + if (attr == null && canBeCompiled) + return !CanBeCompiled(pi); + } + + break; + } + + case ExpressionType.TypeIs : return canBeCompiled; + case ExpressionType.TypeAs : + case ExpressionType.New : return true; + + case ExpressionType.NotEqual : case ExpressionType.Equal : { var e = (BinaryExpression)pi; @@ -2293,217 +2298,217 @@ bool CanBeTranslatedToSql(IBuildContext context, Expression expr, bool canBeComp if (ctx != null) { - if (ctx.IsExpression(obj, 0, RequestFor.Table). Result || - ctx.IsExpression(obj, 0, RequestFor.Association).Result) + if (ctx.IsExpression(obj, 0, RequestFor.Table). Result || + ctx.IsExpression(obj, 0, RequestFor.Association).Result) { - ignoredMembers = obj.GetMembers(); + ignoredMembers = obj.GetMembers(); } } } break; - } - } - - return false; - }); - } - - #endregion - - #region Helpers - - public IBuildContext GetContext([JetBrains.Annotations.NotNull] IBuildContext current, Expression expression) - { - var root = expression.GetRootObject(); - - for (; current != null; current = current.Parent) - if (current.IsExpression(root, 0, RequestFor.Root).Result) - return current; - - return null; - } - - SqlFunctionAttribute GetFunctionAttribute(ICustomAttributeProvider member) - { - var attrs = member.GetCustomAttributes(typeof(SqlFunctionAttribute), true); - - if (attrs.Length == 0) - return null; - - SqlFunctionAttribute attr = null; - - foreach (SqlFunctionAttribute a in attrs) - { - if (a.SqlProvider == SqlProvider.Name) - { - attr = a; - break; - } - - if (a.SqlProvider == null) - attr = a; - } - - return attr; - } - - internal TableFunctionAttribute GetTableFunctionAttribute(ICustomAttributeProvider member) - { - var attrs = member.GetCustomAttributes(typeof(TableFunctionAttribute), true); - - if (attrs.Length == 0) - return null; - - TableFunctionAttribute attr = null; - - foreach (TableFunctionAttribute a in attrs) - { - if (a.SqlProvider == SqlProvider.Name) - { - attr = a; - break; - } - - if (a.SqlProvider == null) - attr = a; - } - - return attr; - } - - public ISqlExpression Convert(IBuildContext context, ISqlExpression expr) - { - SqlProvider.SqlQuery = context.SqlQuery; - return SqlProvider.ConvertExpression(expr); - } - - public ISqlPredicate Convert(IBuildContext context, ISqlPredicate predicate) - { - SqlProvider.SqlQuery = context.SqlQuery; - return SqlProvider.ConvertPredicate(predicate); - } - - public ISqlExpression ConvertTimeSpanMember(IBuildContext context, MemberExpression expression) - { - if (expression.Member.DeclaringType == typeof(TimeSpan)) - { - switch (expression.Expression.NodeType) - { - case ExpressionType.Subtract : - case ExpressionType.SubtractChecked: - - Sql.DateParts datePart; - - switch (expression.Member.Name) - { - case "TotalMilliseconds" : datePart = Sql.DateParts.Millisecond; break; - case "TotalSeconds" : datePart = Sql.DateParts.Second; break; - case "TotalMinutes" : datePart = Sql.DateParts.Minute; break; - case "TotalHours" : datePart = Sql.DateParts.Hour; break; - case "TotalDays" : datePart = Sql.DateParts.Day; break; - default : return null; - } - - var e = (BinaryExpression)expression.Expression; - - return new SqlFunction( - typeof(int), - "DateDiff", - new SqlValue(datePart), + } + } + + return false; + }); + } + + #endregion + + #region Helpers + + public IBuildContext GetContext([JetBrains.Annotations.NotNull] IBuildContext current, Expression expression) + { + var root = expression.GetRootObject(); + + for (; current != null; current = current.Parent) + if (current.IsExpression(root, 0, RequestFor.Root).Result) + return current; + + return null; + } + + SqlFunctionAttribute GetFunctionAttribute(ICustomAttributeProvider member) + { + var attrs = member.GetCustomAttributes(typeof(SqlFunctionAttribute), true); + + if (attrs.Length == 0) + return null; + + SqlFunctionAttribute attr = null; + + foreach (SqlFunctionAttribute a in attrs) + { + if (a.SqlProvider == SqlProvider.Name) + { + attr = a; + break; + } + + if (a.SqlProvider == null) + attr = a; + } + + return attr; + } + + internal TableFunctionAttribute GetTableFunctionAttribute(ICustomAttributeProvider member) + { + var attrs = member.GetCustomAttributes(typeof(TableFunctionAttribute), true); + + if (attrs.Length == 0) + return null; + + TableFunctionAttribute attr = null; + + foreach (TableFunctionAttribute a in attrs) + { + if (a.SqlProvider == SqlProvider.Name) + { + attr = a; + break; + } + + if (a.SqlProvider == null) + attr = a; + } + + return attr; + } + + public ISqlExpression Convert(IBuildContext context, ISqlExpression expr) + { + SqlProvider.SqlQuery = context.SqlQuery; + return SqlProvider.ConvertExpression(expr); + } + + public ISqlPredicate Convert(IBuildContext context, ISqlPredicate predicate) + { + SqlProvider.SqlQuery = context.SqlQuery; + return SqlProvider.ConvertPredicate(predicate); + } + + public ISqlExpression ConvertTimeSpanMember(IBuildContext context, MemberExpression expression) + { + if (expression.Member.DeclaringType == typeof(TimeSpan)) + { + switch (expression.Expression.NodeType) + { + case ExpressionType.Subtract : + case ExpressionType.SubtractChecked: + + Sql.DateParts datePart; + + switch (expression.Member.Name) + { + case "TotalMilliseconds" : datePart = Sql.DateParts.Millisecond; break; + case "TotalSeconds" : datePart = Sql.DateParts.Second; break; + case "TotalMinutes" : datePart = Sql.DateParts.Minute; break; + case "TotalHours" : datePart = Sql.DateParts.Hour; break; + case "TotalDays" : datePart = Sql.DateParts.Day; break; + default : return null; + } + + var e = (BinaryExpression)expression.Expression; + + return new SqlFunction( + typeof(int), + "DateDiff", + new SqlValue(datePart), ConvertToSql(context, e.Right, false), ConvertToSql(context, e.Left, false)); - } - } - - return null; - } - - internal ISqlExpression ConvertSearchCondition(IBuildContext context, ISqlExpression sqlExpression) - { - if (sqlExpression is SqlQuery.SearchCondition) - { - if (sqlExpression.CanBeNull()) - { - var notExpr = new SqlQuery.SearchCondition - { - Conditions = { new SqlQuery.Condition(true, new SqlQuery.Predicate.Expr(sqlExpression, sqlExpression.Precedence)) } - }; - - return Convert(context, new SqlFunction(sqlExpression.SystemType, "CASE", sqlExpression, new SqlValue(1), notExpr, new SqlValue(0), new SqlValue(null))); - } - - return Convert(context, new SqlFunction(sqlExpression.SystemType, "CASE", sqlExpression, new SqlValue(1), new SqlValue(0))); - } - - return sqlExpression; - } - - public bool ProcessProjection(Dictionary members, Expression expression) - { - switch (expression.NodeType) - { - // new { ... } - // - case ExpressionType.New : - { - var expr = (NewExpression)expression; - -// ReSharper disable ConditionIsAlwaysTrueOrFalse -// ReSharper disable HeuristicUnreachableCode - if (expr.Members == null) - return false; -// ReSharper restore HeuristicUnreachableCode -// ReSharper restore ConditionIsAlwaysTrueOrFalse - - for (var i = 0; i < expr.Members.Count; i++) - { - var member = expr.Members[i]; - - members.Add(member, expr.Arguments[i]); - - if (member is MethodInfo) - members.Add(TypeHelper.GetPropertyByMethod((MethodInfo)member), expr.Arguments[i]); - } - - return true; - } - - // new MyObject { ... } - // - case ExpressionType.MemberInit : - { - var expr = (MemberInitExpression)expression; - var dic = TypeAccessor.GetAccessor(expr.Type) - .Select((m,i) => new { m, i }) - .ToDictionary(_ => _.m.MemberInfo.Name, _ => _.i); - - foreach (var binding in expr.Bindings.Cast().OrderBy(b => dic.ContainsKey(b.Member.Name) ? dic[b.Member.Name] : 1000000)) - { - members.Add(binding.Member, binding.Expression); - - if (binding.Member is MethodInfo) - members.Add(TypeHelper.GetPropertyByMethod((MethodInfo)binding.Member), binding.Expression); - } - - return true; - } - - // .Select(p => everything else) - // - default : - return false; - } - } - - public void ReplaceParent(IBuildContext oldParent, IBuildContext newParent) - { - foreach (var context in Contexts) - if (context != newParent) - if (context.Parent == oldParent) - context.Parent = newParent; - } - - #endregion - } -} + } + } + + return null; + } + + internal ISqlExpression ConvertSearchCondition(IBuildContext context, ISqlExpression sqlExpression) + { + if (sqlExpression is SqlQuery.SearchCondition) + { + if (sqlExpression.CanBeNull()) + { + var notExpr = new SqlQuery.SearchCondition + { + Conditions = { new SqlQuery.Condition(true, new SqlQuery.Predicate.Expr(sqlExpression, sqlExpression.Precedence)) } + }; + + return Convert(context, new SqlFunction(sqlExpression.SystemType, "CASE", sqlExpression, new SqlValue(1), notExpr, new SqlValue(0), new SqlValue(null))); + } + + return Convert(context, new SqlFunction(sqlExpression.SystemType, "CASE", sqlExpression, new SqlValue(1), new SqlValue(0))); + } + + return sqlExpression; + } + + public bool ProcessProjection(Dictionary members, Expression expression) + { + switch (expression.NodeType) + { + // new { ... } + // + case ExpressionType.New : + { + var expr = (NewExpression)expression; + +// ReSharper disable ConditionIsAlwaysTrueOrFalse +// ReSharper disable HeuristicUnreachableCode + if (expr.Members == null) + return false; +// ReSharper restore HeuristicUnreachableCode +// ReSharper restore ConditionIsAlwaysTrueOrFalse + + for (var i = 0; i < expr.Members.Count; i++) + { + var member = expr.Members[i]; + + members.Add(member, expr.Arguments[i]); + + if (member is MethodInfo) + members.Add(TypeHelper.GetPropertyByMethod((MethodInfo)member), expr.Arguments[i]); + } + + return true; + } + + // new MyObject { ... } + // + case ExpressionType.MemberInit : + { + var expr = (MemberInitExpression)expression; + var dic = TypeAccessor.GetAccessor(expr.Type) + .Select((m,i) => new { m, i }) + .ToDictionary(_ => _.m.MemberInfo.Name, _ => _.i); + + foreach (var binding in expr.Bindings.Cast().OrderBy(b => dic.ContainsKey(b.Member.Name) ? dic[b.Member.Name] : 1000000)) + { + members.Add(binding.Member, binding.Expression); + + if (binding.Member is MethodInfo) + members.Add(TypeHelper.GetPropertyByMethod((MethodInfo)binding.Member), binding.Expression); + } + + return true; + } + + // .Select(p => everything else) + // + default : + return false; + } + } + + public void ReplaceParent(IBuildContext oldParent, IBuildContext newParent) + { + foreach (var context in Contexts) + if (context != newParent) + if (context.Parent == oldParent) + context.Parent = newParent; + } + + #endregion + } +} diff --git a/Source/Data/Linq/Builder/InsertBuilder.cs b/Source/Data/Linq/Builder/InsertBuilder.cs index 992419746..5808e7b41 100644 --- a/Source/Data/Linq/Builder/InsertBuilder.cs +++ b/Source/Data/Linq/Builder/InsertBuilder.cs @@ -13,7 +13,7 @@ class InsertBuilder : MethodCallBuilder protected override bool CanBuildMethodCall(ExpressionBuilder builder, MethodCallExpression methodCall, BuildInfo buildInfo) { - return methodCall.IsQueryable("Insert", "InsertWithIdentity"); + return methodCall.IsQueryable("Insert", "InsertWithIdentity","InsertWithOutput"); } protected override IBuildContext BuildMethodCall(ExpressionBuilder builder, MethodCallExpression methodCall, BuildInfo buildInfo) @@ -98,8 +98,9 @@ protected override IBuildContext BuildMethodCall(ExpressionBuilder builder, Meth sequence.SqlQuery.QueryType = QueryType.Insert; sequence.SqlQuery.Insert.WithIdentity = methodCall.Method.Name == "InsertWithIdentity"; + sequence.SqlQuery.Insert.WithOutput = methodCall.Method.Name == "InsertWithOutput"; - return new InsertContext(buildInfo.Parent, sequence, sequence.SqlQuery.Insert.WithIdentity); + return new InsertContext(buildInfo.Parent, sequence, sequence.SqlQuery.Insert.WithIdentity || sequence.SqlQuery.Insert.WithOutput); } protected override SequenceConvertInfo Convert( diff --git a/Source/Data/Linq/Builder/SelectContext.cs b/Source/Data/Linq/Builder/SelectContext.cs index 9304062c9..66968682c 100644 --- a/Source/Data/Linq/Builder/SelectContext.cs +++ b/Source/Data/Linq/Builder/SelectContext.cs @@ -64,6 +64,7 @@ public virtual void BuildQuery(Query query, ParameterExpression queryParam var expr = BuildExpression(null, 0); var mapper = Builder.BuildMapper(expr); + //TODO CHeck if it could be useful to use a cache for these queries query.SetQuery(mapper.Compile()); } @@ -673,7 +674,9 @@ public virtual IsExpressionResult IsExpression(Expression expression, int level, case ExpressionType.Parameter : { var sequence = GetSequence(expression, level); - var parameter = Lambda.Parameters[Sequence.Length == 0 ? 0 : Array.IndexOf(Sequence, sequence)]; + var index = Sequence.Length == 0 ? 0 : Array.IndexOf(Sequence, sequence); + var parameter = Lambda.Parameters[index == -1 ? 0 : index]; + //var parameter = Lambda.Parameters[Sequence.Length == 0 ? 0 : Array.IndexOf(Sequence, sequence)]; if (levelExpression == expression) { diff --git a/Source/Data/Linq/Expressions.cs b/Source/Data/Linq/Expressions.cs index c53bc7489..2f1615840 100644 --- a/Source/Data/Linq/Expressions.cs +++ b/Source/Data/Linq/Expressions.cs @@ -144,8 +144,8 @@ static MemberInfo M(Expression> func) { M(() => "".Length ), L ( obj => Sql.Length(obj).Value) }, { M(() => "".Substring (0) ), L ((obj,p0) => Sql.Substring(obj, p0 + 1, obj.Length - p0)) }, - { M(() => "".Substring (0,0) ), L ((obj,p0,p1) => Sql.Substring(obj, p0 + 1, p1)) }, - { M(() => "".ContainsExactly("") ), L ((obj,p0) => p0.Length == 0 ? 0 : (Sql.ContainsExactly(p0, obj) .Value) - 1) }, + { M(() => "".Substring (0,0) ), L ((obj,p0,p1) => Sql.Substring(obj, p0 + 1, p1)) }, + { M(() => "".ContainsExactly("") ), L ((obj,p0) => p0.Length == 0 ? 0 : (Sql.ContainsExactly(p0, obj) .Value) - 1) }, { M(() => "".IndexOf ("") ), L ((obj,p0) => p0.Length == 0 ? 0 : (Sql.CharIndex(p0, obj) .Value) - 1) }, { M(() => "".IndexOf ("",0) ), L ((obj,p0,p1) => p0.Length == 0 && obj.Length > p1 ? p1 : (Sql.CharIndex(p0, obj, p1 + 1).Value) - 1) }, { M(() => "".IndexOf ("",0,0) ), L((obj,p0,p1,p2) => p0.Length == 0 && obj.Length > p1 ? p1 : (Sql.CharIndex(p0, Sql.Left(obj, p2), p1) .Value) - 1) }, diff --git a/Source/Data/Linq/Extensions.cs b/Source/Data/Linq/Extensions.cs index 7d5b57b39..b98e63119 100644 --- a/Source/Data/Linq/Extensions.cs +++ b/Source/Data/Linq/Extensions.cs @@ -2,8 +2,7 @@ using System.Collections.Generic; using System.Linq.Expressions; using System.Reflection; -using System.Text.RegularExpressions; - +using System.Text.RegularExpressions; using JetBrains.Annotations; namespace BLToolkit.Data.Linq @@ -255,6 +254,11 @@ public static int InsertBatch(this DbManager dataContext, IEnumerable list return InsertBatch(dataContext, int.MaxValue, list); } + public static int InsertBatchWithIdentity(this DbManager dataContext, IEnumerable list) + { + return new SqlQuery().InsertBatchWithIdentity(dataContext, int.MaxValue, list); + } + public static int InsertBatch(this DbManager dataContext, T[] list) { return InsertBatch(dataContext, int.MaxValue, list); @@ -296,6 +300,21 @@ public static object InsertWithIdentity(this IDataContext dataContext, T obj) } #endregion + + #region InsertWithOutput + + public static object InsertWithOutput([NotNull] this IDataContextInfo dataContextInfo, T obj) + { + if (dataContextInfo == null) throw new ArgumentNullException("dataContextInfo"); + return Query.InsertWithOutput(dataContextInfo, obj); + } + + public static object InsertWithOutput( this IDataContext dataContext, T obj ) + { + return Query.InsertWithOutput(DataContextInfo.Create( dataContext ), obj); + } + + #endregion #region Update @@ -356,7 +375,7 @@ public static int Delete(this DbManager dataContext, IEnumerable list) #endregion #endregion - + #region String Extensions public static int ContainsExactly(this string s, string value) @@ -365,5 +384,5 @@ public static int ContainsExactly(this string s, string value) } #endregion - } -} + } +} diff --git a/Source/Data/Linq/LinqExtensions.cs b/Source/Data/Linq/LinqExtensions.cs index 76540a229..f79561c69 100644 --- a/Source/Data/Linq/LinqExtensions.cs +++ b/Source/Data/Linq/LinqExtensions.cs @@ -69,9 +69,9 @@ static public T Select([NotNull] this IDataContext dataContext, [NotNull, Ins #endregion - #region Delete + #region Delete - public static int Delete([NotNull] this IQueryable source) + public static int Delete([NotNull] this IQueryable source) { if (source == null) throw new ArgumentNullException("source"); @@ -324,6 +324,22 @@ public static object InsertWithIdentity( ((MethodInfo)MethodBase.GetCurrentMethod()).MakeGenericMethod(new[] { typeof(T) }), new[] { query.Expression, Expression.Quote(setter) })); } + + public static object InsertWithOutput( + [NotNull] this Table target, + [NotNull, InstantHandle] Expression> setter ) + { + if (target == null) throw new ArgumentNullException("target"); + if (setter == null) throw new ArgumentNullException("setter"); + + IQueryable query = target; + + return query.Provider.Execute( + Expression.Call( + null, + ( (MethodInfo)MethodBase.GetCurrentMethod() ).MakeGenericMethod( new[] { typeof( T ) } ), + new[] { query.Expression, Expression.Quote( setter ) } ) ); + } #region ValueInsertable @@ -450,6 +466,19 @@ public static object InsertWithIdentity([NotNull] this IValueInsertable so ((MethodInfo)MethodBase.GetCurrentMethod()).MakeGenericMethod(new[] { typeof(T) }), new[] { query.Expression })); } + + public static object InsertWithOutput( [NotNull] this IValueInsertable source ) + { + if (source == null) throw new ArgumentNullException( "source" ); + + var query = ( (ValueInsertable)source ).Query; + + return query.Provider.Execute( + Expression.Call( + null, + ( (MethodInfo)MethodBase.GetCurrentMethod() ).MakeGenericMethod( new[] { typeof( T ) } ), + new[] { query.Expression } ) ); + } #endregion @@ -486,6 +515,22 @@ public static object InsertWithIdentity( ((MethodInfo)MethodBase.GetCurrentMethod()).MakeGenericMethod(new[] { typeof(TSource), typeof(TTarget) }), new[] { source.Expression, ((IQueryable)target).Expression, Expression.Quote(setter) })); } + + public static object InsertWithOutput( + [NotNull] this IQueryable source, + [NotNull] Table target, + [NotNull, InstantHandle] Expression> setter) + { + if (source == null) throw new ArgumentNullException( "source" ); + if (target == null) throw new ArgumentNullException( "target" ); + if (setter == null) throw new ArgumentNullException( "setter" ); + + return source.Provider.Execute( + Expression.Call( + null, + ( (MethodInfo)MethodBase.GetCurrentMethod() ).MakeGenericMethod( new[] { typeof( TSource ), typeof( TTarget ) } ), + new[] { source.Expression, ( (IQueryable)target ).Expression, Expression.Quote( setter ) } ) ); + } class SelectInsertable : ISelectInsertable { diff --git a/Source/Data/Linq/Query.cs b/Source/Data/Linq/Query.cs index 0e3b7d322..6b2785f7f 100644 --- a/Source/Data/Linq/Query.cs +++ b/Source/Data/Linq/Query.cs @@ -117,6 +117,30 @@ IEnumerable MakeEnumerable(QueryContext qc, IDataContextInfo dci, Expression const int CacheSize = 100; + public static void ClearCache() + { + lock (_sync) + { + var temp = _first; + + while (temp != null) + { + var temp2 = temp; + temp = temp.Next; + + temp2.Queries.Clear(); + } + + _first = null; + + ObjectOperation.InsertWithIdentity.Clear(); + ObjectOperation.InsertOrUpdate.Clear(); + ObjectOperation.Insert.Clear(); + ObjectOperation.Update.Clear(); + ObjectOperation.Delete.Clear(); + } + } + public static Query GetQuery(IDataContextInfo dataContextInfo, Expression expr) { var query = FindQuery(dataContextInfo, expr); @@ -377,14 +401,27 @@ object SetCommand(IDataContext dataContext, Expression expr, object[] parameters { lock (this) { - SetParameters(expr, parameters, idx); + bool useQueryText = false; +#if !SILVERLIGHT + useQueryText = dataContext is DbManager && ((DbManager) dataContext).UseQueryText; +#endif + SetParameters(expr, parameters, idx, useQueryText); + return dataContext.SetQuery(Queries[idx]); } } - void SetParameters(Expression expr, object[] parameters, int idx) + void SetParameters(Expression expr, object[] parameters, int idx, bool useQueryText) { - foreach (var p in Queries[idx].Parameters) + QueryInfo query = Queries[idx]; + + if (query.UseQueryText != useQueryText) + { + query.Context = null; + query.UseQueryText = useQueryText; + } + + foreach (var p in query.Parameters) { var value = p.Accessor(expr, parameters); @@ -407,11 +444,16 @@ void SetParameters(Expression expr, object[] parameters, int idx) // MappingSchema.MapEnumToValue(v, true) : // v); } - + value = values; } } + // Reset the query context sql when the parameters values change. When UseQueryText = true + // the query context sql includes the parameters values + if (useQueryText && query.Context != null && !Equals(p.SqlParameter.Value, value)) + query.Context = null; + p.SqlParameter.Value = value; } } @@ -448,6 +490,7 @@ public QueryInfo() public SqlQuery SqlQuery { get; set; } public object Context { get; set; } + public bool UseQueryText { get; set; } public SqlParameter[] GetParameters() { @@ -470,6 +513,7 @@ static class ObjectOperation { public static readonly Dictionary> Insert = new Dictionary>(); public static readonly Dictionary> InsertWithIdentity = new Dictionary>(); + public static readonly Dictionary> InsertWithOutput = new Dictionary>(); public static readonly Dictionary> InsertOrUpdate = new Dictionary>(); public static readonly Dictionary> Update = new Dictionary>(); public static readonly Dictionary> Delete = new Dictionary>(); @@ -670,6 +714,64 @@ public static object InsertWithIdentity(IDataContextInfo dataContextInfo, T obj) } #endregion + + #region InsertWithOutput + + public static object InsertWithOutput( IDataContextInfo dataContextInfo, T obj ) + { + if ( Equals( default( T ), obj ) ) + return 0; + + Query ei; + + var key = new { dataContextInfo.MappingSchema, dataContextInfo.ContextID }; + + if ( !ObjectOperation.InsertWithOutput.TryGetValue( key, out ei ) ) + lock ( _sync ) + if ( !ObjectOperation.InsertWithOutput.TryGetValue( key, out ei ) ) + { + var sqlTable = new SqlTable( dataContextInfo.MappingSchema ); + var sqlQuery = new SqlQuery { QueryType = QueryType.Insert }; + + sqlQuery.Insert.Into = sqlTable; + sqlQuery.Insert.WithIdentity = true; + + ei = new Query + { + MappingSchema = dataContextInfo.MappingSchema, + ContextID = dataContextInfo.ContextID, + CreateSqlProvider = dataContextInfo.CreateSqlProvider, + Queries = { new Query.QueryInfo { SqlQuery = sqlQuery, } } + }; + + foreach ( var field in sqlTable.Fields ) + { + if ( field.Value.IsInsertable ) + { + var param = GetParameter( dataContextInfo.DataContext, field.Value ); + + ei.Queries[0].Parameters.Add( param ); + + sqlQuery.Insert.Items.Add( new SqlQuery.SetExpression( field.Value, param.SqlParameter ) ); + } + else if ( field.Value.IsIdentity ) + { + var expr = ei.SqlProvider.GetIdentityExpression( sqlTable, field.Value, true ); + + if ( expr != null ) + sqlQuery.Insert.Items.Add( new SqlQuery.SetExpression( field.Value, expr ) ); + } + } + + ei.SetScalarQuery(); + + ObjectOperation.InsertWithOutput.Add( key, ei ); + } + + return ei.GetElement( null, dataContextInfo, Expression.Constant( obj ), null ); + } + + #endregion #region InsertOrReplace @@ -1067,6 +1169,10 @@ Func> GetQuery internal void SetQuery(Func mapper) { var query = GetQuery(); + + // TODO => Add the possibility to switch to the FullMappingSchema + //mapper = (context, dataContext, arg3, arg4, arg5) => MappingSchema.MapDataReaderToObject(arg3); + GetIEnumerable = (ctx,db,expr,ps) => Map(query(db, expr, ps, 0), ctx, db, expr, ps, mapper); } @@ -1082,7 +1188,9 @@ static IEnumerable Map( queryContext = new QueryContext(dataContextInfo, expr, ps); foreach (var dr in data) - yield return mapper(queryContext, dataContextInfo.DataContext, dr, expr, ps); + { + yield return mapper(queryContext, dataContextInfo.DataContext, dr, expr, ps); + } } internal void SetQuery(Func mapper) diff --git a/Source/Data/Linq/Sql.cs b/Source/Data/Linq/Sql.cs index 106e84e03..60cd902af 100644 --- a/Source/Data/Linq/Sql.cs +++ b/Source/Data/Linq/Sql.cs @@ -276,14 +276,14 @@ public static bool Like(string matchExpression, string pattern, char? escapeChar return str.IndexOf(value) + 1; } - [SqlFunction] - public static int? ContainsExactly(string value, string str) - { - if (str == null || value == null) - return null; + [SqlFunction] + public static int? ContainsExactly(string value, string str) + { + if (str == null || value == null) + return null; - return str.ContainsExactly(value); - } + return str.ContainsExactly(value); + } [SqlFunction] [SqlFunction("DB2", "Locate")] @@ -471,6 +471,7 @@ public static string Upper(string str) [SqlProperty("CURRENT_TIMESTAMP")] [SqlProperty("Informix", "CURRENT")] [SqlProperty("Access", "Now")] + [SqlProperty("Oracle", "SYSDATE")] public static DateTime GetDate() { return DateTime.Now; @@ -481,6 +482,7 @@ public static DateTime GetDate() [SqlProperty("Access", "Now", ServerSideOnly = true)] [SqlFunction("SqlCe", "GetDate", ServerSideOnly = true)] [SqlFunction("Sybase", "GetDate", ServerSideOnly = true)] + [SqlFunction("Oracle", "SYSDATE", ServerSideOnly = true)] public static DateTime CurrentTimestamp { get { throw new LinqException("The 'CurrentTimestamp' is server side only property."); } @@ -491,6 +493,7 @@ public static DateTime CurrentTimestamp [SqlProperty("Access", "Now")] [SqlFunction("SqlCe", "GetDate")] [SqlFunction("Sybase", "GetDate")] + [SqlFunction("Oracle", "SYSDATE")] public static DateTime CurrentTimestamp2 { get { return DateTime.Now; } diff --git a/Source/Data/Sql/SqlProvider/AccessSqlProvider.cs b/Source/Data/Sql/SqlProvider/AccessSqlProvider.cs index c58d2843c..c69c4ac40 100644 --- a/Source/Data/Sql/SqlProvider/AccessSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/AccessSqlProvider.cs @@ -338,7 +338,7 @@ SqlFunction ConvertCase(Type systemType, ISqlExpression[] parameters, int start) return new SqlFunction(systemType, "Iif", parameters[start], parameters[start + 1], ConvertCase(systemType, parameters, start + 2)); } - public override void BuildValue(StringBuilder sb, object value) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (value is bool) sb.Append(value); diff --git a/Source/Data/Sql/SqlProvider/BasicSqlProvider.cs b/Source/Data/Sql/SqlProvider/BasicSqlProvider.cs index 2bd50c700..6453344f9 100644 --- a/Source/Data/Sql/SqlProvider/BasicSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/BasicSqlProvider.cs @@ -37,7 +37,8 @@ public int Nesting #region Support Flags - public virtual bool SkipAcceptsParameter { get { return true; } } + public bool UseQueryText { get; set; } + public virtual bool SkipAcceptsParameter { get { return true; } } public virtual bool TakeAcceptsParameter { get { return true; } } public virtual bool IsTakeSupported { get { return true; } } public virtual bool IsSkipSupported { get { return true; } } @@ -92,7 +93,9 @@ public virtual int BuildSql(int commandNumber, SqlQuery sqlQuery, StringBuilder if (union.IsAll) sb.Append(" ALL"); sb.AppendLine(); - CreateSqlProvider().BuildSql(commandNumber, union.SqlQuery, sb, indent, nesting, skipAlias); + var sqlProvider = CreateSqlProvider(); + sqlProvider.UseQueryText = UseQueryText; + sqlProvider.BuildSql(commandNumber, union.SqlQuery, sb, indent, nesting, skipAlias); } } } @@ -120,7 +123,9 @@ protected virtual int BuildSqlBuilder(SqlQuery sqlQuery, StringBuilder sb, int i if (!IsTakeSupported && sqlQuery.Select.TakeValue != null) throw new SqlException("Take for subqueries is not supported by the '{0}' provider.", Name); - return CreateSqlProvider().BuildSql(0, sqlQuery, sb, indent, nesting, skipAlias); + var sqlProvider = CreateSqlProvider(); + sqlProvider.UseQueryText = UseQueryText; + return sqlProvider.BuildSql(0, sqlQuery, sb, indent, nesting, skipAlias); } protected abstract ISqlProvider CreateSqlProvider(); @@ -178,6 +183,9 @@ protected virtual void BuildSelectQuery(StringBuilder sb) protected virtual void BuildInsertQuery(StringBuilder sb) { + if (SqlQuery.Insert.WithOutput) + BuildSetOutput(sb); + BuildStep = Step.InsertClause; BuildInsertClause(sb); if (SqlQuery.QueryType == QueryType.Insert && SqlQuery.From.Tables.Count != 0) @@ -193,6 +201,9 @@ protected virtual void BuildInsertQuery(StringBuilder sb) if (SqlQuery.Insert.WithIdentity) BuildGetIdentity(sb); + + if (SqlQuery.Insert.WithOutput) + BuildGetOutput(sb); } protected virtual void BuildUnknownQuery(StringBuilder sb) @@ -395,6 +406,13 @@ protected virtual void BuildInsertClause(StringBuilder sb, string insertText, bo sb.AppendLine(); AppendIndent(sb).AppendLine(")"); + + if ( SqlQuery.Insert.WithOutput ) + { + var pkField = SqlQuery.Insert.Into.Fields.FirstOrDefault(x=>x.Value.IsIdentity && x.Value.IsPrimaryKey); + + AppendIndent( sb ).Append( "output inserted.[" ).Append( pkField.Value.Name ).AppendLine( "] into @tabTempInsert" ); + } if (SqlQuery.QueryType == QueryType.InsertOrUpdate || SqlQuery.From.Tables.Count == 0) { @@ -427,6 +445,16 @@ protected virtual void BuildGetIdentity(StringBuilder sb) { //throw new SqlException("Insert with identity is not supported by the '{0}' sql provider.", Name); } + + protected virtual void BuildSetOutput(StringBuilder sb) + { + //throw new SqlException("Insert with identity is not supported by the '{0}' sql provider.", Name); + } + + protected virtual void BuildGetOutput(StringBuilder sb) + { + //throw new SqlException("Insert with identity is not supported by the '{0}' sql provider.", Name); + } #endregion @@ -1483,13 +1511,13 @@ protected virtual StringBuilder BuildExpression( { var parm = (SqlParameter)expr; - if (parm.IsQueryParameter) - { - var name = Convert(parm.Name, ConvertType.NameToQueryParameter); - sb.Append(name); - } - else - BuildValue(sb, parm.Value); + if (!UseQueryText && parm.IsQueryParameter) + { + var name = Convert(parm.Name, ConvertType.NameToQueryParameter); + sb.Append(name); + } + else + BuildValue(sb, parm.Value, parm); } break; @@ -1509,7 +1537,7 @@ protected virtual StringBuilder BuildExpression( return sb; } - protected void BuildExpression(StringBuilder sb, int parentPrecedence, ISqlExpression expr, string alias, ref bool addAlias) + private void BuildExpression(StringBuilder sb, int parentPrecedence, ISqlExpression expr, string alias, ref bool addAlias) { var wrap = Wrap(GetPrecedence(expr), parentPrecedence); @@ -1584,13 +1612,26 @@ public object GetValue(object value) PositiveSign = NumberFormatInfo.InvariantInfo.PositiveSign, }; - public virtual void BuildValue(StringBuilder sb, object value) + public virtual void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (value == null) sb.Append("NULL"); else if (value is string) BuildString(sb, value.ToString()); else if (value is char) BuildChar (sb, (char)value); else if (value is bool) sb.Append((bool)value ? "1" : "0"); - else if (value is DateTime) BuildDateTime(sb, value); + else if (value is DateTime) + { + var dt = (DateTime) value; + if (sqlParameter != null && sqlParameter.DbType == DbType.Date) + { + dt = new DateTime(dt.Year, dt.Month, dt.Day, 0, 0, 0, dt.Kind); + } + if (dt.TimeOfDay.TotalSeconds == 0) + { + BuildDate(sb, dt); + } + else + BuildDateTime(sb, dt); + } else if (value is Guid) sb.Append('\'').Append(value).Append('\''); else if (value is decimal) sb.Append(((decimal)value).ToString(NumberFormatInfo)); else if (value is double) sb.Append(((double) value).ToString(NumberFormatInfo)); @@ -1652,6 +1693,11 @@ protected virtual void BuildChar(StringBuilder sb, char value) sb.Append('\''); } + protected virtual void BuildDate(StringBuilder sb, object value) + { + sb.Append(string.Format("'{0:yyyy-MM-dd}'", value)); + } + protected virtual void BuildDateTime(StringBuilder sb, object value) { sb.Append(string.Format("'{0:yyyy-MM-dd HH:mm:ss.fff}'", value)); diff --git a/Source/Data/Sql/SqlProvider/DB2SqlProvider.cs b/Source/Data/Sql/SqlProvider/DB2SqlProvider.cs index 8df3b7e41..d5566d9e6 100644 --- a/Source/Data/Sql/SqlProvider/DB2SqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/DB2SqlProvider.cs @@ -218,7 +218,7 @@ protected override void BuildFromClause(StringBuilder sb) base.BuildFromClause(sb); } - public override void BuildValue(StringBuilder sb, object value) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (value is Guid) { diff --git a/Source/Data/Sql/SqlProvider/ISqlProvider.cs b/Source/Data/Sql/SqlProvider/ISqlProvider.cs index d5b2ccea5..23395a3c1 100644 --- a/Source/Data/Sql/SqlProvider/ISqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/ISqlProvider.cs @@ -22,6 +22,7 @@ public interface ISqlProvider string Name { get; } SqlQuery SqlQuery { get; set; } + bool UseQueryText { get; set; } bool SkipAcceptsParameter { get; } bool TakeAcceptsParameter { get; } diff --git a/Source/Data/Sql/SqlProvider/InformixSqlProvider.cs b/Source/Data/Sql/SqlProvider/InformixSqlProvider.cs index 7eebbacd9..b919384b3 100644 --- a/Source/Data/Sql/SqlProvider/InformixSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/InformixSqlProvider.cs @@ -184,7 +184,7 @@ public virtual object ConvertBooleanValue(bool value) return value ? 't' : 'f'; } - public override void BuildValue(StringBuilder sb, object value) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (value is bool || value is bool?) sb.Append("'").Append(ConvertBooleanValue((bool)value)).Append("'"); diff --git a/Source/Data/Sql/SqlProvider/MSSqlSqlProvider.cs b/Source/Data/Sql/SqlProvider/MSSqlSqlProvider.cs index ca8ab148d..e3856c3af 100644 --- a/Source/Data/Sql/SqlProvider/MSSqlSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/MSSqlSqlProvider.cs @@ -32,6 +32,21 @@ protected override void BuildGetIdentity(StringBuilder sb) .AppendLine() .AppendLine("SELECT SCOPE_IDENTITY()"); } + + protected override void BuildSetOutput( StringBuilder sb ) + { + // TODO: set the right data type + sb + .AppendLine() + .Append( "declare @tabTempInsert table(TempID " ).Append( "uniqueidentifier" ).AppendLine( ")" ); + } + + protected override void BuildGetOutput( StringBuilder sb ) + { + sb + .AppendLine() + .AppendLine( "select top 1 TempID from @tabTempInsert" ); + } protected override void BuildOrderByClause(StringBuilder sb) { @@ -225,12 +240,12 @@ protected override void BuildInsertOrUpdateQuery(StringBuilder sb) BuildInsertOrUpdateQueryAsUpdateInsert(sb); } - protected override void BuildDateTime(StringBuilder sb, object value) - { - sb.Append(string.Format("'{0:yyyy-MM-ddTHH:mm:ss.fff}'", value)); + protected override void BuildDateTime(StringBuilder sb, object value) + { + sb.Append(string.Format("'{0:yyyy-MM-ddTHH:mm:ss.fff}'", value)); } - public override void BuildValue(StringBuilder sb, object value) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (value is sbyte) sb.Append((byte)(sbyte)value); else if (value is ushort) sb.Append((short)(ushort)value); diff --git a/Source/Data/Sql/SqlProvider/MySqlSqlProvider.cs b/Source/Data/Sql/SqlProvider/MySqlSqlProvider.cs index 398ad868a..6b531df7f 100644 --- a/Source/Data/Sql/SqlProvider/MySqlSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/MySqlSqlProvider.cs @@ -304,7 +304,7 @@ protected override void BuildEmptyInsert(StringBuilder sb) public static bool GenerateOldGuid = false; - public override void BuildValue(StringBuilder sb, object value) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (GenerateOldGuid && value is Guid) { diff --git a/Source/Data/Sql/SqlProvider/OracleSqlProvider.cs b/Source/Data/Sql/SqlProvider/OracleSqlProvider.cs index 49e062284..6b8cfecf6 100644 --- a/Source/Data/Sql/SqlProvider/OracleSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/OracleSqlProvider.cs @@ -215,14 +215,14 @@ public override ISqlExpression ConvertExpression(ISqlExpression expr) return new SqlExpression(func.SystemType, "Cast({0} as {1})", Precedence.Primary, FloorBeforeConvert(func), func.Parameters[0]); } - case "ContainsExactly": - return func.Parameters.Length == 2 ? - new SqlFunction(func.SystemType, "Contains", func.Parameters[1], func.Parameters[0]) : - new SqlFunction(func.SystemType, "Contains", func.Parameters[1], func.Parameters[0], func.Parameters[2]); + case "ContainsExactly": + return func.Parameters.Length == 2 ? + new SqlFunction(func.SystemType, "Contains", func.Parameters[1], func.Parameters[0]) : + new SqlFunction(func.SystemType, "Contains", func.Parameters[1], func.Parameters[0], func.Parameters[2]); case "CharIndex" : - return func.Parameters.Length == 2? - new SqlFunction(func.SystemType, "InStr", func.Parameters[1], func.Parameters[0]): - new SqlFunction(func.SystemType, "InStr", func.Parameters[1], func.Parameters[0], func.Parameters[2]); + return func.Parameters.Length == 2 ? + new SqlFunction(func.SystemType, "InStr", func.Parameters[1], func.Parameters[0]) : + new SqlFunction(func.SystemType, "InStr", func.Parameters[1], func.Parameters[0], func.Parameters[2]); case "AddYear" : return new SqlFunction(func.SystemType, "Add_Months", func.Parameters[0], Mul(func.Parameters[1], 12)); case "AddQuarter" : return new SqlFunction(func.SystemType, "Add_Months", func.Parameters[0], Mul(func.Parameters[1], 3)); case "AddMonth" : return new SqlFunction(func.SystemType, "Add_Months", func.Parameters[0], func.Parameters[1]); @@ -302,34 +302,43 @@ protected override void BuildFromClause(StringBuilder sb) base.BuildFromClause(sb); } - public override void BuildValue(StringBuilder sb, object value) - { - if (value is Guid) - { - var s = ((Guid)value).ToString("N"); - - sb - .Append("Cast('") - .Append(s.Substring( 6, 2)) - .Append(s.Substring( 4, 2)) - .Append(s.Substring( 2, 2)) - .Append(s.Substring( 0, 2)) - .Append(s.Substring(10, 2)) - .Append(s.Substring( 8, 2)) - .Append(s.Substring(14, 2)) - .Append(s.Substring(12, 2)) - .Append(s.Substring(16, 16)) - .Append("' as raw(16))"); - } - else if (value is DateTime) - { - sb.AppendFormat("TO_TIMESTAMP('{0:yyyy-MM-dd HH:mm:ss.fffffff}', 'YYYY-MM-DD HH24:MI:SS.FF7')", value); - } - else - base.BuildValue(sb, value); - } - - protected override void BuildColumnExpression(StringBuilder sb, ISqlExpression expr, string alias, ref bool addAlias) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) + { + if (value is Guid) + { + var s = ((Guid) value).ToString("N"); + + sb + .Append("Cast('") + .Append(s.Substring(6, 2)) + .Append(s.Substring(4, 2)) + .Append(s.Substring(2, 2)) + .Append(s.Substring(0, 2)) + .Append(s.Substring(10, 2)) + .Append(s.Substring(8, 2)) + .Append(s.Substring(14, 2)) + .Append(s.Substring(12, 2)) + .Append(s.Substring(16, 16)) + .Append("' as raw(16))"); + } + else + base.BuildValue(sb, value, sqlParameter); + } + + protected override void BuildDate(StringBuilder sb, object value) + { + sb.AppendFormat("TO_DATE('{0:yyyy-MM-dd}', 'YYYY-MM-DD')", value); + } + + protected override void BuildDateTime(StringBuilder sb, object value) + { + var dt = (DateTime) value; + sb.AppendFormat(dt.Millisecond == 0 + ? "TO_DATE('{0:yyyy-MM-dd HH:mm:ss}', 'YYYY-MM-DD HH24:MI:SS')" + : "TO_TIMESTAMP('{0:yyyy-MM-dd HH:mm:ss.fffffff}', 'YYYY-MM-DD HH24:MI:SS.FF7')", value); + } + + protected override void BuildColumnExpression(StringBuilder sb, ISqlExpression expr, string alias, ref bool addAlias) { var wrap = false; diff --git a/Source/Data/Sql/SqlProvider/PostgreSQLSqlProvider.cs b/Source/Data/Sql/SqlProvider/PostgreSQLSqlProvider.cs index 1994393b0..8ddc52de8 100644 --- a/Source/Data/Sql/SqlProvider/PostgreSQLSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/PostgreSQLSqlProvider.cs @@ -97,7 +97,7 @@ public override ISqlExpression ConvertExpression(ISqlExpression expr) return expr; } - public override void BuildValue(StringBuilder sb, object value) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (value is bool) sb.Append(value); @@ -186,19 +186,18 @@ public override object Convert(object value, ConvertType convertType) return value; } - - public override ISqlExpression GetIdentityExpression(SqlTable table, SqlField identityField, bool forReturning) - { - if (table.SequenceAttributes != null) - { - var attr = GetSequenceNameAttribute(table, false); - - if (attr != null) - return new SqlExpression("nextval('" + attr.SequenceName+"')", Precedence.Primary); - } - - return base.GetIdentityExpression(table, identityField, forReturning); - } + + public override ISqlExpression GetIdentityExpression(SqlTable table, SqlField identityField, bool forReturning) + { + if (table.SequenceAttributes != null) + { + var attr = GetSequenceNameAttribute(table, false); + + if (attr != null) + return new SqlExpression("nextval('" + attr.SequenceName + "')", Precedence.Primary); + } + return base.GetIdentityExpression(table, identityField, forReturning); + } //protected override void BuildInsertOrUpdateQuery(StringBuilder sb) //{ diff --git a/Source/Data/Sql/SqlProvider/SQLiteSqlProvider.cs b/Source/Data/Sql/SqlProvider/SQLiteSqlProvider.cs index 9fc88771c..382eb1cc4 100644 --- a/Source/Data/Sql/SqlProvider/SQLiteSqlProvider.cs +++ b/Source/Data/Sql/SqlProvider/SQLiteSqlProvider.cs @@ -127,7 +127,7 @@ protected override void BuildFromClause(StringBuilder sb) base.BuildFromClause(sb); } - public override void BuildValue(StringBuilder sb, object value) + public override void BuildValue(StringBuilder sb, object value, SqlParameter sqlParameter = null) { if (value is Guid) { diff --git a/Source/Data/Sql/SqlQuery.cs b/Source/Data/Sql/SqlQuery.cs index 872916855..17dbacf1c 100644 --- a/Source/Data/Sql/SqlQuery.cs +++ b/Source/Data/Sql/SqlQuery.cs @@ -2183,7 +2183,7 @@ public SetExpression(ISqlExpression column, ISqlExpression expression) { Column = column; Expression = expression; - + if (expression is SqlParameter) { var p = (SqlParameter)expression; @@ -2204,7 +2204,7 @@ public SetExpression(ISqlExpression column, ISqlExpression expression) p.DbSize = field.MemberMapper.MapMemberInfo.DbSize; } } - } + } } public ISqlExpression Column { get; set; } @@ -2282,6 +2282,7 @@ public InsertClause() public List Items { get; private set; } public SqlTable Into { get; set; } public bool WithIdentity { get; set; } + public bool WithOutput { get; set; } #region Overrides @@ -2303,7 +2304,7 @@ public ICloneableElement Clone(Dictionary if (!doClone(this)) return this; - var clone = new InsertClause { WithIdentity = WithIdentity }; + var clone = new InsertClause { WithIdentity = WithIdentity, WithOutput = WithOutput }; if (Into != null) clone.Into = (SqlTable)Into.Clone(objectTree, doClone); @@ -3771,10 +3772,10 @@ internal static void OptimizeSearchCondition(SearchCondition searchCondition) void ForEachTable(Action action, HashSet visitedQueries) { - if (!visitedQueries.Add(this)) + if (!visitedQueries.Add(this)) return; - foreach (var table in From.Tables) + foreach (var table in From.Tables) table.ForEach(action, visitedQueries); new QueryVisitor().Visit(this, e => diff --git a/Source/Data/Sql/SqlTable.cs b/Source/Data/Sql/SqlTable.cs index a0104c9c0..e6e41b45a 100644 --- a/Source/Data/Sql/SqlTable.cs +++ b/Source/Data/Sql/SqlTable.cs @@ -96,7 +96,11 @@ public SqlTable([JetBrains.Annotations.NotNull] MappingSchema mappingSchema, Typ var om = mappingSchema.GetObjectMapper(ObjectType); var mm = om[identityField.Name, true]; - _sequenceAttributes = mm.MapMemberInfo.MemberAccessor.GetAttributes(); + var generator = mm.MapMemberInfo.KeyGenerator as SequenceKeyGenerator; + + _sequenceAttributes = generator != null + ? new[] {new SequenceNameAttribute(generator.Sequence)} + : mm.MapMemberInfo.MemberAccessor.GetAttributes(); } } diff --git a/Source/DataAccess/PrimaryKeyGeneratorType.cs b/Source/DataAccess/PrimaryKeyGeneratorType.cs deleted file mode 100644 index a05a0e98e..000000000 --- a/Source/DataAccess/PrimaryKeyGeneratorType.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace BLToolkit.DataAccess -{ - public enum PrimaryKeyGeneratorType - { - Sequence, - } -} \ No newline at end of file diff --git a/Source/DataAccess/SequenceKeyGenerator.cs b/Source/DataAccess/SequenceKeyGenerator.cs index 1ef2d81ce..b26198140 100644 --- a/Source/DataAccess/SequenceKeyGenerator.cs +++ b/Source/DataAccess/SequenceKeyGenerator.cs @@ -1,23 +1,26 @@ -using System; - namespace BLToolkit.DataAccess { - public class SequenceKeyGenerator : KeyGenerator - { - private readonly string _sequence; + /// + /// Wrapper class used to get the SequenceName attribute value and add it to the ObjectMapper class. + /// USeful for the SqlQuery InsertWithIdentity method + /// + public class SequenceKeyGenerator : KeyGenerator + { + private readonly string _sequence; - public SequenceKeyGenerator(string sequence) - { - _sequence = sequence; - } + public SequenceKeyGenerator(string sequence) + { + _sequence = sequence; + } - public string Sequence - { - get { return _sequence; } - } - } + public string Sequence + { + get { return _sequence; } + } + } - public class KeyGenerator - { - } + public class KeyGenerator + { + } } + diff --git a/Source/DataAccess/SqlQuery.cs b/Source/DataAccess/SqlQuery.cs index 29cad74c7..9298d3520 100644 --- a/Source/DataAccess/SqlQuery.cs +++ b/Source/DataAccess/SqlQuery.cs @@ -1,6 +1,5 @@ using System; using System.Collections; - using BLToolkit.Data; using BLToolkit.Reflection.Extension; @@ -202,9 +201,9 @@ public virtual TL SelectAll() #endregion - #region Insert + #region Insert - public virtual int Insert(DbManager db, object obj) + public virtual int Insert(DbManager db, object obj) { var query = GetSqlQueryInfo(db, obj.GetType(), "Insert"); diff --git a/Source/DataAccess/SqlQueryBase.cs b/Source/DataAccess/SqlQueryBase.cs index a1a9c8c32..42bf22dbe 100644 --- a/Source/DataAccess/SqlQueryBase.cs +++ b/Source/DataAccess/SqlQueryBase.cs @@ -1,6 +1,8 @@ using System; using System.Collections; using System.Collections.Generic; +using System.Data; +using System.Linq; using System.Text; using BLToolkit.Aspects; @@ -32,6 +34,36 @@ protected SqlQueryBase(DbManager dbManager, bool dispose) #endregion + #region InsertWithIdentity + + public virtual object InsertWithIdentity(DbManager db, object obj) + { + var query = GetSqlQueryInfo(db, obj.GetType(), "InsertWithIdentity"); + + var parameters = query.GetParameters(db, obj); + + db.SetCommand(query.QueryText, parameters).ExecuteNonQuery(); + + var outputParameter = parameters.ToList().First(e => e.Direction == ParameterDirection.Output); + return outputParameter.Value; + } + + public virtual object InsertWithIdentity(object obj) + { + var db = GetDbManager(); + + try + { + return InsertWithIdentity(db, obj); + } + finally + { + Dispose(db); + } + } + + #endregion + #region Protected Members [NoInterception] @@ -212,7 +244,7 @@ protected SqlQueryInfo CreateSelectAllSqlText(DbManager db, Type type) return query; } - protected SqlQueryInfo CreateInsertSqlText(DbManager db, Type type, int nParameter) + protected SqlQueryInfo CreateInsertSqlText(DbManager db, Type type, int nParameter, bool insertAutoSequence = false) { var typeExt = TypeExtension.GetTypeExtension(type, Extensions); var om = db.MappingSchema.GetObjectMapper(type); @@ -225,6 +257,7 @@ protected SqlQueryInfo CreateInsertSqlText(DbManager db, Type type, int nParamet AppendTableName(sb, db, type); sb.Append(" (\n"); + foreach (var mm in GetFieldList(om)) { // IT: This works incorrectly for complex mappers. @@ -233,37 +266,65 @@ protected SqlQueryInfo CreateInsertSqlText(DbManager db, Type type, int nParamet // as in CreateUpdateSqlText // - bool isSet; - var nonUpdatableAttribute = mp.GetNonUpdatableAttribute(type, typeExt, mm.MapMemberInfo.MemberAccessor, out isSet); - if (nonUpdatableAttribute == null || !isSet || nonUpdatableAttribute.OnInsert == false) - { - sb.AppendFormat("\t{0},\n", - db.DataProvider.Convert(mm.Name, ConvertType.NameToQueryField)); - list.Add(mm); - } + bool isSet; + var nonUpdatableAttribute = mp.GetNonUpdatableAttribute(type, typeExt, mm.MapMemberInfo.MemberAccessor, out isSet); + if (insertAutoSequence && nonUpdatableAttribute is IdentityAttribute) + { + sb.AppendFormat("\t{0},\n", db.DataProvider.Convert(mm.Name, ConvertType.NameToQueryField)); + list.Add(mm); + } + else + { + if (nonUpdatableAttribute == null || !isSet || nonUpdatableAttribute.IsIdentity || nonUpdatableAttribute.OnInsert == false) + { + sb.AppendFormat("\t{0},\n", db.DataProvider.Convert(mm.Name, ConvertType.NameToQueryField)); + list.Add(mm); + } + } } sb.Remove(sb.Length - 2, 1); sb.Append(") VALUES (\n"); - foreach (var mm in list) - { - var p = query.AddParameter( - db.DataProvider.Convert(mm.Name + "_P", ConvertType.NameToQueryParameter).ToString(), - mm.Name); + MemberMapper identityMember = null; + foreach (var mm in list) + { + var keyGenerator = mm.MapMemberInfo.KeyGenerator as SequenceKeyGenerator; + if (keyGenerator != null && insertAutoSequence) + { + string seqQuery = db.DataProvider.NextSequenceQuery(keyGenerator.Sequence); + sb.AppendFormat("\t{0},\n", seqQuery); + identityMember = mm; + } + else + { + // Previously : mm.Name + var p = query.AddParameter( + db.DataProvider.Convert(mm.MemberName + "_P", ConvertType.NameToQueryParameter).ToString(), + mm.Name); + + if (nParameter < 0) + sb.AppendFormat("\t{0},\n", p.ParameterName); + //sb.AppendFormat("\t{0},\n", db.DataProvider.Convert(p.ParameterName, ConvertType.NameToQueryParameter)); + else + sb.AppendFormat("\t{{{0}}},\n", nParameter++); + } + } + + sb.Remove(sb.Length - 2, 1); - if (nParameter < 0) - sb.AppendFormat("\t{0},\n", p.ParameterName); - //sb.AppendFormat("\t{0},\n", db.DataProvider.Convert(p.ParameterName, ConvertType.NameToQueryParameter)); - else - sb.AppendFormat("\t{{{0}}},\n", nParameter++); - } + sb.Append(")"); - sb.Remove(sb.Length - 2, 1); + if (identityMember != null) + { + sb.AppendFormat("\r\n{0}", db.DataProvider.GetReturningInto(identityMember.Name)); - sb.Append(")"); + query.AddParameter( + db.DataProvider.Convert("IDENTITY_PARAMETER", ConvertType.NameToQueryParameter).ToString(), + identityMember.Name); + } query.QueryText = sb.ToString(); @@ -349,11 +410,16 @@ protected virtual SqlQueryInfo CreateSqlText(DbManager db, Type type, string act switch (actionName) { case "SelectByKey": return CreateSelectByKeySqlText(db, type); - case "SelectAll": return CreateSelectAllSqlText (db, type); - case "Insert": return CreateInsertSqlText (db, type, -1); - case "InsertBatch": return CreateInsertSqlText (db, type, 0); + case "SelectAll": return CreateSelectAllSqlText (db, type); + + case "Insert": return CreateInsertSqlText (db, type, -1, false); + case "InsertWithIdentity": return CreateInsertSqlText(db, type, -1, true); + case "InsertBatch": return CreateInsertSqlText(db, type, 0, false); + case "InsertBatchWithIdentity": return CreateInsertSqlText(db, type, 0, db.UseQueryText || db.Transaction != null); + case "Update": return CreateUpdateSqlText (db, type, -1); case "UpdateBatch": return CreateUpdateSqlText (db, type, 0); + case "Delete": return CreateDeleteSqlText (db, type, -1); case "DeleteBatch": return CreateDeleteSqlText (db, type, 0); default: @@ -364,6 +430,11 @@ protected virtual SqlQueryInfo CreateSqlText(DbManager db, Type type, string act private static readonly Hashtable _actionSqlQueryInfo = new Hashtable(); + public static void ClearCache() + { + _actionSqlQueryInfo.Clear(); + } + [NoInterception] public virtual SqlQueryInfo GetSqlQueryInfo(DbManager db, Type type, string actionName) { @@ -373,7 +444,9 @@ public virtual SqlQueryInfo GetSqlQueryInfo(DbManager db, Type type, string acti if (query == null) { query = CreateSqlText(db, type, actionName); - _actionSqlQueryInfo[key] = query; + query.OwnerName = GetOwnerName(type); + query.ActionName = actionName; + _actionSqlQueryInfo[key] = query; } return query; diff --git a/Source/DataAccess/SqlQueryInfo.cs b/Source/DataAccess/SqlQueryInfo.cs index 1b3019d8f..6bbd9c1cd 100644 --- a/Source/DataAccess/SqlQueryInfo.cs +++ b/Source/DataAccess/SqlQueryInfo.cs @@ -19,6 +19,8 @@ public SqlQueryInfo(ObjectMapper objectMapper) ObjectMapper = objectMapper; } + public string OwnerName { get; set; } + public string ActionName { get; set; } public string QueryText { get; set; } public ObjectMapper ObjectMapper { get; private set; } @@ -74,22 +76,27 @@ public IDbDataParameter[] GetParameters(DbManager db, object obj) if (val == null && mmi.Nullable/* && mmi.NullValue == null*/) { - //replace value with DbNull - val = DBNull.Value; - } - - if (mmi.IsDbTypeSet) - { - parameters[i] = mmi.IsDbSizeSet - ? db.Parameter(info.ParameterName, val, info.MemberMapper.DbType, mmi.DbSize) - : db.Parameter(info.ParameterName, val, info.MemberMapper.DbType); - } - else - { - parameters[i] = val != DBNull.Value - ? db.Parameter(info.ParameterName, val) - : db.Parameter(info.ParameterName, val, info.MemberMapper.GetDbType()); - } + //replace value with DbNull + val = DBNull.Value; + } + + if (mmi.IsDbTypeSet) + { + parameters[i] = mmi.IsDbSizeSet + ? db.Parameter(info.ParameterName, val, info.MemberMapper.DbType, mmi.DbSize) + : db.Parameter(info.ParameterName, val, info.MemberMapper.DbType); + } + else + { + parameters[i] = val != DBNull.Value + ? db.Parameter(info.ParameterName, val) + : db.Parameter(info.ParameterName, val, info.MemberMapper.GetDbType()); + } + + if (mmi.KeyGenerator is SequenceKeyGenerator && ActionName == "InsertWithIdentity") + { + parameters[i] = db.OutputParameter(info.ParameterName, val); + } } return parameters; @@ -97,12 +104,12 @@ public IDbDataParameter[] GetParameters(DbManager db, object obj) public MemberMapper[] GetMemberMappers() { - var members = new MemberMapper[Parameters.Count]; + var members = new MemberMapper[Parameters.Count]; - for (var i = 0; i < Parameters.Count; i++) - members[i] = Parameters[i].MemberMapper; + for (var i = 0; i < Parameters.Count; i++) + members[i] = Parameters[i].MemberMapper; - return members; + return members; } } } diff --git a/Source/DataAccess/SqlQueryT.cs b/Source/DataAccess/SqlQueryT.cs index 76800974a..d9d6b8911 100644 --- a/Source/DataAccess/SqlQueryT.cs +++ b/Source/DataAccess/SqlQueryT.cs @@ -1,4 +1,3 @@ -using System; using System.Collections.Generic; namespace BLToolkit.DataAccess @@ -7,7 +6,7 @@ namespace BLToolkit.DataAccess using Mapping; using Reflection.Extension; - public class SqlQuery : SqlQueryBase + public class SqlQuery : SqlQueryBase, ISqlQueryT { #region Constructors @@ -149,6 +148,16 @@ public virtual int Insert(DbManager db, T obj) .ExecuteNonQuery(); } + public virtual object InsertWithIdentity(DbManager db, T obj) + { + return base.InsertWithIdentity(db, obj); + } + + public virtual object InsertWithIdentity(T obj) + { + return base.InsertWithIdentity(obj); + } + public virtual int Insert(T obj) { var db = GetDbManager(); @@ -164,9 +173,22 @@ public virtual int Insert(T obj) } } + public virtual int InsertBatchWithIdentity(DbManager db, int maxBatchSize, IEnumerable list) + { + var query = GetSqlQueryInfo(db, typeof(T), "InsertBatchWithIdentity"); + + return db.DataProvider.InsertBatchWithIdentity( + db, + query.QueryText, + list, + query.GetMemberMappers(), + maxBatchSize, + obj => query.GetParameters(db, obj)); + } + public virtual int Insert(DbManager db, int maxBatchSize, IEnumerable list) { - var query = GetSqlQueryInfo(db, typeof(T), "InsertBatch"); + var query = GetSqlQueryInfo(db, typeof(T), "InsertBatch"); return db.DataProvider.InsertBatch( db, diff --git a/Source/Mapping/MapMemberInfo.cs b/Source/Mapping/MapMemberInfo.cs index c1f18af17..9dc057e4a 100644 --- a/Source/Mapping/MapMemberInfo.cs +++ b/Source/Mapping/MapMemberInfo.cs @@ -2,7 +2,6 @@ using System.Collections.Generic; using System.Data; using System.Diagnostics; - using BLToolkit.DataAccess; using BLToolkit.Reflection; using BLToolkit.Reflection.Extension; @@ -34,9 +33,9 @@ public MapMemberInfo() public bool IsDbSizeSet { get; set; } public MappingSchema MappingSchema { get; set; } public MemberExtension MemberExtension { get; set; } - public DbType DbType { get; set; } + public DbType DbType { get; set; } public KeyGenerator KeyGenerator { get; set; } - + private MapValue[] _mapValues; public MapValue[] MapValues { @@ -96,6 +95,6 @@ private void CacheMapValues() if (!_origValueCache.ContainsKey(mv.OrigValue)) _origValueCache[mv.OrigValue] = mv.MapValues[0]; } - } + } } } diff --git a/Source/Mapping/MappingSchema.cs b/Source/Mapping/MappingSchema.cs index 243bfc3b3..1df141c97 100644 --- a/Source/Mapping/MappingSchema.cs +++ b/Source/Mapping/MappingSchema.cs @@ -50,6 +50,22 @@ public MappingSchema() private readonly Dictionary _mappers = new Dictionary(); private readonly Dictionary _pendingMappers = new Dictionary(); + private readonly Dictionary _mappersSequences = new Dictionary(); + + public void SetMappingTypeSequence(Type type, string sequenceName) + { + lock (_mappers) + { + _mappersSequences[type] = sequenceName; + + ObjectMapper om; + if (_mappers.TryGetValue(type, out om)) + { + om.SetMappingTypeSequence(sequenceName); + } + } + } + public ObjectMapper GetObjectMapper(Type type) { ObjectMapper om; @@ -76,6 +92,10 @@ public ObjectMapper GetObjectMapper(Type type) try { om.Init(this, type); + if (_mappersSequences.ContainsKey(type)) + { + om.SetMappingTypeSequence(_mappersSequences[type]); + } } finally { @@ -1411,21 +1431,6 @@ internal protected static int[] GetIndex( return index; } - [CLSCompliant(false), Obsolete] - protected static void MapInternal( - IMapDataSource source, object sourceObject, - IMapDataDestination dest, object destObject, - int[] index) - { - for (int i = 0; i < index.Length; i++) - { - int n = index[i]; - - if (n >= 0) - dest.SetValue(destObject, n, source.GetValue(sourceObject, i)); - } - } - [CLSCompliant(false)] internal protected static void MapInternal( IMapDataSource source, object sourceObject, @@ -1680,26 +1685,26 @@ public virtual object MapValueToEnum(object value, Type type) value = ConvertChangeType(value, mapValueType); } - if (mapValues != null) - { - var comp = (IComparable)value; - - foreach (MapValue mv in mapValues) - foreach (object mapValue in mv.MapValues) - { - try - { - if (comp.CompareTo(mapValue) == 0) - return mv.OrigValue; - } - catch (ArgumentException ex) - { - Debug.WriteLine(ex.Message, MethodBase.GetCurrentMethod().Name); - } - } - } - - InvalidCastException exInvalidCast = null; + if (mapValues != null) + { + var comp = (IComparable) value; + + foreach (MapValue mv in mapValues) + foreach (object mapValue in mv.MapValues) + { + try + { + if (comp.CompareTo(mapValue) == 0) + return mv.OrigValue; + } + catch (ArgumentException ex) + { + Debug.WriteLine(ex.Message, MethodBase.GetCurrentMethod().Name); + } + } + } + + InvalidCastException exInvalidCast = null; var enumType = TypeHelper.UnwrapNullableType(type); try @@ -2123,15 +2128,7 @@ public object MapDataRowToObject( object destObject, params object[] parameters) { - if (destObject == null) throw new ArgumentNullException("destObject"); - - MapInternal( - null, - CreateDataRowMapper(dataRow, DataRowVersion.Default), dataRow, - GetObjectMapper(destObject. GetType()), destObject, - parameters); - - return destObject; + return MapDataRowToObject(dataRow, DataRowVersion.Default, destObject, parameters); } public object MapDataRowToObject( @@ -2156,15 +2153,7 @@ public object MapDataRowToObject( Type destObjectType, params object[] parameters) { - InitContext ctx = new InitContext(); - - ctx.MappingSchema = this; - ctx.DataSource = CreateDataRowMapper(dataRow, DataRowVersion.Default); - ctx.SourceObject = dataRow; - ctx.ObjectMapper = GetObjectMapper(destObjectType); - ctx.Parameters = parameters; - - return MapInternal(ctx); + return MapDataRowToObject(dataRow, DataRowVersion.Default, destObjectType, parameters); } public object MapDataRowToObject( @@ -2184,21 +2173,6 @@ public object MapDataRowToObject( return MapInternal(ctx); } - public T MapDataRowToObject( - DataRow dataRow, - params object[] parameters) - { - return (T)MapDataRowToObject(dataRow, typeof(T), parameters); - } - - public T MapDataRowToObject( - DataRow dataRow, - DataRowVersion version, - params object[] parameters) - { - return (T)MapDataRowToObject(dataRow, version, typeof(T), parameters); - } - #endregion #region MapDataRowToDataRow @@ -2358,12 +2332,11 @@ public object MapDataReaderToObject( return destObject; } - //NOTE changed to virtual public virtual object MapDataReaderToObject( IDataReader dataReader, Type destObjectType, params object[] parameters) - { + { InitContext ctx = new InitContext(); ctx.MappingSchema = this; @@ -2375,6 +2348,7 @@ public virtual object MapDataReaderToObject( return MapInternal(ctx); } + //TODO Remove unused method public T MapDataReaderToObject( IDataReader dataReader, params object[] parameters) @@ -3101,8 +3075,8 @@ public Dictionary MapDataTableToDictionary( #region DataReader #region MapDataReaderToList - - public virtual IList MapDataReaderToList( + + public virtual IList MapDataReaderToList( IDataReader reader, IList list, Type destObjectType, @@ -3123,24 +3097,15 @@ public IList MapDataReaderToList( { IList list = new List(); - MapSourceListToDestinationList( - CreateDataReaderListMapper(reader), - CreateObjectListMapper (list, GetObjectMapper(destObjectType)), - parameters); - - return list; + return MapDataReaderToList(reader, list, destObjectType, parameters); } - //NOTE changed to virtual - public virtual IList MapDataReaderToList( + public IList MapDataReaderToList( IDataReader reader, IList list, params object[] parameters) { - MapSourceListToDestinationList( - CreateDataReaderListMapper(reader), - CreateObjectListMapper ((IList)list, GetObjectMapper(typeof(T))), - parameters); + MapDataReaderToList(reader, (IList) list, typeof (T), parameters); return list; } @@ -3151,12 +3116,9 @@ public List MapDataReaderToList( { List list = new List(); - MapSourceListToDestinationList( - CreateDataReaderListMapper(reader), - CreateObjectListMapper (list, GetObjectMapper(typeof(T))), - parameters); + MapDataReaderToList(reader, list, parameters); - return list; + return list; } #endregion diff --git a/Source/Mapping/MemberMappers/JSONSerialisationMapper.cs b/Source/Mapping/MemberMappers/JSONSerialisationMapper.cs index 712912750..eb4eafa49 100644 --- a/Source/Mapping/MemberMappers/JSONSerialisationMapper.cs +++ b/Source/Mapping/MemberMappers/JSONSerialisationMapper.cs @@ -11,15 +11,15 @@ public override void SetValue(object o, object value) { if (value != null) this.MemberAccessor.SetValue(o, Deserialize(value.ToString())); } - + public override object GetValue(object o) { return this.serialize(this.MemberAccessor.GetValue(o)); } private string serialize(object obj) - { - if (obj == null) return null; + { + if (obj == null) return null; DataContractJsonSerializer ser = new DataContractJsonSerializer(this.Type); MemoryStream ms = new MemoryStream(); diff --git a/Source/Mapping/MemberMappers/TimeSpanBigIntMapper.cs b/Source/Mapping/MemberMappers/TimeSpanBigIntMapper.cs index b8bfe6f77..ee4b62ff0 100644 --- a/Source/Mapping/MemberMappers/TimeSpanBigIntMapper.cs +++ b/Source/Mapping/MemberMappers/TimeSpanBigIntMapper.cs @@ -1,6 +1,8 @@ -using System; -using System.IO; -using System.Runtime.Serialization.Formatters.Binary; +#region + +using System; + +#endregion namespace BLToolkit.Mapping.MemberMappers { @@ -8,15 +10,15 @@ public class TimeSpanBigIntMapper : MemberMapper { public override void SetValue(object o, object value) { - if (value != null) this.MemberAccessor.SetValue(o, new TimeSpan((long)value)); + if (value != null) MemberAccessor.SetValue(o, new TimeSpan(Convert.ToInt64(value))); } public override object GetValue(object o) { - var val = this.MemberAccessor.GetValue(o); + var val = MemberAccessor.GetValue(o); if (val != null) return ((TimeSpan) val).Ticks; - return null; - } + return null; + } } -} +} \ No newline at end of file diff --git a/Source/Mapping/ObjectMapper.cs b/Source/Mapping/ObjectMapper.cs index 8f4460bef..17f4e1aa7 100644 --- a/Source/Mapping/ObjectMapper.cs +++ b/Source/Mapping/ObjectMapper.cs @@ -239,6 +239,18 @@ public MappingSchema MappingSchema #region Init Mapper + public void SetMappingTypeSequence(string sequenceName) + { + foreach (var memberMapper in _members) + { + if (memberMapper.MapMemberInfo.KeyGenerator != null) + { + memberMapper.MapMemberInfo.KeyGenerator = new SequenceKeyGenerator(sequenceName); + break; + } + } + } + public virtual void Init(MappingSchema mappingSchema, Type type) { if (type == null) throw new ArgumentNullException("type"); @@ -296,6 +308,7 @@ public virtual void Init(MappingSchema mappingSchema, Type type) mi.DefaultValue = GetDefaultValue(ma); mi.Nullable = GetNullable (ma); mi.NullValue = GetNullValue (ma, mi.Nullable); + mi.KeyGenerator = GetKeyGenerator(ma); Add(CreateMemberMapper(mi)); } @@ -433,6 +446,7 @@ protected MemberMapper GetComplexMapper(string mapName, string origName) // So we cache failed requests. // If this optimization is a memory leak for you, just comment out next line. // + // TODO : Should we add an option property? if (_nameToComplexMapper.ContainsKey(name)) _nameToComplexMapper[name] = null; else @@ -510,6 +524,25 @@ protected virtual string GetFieldName(MemberAccessor memberAccessor) return MetadataProvider.GetFieldName(Extension, memberAccessor, out isSet); } + protected virtual KeyGenerator GetKeyGenerator(MemberAccessor memberAccessor) + { + bool isSet; + var nonUpdatableAttribute = MetadataProvider.GetNonUpdatableAttribute(memberAccessor.Type, Extension, memberAccessor, out isSet); + if (isSet && nonUpdatableAttribute is IdentityAttribute) + { + bool isSeqSet; + string sequenceName = MetadataProvider.GetSequenceName(Extension, memberAccessor, out isSeqSet); + if (!isSeqSet) + throw new NotImplementedException("Identity without sequence"); + + if (string.IsNullOrWhiteSpace(sequenceName)) + throw new Exception("SequenceName is empty"); + + return new SequenceKeyGenerator(sequenceName); + } + return null; + } + protected virtual string GetFieldStorage(MemberAccessor memberAccessor) { bool isSet; diff --git a/Source/Properties/BLToolkitConstants.cs b/Source/Properties/BLToolkitConstants.cs index 947217dbb..32df00dc3 100644 --- a/Source/Properties/BLToolkitConstants.cs +++ b/Source/Properties/BLToolkitConstants.cs @@ -25,7 +25,7 @@ public static partial class BLToolkitConstants /// /// Full version string. /// - public const string FullVersionString = MajorVersion + "." + MinorVersion + "." + Build + "." + Revision; + public const string FullVersionString = MajorVersion + "." + MinorVersion + "." + Build + "." + AutoRevision; /// /// Full BLT version. @@ -36,4 +36,12 @@ public static partial class BLToolkitConstants public const string ProductDescription = "Business Logic Toolkit for .NET"; public const string Copyright = "\xA9 2002-2013 www.bltoolkit.net"; } + + partial class BLToolkitConstants + { + // + // Revision component of version. + // + public const string AutoRevision = "15"; + } } diff --git a/Extensions/JointureAddOn/Emit/DynamicCompilationSpike.cs b/Source/Reflection/Emit/DynamicCompilationSpike.cs similarity index 100% rename from Extensions/JointureAddOn/Emit/DynamicCompilationSpike.cs rename to Source/Reflection/Emit/DynamicCompilationSpike.cs diff --git a/Extensions/JointureAddOn/Emit/FunctionFactory.cs b/Source/Reflection/Emit/FunctionFactory.cs similarity index 100% rename from Extensions/JointureAddOn/Emit/FunctionFactory.cs rename to Source/Reflection/Emit/FunctionFactory.cs diff --git a/Source/Reflection/MemberAccessor.cs b/Source/Reflection/MemberAccessor.cs index 22f36ba6c..33b51edb9 100644 --- a/Source/Reflection/MemberAccessor.cs +++ b/Source/Reflection/MemberAccessor.cs @@ -1,12 +1,16 @@ using System; -using System.Data.SqlTypes; using System.Linq.Expressions; -using System.Reflection; -using System.ComponentModel; +using System.Reflection; using BLToolkit.Data.Linq; +#if DATA +using System.Data.SqlTypes; +#endif + #if !SILVERLIGHT && !DATA using BLToolkit.ComponentModel; +using System.ComponentModel; +using System.Data.SqlTypes; #endif namespace BLToolkit.Reflection diff --git a/Source/Reflection/MetadataProvider/AttributeMetadataProvider.cs b/Source/Reflection/MetadataProvider/AttributeMetadataProvider.cs index 8a4b6ae48..8fc09afdc 100644 --- a/Source/Reflection/MetadataProvider/AttributeMetadataProvider.cs +++ b/Source/Reflection/MetadataProvider/AttributeMetadataProvider.cs @@ -594,7 +594,13 @@ public override string GetDatabaseName(Type type, ExtensionList extensions, out public override string GetOwnerName(Type type, ExtensionList extensions, out bool isSet) { - var attrs = type.GetCustomAttributes(typeof(TableNameAttribute), true); + if (_typesOwners.ContainsKey(type)) + { + isSet = true; + return _typesOwners[type]; + } + + var attrs = type.GetCustomAttributes(typeof(TableNameAttribute), true); if (attrs.Length > 0) { @@ -606,7 +612,15 @@ public override string GetOwnerName(Type type, ExtensionList extensions, out boo return base.GetOwnerName(type, extensions, out isSet); } - #endregion + private readonly Dictionary _typesOwners = new Dictionary(); + + public override void SetOwnerName(Type type, string ownerName) + { + _typesOwners[type] = ownerName; + base.SetOwnerName(type, ownerName); + } + + #endregion #region GetTableName @@ -642,19 +656,19 @@ public override int GetPrimaryKeyOrder(Type type, TypeExtension typeExt, MemberA } #endregion - - public override string GetSequenceName(TypeExtension typeExtension, MemberAccessor member, out bool isSet) - { - var attr = member.GetAttribute(); - - if (attr != null) - { - isSet = true; - return attr.SequenceName; - } - - return base.GetSequenceName(typeExtension, member, out isSet); - } + + public override string GetSequenceName(TypeExtension typeExtension, MemberAccessor member, out bool isSet) + { + var attr = member.GetAttribute(); + + if (attr != null) + { + isSet = true; + return attr.SequenceName; + } + + return base.GetSequenceName(typeExtension, member, out isSet); + } #region GetNonUpdatableFlag diff --git a/Source/Reflection/MetadataProvider/MetadataProviderBase.cs b/Source/Reflection/MetadataProvider/MetadataProviderBase.cs index 550b9be4e..661ecdb10 100644 --- a/Source/Reflection/MetadataProvider/MetadataProviderBase.cs +++ b/Source/Reflection/MetadataProvider/MetadataProviderBase.cs @@ -41,12 +41,12 @@ public virtual string GetFieldName(TypeExtension typeExtension, MemberAccessor m } #endregion - - public virtual string GetSequenceName(TypeExtension typeExtension, MemberAccessor member, out bool isSet) - { - isSet = false; - return null; - } + + public virtual string GetSequenceName(TypeExtension typeExtension, MemberAccessor member, out bool isSet) + { + isSet = false; + return null; + } #region GetFieldStorage @@ -229,6 +229,11 @@ public virtual string GetOwnerName(Type type, ExtensionList extensions, out bool return null; } + public virtual void SetOwnerName(Type type, string ownerName) + { + + } + #endregion #region GetTableName diff --git a/Source/Reflection/MetadataProvider/MetadataProviderList.cs b/Source/Reflection/MetadataProvider/MetadataProviderList.cs index 123788593..d06b81bcf 100644 --- a/Source/Reflection/MetadataProvider/MetadataProviderList.cs +++ b/Source/Reflection/MetadataProvider/MetadataProviderList.cs @@ -336,7 +336,16 @@ public override string GetOwnerName(Type type, ExtensionList extensions, out boo return base.GetOwnerName(type, extensions, out isSet); } - #endregion + public override void SetOwnerName(Type type, string ownerName) + { + foreach (var providerBase in _list) + { + providerBase.SetOwnerName(type, ownerName); + } + base.SetOwnerName(type, ownerName); + } + + #endregion #region GetTableName diff --git a/Tools/Templates/MySqlDataModel.generated.cs b/Tools/Templates/MySqlDataModel.generated.cs index 216a77b27..42e937ae1 100644 --- a/Tools/Templates/MySqlDataModel.generated.cs +++ b/Tools/Templates/MySqlDataModel.generated.cs @@ -1,180 +1,180 @@ -//--------------------------------------------------------------------------------------------------- -// -// This code was generated by BLToolkit template for T4. -// Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. -// -//--------------------------------------------------------------------------------------------------- -using System; - -using BLToolkit.Data; -using BLToolkit.Data.Linq; -using BLToolkit.DataAccess; -using BLToolkit.Mapping; -using BLToolkit.Validation; - -namespace MySqlDataModel -{ - public partial class MySqlDataContext : DbManager - { - public Table alltypes { get { return this.GetTable(); } } - public Table binarydata { get { return this.GetTable(); } } - public Table child { get { return this.GetTable(); } } - public Table datatypetest { get { return this.GetTable(); } } - public Table doctor { get { return this.GetTable(); } } - public Table grandchild { get { return this.GetTable(); } } - public Table linqdatatypes { get { return this.GetTable(); } } - public Table parent { get { return this.GetTable(); } } - public Table patient { get { return this.GetTable(); } } - public Table person { get { return this.GetTable(); } } - public Table testidentity { get { return this.GetTable(); } } - } - - [TableName(Name="alltypes")] - public partial class alltypes - { - [Identity, PrimaryKey(1), Required ] public int ID { get; set; } // int(10) - [Nullable ] public long? bigintDataType { get; set; } // bigint(19) - [Nullable ] public short? smallintDataType { get; set; } // smallint(5) - [Nullable ] public sbyte? tinyintDataType { get; set; } // tinyint(3) - [Nullable ] public int? mediumintDataType { get; set; } // mediumint(7) - [Nullable ] public int? intDataType { get; set; } // int(10) - [Nullable ] public decimal? numericDataType { get; set; } // decimal(10) - [Nullable ] public decimal? decimalDataType { get; set; } // decimal(10) - [Nullable ] public double? doubleDataType { get; set; } // double(22) - [Nullable ] public float? floatDataType { get; set; } // float(12) - [Nullable ] public DateTime? dateDataType { get; set; } // date - [Nullable ] public DateTime? datetimeDataType { get; set; } // datetime - [Nullable ] public DateTime? timestampDataType { get; set; } // timestamp - [Nullable ] public DateTime? timeDataType { get; set; } // time - [Nullable ] public DateTime? yearDataType { get; set; } // year - [Nullable ] public DateTime? year2DataType { get; set; } // year - [Nullable ] public DateTime? year4DataType { get; set; } // year - [Nullable, MaxLength( 1)] public string charDataType { get; set; } // char(1) - [Nullable, MaxLength( 20)] public string varcharDataType { get; set; } // varchar(20) - [Nullable, MaxLength(65535)] public string textDataType { get; set; } // text(65535) - [Nullable ] public byte[] binaryDataType { get; set; } // binary(3) - [Nullable ] public byte[] varbinaryDataType { get; set; } // varbinary(5) - [Nullable ] public byte[] blobDataType { get; set; } // blob(65535) - [Nullable ] public bool? bitDataType { get; set; } // bit(3) - [Nullable, MaxLength( 5)] public string enumDataType { get; set; } // enum(5) - [Nullable, MaxLength( 7)] public string setDataType { get; set; } // set(7) - } - - [TableName(Name="binarydata")] - public partial class binarydata - { - [Identity, PrimaryKey(1), Required ] public int BinaryDataID { get; set; } // int(10) - [ NonUpdatable(OnInsert = true, OnUpdate = true), Required] public DateTime Stamp { get; set; } // timestamp - [ Required ] public byte[] Data { get; set; } // varbinary(1024) - } - - [TableName(Name="child")] - public partial class child - { - [Nullable] public int? ParentID { get; set; } // int(10) - [Nullable] public int? ChildID { get; set; } // int(10) - } - - [TableName(Name="datatypetest")] - public partial class datatypetest - { - [Identity, PrimaryKey(1), Required ] public int DataTypeID { get; set; } // int(10) - [Nullable ] public byte[] Binary_ { get; set; } // binary(50) - [ Required ] public bool Boolean_ { get; set; } // bit(1) - [Nullable ] public sbyte? Byte_ { get; set; } // tinyint(3) - [Nullable ] public byte[] Bytes_ { get; set; } // varbinary(50) - [Nullable, MaxLength( 1)] public string Char_ { get; set; } // char(1) - [Nullable ] public DateTime? DateTime_ { get; set; } // datetime - [Nullable ] public decimal? Decimal_ { get; set; } // decimal(20,2) - [Nullable ] public float? Double_ { get; set; } // float(12) - [Nullable ] public byte[] Guid_ { get; set; } // varbinary(50) - [Nullable ] public short? Int16_ { get; set; } // smallint(5) - [Nullable ] public int? Int32_ { get; set; } // int(10) - [Nullable ] public long? Int64_ { get; set; } // bigint(19) - [Nullable ] public decimal? Money_ { get; set; } // decimal(20,4) - [Nullable ] public sbyte? SByte_ { get; set; } // tinyint(3) - [Nullable ] public double? Single_ { get; set; } // double(22) - [Nullable ] public byte[] Stream_ { get; set; } // varbinary(50) - [Nullable, MaxLength( 50)] public string String_ { get; set; } // varchar(50) - [Nullable ] public short? UInt16_ { get; set; } // smallint(5) - [Nullable ] public int? UInt32_ { get; set; } // int(10) - [Nullable ] public long? UInt64_ { get; set; } // bigint(19) - [Nullable, MaxLength(1000)] public string Xml_ { get; set; } // varchar(1000) - } - - [TableName(Name="doctor")] - public partial class doctor - { - [PrimaryKey(1), Required ] public int PersonID { get; set; } // int(10) - [ MaxLength(50), Required] public string Taxonomy { get; set; } // varchar(50) - - // FK_Doctor_Person - [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=false)] - public person DoctorPerson { get; set; } - } - - [TableName(Name="grandchild")] - public partial class grandchild - { - [Nullable] public int? ParentID { get; set; } // int(10) - [Nullable] public int? ChildID { get; set; } // int(10) - [Nullable] public int? GrandChildID { get; set; } // int(10) - } - - [TableName(Name="linqdatatypes")] - public partial class linqdatatypes - { - [Nullable ] public int? ID { get; set; } // int(10) - [Nullable ] public decimal? MoneyValue { get; set; } // decimal(10,4) - [Nullable ] public DateTime? DateTimeValue { get; set; } // datetime - [Nullable ] public DateTime? DateTimeValue2 { get; set; } // datetime - [Nullable ] public bool? BoolValue { get; set; } // tinyint(3) - [Nullable, MaxLength(36)] public string GuidValue { get; set; } // char(36) - [Nullable ] public byte[] BinaryValue { get; set; } // varbinary(5000) - [Nullable ] public short? SmallIntValue { get; set; } // smallint(5) - [Nullable ] public int? IntValue { get; set; } // int(10) - [Nullable ] public long? BigIntValue { get; set; } // bigint(19) - } - - [TableName(Name="parent")] - public partial class parent - { - [Nullable] public int? ParentID { get; set; } // int(10) - [Nullable] public int? Value1 { get; set; } // int(10) - } - - [TableName(Name="patient")] - public partial class patient - { - [PrimaryKey(1), Required ] public int PersonID { get; set; } // int(10) - [ MaxLength(256), Required] public string Diagnosis { get; set; } // varchar(256) - - // FK_Patient_Person - [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=false)] - public person PatientPerson { get; set; } - } - - [TableName(Name="person")] - public partial class person - { - [Identity, PrimaryKey(1), Required ] public int PersonID { get; set; } // int(10) - [ MaxLength(50), Required] public string FirstName { get; set; } // varchar(50) - [ MaxLength(50), Required] public string LastName { get; set; } // varchar(50) - [Nullable, MaxLength(50) ] public string MiddleName { get; set; } // varchar(50) - [ MaxLength( 1), Required] public string Gender { get; set; } // char(1) - - // FK_Doctor_Person_BackReference - [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=true)] - public doctor DoctorPerson { get; set; } - - // FK_Patient_Person_BackReference - [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=true)] - public patient PatientPerson { get; set; } - } - - [TableName(Name="testidentity")] - public partial class testidentity - { - [Identity, PrimaryKey(1), Required] public int ID { get; set; } // int(10) - } -} +//--------------------------------------------------------------------------------------------------- +// +// This code was generated by BLToolkit template for T4. +// Changes to this file may cause incorrect behavior and will be lost if the code is regenerated. +// +//--------------------------------------------------------------------------------------------------- +using System; + +using BLToolkit.Data; +using BLToolkit.Data.Linq; +using BLToolkit.DataAccess; +using BLToolkit.Mapping; +using BLToolkit.Validation; + +namespace MySqlDataModel +{ + public partial class MySqlDataContext : DbManager + { + public Table alltypes { get { return this.GetTable(); } } + public Table binarydata { get { return this.GetTable(); } } + public Table child { get { return this.GetTable(); } } + public Table datatypetest { get { return this.GetTable(); } } + public Table doctor { get { return this.GetTable(); } } + public Table grandchild { get { return this.GetTable(); } } + public Table linqdatatypes { get { return this.GetTable(); } } + public Table parent { get { return this.GetTable(); } } + public Table patient { get { return this.GetTable(); } } + public Table person { get { return this.GetTable(); } } + public Table testidentity { get { return this.GetTable(); } } + } + + [TableName(Name="alltypes")] + public partial class alltypes + { + [Identity, PrimaryKey(1), Required ] public int ID { get; set; } // int(10) + [Nullable ] public long? bigintDataType { get; set; } // bigint(19) + [Nullable ] public short? smallintDataType { get; set; } // smallint(5) + [Nullable ] public sbyte? tinyintDataType { get; set; } // tinyint(3) + [Nullable ] public int? mediumintDataType { get; set; } // mediumint(7) + [Nullable ] public int? intDataType { get; set; } // int(10) + [Nullable ] public decimal? numericDataType { get; set; } // decimal(10) + [Nullable ] public decimal? decimalDataType { get; set; } // decimal(10) + [Nullable ] public double? doubleDataType { get; set; } // double(22) + [Nullable ] public float? floatDataType { get; set; } // float(12) + [Nullable ] public DateTime? dateDataType { get; set; } // date + [Nullable ] public DateTime? datetimeDataType { get; set; } // datetime + [Nullable ] public DateTime? timestampDataType { get; set; } // timestamp + [Nullable ] public DateTime? timeDataType { get; set; } // time + [Nullable ] public DateTime? yearDataType { get; set; } // year + [Nullable ] public DateTime? year2DataType { get; set; } // year + [Nullable ] public DateTime? year4DataType { get; set; } // year + [Nullable, MaxLength( 1)] public string charDataType { get; set; } // char(1) + [Nullable, MaxLength( 20)] public string varcharDataType { get; set; } // varchar(20) + [Nullable, MaxLength(65535)] public string textDataType { get; set; } // text(65535) + [Nullable ] public byte[] binaryDataType { get; set; } // binary(3) + [Nullable ] public byte[] varbinaryDataType { get; set; } // varbinary(5) + [Nullable ] public byte[] blobDataType { get; set; } // blob(65535) + [Nullable ] public bool? bitDataType { get; set; } // bit(3) + [Nullable, MaxLength( 5)] public string enumDataType { get; set; } // enum(5) + [Nullable, MaxLength( 7)] public string setDataType { get; set; } // set(7) + } + + [TableName(Name="binarydata")] + public partial class binarydata + { + [Identity, PrimaryKey(1), Required ] public int BinaryDataID { get; set; } // int(10) + [ NonUpdatable(OnInsert = true, OnUpdate = true), Required] public DateTime Stamp { get; set; } // timestamp + [ Required ] public byte[] Data { get; set; } // varbinary(1024) + } + + [TableName(Name="child")] + public partial class child + { + [Nullable] public int? ParentID { get; set; } // int(10) + [Nullable] public int? ChildID { get; set; } // int(10) + } + + [TableName(Name="datatypetest")] + public partial class datatypetest + { + [Identity, PrimaryKey(1), Required ] public int DataTypeID { get; set; } // int(10) + [Nullable ] public byte[] Binary_ { get; set; } // binary(50) + [ Required ] public bool Boolean_ { get; set; } // bit(1) + [Nullable ] public sbyte? Byte_ { get; set; } // tinyint(3) + [Nullable ] public byte[] Bytes_ { get; set; } // varbinary(50) + [Nullable, MaxLength( 1)] public string Char_ { get; set; } // char(1) + [Nullable ] public DateTime? DateTime_ { get; set; } // datetime + [Nullable ] public decimal? Decimal_ { get; set; } // decimal(20,2) + [Nullable ] public float? Double_ { get; set; } // float(12) + [Nullable ] public byte[] Guid_ { get; set; } // varbinary(50) + [Nullable ] public short? Int16_ { get; set; } // smallint(5) + [Nullable ] public int? Int32_ { get; set; } // int(10) + [Nullable ] public long? Int64_ { get; set; } // bigint(19) + [Nullable ] public decimal? Money_ { get; set; } // decimal(20,4) + [Nullable ] public sbyte? SByte_ { get; set; } // tinyint(3) + [Nullable ] public double? Single_ { get; set; } // double(22) + [Nullable ] public byte[] Stream_ { get; set; } // varbinary(50) + [Nullable, MaxLength( 50)] public string String_ { get; set; } // varchar(50) + [Nullable ] public short? UInt16_ { get; set; } // smallint(5) + [Nullable ] public int? UInt32_ { get; set; } // int(10) + [Nullable ] public long? UInt64_ { get; set; } // bigint(19) + [Nullable, MaxLength(1000)] public string Xml_ { get; set; } // varchar(1000) + } + + [TableName(Name="doctor")] + public partial class doctor + { + [PrimaryKey(1), Required ] public int PersonID { get; set; } // int(10) + [ MaxLength(50), Required] public string Taxonomy { get; set; } // varchar(50) + + // FK_Doctor_Person + [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=false)] + public person DoctorPerson { get; set; } + } + + [TableName(Name="grandchild")] + public partial class grandchild + { + [Nullable] public int? ParentID { get; set; } // int(10) + [Nullable] public int? ChildID { get; set; } // int(10) + [Nullable] public int? GrandChildID { get; set; } // int(10) + } + + [TableName(Name="linqdatatypes")] + public partial class linqdatatypes + { + [Nullable ] public int? ID { get; set; } // int(10) + [Nullable ] public decimal? MoneyValue { get; set; } // decimal(10,4) + [Nullable ] public DateTime? DateTimeValue { get; set; } // datetime + [Nullable ] public DateTime? DateTimeValue2 { get; set; } // datetime + [Nullable ] public bool? BoolValue { get; set; } // tinyint(3) + [Nullable, MaxLength(36)] public string GuidValue { get; set; } // char(36) + [Nullable ] public byte[] BinaryValue { get; set; } // varbinary(5000) + [Nullable ] public short? SmallIntValue { get; set; } // smallint(5) + [Nullable ] public int? IntValue { get; set; } // int(10) + [Nullable ] public long? BigIntValue { get; set; } // bigint(19) + } + + [TableName(Name="parent")] + public partial class parent + { + [Nullable] public int? ParentID { get; set; } // int(10) + [Nullable] public int? Value1 { get; set; } // int(10) + } + + [TableName(Name="patient")] + public partial class patient + { + [PrimaryKey(1), Required ] public int PersonID { get; set; } // int(10) + [ MaxLength(256), Required] public string Diagnosis { get; set; } // varchar(256) + + // FK_Patient_Person + [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=false)] + public person PatientPerson { get; set; } + } + + [TableName(Name="person")] + public partial class person + { + [Identity, PrimaryKey(1), Required ] public int PersonID { get; set; } // int(10) + [ MaxLength(50), Required] public string FirstName { get; set; } // varchar(50) + [ MaxLength(50), Required] public string LastName { get; set; } // varchar(50) + [Nullable, MaxLength(50) ] public string MiddleName { get; set; } // varchar(50) + [ MaxLength( 1), Required] public string Gender { get; set; } // char(1) + + // FK_Doctor_Person_BackReference + [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=true)] + public doctor DoctorPerson { get; set; } + + // FK_Patient_Person_BackReference + [Association(ThisKey="PersonID", OtherKey="PersonID", CanBeNull=true)] + public patient PatientPerson { get; set; } + } + + [TableName(Name="testidentity")] + public partial class testidentity + { + [Identity, PrimaryKey(1), Required] public int ID { get; set; } // int(10) + } +} diff --git a/Tools/Templates/MySqlDataModel.tt b/Tools/Templates/MySqlDataModel.tt index f2450f842..f766d9514 100644 --- a/Tools/Templates/MySqlDataModel.tt +++ b/Tools/Templates/MySqlDataModel.tt @@ -1,15 +1,15 @@ -<#@ template language="C#" debug="True" hostspecific="True" #> -<#@ output extension=".generated.cs" #> -<#@ assembly name="$(SolutionDir)\packages\MySql.Data.6.6.4\lib\Net40\MySql.Data.dll" #> -<#@ include file="$(SolutionDir)\Source\Templates\BLToolkit.ttinclude" #> -<#@ include file="$(SolutionDir)\Source\Templates\MySql.ttinclude" #> -<#@ include file="$(SolutionDir)\Source\Templates\ValidationAttributes.ttinclude" #> -<# - GetConnectionObject = () => new MySql.Data.MySqlClient.MySqlConnection(); - ConnectionString = "Server=DBHost;Port=3306;Database=testdata;Uid=root;Pwd=TestPassword;charset=utf8;"; - - DataContextName = "MySqlDataContext"; - Namespace = "MySqlDataModel"; - - GenerateModel(); -#> +<#@ template language="C#" debug="True" hostspecific="True" #> +<#@ output extension=".generated.cs" #> +<#@ assembly name="$(SolutionDir)\packages\MySql.Data.6.6.4\lib\Net40\MySql.Data.dll" #> +<#@ include file="$(SolutionDir)\Source\Templates\BLToolkit.ttinclude" #> +<#@ include file="$(SolutionDir)\Source\Templates\MySql.ttinclude" #> +<#@ include file="$(SolutionDir)\Source\Templates\ValidationAttributes.ttinclude" #> +<# + GetConnectionObject = () => new MySql.Data.MySqlClient.MySqlConnection(); + ConnectionString = "Server=DBHost;Port=3306;Database=testdata;Uid=root;Pwd=TestPassword;charset=utf8;"; + + DataContextName = "MySqlDataContext"; + Namespace = "MySqlDataModel"; + + GenerateModel(); +#> diff --git a/UnitTests/CS/JointureTests/Artist.cs b/UnitTests/CS/JointureTests/Artist.cs deleted file mode 100644 index 371eb5fb3..000000000 --- a/UnitTests/CS/JointureTests/Artist.cs +++ /dev/null @@ -1,15 +0,0 @@ -using BLToolkit.DataAccess; -using BLToolkit.Mapping; - -namespace UnitTests.CS.JointureTests -{ - [TableName(Name = "ARTIST", Owner = Consts.Owner)] - public class Artist - { - [MapField("ID_ARTIST"), PrimaryKey, NonUpdatable] - public long Id { get; set; } - - [MapField("ARTIST")] - public string Name { get; set; } - } -} \ No newline at end of file diff --git a/UnitTests/CS/JointureTests/Artist2.cs b/UnitTests/CS/JointureTests/Artist2.cs deleted file mode 100644 index d1242172d..000000000 --- a/UnitTests/CS/JointureTests/Artist2.cs +++ /dev/null @@ -1,21 +0,0 @@ -using System.Collections.Generic; -using BLToolkit.DataAccess; -using BLToolkit.Mapping; -using BLToolkit.TypeBuilder; - -namespace UnitTests.CS.JointureTests -{ - [TableName(Name = "ARTIST", Owner = Consts.Owner)] - public class Artist2 - { - [MapField("ID_ARTIST"), PrimaryKey, NonUpdatable] - public long Id { get; set; } - - [MapField("ARTIST")] - public string Name { get; set; } - - [LazyInstance(true)] - [Association(ThisKey = "Id", OtherKey = "ArtistID", CanBeNull = false)] - public virtual List Titles { get; set; } - } -} \ No newline at end of file diff --git a/UnitTests/CS/JointureTests/AssociationTests.cs b/UnitTests/CS/JointureTests/AssociationTests.cs deleted file mode 100644 index 4f8673f0a..000000000 --- a/UnitTests/CS/JointureTests/AssociationTests.cs +++ /dev/null @@ -1,102 +0,0 @@ -using System.Collections.Generic; -using BLToolkit.Data; -using BLToolkit.Data.DataProvider; -using BLToolkit.DataAccess; -using BLToolkit.Mapping; -using NUnit.Framework; - -namespace UnitTests.CS.JointureTests -{ - //[TestFixture] - internal class AssociationTests - { - [TestFixtureSetUp] - public void Setup() - { - DataProviderBase provider = new OdpDataProvider(); - DbManager.AddDataProvider(provider); - DbManager.AddConnectionString(provider.Name, - string.Format( - "data source={0};User Id={1};Password={2};Incr Pool Size=1;Max Pool Size=3; Connection Timeout=15; pooling=false", - "MUSICFR01.TEST", "scurutchet", "kisscool12")); - } - - //[Test] - public void SelectAllArtistsIgnoreLazyLoading() - { - using (var db = new MusicDB()) - { - var query2 = new FullSqlQuery(db, true); //loading is automatic - var artist2 = (Artist2) query2.SelectByKey(typeof (Artist2), 2643); - var titles2 = artist2.Titles; - - var query = new FullSqlQuery(db); // Dont ignore lazyloading - var artist = (Artist2) query.SelectByKey(typeof (Artist2), 2643); - var titles = artist.Titles; - Assert.AreEqual(titles2.Count, titles.Count); - } - } - - //[Test] - public void SelectAllArtistsLazyLoading() - { -// using (var db = new MusicDB()) -// { -// var dbCmd = db.SetCommand("SELECT ID_ARTIST FROM PITAFR01.Artist where date_creation > sysdate - 200"); -// -// dbCmd.MappingSchema = new FullMappingSchema(); -// -// var art = dbCmd.ExecuteList<Artist2>(); -// var titles = art[0].Titles; -// var query2 = new FullSqlQueryT<Artist2>(db); -// var artists = query2.SelectAll(); -// var artist2 = artists[0]; -// var titles2 = artist2.Titles; -// } - } - - //[Test] - public void SelectAllTitlesFull() - { - using (var db = new MusicDB()) - { - var query = new FullSqlQueryT<Title>(db); - var titles1 = query.SelectAll<List<Title>>(); - List<Title> titles2 = query.SelectAll(); - } - } - - //[Test] - public void SelectAllTitlesFull2() - { - using (var db = new MusicDB()) - { - var query2 = new FullSqlQuery(db); - var titles = query2.SelectAll<Title>(); - var title = (Title) query2.SelectByKey(typeof (Title), 137653); - } - } - - //[Test] - public void SelectArtistFullWithLazyLoadingTitles() - { - using (var db = new MusicDB()) - { - var query2 = new FullSqlQueryT<Artist2>(db); - var artist = query2.SelectByKey(2643); - var titles = artist.Titles; - } - } - - //[Test] - public void SelectTitleFull() - { - using (var db = new MusicDB()) - { - var query2 = new FullSqlQueryT<Title>(db); - var title = query2.SelectByKey(137653); - var titleName = title.Name; - } - } - } -} \ No newline at end of file diff --git a/UnitTests/CS/JointureTests/Consts.cs b/UnitTests/CS/JointureTests/Consts.cs deleted file mode 100644 index e459badae..000000000 --- a/UnitTests/CS/JointureTests/Consts.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace UnitTests.CS.JointureTests -{ - public static class Consts - { - public const string Owner = "PITAFR01"; - } -} \ No newline at end of file diff --git a/UnitTests/CS/JointureTests/MusicDB.cs b/UnitTests/CS/JointureTests/MusicDB.cs deleted file mode 100644 index 5222e9e4c..000000000 --- a/UnitTests/CS/JointureTests/MusicDB.cs +++ /dev/null @@ -1,11 +0,0 @@ -using BLToolkit.Data; -using BLToolkit.Data.Linq; - -namespace UnitTests.CS.JointureTests -{ - public class MusicDB : DbManager - { - public Table<Title> Title { get { return GetTable<Title>(); } } - public Table<Artist2> Artist2 { get { return GetTable<Artist2>(); } } - } -} \ No newline at end of file diff --git a/UnitTests/CS/JointureTests/Title.cs b/UnitTests/CS/JointureTests/Title.cs deleted file mode 100644 index b7a9f9168..000000000 --- a/UnitTests/CS/JointureTests/Title.cs +++ /dev/null @@ -1,21 +0,0 @@ -using BLToolkit.DataAccess; -using BLToolkit.Mapping; - -namespace UnitTests.CS.JointureTests -{ - [TableName(Name = "TRACK", Owner = Consts.Owner)] - public class Title - { - [MapField("ID_TRACK"), PrimaryKey, NonUpdatable] - public long Id { get; set; } - - [MapField("TRACK")] - public string Name { get; set; } - - [MapField("ID_ARTIST")] - public long? ArtistID { get; set; } - - [Association(ThisKey = "ArtistID", OtherKey = "Id", CanBeNull = false)] - public Artist Artist { get; set; } - } -} \ No newline at end of file diff --git a/UnitTests/CS/Mapping/EnumExtension.cs b/UnitTests/CS/Mapping/EnumExtension.cs index 720529db2..77f154ed1 100644 --- a/UnitTests/CS/Mapping/EnumExtension.cs +++ b/UnitTests/CS/Mapping/EnumExtension.cs @@ -64,7 +64,7 @@ public void EnumToValueTest() Assert.AreEqual(101, Map.EnumToValue(OtherEnum1.EnumValue2)); } - //[Test] + [Test] public void ObjToDicTest() { var obj = new TestObj { Country = CountryCodeEnum1.DZ, Other = OtherEnum1.EnumValue2 }; diff --git a/UnitTests/CS/Properties/Settings.Designer.cs b/UnitTests/CS/Properties/Settings.Designer.cs index e483f2799..ac6b56f4b 100644 --- a/UnitTests/CS/Properties/Settings.Designer.cs +++ b/UnitTests/CS/Properties/Settings.Designer.cs @@ -1,7 +1,7 @@ //------------------------------------------------------------------------------ // <auto-generated> // This code was generated by a tool. -// Runtime Version:4.0.30319.1 +// Runtime Version:4.0.30319.17626 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. @@ -32,5 +32,16 @@ public string BLToolkitDataConnectionString { return ((string)(this["BLToolkitDataConnectionString"])); } } + + [global::System.Configuration.ApplicationScopedSettingAttribute()] + [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] + [global::System.Configuration.SpecialSettingAttribute(global::System.Configuration.SpecialSetting.ConnectionString)] + [global::System.Configuration.DefaultSettingValueAttribute("DATA SOURCE=PITAOLERONFR01.PIGE;PASSWORD=smsmms8;PERSIST SECURITY INFO=True;USER " + + "ID=PITAFR01_PROC_11")] + public string ConnectionString { + get { + return ((string)(this["ConnectionString"])); + } + } } } diff --git a/UnitTests/CS/Properties/Settings.settings b/UnitTests/CS/Properties/Settings.settings index 9eb21ffa9..74319575d 100644 --- a/UnitTests/CS/Properties/Settings.settings +++ b/UnitTests/CS/Properties/Settings.settings @@ -10,5 +10,13 @@ </SerializableConnectionString></DesignTimeValue> <Value Profile="(Default)">Data Source=(local);Initial Catalog=BLToolkitData;Integrated Security=True</Value> </Setting> + <Setting Name="ConnectionString" Type="(Connection string)" Scope="Application"> + <DesignTimeValue Profile="(Default)"><?xml version="1.0" encoding="utf-16"?> +<SerializableConnectionString xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> + <ConnectionString>DATA SOURCE=PITAOLERONFR01.PIGE;PASSWORD=smsmms8;PERSIST SECURITY INFO=True;USER ID=PITAFR01_PROC_11</ConnectionString> + <ProviderName>Oracle.DataAccess.Client</ProviderName> +</SerializableConnectionString></DesignTimeValue> + <Value Profile="(Default)">DATA SOURCE=PITAOLERONFR01.PIGE;PASSWORD=smsmms8;PERSIST SECURITY INFO=True;USER ID=PITAFR01_PROC_11</Value> + </Setting> </Settings> </SettingsFile> \ No newline at end of file diff --git a/UnitTests/CS/UnitTests.CS.csproj b/UnitTests/CS/UnitTests.CS.csproj index cd17660ce..6a57c7348 100644 --- a/UnitTests/CS/UnitTests.CS.csproj +++ b/UnitTests/CS/UnitTests.CS.csproj @@ -179,14 +179,6 @@ <Compile Include="EditableObjects\NestedObjectTest.cs" /> <Compile Include="EditableObjects\NotifyCollectionChangeTest.cs" /> <Compile Include="EditableObjects\NotifyPropertyChangedTest.cs" /> - <Compile Include="JointureTests\Artist.cs" /> - <Compile Include="JointureTests\Artist2.cs" /> - <Compile Include="JointureTests\AssociationTests.cs" /> - <Compile Include="JointureTests\Consts.cs" /> - <Compile Include="JointureTests\MusicDB.cs"> - <SubType>Component</SubType> - </Compile> - <Compile Include="JointureTests\Title.cs" /> <Compile Include="Mapping\BltMapTests.cs" /> <Compile Include="Mapping\MemberMapperDefaultMappersTest.cs" /> <Compile Include="Mapping\ExpressionMapperTest.cs" /> @@ -322,22 +314,11 @@ <EmbeddedResource Include="Data\Sql\DefinitionData.xml" /> </ItemGroup> <ItemGroup> - <ProjectReference Include="..\..\DataProviders\MySql\BLToolkit.Data.DataProvider.MySql.4.csproj"> - <Project>{3578AF4C-CBFF-4A38-88F5-E86AC990AFBD}</Project> - <Name>BLToolkit.Data.DataProvider.MySql.4</Name> - </ProjectReference> - <ProjectReference Include="..\..\DataProviders\Oracle\BLToolkit.Data.DataProvider.Oracle.4.csproj"> - <Project>{2B5287F2-A6AC-4D5A-B0A8-01C06144824D}</Project> - <Name>BLToolkit.Data.DataProvider.Oracle.4</Name> - </ProjectReference> <ProjectReference Include="..\..\Source\BLToolkit.4.csproj"> <Project>{0C325F5D-E50E-4340-8724-D29896CCC583}</Project> <Name>BLToolkit.4</Name> </ProjectReference> - <ProjectReference Include="..\..\Extensions\JointureAddOn\BLToolkit.4.JointureAddOn.csproj"> - <Project>{9FD2722C-1E6C-4061-8AC0-32EE28808FC0}</Project> - <Name>BLToolkit.4.JointureAddOn</Name> - </ProjectReference> </ItemGroup> + <ItemGroup /> <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" /> </Project> \ No newline at end of file diff --git a/UnitTests/CS/app.config b/UnitTests/CS/app.config index 2d9aaa18f..98e1ac611 100644 --- a/UnitTests/CS/app.config +++ b/UnitTests/CS/app.config @@ -1,32 +1,73 @@ <?xml version="1.0"?> + <configuration> - <configSections> - <section name="bltoolkit" type="BLToolkit.Configuration.BLToolkitSection, BLToolkit.4"/> - </configSections> - <appSettings> - <!-- Default configuration --> - <add key="ConnectionString" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI"/> - <!-- SQL Server Development configuration --> - <add key="ConnectionString.Development" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI"/> - <!-- SQL Server Production configuration --> - <add key="ConnectionString.Production" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI"/> - <!-- SQL Server configuration --> - <add key="ConnectionString.Sql" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI"/> - <!-- Oracle configuration --> - <add key="ConnectionString.Oracle" value="User Id=/;Data Source=BLToolkitData"/> - <!-- OLEDB configuration --> - <add key="ConnectionString.OleDb" value="Provider=SQLOLEDB;Data Source=.;Integrated Security=SSPI;Initial Catalog=BLToolkitData"/> - <!-- OLEDB Development configuration --> - <add key="ConnectionString.OleDb.Development" value="Provider=SQLOLEDB;Data Source=.;Integrated Security=SSPI;Initial Catalog=BLToolkitData"/> - <!-- OLEDB Production configuration --> - <add key="ConnectionString.OleDb.Production" value="Provider=SQLOLEDB;Data Source=.;Integrated Security=SSPI;Initial Catalog=BLToolkitData"/> - <!-- MySql configuration --> - <add key="ConnectionString.MySql" value="Server=DBHost;Port=3306;Database=bltoolkitdata;Uid=root;Pwd=TestPassword;"/> - <!-- Additional data providers --> - <add key="BLToolkit.DataProviders" value="BLToolkit.Data.DataProvider.MySqlDataProvider, BLToolkit.Data.DataProvider.MySql.4"/> - <add key="BLToolkit.DataProviders" value="BLToolkit.Data.DataProvider.OdpDataProvider, BLToolkit.Data.DataProvider.Oracle.4"/> + <configSections> + <section name="bltoolkit" type="BLToolkit.Configuration.BLToolkitSection, BLToolkit.4" /> + </configSections> + + <connectionStrings> + <clear /> + <add name="Sqlite" + connectionString="Data Source=E:\CSAMatching\BLToolkitData.sqlite;Version=3;Pooling=False;Max Pool Size=100;" + providerName="System.Data.SQLite" /> + + <add name="Oracle" connectionString="User Id={0}; Password={1}; Data Source={2}; Pooling=True;Connection Timeout=120;Max Pool Size=150;Decr Pool Size=20;" + providerName="Oracle.DataAccess.Client" /> + + <add name="UnitTests.CS.Properties.Settings.BLToolkitDataConnectionString" + connectionString="Data Source=(local);Initial Catalog=BLToolkitData;Integrated Security=True" + providerName="System.Data.SqlClient" /> + + <add name="UnitTests.CS.Properties.Settings.ConnectionString" + connectionString="DATA SOURCE=PITAOLERONFR01.PIGE;PASSWORD=smsmms8;PERSIST SECURITY INFO=True;USER ID=PITAFR01_PROC_11" + providerName="Oracle.DataAccess.Client" /> + </connectionStrings> + + <system.data> + <DbProviderFactories> + <remove invariant="System.Data.SQLite" /> + <add name="SQLite Data Provider" invariant="System.Data.SQLite" + description=".Net Framework Data Provider for SQLite" + type="System.Data.SQLite.SQLiteFactory, System.Data.SQLite, Version=1.0.80.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139" /> + + <!--<remove invariant="Oracle.DataAccess.Client" /> + <add name="Oracle Data Provider for .NET" invariant="Oracle.DataAccess.Client" + description="Oracle.DataAccess.Client" + type="Oracle.DataAccess.Client.OracleClientFactory, Oracle.DataAccess, Version=2.112.1.0, Culture=neutral, PublicKeyToken=89b483f429c47342" />--> + </DbProviderFactories> + </system.data> + + <appSettings> + <!-- Default configuration --> + <add key="ConnectionString" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI" /> + <!-- SQL Server Development configuration --> + <add key="ConnectionString.Development" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI" /> + <!-- SQL Server Production configuration --> + <add key="ConnectionString.Production" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI" /> + <!-- SQL Server configuration --> + <add key="ConnectionString.Sql" value="Server=.;Database=BLToolkitData;Integrated Security=SSPI" /> + <!-- Oracle configuration --> + <add key="ConnectionString.Oracle" value="User Id=/;Data Source=BLToolkitData" /> + <!-- OLEDB configuration --> + <add key="ConnectionString.OleDb" + value="Provider=SQLOLEDB;Data Source=.;Integrated Security=SSPI;Initial Catalog=BLToolkitData" /> + <!-- OLEDB Development configuration --> + <add key="ConnectionString.OleDb.Development" + value="Provider=SQLOLEDB;Data Source=.;Integrated Security=SSPI;Initial Catalog=BLToolkitData" /> + <!-- OLEDB Production configuration --> + <add key="ConnectionString.OleDb.Production" + value="Provider=SQLOLEDB;Data Source=.;Integrated Security=SSPI;Initial Catalog=BLToolkitData" /> + <!-- MySql configuration --> + <add key="ConnectionString.MySql" value="Server=DBHost;Port=3306;Database=bltoolkitdata;Uid=root;Pwd=TestPassword;" /> + <!-- Additional data providers --> + <add key="BLToolkit.DataProviders" + value="BLToolkit.Data.DataProvider.MySqlDataProvider, BLToolkit.Data.DataProvider.MySql.4" /> + <add key="BLToolkit.DataProviders" + value="BLToolkit.Data.DataProvider.OdpDataProvider, BLToolkit.Data.DataProvider.Oracle.4" /> + <add key="BLToolkit.DataProviders" + value="BLToolkit.Data.DataProvider.SQLiteDataProvider, BLToolkit.Data.DataProvider.SQLite.4" /> - <!-- Samples + <!-- Samples <add key = "BLToolkit.DataProviders" value = "BLToolkit.Data.DataProvider.OracleDataProvider;SomeNamespace.SomeType, SomeAssembly, Version=1.0.0.0, Culture=neutral, PublicKeyToken=1234567890ABCDEF"/> @@ -34,8 +75,11 @@ key = "BLToolkit.DefaultConfiguration" value = "Oracle"/> --> - </appSettings> - <bltoolkit> - <typeFactory saveTypes="true"/> - </bltoolkit> -<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/></startup></configuration> + </appSettings> + <bltoolkit> + <typeFactory saveTypes="true" /> + </bltoolkit> + <startup> + <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0" /> + </startup> +</configuration> \ No newline at end of file diff --git a/UnitTests/Linq/AssociationTest.cs b/UnitTests/Linq/AssociationTest.cs index 6549da1e3..7a5ce96b3 100644 --- a/UnitTests/Linq/AssociationTest.cs +++ b/UnitTests/Linq/AssociationTest.cs @@ -1,6 +1,6 @@ using System; using System.Linq; - +using BLToolkit.Data; using BLToolkit.Data.DataProvider; using BLToolkit.Data.Linq; using BLToolkit.DataAccess; @@ -368,33 +368,34 @@ orderby t.ParentID Assert.Null (list[1]); }); } - - [TableName("Child")] - [InheritanceMapping(Code = 1, IsDefault = true, Type = typeof(ChildForHeirarhy))] - public class ChildBaseForHeirarhy - { - [MapField(IsInheritanceDiscriminator = true)] - public int ChildID { get; set; } - } - - public class ChildForHeirarhy : ChildBaseForHeirarhy - { - public int ParentID { get; set; } - [Association(ThisKey = "ParentID", OtherKey = "ParentID", CanBeNull = true)] - public Parent Parent { get; set; } - } - - [Test] - public void AssociationInHeirarhy() - { - ForEachProvider(db => - { - db.GetTable<ChildBaseForHeirarhy>() - .OfType<ChildForHeirarhy>() - .Select(ch => new ChildForHeirarhy { Parent = ch.Parent }) - .ToList(); - }); - } + + [TableName("CHILD")] + [InheritanceMapping(Code = 1, IsDefault = true, Type = typeof(ChildForHeirarhy))] + public class ChildBaseForHeirarhy + { + [MapField(IsInheritanceDiscriminator = true)] + public int ChildID { get; set; } + } + + public class ChildForHeirarhy : ChildBaseForHeirarhy + { + public int ParentID { get; set; } + [Association(ThisKey = "ParentID", OtherKey = "ParentID", CanBeNull = true)] + public Parent Parent { get; set; } + } + + + [Test] + public void TestAssociationInHeirarhy() + { + ForEachProvider( Providers.Select(p => p.Name).Except(new [] { ProviderName.Firebird }).ToArray(), context => + { + var db = context as TestDbManager; + if (db == null) return; + db.GetTable<ChildBaseForHeirarhy>().OfType<ChildForHeirarhy>() + .Select(ch => new ChildForHeirarhy() {Parent = ch.Parent}).ToList(); + }); + } [Test] public void LetTest1() @@ -422,6 +423,6 @@ from p in db.Parent select new { p } into p let chs = p.p.Children select new { p.p.ParentID, Count = chs.Count() })); - } + } } } diff --git a/UnitTests/Linq/Exceptions/Common.cs b/UnitTests/Linq/Exceptions/Common.cs index e87528c8c..9a736940a 100644 --- a/UnitTests/Linq/Exceptions/Common.cs +++ b/UnitTests/Linq/Exceptions/Common.cs @@ -20,7 +20,7 @@ class MyDbManager : TestDbManager { public MyDbManager() : base("Sql2008") {} - protected override SqlQuery ProcessQuery(SqlQuery sqlQuery) + public override SqlQuery ProcessQuery(SqlQuery sqlQuery) { if (sqlQuery.IsInsert && sqlQuery.Insert.Into.Name == "Parent") { diff --git a/UnitTests/Linq/Inheritance.cs b/UnitTests/Linq/Inheritance.cs index ed0ae5cec..8678131d4 100644 --- a/UnitTests/Linq/Inheritance.cs +++ b/UnitTests/Linq/Inheritance.cs @@ -454,37 +454,55 @@ public void QuerySyntaxSimpleTest() } [TableName("Person")] - [InheritanceMapping(Code = 1, Type = typeof(Test17John))] - [InheritanceMapping(Code = 2, Type = typeof(Test17Tester))] + //[InheritanceMapping(Code = 1, Type = typeof(Test17John))] + //[InheritanceMapping(Code = 2, Type = typeof(Test17Tester))] public class Test17Person { [MapField(IsInheritanceDiscriminator = true)] public int PersonID { get; set; } } - public class Test17John : Test17Person - { - public string FirstName { get; set; } - } - - public class Test17Tester : Test17Person - { - public string LastName { get; set; } - } - - [Test] - public void Test17() - { - ForEachProvider(context => - { - if (context is TestDbManager) - { - var db = (TestDbManager)context; - db.GetTable<Test17Person>().OfType<Test17John>().ToList(); - Assert.False(db.LastQuery.ToLowerInvariant().Contains("lastname"), "Why select LastName field??"); - } - }); - } + public class Test17Male : Test17Person + { + public string FirstName { get; set; } + } + + public class Test17Female : Test17Person + { + public string FirstName { get; set; } + public string LastName { get; set; } + } + + [Test] + public void Test17() + { + ForEachProvider(context => + { + if (context is TestDbManager) + { + var db = (TestDbManager)context; + db.GetTable<Test17Person>().OfType<Test17Male>().ToList(); + Assert.False(db.LastQuery.ToLowerInvariant().Contains("lastname"), "Why select LastName field??"); + } + }); + } + + [Test] + public void Test18ExceptFirebird() + { + ForEachProvider(Providers.Select(p => p.Name).Except(new[] { ProviderName.Firebird }).ToArray(), context => + { + var db = context as TestDbManager; + if (db == null) return; + var ids = Enumerable.Range(0, 10).ToList(); + var persons = + (from person1 in db.GetTable<Test17Person>() + where ids.Contains(person1.PersonID) + join person2 in db.GetTable<Test17Person>() on person1.PersonID equals person2.PersonID + select person1).Distinct(); + persons.OfType<Test17Female>().ToList(); + }); + } [TableName("Person")] [InheritanceMapping(Code = Gender.Male, Type = typeof(Test18Male))] diff --git a/UnitTests/Linq/InsertTest.cs b/UnitTests/Linq/InsertTest.cs index b5d48bbfc..d37c921fe 100644 --- a/UnitTests/Linq/InsertTest.cs +++ b/UnitTests/Linq/InsertTest.cs @@ -243,6 +243,25 @@ public void Insert5() }); } + [Test] + public void Insert65() + { + ForEachProvider(db => + { + try + { + db.Person.Where(p => p.Gender == Gender.Male) + .Into(db.Doctor) + .Value(d => d.PersonID, p => p.ID + 10) + .Value(d => d.Taxonomy, "VALERIU") + .Insert(); + } + finally + { + } + }); + } + [Test] public void Insert6() { diff --git a/UnitTests/Linq/JoinTest.cs b/UnitTests/Linq/JoinTest.cs index d4680d615..316796a67 100644 --- a/UnitTests/Linq/JoinTest.cs +++ b/UnitTests/Linq/JoinTest.cs @@ -807,7 +807,7 @@ into b Count = b.Count() }; - q.ToList(); + q.ToList(); } } } diff --git a/UnitTests/Linq/Model/Person.cs b/UnitTests/Linq/Model/Person.cs index 6e1556b2e..e497cbb99 100644 --- a/UnitTests/Linq/Model/Person.cs +++ b/UnitTests/Linq/Model/Person.cs @@ -37,6 +37,9 @@ public Person(int id, string firstName) [Association(ThisKey = "ID", OtherKey = "PersonID", CanBeNull = true)] public Patient Patient; + //[Association(ThisKey = "ID", OtherKey = "PersonID", CanBeNull = true)] + //public Doctor Doctor; + public override bool Equals(object obj) { return Equals(obj as Person); diff --git a/UnitTests/Linq/Model/TestIdentity.cs b/UnitTests/Linq/Model/TestIdentity.cs index 5ea30dc8b..9daff3895 100644 --- a/UnitTests/Linq/Model/TestIdentity.cs +++ b/UnitTests/Linq/Model/TestIdentity.cs @@ -1,15 +1,15 @@ -using System; - -using BLToolkit.DataAccess; - -namespace Data.Linq.Model -{ - public class TestIdentity - { - [Identity, PrimaryKey] - //[SequenceName(ProviderName.PostgreSQL, "Seq")] - //[SequenceName(ProviderName.Firebird, "PersonID")] - //[SequenceName("ID")] - public int ID; - } -} +using System; + +using BLToolkit.DataAccess; + +namespace Data.Linq.Model +{ + public class TestIdentity + { + [Identity, PrimaryKey] + //[SequenceName(ProviderName.PostgreSQL, "Seq")] + //[SequenceName(ProviderName.Firebird, "PersonID")] + //[SequenceName("ID")] + public int ID; + } +} diff --git a/UnitTests/Linq/TestBase.cs b/UnitTests/Linq/TestBase.cs index e0ebcc513..92c41d3f1 100644 --- a/UnitTests/Linq/TestBase.cs +++ b/UnitTests/Linq/TestBase.cs @@ -24,9 +24,15 @@ namespace Data.Linq // fix for failing tests due to use of "," vs "." in numbers parsing for some cultures [SetCulture("")] - public class TestBase - { - static TestBase() + public class TestBase + { + private static TestDbManager GetDbManager() + { + SQLiteDataProvider dataProvider = new SQLiteDataProvider(); + return new TestDbManager(dataProvider, DbManager.GetConnectionString("SQLite")); + } + + static TestBase() { var providerListFile = File.Exists(@"..\..\UserDataProviders.txt") ? @@ -108,6 +114,7 @@ static TestBase() default : return null; } }; + } const int StartIP = 12345; @@ -200,6 +207,8 @@ static IEnumerable<ITestDataContext> GetProviders(IEnumerable<string> exceptList if (!info.Loaded) continue; + //SQLiteDataProvider dataProvider = new SQLiteDataProvider(); + //yield return new TestDbManager(dataProvider, DbManager.GetConnectionString(info.Name)); yield return new TestDbManager(info.Name); var ip = GetIP(info.Name); @@ -392,8 +401,8 @@ protected IEnumerable<LinqDataTypes> Types { get { - if (_types == null) - using (var db = new TestDbManager()) + if (_types == null) + using (var db = GetDbManager()) _types = db.Types.ToList(); foreach (var type in _types) @@ -406,8 +415,8 @@ protected List<LinqDataTypes2> Types2 { get { - if (_types2 == null) - using (var db = new TestDbManager()) + if (_types2 == null) + using (var db = GetDbManager()) _types2 = db.Types2.ToList(); return _types2; } @@ -420,7 +429,7 @@ protected IEnumerable<Person> Person { if (_person == null) { - using (var db = new TestDbManager()) + using (var db = GetDbManager()) _person = db.Person.ToList(); foreach (var p in _person) @@ -438,8 +447,8 @@ protected List<Patient> Patient get { if (_patient == null) - { - using (var db = new TestDbManager()) + { + using (var db = GetDbManager()) _patient = db.Patient.ToList(); foreach (var p in _patient) @@ -456,8 +465,8 @@ protected List<Doctor> Doctor get { if (_doctor == null) - { - using (var db = new TestDbManager()) + { + using (var db = GetDbManager()) _doctor = db.Doctor.ToList(); } @@ -472,8 +481,8 @@ protected IEnumerable<Parent> Parent { get { - if (_parent == null) - using (var db = new TestDbManager()) + if (_parent == null) + using (var db = GetDbManager()) { db.Parent.Delete(c => c.ParentID >= 1000); _parent = db.Parent.ToList(); @@ -587,8 +596,8 @@ protected IEnumerable<Child> Child { get { - if (_child == null) - using (var db = new TestDbManager()) + if (_child == null) + using (var db = GetDbManager()) { db.Child.Delete(c => c.ParentID >= 1000); _child = db.Child.ToList(); @@ -613,8 +622,8 @@ protected IEnumerable<GrandChild> GrandChild { get { - if (_grandChild == null) - using (var db = new TestDbManager()) + if (_grandChild == null) + using (var db = GetDbManager()) { _grandChild = db.GrandChild.ToList(); db.Close(); @@ -633,8 +642,8 @@ protected IEnumerable<GrandChild1> GrandChild1 { get { - if (_grandChild1 == null) - using (var db = new TestDbManager()) + if (_grandChild1 == null) + using (var db = GetDbManager()) { _grandChild1 = db.GrandChild1.ToList(); diff --git a/UnitTests/Linq/TestDbManager.cs b/UnitTests/Linq/TestDbManager.cs index fd3af3593..c62b1cef7 100644 --- a/UnitTests/Linq/TestDbManager.cs +++ b/UnitTests/Linq/TestDbManager.cs @@ -15,6 +15,11 @@ namespace Data.Linq public class TestDbManager : DbManager, ITestDataContext { + public TestDbManager(DataProviderBase dataProviderBase, string configString) + : base(dataProviderBase, configString) + { + } + public TestDbManager(string configString) : base(configString) { diff --git a/UnitTests/Linq/UnitTests.Linq.Interface.csproj b/UnitTests/Linq/UnitTests.Linq.Interface.csproj index b248ce3ad..366cdae4e 100644 --- a/UnitTests/Linq/UnitTests.Linq.Interface.csproj +++ b/UnitTests/Linq/UnitTests.Linq.Interface.csproj @@ -106,6 +106,14 @@ <WarningLevel>4</WarningLevel> </PropertyGroup> <ItemGroup> + <Reference Include="FirebirdSql.Data.FirebirdClient, Version=3.0.2.0, Culture=neutral, PublicKeyToken=3750abcc3150b00c, processorArchitecture=MSIL"> + <SpecificVersion>False</SpecificVersion> + <HintPath>..\..\packages\FirebirdSql.Data.FirebirdClient.3.0.2.1\lib\net40-client\FirebirdSql.Data.FirebirdClient.dll</HintPath> + </Reference> + <Reference Include="nunit.framework, Version=2.6.2.12296, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77, processorArchitecture=MSIL"> + <SpecificVersion>False</SpecificVersion> + <HintPath>..\..\packages\NUnit.2.6.2\lib\nunit.framework.dll</HintPath> + </Reference> <Reference Include="System"> </Reference> <Reference Include="System.Core"> diff --git a/UnitTests/Linq/UnitTests.Linq.csproj b/UnitTests/Linq/UnitTests.Linq.csproj index 1cd7da34d..59b792631 100644 --- a/UnitTests/Linq/UnitTests.Linq.csproj +++ b/UnitTests/Linq/UnitTests.Linq.csproj @@ -302,10 +302,6 @@ <Project>{2B5287F2-A6AC-4D5A-B0A8-01C06144824D}</Project> <Name>BLToolkit.Data.DataProvider.Oracle.4</Name> </ProjectReference> - <ProjectReference Include="..\..\DataProviders\Oracle\BLToolkit.Data.DataProvider.OracleManaged.4.csproj"> - <Project>{785ce174-0a91-465f-9e41-65e6e05a0ec9}</Project> - <Name>BLToolkit.Data.DataProvider.OracleManaged.4</Name> - </ProjectReference> <ProjectReference Include="..\..\DataProviders\PostgreSQL\BLToolkit.Data.DataProvider.PostgreSQL.4.csproj"> <Project>{5A556D57-0D68-433B-AD78-02849583582B}</Project> <Name>BLToolkit.Data.DataProvider.PostgreSQL.4</Name> diff --git a/UnitTests/UnitTests.Regression/Issues/Issue_0047_Test.cs b/UnitTests/UnitTests.Regression/Issues/Issue_0047_Test.cs new file mode 100644 index 000000000..ea11c1a39 --- /dev/null +++ b/UnitTests/UnitTests.Regression/Issues/Issue_0047_Test.cs @@ -0,0 +1,35 @@ +using System; +using System.Security.Principal; +using System.Threading; + +using BLToolkit.Aspects; +using BLToolkit.Reflection; + +using NUnit.Framework; + +namespace Aspects +{ + [TestFixture] + public class Issue_0047_Test + { + public abstract class TestClass + { + [Counter] + public virtual void Test() + { + } + } + + [Test] + public void Test() + { + // custom create counter delegate returns null + CounterAspect.CreateCounter = mi => null; + + TestClass t = (TestClass)TypeAccessor.CreateInstance(typeof(TestClass)); + + // interceptor should fallback to default counter implementation + t.Test(); + } + } +} diff --git a/UnitTests/UnitTests.Regression/Properties/AssemblyInfo.cs b/UnitTests/UnitTests.Regression/Properties/AssemblyInfo.cs new file mode 100644 index 000000000..6ffcdaad6 --- /dev/null +++ b/UnitTests/UnitTests.Regression/Properties/AssemblyInfo.cs @@ -0,0 +1,31 @@ +using System.Reflection; +using System.Runtime.InteropServices; + +// General Information about an assembly is controlled through the following +// set of attributes. Change these attribute values to modify the information +// associated with an assembly. +[assembly: AssemblyTitle("UnitTests.Regression")] +[assembly: AssemblyDescription("Business Logic Toolkit Unit tests")] +[assembly: AssemblyProduct("Business Logic Toolkit")] +[assembly: AssemblyCopyright("\xA9 2002-2011 www.bltoolkit.net")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM componenets. If you need to access a type in this assembly from +// COM, set the ComVisible attribute to true on that type. +[assembly: ComVisible(false)] + +// The following GUID is for the ID of the typelib if this project is exposed to COM +[assembly: Guid("885afb0a-4524-4c06-975a-d4883aa8062a")] + +// Version information for an assembly consists of the following four values: +// +// Major Version +// Minor Version +// Build Number +// Revision +// +// You can specify all the values or you can default the Revision and Build Numbers +// by using the '*' as shown below: +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/UnitTests/UnitTests.Regression/UnitTests.Regression.csproj b/UnitTests/UnitTests.Regression/UnitTests.Regression.csproj new file mode 100644 index 000000000..2c32ce6a0 --- /dev/null +++ b/UnitTests/UnitTests.Regression/UnitTests.Regression.csproj @@ -0,0 +1,100 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="4.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <PropertyGroup> + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> + <ProductVersion>8.0.30703</ProductVersion> + <SchemaVersion>2.0</SchemaVersion> + <ProjectGuid>{74D1AF0E-C0AB-4A62-99A3-0975585760A5}</ProjectGuid> + <OutputType>Library</OutputType> + <AppDesignerFolder>Properties</AppDesignerFolder> + <RootNamespace>UnitTests.Regression</RootNamespace> + <AssemblyName>UnitTests.Regression</AssemblyName> + <TargetFrameworkVersion>v4.0</TargetFrameworkVersion> + <FileAlignment>512</FileAlignment> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> + <DebugSymbols>true</DebugSymbols> + <DebugType>full</DebugType> + <Optimize>false</Optimize> + <OutputPath>bin\Debug\</OutputPath> + <DefineConstants>TRACE;DEBUG;MSSQL;FW3</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + <PlatformTarget>x86</PlatformTarget> + <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> + <DebugType>pdbonly</DebugType> + <Optimize>true</Optimize> + <OutputPath>bin\Release\</OutputPath> + <DefineConstants>TRACE;MSSQL;FW3</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'DebugMono|AnyCPU'"> + <DebugSymbols>true</DebugSymbols> + <OutputPath>bin\DebugMono\</OutputPath> + <DefineConstants>TRACE;DEBUG;MSSQL;FW3</DefineConstants> + <DebugType>full</DebugType> + <PlatformTarget>x86</PlatformTarget> + <CodeAnalysisLogFile>bin\Debug\UnitTests.Regression.dll.CodeAnalysisLog.xml</CodeAnalysisLogFile> + <CodeAnalysisUseTypeNameInSuppression>true</CodeAnalysisUseTypeNameInSuppression> + <CodeAnalysisModuleSuppressionsFile>GlobalSuppressions.cs</CodeAnalysisModuleSuppressionsFile> + <ErrorReport>prompt</ErrorReport> + <CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet> + <CodeAnalysisRuleSetDirectories>;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\\Rule Sets</CodeAnalysisRuleSetDirectories> + <CodeAnalysisIgnoreBuiltInRuleSets>false</CodeAnalysisIgnoreBuiltInRuleSets> + <CodeAnalysisRuleDirectories>;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\\Rules</CodeAnalysisRuleDirectories> + <CodeAnalysisIgnoreBuiltInRules>false</CodeAnalysisIgnoreBuiltInRules> + <CodeAnalysisFailOnMissingRules>false</CodeAnalysisFailOnMissingRules> + </PropertyGroup> + <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'ReleaseMono|AnyCPU'"> + <OutputPath>bin\ReleaseMono\</OutputPath> + <DefineConstants>TRACE;MSSQL;FW3</DefineConstants> + <Optimize>true</Optimize> + <DebugType>pdbonly</DebugType> + <PlatformTarget>AnyCPU</PlatformTarget> + <CodeAnalysisLogFile>bin\Release\UnitTests.Regression.dll.CodeAnalysisLog.xml</CodeAnalysisLogFile> + <CodeAnalysisUseTypeNameInSuppression>true</CodeAnalysisUseTypeNameInSuppression> + <CodeAnalysisModuleSuppressionsFile>GlobalSuppressions.cs</CodeAnalysisModuleSuppressionsFile> + <ErrorReport>prompt</ErrorReport> + <CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet> + <CodeAnalysisRuleSetDirectories>;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\\Rule Sets</CodeAnalysisRuleSetDirectories> + <CodeAnalysisRuleDirectories>;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Team Tools\Static Analysis Tools\FxCop\\Rules</CodeAnalysisRuleDirectories> + </PropertyGroup> + <ItemGroup> + <Reference Include="nunit.framework"> + <HintPath>..\..\Tools\NUnit\nunit.framework.dll</HintPath> + </Reference> + <Reference Include="System" /> + <Reference Include="System.Core" /> + <Reference Include="System.Xml.Linq" /> + <Reference Include="System.Data.DataSetExtensions" /> + <Reference Include="Microsoft.CSharp" /> + <Reference Include="System.Data" /> + <Reference Include="System.Xml" /> + </ItemGroup> + <ItemGroup> + <Compile Include="Issues\Issue_0047_Test.cs" /> + <Compile Include="Properties\AssemblyInfo.cs" /> + </ItemGroup> + <ItemGroup> + <None Include="app.config" /> + </ItemGroup> + <ItemGroup /> + <ItemGroup> + <ProjectReference Include="..\..\Source\BLToolkit.4.csproj"> + <Project>{0C325F5D-E50E-4340-8724-D29896CCC583}</Project> + <Name>BLToolkit.4</Name> + </ProjectReference> + </ItemGroup> + <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> + <!-- To modify your build process, add your task inside one of the targets below and uncomment it. + Other similar extension points exist, see Microsoft.Common.targets. + <Target Name="BeforeBuild"> + </Target> + <Target Name="AfterBuild"> + </Target> + --> +</Project> \ No newline at end of file diff --git a/UnitTests/UnitTests.Regression/app.config b/UnitTests/UnitTests.Regression/app.config new file mode 100644 index 000000000..b5ebc1c74 --- /dev/null +++ b/UnitTests/UnitTests.Regression/app.config @@ -0,0 +1,6 @@ +<?xml version="1.0"?> +<configuration> + <startup> + <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.0"/> + </startup> +</configuration> diff --git a/packages/FirebirdSql.Data.FirebirdClient.4.0.0.0/FirebirdSql.Data.FirebirdClient.4.0.0.0.nuspec b/packages/FirebirdSql.Data.FirebirdClient.4.0.0.0/FirebirdSql.Data.FirebirdClient.4.0.0.0.nuspec index f6458967b..39f221d54 100644 --- a/packages/FirebirdSql.Data.FirebirdClient.4.0.0.0/FirebirdSql.Data.FirebirdClient.4.0.0.0.nuspec +++ b/packages/FirebirdSql.Data.FirebirdClient.4.0.0.0/FirebirdSql.Data.FirebirdClient.4.0.0.0.nuspec @@ -1,16 +1,16 @@ -<?xml version="1.0"?> -<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd"> - <metadata> - <id>FirebirdSql.Data.FirebirdClient</id> - <version>4.0.0.0</version> - <title>Firebird ADO.NET Data provider - FirebirdSQL - FirebirdSQL - http://firebird.svn.sourceforge.net/viewvc/firebird/NETProvider/trunk/NETProvider/license.txt - http://www.firebirdsql.org/en/net-provider/ - http://www.firebirdsql.org/file/about/ds-firebird-logo-64.png - false - Firebird ADO.NET Data provider - firebird firebirsql firebirdclient adonet database - + + + + FirebirdSql.Data.FirebirdClient + 4.0.0.0 + Firebird ADO.NET Data provider + FirebirdSQL + FirebirdSQL + http://firebird.svn.sourceforge.net/viewvc/firebird/NETProvider/trunk/NETProvider/license.txt + http://www.firebirdsql.org/en/net-provider/ + http://www.firebirdsql.org/file/about/ds-firebird-logo-64.png + false + Firebird ADO.NET Data provider + firebird firebirsql firebirdclient adonet database + \ No newline at end of file diff --git a/packages/NUnit.2.6.3/lib/nunit.framework.xml b/packages/NUnit.2.6.3/lib/nunit.framework.xml index 4c8c26e88..f40847c7a 100644 --- a/packages/NUnit.2.6.3/lib/nunit.framework.xml +++ b/packages/NUnit.2.6.3/lib/nunit.framework.xml @@ -1,10960 +1,10960 @@ - - - - nunit.framework - - - - - The different targets a test action attribute can be applied to - - - - - Default target, which is determined by where the action attribute is attached - - - - - Target a individual test case - - - - - Target a suite of test cases - - - - - Delegate used by tests that execute code and - capture any thrown exception. - - - - - The Assert class contains a collection of static methods that - implement the most common assertions used in NUnit. - - - - - We don't actually want any instances of this object, but some people - like to inherit from it to add other static methods. Hence, the - protected constructor disallows any instances of this object. - - - - - The Equals method throws an AssertionException. This is done - to make sure there is no mistake by calling this function. - - - - - - - override the default ReferenceEquals to throw an AssertionException. This - implementation makes sure there is no mistake in calling this function - as part of Assert. - - - - - - - Throws a with the message and arguments - that are passed in. This allows a test to be cut short, with a result - of success returned to NUnit. - - The message to initialize the with. - Arguments to be used in formatting the message - - - - Throws a with the message and arguments - that are passed in. This allows a test to be cut short, with a result - of success returned to NUnit. - - The message to initialize the with. - - - - Throws a with the message and arguments - that are passed in. This allows a test to be cut short, with a result - of success returned to NUnit. - - - - - Throws an with the message and arguments - that are passed in. This is used by the other Assert functions. - - The message to initialize the with. - Arguments to be used in formatting the message - - - - Throws an with the message that is - passed in. This is used by the other Assert functions. - - The message to initialize the with. - - - - Throws an . - This is used by the other Assert functions. - - - - - Throws an with the message and arguments - that are passed in. This causes the test to be reported as ignored. - - The message to initialize the with. - Arguments to be used in formatting the message - - - - Throws an with the message that is - passed in. This causes the test to be reported as ignored. - - The message to initialize the with. - - - - Throws an . - This causes the test to be reported as ignored. - - - - - Throws an with the message and arguments - that are passed in. This causes the test to be reported as inconclusive. - - The message to initialize the with. - Arguments to be used in formatting the message - - - - Throws an with the message that is - passed in. This causes the test to be reported as inconclusive. - - The message to initialize the with. - - - - Throws an . - This causes the test to be reported as Inconclusive. - - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - The message that will be displayed on failure - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint expression to be applied - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display if the condition is false - Arguments to be used in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display if the condition is false - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - An ActualValueDelegate returning the value to be tested - A Constraint expression to be applied - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - An ActualValueDelegate returning the value to be tested - A Constraint expression to be applied - The message that will be displayed on failure - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - An ActualValueDelegate returning the value to be tested - A Constraint expression to be applied - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - The message that will be displayed on failure - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that the code represented by a delegate throws an exception - that satisfies the constraint provided. - - A TestDelegate to be executed - A ThrowsConstraint used in the test - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - Used as a synonym for That in rare cases where a private setter - causes a Visual Basic compilation error. - - The actual value to test - A Constraint to be applied - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - Used as a synonym for That in rare cases where a private setter - causes a Visual Basic compilation error. - - The actual value to test - A Constraint to be applied - The message that will be displayed on failure - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - Used as a synonym for That in rare cases where a private setter - causes a Visual Basic compilation error. - - - This method is provided for use by VB developers needing to test - the value of properties with private setters. - - The actual value to test - A Constraint expression to be applied - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate throws a particular exception when called. - - A constraint to be satisfied by the exception - A TestDelegate - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate throws a particular exception when called. - - A constraint to be satisfied by the exception - A TestDelegate - The message that will be displayed on failure - - - - Verifies that a delegate throws a particular exception when called. - - A constraint to be satisfied by the exception - A TestDelegate - - - - Verifies that a delegate throws a particular exception when called. - - The exception Type expected - A TestDelegate - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate throws a particular exception when called. - - The exception Type expected - A TestDelegate - The message that will be displayed on failure - - - - Verifies that a delegate throws a particular exception when called. - - The exception Type expected - A TestDelegate - - - - Verifies that a delegate throws a particular exception when called. - - Type of the expected exception - A TestDelegate - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate throws a particular exception when called. - - Type of the expected exception - A TestDelegate - The message that will be displayed on failure - - - - Verifies that a delegate throws a particular exception when called. - - Type of the expected exception - A TestDelegate - - - - Verifies that a delegate throws an exception when called - and returns it. - - A TestDelegate - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate throws an exception when called - and returns it. - - A TestDelegate - The message that will be displayed on failure - - - - Verifies that a delegate throws an exception when called - and returns it. - - A TestDelegate - - - - Verifies that a delegate throws an exception of a certain Type - or one derived from it when called and returns it. - - The expected Exception Type - A TestDelegate - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate throws an exception of a certain Type - or one derived from it when called and returns it. - - The expected Exception Type - A TestDelegate - The message that will be displayed on failure - - - - Verifies that a delegate throws an exception of a certain Type - or one derived from it when called and returns it. - - The expected Exception Type - A TestDelegate - - - - Verifies that a delegate throws an exception of a certain Type - or one derived from it when called and returns it. - - The expected Exception Type - A TestDelegate - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate throws an exception of a certain Type - or one derived from it when called and returns it. - - The expected Exception Type - A TestDelegate - The message that will be displayed on failure - - - - Verifies that a delegate throws an exception of a certain Type - or one derived from it when called and returns it. - - The expected Exception Type - A TestDelegate - - - - Verifies that a delegate does not throw an exception - - A TestDelegate - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Verifies that a delegate does not throw an exception. - - A TestDelegate - The message that will be displayed on failure - - - - Verifies that a delegate does not throw an exception. - - A TestDelegate - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display in case of failure - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display in case of failure - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - - - - Asserts that a condition is false. If the condition is true the method throws - an . - - The evaluated condition - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that a condition is false. If the condition is true the method throws - an . - - The evaluated condition - The message to display in case of failure - - - - Asserts that a condition is false. If the condition is true the method throws - an . - - The evaluated condition - - - - Asserts that a condition is false. If the condition is true the method throws - an . - - The evaluated condition - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that a condition is false. If the condition is true the method throws - an . - - The evaluated condition - The message to display in case of failure - - - - Asserts that a condition is false. If the condition is true the method throws - an . - - The evaluated condition - - - - Verifies that the object that is passed in is not equal to null - If the object is null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the object that is passed in is not equal to null - If the object is null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - - - - Verifies that the object that is passed in is not equal to null - If the object is null then an - is thrown. - - The object that is to be tested - - - - Verifies that the object that is passed in is not equal to null - If the object is null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the object that is passed in is not equal to null - If the object is null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - - - - Verifies that the object that is passed in is not equal to null - If the object is null then an - is thrown. - - The object that is to be tested - - - - Verifies that the object that is passed in is equal to null - If the object is not null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the object that is passed in is equal to null - If the object is not null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - - - - Verifies that the object that is passed in is equal to null - If the object is not null then an - is thrown. - - The object that is to be tested - - - - Verifies that the object that is passed in is equal to null - If the object is not null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the object that is passed in is equal to null - If the object is not null then an - is thrown. - - The object that is to be tested - The message to display in case of failure - - - - Verifies that the object that is passed in is equal to null - If the object is not null then an - is thrown. - - The object that is to be tested - - - - Verifies that two ints are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two ints are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two ints are equal. If they are not, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two longs are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two longs are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two longs are equal. If they are not, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two unsigned ints are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two unsigned ints are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two unsigned ints are equal. If they are not, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two unsigned longs are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two unsigned longs are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two unsigned longs are equal. If they are not, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two decimals are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two decimals are equal. If they are not, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two decimals are equal. If they are not, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two doubles are equal considering a delta. If the - expected value is infinity then the delta value is ignored. If - they are not equal then an is - thrown. - - The expected value - The actual value - The maximum acceptable difference between the - the expected and the actual - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two doubles are equal considering a delta. If the - expected value is infinity then the delta value is ignored. If - they are not equal then an is - thrown. - - The expected value - The actual value - The maximum acceptable difference between the - the expected and the actual - The message to display in case of failure - - - - Verifies that two doubles are equal considering a delta. If the - expected value is infinity then the delta value is ignored. If - they are not equal then an is - thrown. - - The expected value - The actual value - The maximum acceptable difference between the - the expected and the actual - - - - Verifies that two doubles are equal considering a delta. If the - expected value is infinity then the delta value is ignored. If - they are not equal then an is - thrown. - - The expected value - The actual value - The maximum acceptable difference between the - the expected and the actual - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two doubles are equal considering a delta. If the - expected value is infinity then the delta value is ignored. If - they are not equal then an is - thrown. - - The expected value - The actual value - The maximum acceptable difference between the - the expected and the actual - The message to display in case of failure - - - - Verifies that two doubles are equal considering a delta. If the - expected value is infinity then the delta value is ignored. If - they are not equal then an is - thrown. - - The expected value - The actual value - The maximum acceptable difference between the - the expected and the actual - - - - Verifies that two objects are equal. Two objects are considered - equal if both are null, or if both have the same value. NUnit - has special semantics for some object types. - If they are not equal an is thrown. - - The value that is expected - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two objects are equal. Two objects are considered - equal if both are null, or if both have the same value. NUnit - has special semantics for some object types. - If they are not equal an is thrown. - - The value that is expected - The actual value - The message to display in case of failure - - - - Verifies that two objects are equal. Two objects are considered - equal if both are null, or if both have the same value. NUnit - has special semantics for some object types. - If they are not equal an is thrown. - - The value that is expected - The actual value - - - - Verifies that two ints are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two ints are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two ints are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two longs are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two longs are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two longs are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two unsigned ints are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two unsigned ints are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two unsigned ints are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two unsigned longs are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two unsigned longs are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two unsigned longs are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two decimals are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two decimals are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two decimals are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two floats are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two floats are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two floats are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two doubles are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two doubles are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - The message to display in case of failure - - - - Verifies that two doubles are not equal. If they are equal, then an - is thrown. - - The expected value - The actual value - - - - Verifies that two objects are not equal. Two objects are considered - equal if both are null, or if both have the same value. NUnit - has special semantics for some object types. - If they are equal an is thrown. - - The value that is expected - The actual value - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that two objects are not equal. Two objects are considered - equal if both are null, or if both have the same value. NUnit - has special semantics for some object types. - If they are equal an is thrown. - - The value that is expected - The actual value - The message to display in case of failure - - - - Verifies that two objects are not equal. Two objects are considered - equal if both are null, or if both have the same value. NUnit - has special semantics for some object types. - If they are equal an is thrown. - - The value that is expected - The actual value - - - - Asserts that two objects refer to the same object. If they - are not the same an is thrown. - - The expected object - The actual object - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that two objects refer to the same object. If they - are not the same an is thrown. - - The expected object - The actual object - The message to display in case of failure - - - - Asserts that two objects refer to the same object. If they - are not the same an is thrown. - - The expected object - The actual object - - - - Asserts that two objects do not refer to the same object. If they - are the same an is thrown. - - The expected object - The actual object - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that two objects do not refer to the same object. If they - are the same an is thrown. - - The expected object - The actual object - The message to display in case of failure - - - - Asserts that two objects do not refer to the same object. If they - are the same an is thrown. - - The expected object - The actual object - - - - Verifies that the double that is passed in is an NaN value. - If the object is not NaN then an - is thrown. - - The value that is to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the double that is passed in is an NaN value. - If the object is not NaN then an - is thrown. - - The value that is to be tested - The message to display in case of failure - - - - Verifies that the double that is passed in is an NaN value. - If the object is not NaN then an - is thrown. - - The value that is to be tested - - - - Verifies that the double that is passed in is an NaN value. - If the object is not NaN then an - is thrown. - - The value that is to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the double that is passed in is an NaN value. - If the object is not NaN then an - is thrown. - - The value that is to be tested - The message to display in case of failure - - - - Verifies that the double that is passed in is an NaN value. - If the object is not NaN then an - is thrown. - - The value that is to be tested - - - - Assert that a string is empty - that is equal to string.Empty - - The string to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Assert that a string is empty - that is equal to string.Empty - - The string to be tested - The message to display in case of failure - - - - Assert that a string is empty - that is equal to string.Empty - - The string to be tested - - - - Assert that an array, list or other collection is empty - - An array, list or other collection implementing ICollection - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Assert that an array, list or other collection is empty - - An array, list or other collection implementing ICollection - The message to display in case of failure - - - - Assert that an array, list or other collection is empty - - An array, list or other collection implementing ICollection - - - - Assert that a string is not empty - that is not equal to string.Empty - - The string to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Assert that a string is not empty - that is not equal to string.Empty - - The string to be tested - The message to display in case of failure - - - - Assert that a string is not empty - that is not equal to string.Empty - - The string to be tested - - - - Assert that an array, list or other collection is not empty - - An array, list or other collection implementing ICollection - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Assert that an array, list or other collection is not empty - - An array, list or other collection implementing ICollection - The message to display in case of failure - - - - Assert that an array, list or other collection is not empty - - An array, list or other collection implementing ICollection - - - - Assert that a string is either null or equal to string.Empty - - The string to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Assert that a string is either null or equal to string.Empty - - The string to be tested - The message to display in case of failure - - - - Assert that a string is either null or equal to string.Empty - - The string to be tested - - - - Assert that a string is not null or empty - - The string to be tested - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Assert that a string is not null or empty - - The string to be tested - The message to display in case of failure - - - - Assert that a string is not null or empty - - The string to be tested - - - - Asserts that an object may be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object may be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - - - - Asserts that an object may be assigned a value of a given Type. - - The expected Type. - The object under examination - - - - Asserts that an object may be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object may be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - - - - Asserts that an object may be assigned a value of a given Type. - - The expected Type. - The object under examination - - - - Asserts that an object may not be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object may not be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - - - - Asserts that an object may not be assigned a value of a given Type. - - The expected Type. - The object under examination - - - - Asserts that an object may not be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object may not be assigned a value of a given Type. - - The expected Type. - The object under examination - The message to display in case of failure - - - - Asserts that an object may not be assigned a value of a given Type. - - The expected Type. - The object under examination - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - - - - Asserts that an object is an instance of a given type. - - The expected Type - The object being examined - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - The message to display in case of failure - - - - Asserts that an object is not an instance of a given type. - - The expected Type - The object being examined - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than the second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - The message to display in case of failure - - - - Verifies that the first value is greater than or equal tothe second - value. If it is not, then an - is thrown. - - The first value, expected to be greater - The second value, expected to be less - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - The message to display in case of failure - - - - Verifies that the first value is less than or equal to the second - value. If it is not, then an - is thrown. - - The first value, expected to be less - The second value, expected to be greater - - - - Asserts that an object is contained in a list. - - The expected object - The list to be examined - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Asserts that an object is contained in a list. - - The expected object - The list to be examined - The message to display in case of failure - - - - Asserts that an object is contained in a list. - - The expected object - The list to be examined - - - - Helper for Assert.AreEqual(double expected, double actual, ...) - allowing code generation to work consistently. - - The expected value - The actual value - The maximum acceptable difference between the - the expected and the actual - The message to display in case of failure - Array of objects to be used in formatting the message - - - - Gets the number of assertions executed so far and - resets the counter to zero. - - - - - AssertionHelper is an optional base class for user tests, - allowing the use of shorter names for constraints and - asserts and avoiding conflict with the definition of - , from which it inherits much of its - behavior, in certain mock object frameworks. - - - - - Helper class with properties and methods that supply - a number of constraints used in Asserts. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding only if a specified number of them succeed. - - - - - Returns a new PropertyConstraintExpression, which will either - test for the existence of the named property on the object - being tested or apply any following constraint to that property. - - - - - Returns a new AttributeConstraint checking for the - presence of a particular attribute on an object. - - - - - Returns a new AttributeConstraint checking for the - presence of a particular attribute on an object. - - - - - Returns a constraint that tests two items for equality - - - - - Returns a constraint that tests that two references are the same object - - - - - Returns a constraint that tests whether the - actual value is greater than the suppled argument - - - - - Returns a constraint that tests whether the - actual value is greater than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is greater than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than or equal to the suppled argument - - - - - Returns a constraint that tests whether the actual - value is of the exact type supplied as an argument. - - - - - Returns a constraint that tests whether the actual - value is of the exact type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is a collection containing the same elements as the - collection supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is a subset of the collection supplied as an argument. - - - - - Returns a new CollectionContainsConstraint checking for the - presence of a particular object in the collection. - - - - - Returns a new CollectionContainsConstraint checking for the - presence of a particular object in the collection. - - - - - Returns a new ContainsConstraint. This constraint - will, in turn, make use of the appropriate second-level - constraint, depending on the type of the actual argument. - This overload is only used if the item sought is a string, - since any other type implies that we are looking for a - collection member. - - - - - Returns a constraint that succeeds if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that fails if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that fails if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that fails if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value matches the regular expression supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value matches the regular expression supplied as an argument. - - - - - Returns a constraint that fails if the actual - value matches the pattern supplied as an argument. - - - - - Returns a constraint that tests whether the path provided - is the same as an expected path after canonicalization. - - - - - Returns a constraint that tests whether the path provided - is the same path or under an expected path after canonicalization. - - - - - Returns a constraint that tests whether the path provided - is the same path or under an expected path after canonicalization. - - - - - Returns a constraint that tests whether the actual value falls - within a specified range. - - - - - Returns a ConstraintExpression that negates any - following constraint. - - - - - Returns a ConstraintExpression that negates any - following constraint. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them succeed. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if at least one of them succeeds. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them fail. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Length property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Count property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Message property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the InnerException property of the object being tested. - - - - - Returns a constraint that tests for null - - - - - Returns a constraint that tests for True - - - - - Returns a constraint that tests for False - - - - - Returns a constraint that tests for a positive value - - - - - Returns a constraint that tests for a negative value - - - - - Returns a constraint that tests for NaN - - - - - Returns a constraint that tests for empty - - - - - Returns a constraint that tests whether a collection - contains all unique items. - - - - - Returns a constraint that tests whether an object graph is serializable in binary format. - - - - - Returns a constraint that tests whether an object graph is serializable in xml format. - - - - - Returns a constraint that tests whether a collection is ordered - - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. Works - identically to Assert.That. - - The actual value to test - A Constraint to be applied - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. Works - identically to Assert.That. - - The actual value to test - A Constraint to be applied - The message to be displayed in case of failure - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. Works - identically to Assert.That. - - The actual value to test - A Constraint to be applied - The message to be displayed in case of failure - Arguments to use in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . Works Identically to - . - - The evaluated condition - The message to display if the condition is false - Arguments to be used in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . Works Identically to - . - - The evaluated condition - The message to display if the condition is false - - - - Asserts that a condition is true. If the condition is false the method throws - an . Works Identically to . - - The evaluated condition - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - A Constraint expression to be applied - An ActualValueDelegate returning the value to be tested - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - A Constraint expression to be applied - An ActualValueDelegate returning the value to be tested - The message that will be displayed on failure - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - An ActualValueDelegate returning the value to be tested - A Constraint expression to be applied - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - The message that will be displayed on failure - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an assertion exception on failure. - - The actual value to test - A Constraint to be applied - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that the code represented by a delegate throws an exception - that satisfies the constraint provided. - - A TestDelegate to be executed - A ThrowsConstraint used in the test - - - - Returns a ListMapper based on a collection. - - The original collection - - - - - Provides static methods to express the assumptions - that must be met for a test to give a meaningful - result. If an assumption is not met, the test - should produce an inconclusive result. - - - - - The Equals method throws an AssertionException. This is done - to make sure there is no mistake by calling this function. - - - - - - - override the default ReferenceEquals to throw an AssertionException. This - implementation makes sure there is no mistake in calling this function - as part of Assert. - - - - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - The actual value to test - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - The actual value to test - The message that will be displayed on failure - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - The actual value to test - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display if the condition is false - Arguments to be used in formatting the message - - - - Asserts that a condition is true. If the condition is false the method throws - an . - - The evaluated condition - The message to display if the condition is false - - - - Asserts that a condition is true. If the condition is false the - method throws an . - - The evaluated condition - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - An ActualValueDelegate returning the value to be tested - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - An ActualValueDelegate returning the value to be tested - The message that will be displayed on failure - - - - Apply a constraint to an actual value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - An ActualValueDelegate returning the value to be tested - A Constraint expression to be applied - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - The actual value to test - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - The actual value to test - The message that will be displayed on failure - - - - Apply a constraint to a referenced value, succeeding if the constraint - is satisfied and throwing an InconclusiveException on failure. - - A Constraint expression to be applied - The actual value to test - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that the code represented by a delegate throws an exception - that satisfies the constraint provided. - - A TestDelegate to be executed - A ThrowsConstraint used in the test - - - - Waits for pending asynchronous operations to complete, if appropriate, - and returns a proper result of the invocation by unwrapping task results - - The raw result of the method invocation - The unwrapped result, if necessary - - - - A set of Assert methods operationg on one or more collections - - - - - The Equals method throws an AssertionException. This is done - to make sure there is no mistake by calling this function. - - - - - - - override the default ReferenceEquals to throw an AssertionException. This - implementation makes sure there is no mistake in calling this function - as part of Assert. - - - - - - - Asserts that all items contained in collection are of the type specified by expectedType. - - IEnumerable containing objects to be considered - System.Type that all objects in collection must be instances of - - - - Asserts that all items contained in collection are of the type specified by expectedType. - - IEnumerable containing objects to be considered - System.Type that all objects in collection must be instances of - The message that will be displayed on failure - - - - Asserts that all items contained in collection are of the type specified by expectedType. - - IEnumerable containing objects to be considered - System.Type that all objects in collection must be instances of - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that all items contained in collection are not equal to null. - - IEnumerable containing objects to be considered - - - - Asserts that all items contained in collection are not equal to null. - - IEnumerable containing objects to be considered - The message that will be displayed on failure - - - - Asserts that all items contained in collection are not equal to null. - - IEnumerable of objects to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Ensures that every object contained in collection exists within the collection - once and only once. - - IEnumerable of objects to be considered - - - - Ensures that every object contained in collection exists within the collection - once and only once. - - IEnumerable of objects to be considered - The message that will be displayed on failure - - - - Ensures that every object contained in collection exists within the collection - once and only once. - - IEnumerable of objects to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that expected and actual are exactly equal. The collections must have the same count, - and contain the exact same objects in the same order. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - - - - Asserts that expected and actual are exactly equal. The collections must have the same count, - and contain the exact same objects in the same order. - If comparer is not null then it will be used to compare the objects. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The IComparer to use in comparing objects from each IEnumerable - - - - Asserts that expected and actual are exactly equal. The collections must have the same count, - and contain the exact same objects in the same order. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - - - - Asserts that expected and actual are exactly equal. The collections must have the same count, - and contain the exact same objects in the same order. - If comparer is not null then it will be used to compare the objects. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The IComparer to use in comparing objects from each IEnumerable - The message that will be displayed on failure - - - - Asserts that expected and actual are exactly equal. The collections must have the same count, - and contain the exact same objects in the same order. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that expected and actual are exactly equal. The collections must have the same count, - and contain the exact same objects in the same order. - If comparer is not null then it will be used to compare the objects. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The IComparer to use in comparing objects from each IEnumerable - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - - - - Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - - - - Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that expected and actual are not exactly equal. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - - - - Asserts that expected and actual are not exactly equal. - If comparer is not null then it will be used to compare the objects. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The IComparer to use in comparing objects from each IEnumerable - - - - Asserts that expected and actual are not exactly equal. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - - - - Asserts that expected and actual are not exactly equal. - If comparer is not null then it will be used to compare the objects. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The IComparer to use in comparing objects from each IEnumerable - The message that will be displayed on failure - - - - Asserts that expected and actual are not exactly equal. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that expected and actual are not exactly equal. - If comparer is not null then it will be used to compare the objects. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The IComparer to use in comparing objects from each IEnumerable - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that expected and actual are not equivalent. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - - - - Asserts that expected and actual are not equivalent. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - - - - Asserts that expected and actual are not equivalent. - - The first IEnumerable of objects to be considered - The second IEnumerable of objects to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that collection contains actual as an item. - - IEnumerable of objects to be considered - Object to be found within collection - - - - Asserts that collection contains actual as an item. - - IEnumerable of objects to be considered - Object to be found within collection - The message that will be displayed on failure - - - - Asserts that collection contains actual as an item. - - IEnumerable of objects to be considered - Object to be found within collection - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that collection does not contain actual as an item. - - IEnumerable of objects to be considered - Object that cannot exist within collection - - - - Asserts that collection does not contain actual as an item. - - IEnumerable of objects to be considered - Object that cannot exist within collection - The message that will be displayed on failure - - - - Asserts that collection does not contain actual as an item. - - IEnumerable of objects to be considered - Object that cannot exist within collection - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that superset is not a subject of subset. - - The IEnumerable superset to be considered - The IEnumerable subset to be considered - - - - Asserts that superset is not a subject of subset. - - The IEnumerable superset to be considered - The IEnumerable subset to be considered - The message that will be displayed on failure - - - - Asserts that superset is not a subject of subset. - - The IEnumerable superset to be considered - The IEnumerable subset to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Asserts that superset is a subset of subset. - - The IEnumerable superset to be considered - The IEnumerable subset to be considered - - - - Asserts that superset is a subset of subset. - - The IEnumerable superset to be considered - The IEnumerable subset to be considered - The message that will be displayed on failure - - - - Asserts that superset is a subset of subset. - - The IEnumerable superset to be considered - The IEnumerable subset to be considered - The message that will be displayed on failure - Arguments to be used in formatting the message - - - - Assert that an array, list or other collection is empty - - An array, list or other collection implementing IEnumerable - The message to be displayed on failure - Arguments to be used in formatting the message - - - - Assert that an array, list or other collection is empty - - An array, list or other collection implementing IEnumerable - The message to be displayed on failure - - - - Assert that an array,list or other collection is empty - - An array, list or other collection implementing IEnumerable - - - - Assert that an array, list or other collection is empty - - An array, list or other collection implementing IEnumerable - The message to be displayed on failure - Arguments to be used in formatting the message - - - - Assert that an array, list or other collection is empty - - An array, list or other collection implementing IEnumerable - The message to be displayed on failure - - - - Assert that an array,list or other collection is empty - - An array, list or other collection implementing IEnumerable - - - - Assert that an array, list or other collection is ordered - - An array, list or other collection implementing IEnumerable - The message to be displayed on failure - Arguments to be used in formatting the message - - - - Assert that an array, list or other collection is ordered - - An array, list or other collection implementing IEnumerable - The message to be displayed on failure - - - - Assert that an array, list or other collection is ordered - - An array, list or other collection implementing IEnumerable - - - - Assert that an array, list or other collection is ordered - - An array, list or other collection implementing IEnumerable - A custom comparer to perform the comparisons - The message to be displayed on failure - Arguments to be used in formatting the message - - - - Assert that an array, list or other collection is ordered - - An array, list or other collection implementing IEnumerable - A custom comparer to perform the comparisons - The message to be displayed on failure - - - - Assert that an array, list or other collection is ordered - - An array, list or other collection implementing IEnumerable - A custom comparer to perform the comparisons - - - - Helper class with properties and methods that supply - a number of constraints used in Asserts. - - - - - Returns a new CollectionContainsConstraint checking for the - presence of a particular object in the collection. - - - - - Returns a constraint that succeeds if the actual - value contains the substring supplied as an argument. - - - - - Summary description for DirectoryAssert - - - - - The Equals method throws an AssertionException. This is done - to make sure there is no mistake by calling this function. - - - - - - - override the default ReferenceEquals to throw an AssertionException. This - implementation makes sure there is no mistake in calling this function - as part of Assert. - - - - - - - We don't actually want any instances of this object, but some people - like to inherit from it to add other static methods. Hence, the - protected constructor disallows any instances of this object. - - - - - Verifies that two directories are equal. Two directories are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A directory containing the value that is expected - A directory containing the actual value - The message to display if directories are not equal - Arguments to be used in formatting the message - - - - Verifies that two directories are equal. Two directories are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A directory containing the value that is expected - A directory containing the actual value - The message to display if directories are not equal - - - - Verifies that two directories are equal. Two directories are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A directory containing the value that is expected - A directory containing the actual value - - - - Verifies that two directories are equal. Two directories are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A directory path string containing the value that is expected - A directory path string containing the actual value - The message to display if directories are not equal - Arguments to be used in formatting the message - - - - Verifies that two directories are equal. Two directories are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A directory path string containing the value that is expected - A directory path string containing the actual value - The message to display if directories are not equal - - - - Verifies that two directories are equal. Two directories are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A directory path string containing the value that is expected - A directory path string containing the actual value - - - - Asserts that two directories are not equal. If they are equal - an is thrown. - - A directory containing the value that is expected - A directory containing the actual value - The message to display if directories are not equal - Arguments to be used in formatting the message - - - - Asserts that two directories are not equal. If they are equal - an is thrown. - - A directory containing the value that is expected - A directory containing the actual value - The message to display if directories are not equal - - - - Asserts that two directories are not equal. If they are equal - an is thrown. - - A directory containing the value that is expected - A directory containing the actual value - - - - Asserts that two directories are not equal. If they are equal - an is thrown. - - A directory path string containing the value that is expected - A directory path string containing the actual value - The message to display if directories are equal - Arguments to be used in formatting the message - - - - Asserts that two directories are not equal. If they are equal - an is thrown. - - A directory path string containing the value that is expected - A directory path string containing the actual value - The message to display if directories are equal - - - - Asserts that two directories are not equal. If they are equal - an is thrown. - - A directory path string containing the value that is expected - A directory path string containing the actual value - - - - Asserts that the directory is empty. If it is not empty - an is thrown. - - A directory to search - The message to display if directories are not equal - Arguments to be used in formatting the message - - - - Asserts that the directory is empty. If it is not empty - an is thrown. - - A directory to search - The message to display if directories are not equal - - - - Asserts that the directory is empty. If it is not empty - an is thrown. - - A directory to search - - - - Asserts that the directory is empty. If it is not empty - an is thrown. - - A directory to search - The message to display if directories are not equal - Arguments to be used in formatting the message - - - - Asserts that the directory is empty. If it is not empty - an is thrown. - - A directory to search - The message to display if directories are not equal - - - - Asserts that the directory is empty. If it is not empty - an is thrown. - - A directory to search - - - - Asserts that the directory is not empty. If it is empty - an is thrown. - - A directory to search - The message to display if directories are not equal - Arguments to be used in formatting the message - - - - Asserts that the directory is not empty. If it is empty - an is thrown. - - A directory to search - The message to display if directories are not equal - - - - Asserts that the directory is not empty. If it is empty - an is thrown. - - A directory to search - - - - Asserts that the directory is not empty. If it is empty - an is thrown. - - A directory to search - The message to display if directories are not equal - Arguments to be used in formatting the message - - - - Asserts that the directory is not empty. If it is empty - an is thrown. - - A directory to search - The message to display if directories are not equal - - - - Asserts that the directory is not empty. If it is empty - an is thrown. - - A directory to search - - - - Asserts that path contains actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - Arguments to be used in formatting the message - - - - Asserts that path contains actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - - - - Asserts that path contains actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - - - - Asserts that path contains actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - Arguments to be used in formatting the message - - - - Asserts that path contains actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - - - - Asserts that path contains actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - - - - Asserts that path does not contain actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - Arguments to be used in formatting the message - - - - Asserts that path does not contain actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - - - - Asserts that path does not contain actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - - - - Asserts that path does not contain actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - Arguments to be used in formatting the message - - - - Asserts that path does not contain actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - The message to display if directory is not within the path - - - - Asserts that path does not contain actual as a subdirectory or - an is thrown. - - A directory to search - sub-directory asserted to exist under directory - - - - Summary description for FileAssert. - - - - - The Equals method throws an AssertionException. This is done - to make sure there is no mistake by calling this function. - - - - - - - override the default ReferenceEquals to throw an AssertionException. This - implementation makes sure there is no mistake in calling this function - as part of Assert. - - - - - - - We don't actually want any instances of this object, but some people - like to inherit from it to add other static methods. Hence, the - protected constructor disallows any instances of this object. - - - - - Verifies that two Streams are equal. Two Streams are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - The expected Stream - The actual Stream - The message to display if Streams are not equal - Arguments to be used in formatting the message - - - - Verifies that two Streams are equal. Two Streams are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - The expected Stream - The actual Stream - The message to display if objects are not equal - - - - Verifies that two Streams are equal. Two Streams are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - The expected Stream - The actual Stream - - - - Verifies that two files are equal. Two files are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A file containing the value that is expected - A file containing the actual value - The message to display if Streams are not equal - Arguments to be used in formatting the message - - - - Verifies that two files are equal. Two files are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A file containing the value that is expected - A file containing the actual value - The message to display if objects are not equal - - - - Verifies that two files are equal. Two files are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - A file containing the value that is expected - A file containing the actual value - - - - Verifies that two files are equal. Two files are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - The path to a file containing the value that is expected - The path to a file containing the actual value - The message to display if Streams are not equal - Arguments to be used in formatting the message - - - - Verifies that two files are equal. Two files are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - The path to a file containing the value that is expected - The path to a file containing the actual value - The message to display if objects are not equal - - - - Verifies that two files are equal. Two files are considered - equal if both are null, or if both have the same value byte for byte. - If they are not equal an is thrown. - - The path to a file containing the value that is expected - The path to a file containing the actual value - - - - Asserts that two Streams are not equal. If they are equal - an is thrown. - - The expected Stream - The actual Stream - The message to be displayed when the two Stream are the same. - Arguments to be used in formatting the message - - - - Asserts that two Streams are not equal. If they are equal - an is thrown. - - The expected Stream - The actual Stream - The message to be displayed when the Streams are the same. - - - - Asserts that two Streams are not equal. If they are equal - an is thrown. - - The expected Stream - The actual Stream - - - - Asserts that two files are not equal. If they are equal - an is thrown. - - A file containing the value that is expected - A file containing the actual value - The message to display if Streams are not equal - Arguments to be used in formatting the message - - - - Asserts that two files are not equal. If they are equal - an is thrown. - - A file containing the value that is expected - A file containing the actual value - The message to display if objects are not equal - - - - Asserts that two files are not equal. If they are equal - an is thrown. - - A file containing the value that is expected - A file containing the actual value - - - - Asserts that two files are not equal. If they are equal - an is thrown. - - The path to a file containing the value that is expected - The path to a file containing the actual value - The message to display if Streams are not equal - Arguments to be used in formatting the message - - - - Asserts that two files are not equal. If they are equal - an is thrown. - - The path to a file containing the value that is expected - The path to a file containing the actual value - The message to display if objects are not equal - - - - Asserts that two files are not equal. If they are equal - an is thrown. - - The path to a file containing the value that is expected - The path to a file containing the actual value - - - - GlobalSettings is a place for setting default values used - by the framework in performing asserts. - - - - - Default tolerance for floating point equality - - - - - Class used to guard against unexpected argument values - by throwing an appropriate exception. - - - - - Throws an exception if an argument is null - - The value to be tested - The name of the argument - - - - Throws an exception if a string argument is null or empty - - The value to be tested - The name of the argument - - - - Helper class with properties and methods that supply - a number of constraints used in Asserts. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding only if a specified number of them succeed. - - - - - Returns a new PropertyConstraintExpression, which will either - test for the existence of the named property on the object - being tested or apply any following constraint to that property. - - - - - Returns a new AttributeConstraint checking for the - presence of a particular attribute on an object. - - - - - Returns a new AttributeConstraint checking for the - presence of a particular attribute on an object. - - - - - Returns a new CollectionContainsConstraint checking for the - presence of a particular object in the collection. - - - - - Returns a ConstraintExpression that negates any - following constraint. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them succeed. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if at least one of them succeeds. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them fail. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Length property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Count property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Message property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the InnerException property of the object being tested. - - - - - Interface implemented by a user fixture in order to - validate any expected exceptions. It is only called - for test methods marked with the ExpectedException - attribute. - - - - - Method to handle an expected exception - - The exception to be handled - - - - Helper class with properties and methods that supply - a number of constraints used in Asserts. - - - - - Returns a constraint that tests two items for equality - - - - - Returns a constraint that tests that two references are the same object - - - - - Returns a constraint that tests whether the - actual value is greater than the suppled argument - - - - - Returns a constraint that tests whether the - actual value is greater than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is greater than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than or equal to the suppled argument - - - - - Returns a constraint that tests whether the actual - value is of the exact type supplied as an argument. - - - - - Returns a constraint that tests whether the actual - value is of the exact type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is a collection containing the same elements as the - collection supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is a subset of the collection supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value matches the regular expression supplied as an argument. - - - - - Returns a constraint that tests whether the path provided - is the same as an expected path after canonicalization. - - - - - Returns a constraint that tests whether the path provided - is under an expected path after canonicalization. - - - - - Returns a constraint that tests whether the path provided - is the same path or under an expected path after canonicalization. - - - - - Returns a constraint that tests whether the actual value falls - within a specified range. - - - - - Returns a ConstraintExpression that negates any - following constraint. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them succeed. - - - - - Returns a constraint that tests for null - - - - - Returns a constraint that tests for True - - - - - Returns a constraint that tests for False - - - - - Returns a constraint that tests for a positive value - - - - - Returns a constraint that tests for a negative value - - - - - Returns a constraint that tests for NaN - - - - - Returns a constraint that tests for empty - - - - - Returns a constraint that tests whether a collection - contains all unique items. - - - - - Returns a constraint that tests whether an object graph is serializable in binary format. - - - - - Returns a constraint that tests whether an object graph is serializable in xml format. - - - - - Returns a constraint that tests whether a collection is ordered - - - - - The ITestCaseData interface is implemented by a class - that is able to return complete testcases for use by - a parameterized test method. - - NOTE: This interface is used in both the framework - and the core, even though that results in two different - types. However, sharing the source code guarantees that - the various implementations will be compatible and that - the core is able to reflect successfully over the - framework implementations of ITestCaseData. - - - - - Gets the argument list to be provided to the test - - - - - Gets the expected result - - - - - Indicates whether a result has been specified. - This is necessary because the result may be - null, so it's value cannot be checked. - - - - - Gets the expected exception Type - - - - - Gets the FullName of the expected exception - - - - - Gets the name to be used for the test - - - - - Gets the description of the test - - - - - Gets a value indicating whether this is ignored. - - true if ignored; otherwise, false. - - - - Gets a value indicating whether this is explicit. - - true if explicit; otherwise, false. - - - - Gets the ignore reason. - - The ignore reason. - - - - The Iz class is a synonym for Is intended for use in VB, - which regards Is as a keyword. - - - - - The List class is a helper class with properties and methods - that supply a number of constraints used with lists and collections. - - - - - List.Map returns a ListMapper, which can be used to map - the original collection to another collection. - - - - - - - ListMapper is used to transform a collection used as an actual argument - producing another collection to be used in the assertion. - - - - - Construct a ListMapper based on a collection - - The collection to be transformed - - - - Produces a collection containing all the values of a property - - The collection of property values - - - - - Randomizer returns a set of random values in a repeatable - way, to allow re-running of tests if necessary. - - - - - Get a randomizer for a particular member, returning - one that has already been created if it exists. - This ensures that the same values are generated - each time the tests are reloaded. - - - - - Get a randomizer for a particular parameter, returning - one that has already been created if it exists. - This ensures that the same values are generated - each time the tests are reloaded. - - - - - Construct a randomizer using a random seed - - - - - Construct a randomizer using a specified seed - - - - - Return an array of random doubles between 0.0 and 1.0. - - - - - - - Return an array of random doubles with values in a specified range. - - - - - Return an array of random ints with values in a specified range. - - - - - Get a random seed for use in creating a randomizer. - - - - - The SpecialValue enum is used to represent TestCase arguments - that cannot be used as arguments to an Attribute. - - - - - Null represents a null value, which cannot be used as an - argument to an attribute under .NET 1.x - - - - - Basic Asserts on strings. - - - - - The Equals method throws an AssertionException. This is done - to make sure there is no mistake by calling this function. - - - - - - - override the default ReferenceEquals to throw an AssertionException. This - implementation makes sure there is no mistake in calling this function - as part of Assert. - - - - - - - Asserts that a string is found within another string. - - The expected string - The string to be examined - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string is found within another string. - - The expected string - The string to be examined - The message to display in case of failure - - - - Asserts that a string is found within another string. - - The expected string - The string to be examined - - - - Asserts that a string is not found within another string. - - The expected string - The string to be examined - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string is found within another string. - - The expected string - The string to be examined - The message to display in case of failure - - - - Asserts that a string is found within another string. - - The expected string - The string to be examined - - - - Asserts that a string starts with another string. - - The expected string - The string to be examined - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string starts with another string. - - The expected string - The string to be examined - The message to display in case of failure - - - - Asserts that a string starts with another string. - - The expected string - The string to be examined - - - - Asserts that a string does not start with another string. - - The expected string - The string to be examined - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string does not start with another string. - - The expected string - The string to be examined - The message to display in case of failure - - - - Asserts that a string does not start with another string. - - The expected string - The string to be examined - - - - Asserts that a string ends with another string. - - The expected string - The string to be examined - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string ends with another string. - - The expected string - The string to be examined - The message to display in case of failure - - - - Asserts that a string ends with another string. - - The expected string - The string to be examined - - - - Asserts that a string does not end with another string. - - The expected string - The string to be examined - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string does not end with another string. - - The expected string - The string to be examined - The message to display in case of failure - - - - Asserts that a string does not end with another string. - - The expected string - The string to be examined - - - - Asserts that two strings are equal, without regard to case. - - The expected string - The actual string - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that two strings are equal, without regard to case. - - The expected string - The actual string - The message to display in case of failure - - - - Asserts that two strings are equal, without regard to case. - - The expected string - The actual string - - - - Asserts that two strings are not equal, without regard to case. - - The expected string - The actual string - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that two strings are Notequal, without regard to case. - - The expected string - The actual string - The message to display in case of failure - - - - Asserts that two strings are not equal, without regard to case. - - The expected string - The actual string - - - - Asserts that a string matches an expected regular expression pattern. - - The regex pattern to be matched - The actual string - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string matches an expected regular expression pattern. - - The regex pattern to be matched - The actual string - The message to display in case of failure - - - - Asserts that a string matches an expected regular expression pattern. - - The regex pattern to be matched - The actual string - - - - Asserts that a string does not match an expected regular expression pattern. - - The regex pattern to be used - The actual string - The message to display in case of failure - Arguments used in formatting the message - - - - Asserts that a string does not match an expected regular expression pattern. - - The regex pattern to be used - The actual string - The message to display in case of failure - - - - Asserts that a string does not match an expected regular expression pattern. - - The regex pattern to be used - The actual string - - - - The TestCaseData class represents a set of arguments - and other parameter info to be used for a parameterized - test case. It provides a number of instance modifiers - for use in initializing the test case. - - Note: Instance modifiers are getters that return - the same instance after modifying it's state. - - - - - The argument list to be provided to the test - - - - - The expected result to be returned - - - - - Set to true if this has an expected result - - - - - The expected exception Type - - - - - The FullName of the expected exception - - - - - The name to be used for the test - - - - - The description of the test - - - - - A dictionary of properties, used to add information - to tests without requiring the class to change. - - - - - If true, indicates that the test case is to be ignored - - - - - If true, indicates that the test case is marked explicit - - - - - The reason for ignoring a test case - - - - - Initializes a new instance of the class. - - The arguments. - - - - Initializes a new instance of the class. - - The argument. - - - - Initializes a new instance of the class. - - The first argument. - The second argument. - - - - Initializes a new instance of the class. - - The first argument. - The second argument. - The third argument. - - - - Sets the expected result for the test - - The expected result - A modified TestCaseData - - - - Sets the expected exception type for the test - - Type of the expected exception. - The modified TestCaseData instance - - - - Sets the expected exception type for the test - - FullName of the expected exception. - The modified TestCaseData instance - - - - Sets the name of the test case - - The modified TestCaseData instance - - - - Sets the description for the test case - being constructed. - - The description. - The modified TestCaseData instance. - - - - Applies a category to the test - - - - - - - Applies a named property to the test - - - - - - - - Applies a named property to the test - - - - - - - - Applies a named property to the test - - - - - - - - Ignores this TestCase. - - - - - - Ignores this TestCase, specifying the reason. - - The reason. - - - - - Marks this TestCase as Explicit - - - - - - Marks this TestCase as Explicit, specifying the reason. - - The reason. - - - - - Gets the argument list to be provided to the test - - - - - Gets the expected result - - - - - Returns true if the result has been set - - - - - Gets the expected exception Type - - - - - Gets the FullName of the expected exception - - - - - Gets the name to be used for the test - - - - - Gets the description of the test - - - - - Gets a value indicating whether this is ignored. - - true if ignored; otherwise, false. - - - - Gets a value indicating whether this is explicit. - - true if explicit; otherwise, false. - - - - Gets the ignore reason. - - The ignore reason. - - - - Gets a list of categories associated with this test. - - - - - Gets the property dictionary for this test - - - - - Provide the context information of the current test - - - - - Constructs a TestContext using the provided context dictionary - - A context dictionary - - - - Get the current test context. This is created - as needed. The user may save the context for - use within a test, but it should not be used - outside the test for which it is created. - - - - - Gets a TestAdapter representing the currently executing test in this context. - - - - - Gets a ResultAdapter representing the current result for the test - executing in this context. - - - - - Gets the directory containing the current test assembly. - - - - - Gets the directory to be used for outputing files created - by this test run. - - - - - TestAdapter adapts a Test for consumption by - the user test code. - - - - - Constructs a TestAdapter for this context - - The context dictionary - - - - The name of the test. - - - - - The FullName of the test - - - - - The properties of the test. - - - - - ResultAdapter adapts a TestResult for consumption by - the user test code. - - - - - Construct a ResultAdapter for a context - - The context holding the result - - - - The TestState of current test. This maps to the ResultState - used in nunit.core and is subject to change in the future. - - - - - The TestStatus of current test. This enum will be used - in future versions of NUnit and so is to be preferred - to the TestState value. - - - - - Provides details about a test - - - - - Creates an instance of TestDetails - - The fixture that the test is a member of, if available. - The method that implements the test, if available. - The full name of the test. - A string representing the type of test, e.g. "Test Case". - Indicates if the test represents a suite of tests. - - - - The fixture that the test is a member of, if available. - - - - - The method that implements the test, if available. - - - - - The full name of the test. - - - - - A string representing the type of test, e.g. "Test Case". - - - - - Indicates if the test represents a suite of tests. - - - - - The ResultState enum indicates the result of running a test - - - - - The result is inconclusive - - - - - The test was not runnable. - - - - - The test has been skipped. - - - - - The test has been ignored. - - - - - The test succeeded - - - - - The test failed - - - - - The test encountered an unexpected exception - - - - - The test was cancelled by the user - - - - - The TestStatus enum indicates the result of running a test - - - - - The test was inconclusive - - - - - The test has skipped - - - - - The test succeeded - - - - - The test failed - - - - - Helper class with static methods used to supply constraints - that operate on strings. - - - - - Returns a constraint that succeeds if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that fails if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that fails if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that fails if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value matches the Regex pattern supplied as an argument. - - - - - Returns a constraint that fails if the actual - value matches the pattern supplied as an argument. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them succeed. - - - - - TextMessageWriter writes constraint descriptions and messages - in displayable form as a text stream. It tailors the display - of individual message components to form the standard message - format of NUnit assertion failure messages. - - - - - MessageWriter is the abstract base for classes that write - constraint descriptions and messages in some form. The - class has separate methods for writing various components - of a message, allowing implementations to tailor the - presentation as needed. - - - - - Construct a MessageWriter given a culture - - - - - Method to write single line message with optional args, usually - written to precede the general failure message. - - The message to be written - Any arguments used in formatting the message - - - - Method to write single line message with optional args, usually - written to precede the general failure message, at a givel - indentation level. - - The indentation level of the message - The message to be written - Any arguments used in formatting the message - - - - Display Expected and Actual lines for a constraint. This - is called by MessageWriter's default implementation of - WriteMessageTo and provides the generic two-line display. - - The constraint that failed - - - - Display Expected and Actual lines for given values. This - method may be called by constraints that need more control over - the display of actual and expected values than is provided - by the default implementation. - - The expected value - The actual value causing the failure - - - - Display Expected and Actual lines for given values, including - a tolerance value on the Expected line. - - The expected value - The actual value causing the failure - The tolerance within which the test was made - - - - Display the expected and actual string values on separate lines. - If the mismatch parameter is >=0, an additional line is displayed - line containing a caret that points to the mismatch point. - - The expected string value - The actual string value - The point at which the strings don't match or -1 - If true, case is ignored in locating the point where the strings differ - If true, the strings should be clipped to fit the line - - - - Writes the text for a connector. - - The connector. - - - - Writes the text for a predicate. - - The predicate. - - - - Writes the text for an expected value. - - The expected value. - - - - Writes the text for a modifier - - The modifier. - - - - Writes the text for an actual value. - - The actual value. - - - - Writes the text for a generalized value. - - The value. - - - - Writes the text for a collection value, - starting at a particular point, to a max length - - The collection containing elements to write. - The starting point of the elements to write - The maximum number of elements to write - - - - Abstract method to get the max line length - - - - - Prefix used for the expected value line of a message - - - - - Prefix used for the actual value line of a message - - - - - Length of a message prefix - - - - - Construct a TextMessageWriter - - - - - Construct a TextMessageWriter, specifying a user message - and optional formatting arguments. - - - - - - - Method to write single line message with optional args, usually - written to precede the general failure message, at a givel - indentation level. - - The indentation level of the message - The message to be written - Any arguments used in formatting the message - - - - Display Expected and Actual lines for a constraint. This - is called by MessageWriter's default implementation of - WriteMessageTo and provides the generic two-line display. - - The constraint that failed - - - - Display Expected and Actual lines for given values. This - method may be called by constraints that need more control over - the display of actual and expected values than is provided - by the default implementation. - - The expected value - The actual value causing the failure - - - - Display Expected and Actual lines for given values, including - a tolerance value on the expected line. - - The expected value - The actual value causing the failure - The tolerance within which the test was made - - - - Display the expected and actual string values on separate lines. - If the mismatch parameter is >=0, an additional line is displayed - line containing a caret that points to the mismatch point. - - The expected string value - The actual string value - The point at which the strings don't match or -1 - If true, case is ignored in string comparisons - If true, clip the strings to fit the max line length - - - - Writes the text for a connector. - - The connector. - - - - Writes the text for a predicate. - - The predicate. - - - - Write the text for a modifier. - - The modifier. - - - - Writes the text for an expected value. - - The expected value. - - - - Writes the text for an actual value. - - The actual value. - - - - Writes the text for a generalized value. - - The value. - - - - Writes the text for a collection value, - starting at a particular point, to a max length - - The collection containing elements to write. - The starting point of the elements to write - The maximum number of elements to write - - - - Write the generic 'Expected' line for a constraint - - The constraint that failed - - - - Write the generic 'Expected' line for a given value - - The expected value - - - - Write the generic 'Expected' line for a given value - and tolerance. - - The expected value - The tolerance within which the test was made - - - - Write the generic 'Actual' line for a constraint - - The constraint for which the actual value is to be written - - - - Write the generic 'Actual' line for a given value - - The actual value causing a failure - - - - Gets or sets the maximum line length for this writer - - - - - Helper class with properties and methods that supply - constraints that operate on exceptions. - - - - - Creates a constraint specifying the exact type of exception expected - - - - - Creates a constraint specifying the exact type of exception expected - - - - - Creates a constraint specifying the type of exception expected - - - - - Creates a constraint specifying the type of exception expected - - - - - Creates a constraint specifying an expected exception - - - - - Creates a constraint specifying an exception with a given InnerException - - - - - Creates a constraint specifying an expected TargetInvocationException - - - - - Creates a constraint specifying an expected TargetInvocationException - - - - - Creates a constraint specifying an expected TargetInvocationException - - - - - Creates a constraint specifying that no exception is thrown - - - - - Attribute used to apply a category to a test - - - - - The name of the category - - - - - Construct attribute for a given category based on - a name. The name may not contain the characters ',', - '+', '-' or '!'. However, this is not checked in the - constructor since it would cause an error to arise at - as the test was loaded without giving a clear indication - of where the problem is located. The error is handled - in NUnitFramework.cs by marking the test as not - runnable. - - The name of the category - - - - Protected constructor uses the Type name as the name - of the category. - - - - - The name of the category - - - - - Used to mark a field for use as a datapoint when executing a theory - within the same fixture that requires an argument of the field's Type. - - - - - Used to mark an array as containing a set of datapoints to be used - executing a theory within the same fixture that requires an argument - of the Type of the array elements. - - - - - Attribute used to provide descriptive text about a - test case or fixture. - - - - - Construct the attribute - - Text describing the test - - - - Gets the test description - - - - - Enumeration indicating how the expected message parameter is to be used - - - - Expect an exact match - - - Expect a message containing the parameter string - - - Match the regular expression provided as a parameter - - - Expect a message that starts with the parameter string - - - - ExpectedExceptionAttribute - - - - - - Constructor for a non-specific exception - - - - - Constructor for a given type of exception - - The type of the expected exception - - - - Constructor for a given exception name - - The full name of the expected exception - - - - Gets or sets the expected exception type - - - - - Gets or sets the full Type name of the expected exception - - - - - Gets or sets the expected message text - - - - - Gets or sets the user message displayed in case of failure - - - - - Gets or sets the type of match to be performed on the expected message - - - - - Gets the name of a method to be used as an exception handler - - - - - ExplicitAttribute marks a test or test fixture so that it will - only be run if explicitly executed from the gui or command line - or if it is included by use of a filter. The test will not be - run simply because an enclosing suite is run. - - - - - Default constructor - - - - - Constructor with a reason - - The reason test is marked explicit - - - - The reason test is marked explicit - - - - - Attribute used to mark a test that is to be ignored. - Ignored tests result in a warning message when the - tests are run. - - - - - Constructs the attribute without giving a reason - for ignoring the test. - - - - - Constructs the attribute giving a reason for ignoring the test - - The reason for ignoring the test - - - - The reason for ignoring a test - - - - - Abstract base for Attributes that are used to include tests - in the test run based on environmental settings. - - - - - Constructor with no included items specified, for use - with named property syntax. - - - - - Constructor taking one or more included items - - Comma-delimited list of included items - - - - Name of the item that is needed in order for - a test to run. Multiple itemss may be given, - separated by a comma. - - - - - Name of the item to be excluded. Multiple items - may be given, separated by a comma. - - - - - The reason for including or excluding the test - - - - - PlatformAttribute is used to mark a test fixture or an - individual method as applying to a particular platform only. - - - - - Constructor with no platforms specified, for use - with named property syntax. - - - - - Constructor taking one or more platforms - - Comma-deliminted list of platforms - - - - CultureAttribute is used to mark a test fixture or an - individual method as applying to a particular Culture only. - - - - - Constructor with no cultures specified, for use - with named property syntax. - - - - - Constructor taking one or more cultures - - Comma-deliminted list of cultures - - - - Marks a test to use a combinatorial join of any argument data - provided. NUnit will create a test case for every combination of - the arguments provided. This can result in a large number of test - cases and so should be used judiciously. This is the default join - type, so the attribute need not be used except as documentation. - - - - - PropertyAttribute is used to attach information to a test as a name/value pair.. - - - - - Construct a PropertyAttribute with a name and string value - - The name of the property - The property value - - - - Construct a PropertyAttribute with a name and int value - - The name of the property - The property value - - - - Construct a PropertyAttribute with a name and double value - - The name of the property - The property value - - - - Constructor for derived classes that set the - property dictionary directly. - - - - - Constructor for use by derived classes that use the - name of the type as the property name. Derived classes - must ensure that the Type of the property value is - a standard type supported by the BCL. Any custom - types will cause a serialization Exception when - in the client. - - - - - Gets the property dictionary for this attribute - - - - - Default constructor - - - - - Marks a test to use pairwise join of any argument data provided. - NUnit will attempt too excercise every pair of argument values at - least once, using as small a number of test cases as it can. With - only two arguments, this is the same as a combinatorial join. - - - - - Default constructor - - - - - Marks a test to use a sequential join of any argument data - provided. NUnit will use arguements for each parameter in - sequence, generating test cases up to the largest number - of argument values provided and using null for any arguments - for which it runs out of values. Normally, this should be - used with the same number of arguments for each parameter. - - - - - Default constructor - - - - - Summary description for MaxTimeAttribute. - - - - - Construct a MaxTimeAttribute, given a time in milliseconds. - - The maximum elapsed time in milliseconds - - - - RandomAttribute is used to supply a set of random values - to a single parameter of a parameterized test. - - - - - ValuesAttribute is used to provide literal arguments for - an individual parameter of a test. - - - - - Abstract base class for attributes that apply to parameters - and supply data for the parameter. - - - - - Gets the data to be provided to the specified parameter - - - - - The collection of data to be returned. Must - be set by any derived attribute classes. - We use an object[] so that the individual - elements may have their type changed in GetData - if necessary. - - - - - Construct with one argument - - - - - - Construct with two arguments - - - - - - - Construct with three arguments - - - - - - - - Construct with an array of arguments - - - - - - Get the collection of values to be used as arguments - - - - - Construct a set of doubles from 0.0 to 1.0, - specifying only the count. - - - - - - Construct a set of doubles from min to max - - - - - - - - Construct a set of ints from min to max - - - - - - - - Get the collection of values to be used as arguments - - - - - RangeAttribute is used to supply a range of values to an - individual parameter of a parameterized test. - - - - - Construct a range of ints using default step of 1 - - - - - - - Construct a range of ints specifying the step size - - - - - - - - Construct a range of longs - - - - - - - - Construct a range of doubles - - - - - - - - Construct a range of floats - - - - - - - - RepeatAttribute may be applied to test case in order - to run it multiple times. - - - - - Construct a RepeatAttribute - - The number of times to run the test - - - - RequiredAddinAttribute may be used to indicate the names of any addins - that must be present in order to run some or all of the tests in an - assembly. If the addin is not loaded, the entire assembly is marked - as NotRunnable. - - - - - Initializes a new instance of the class. - - The required addin. - - - - Gets the name of required addin. - - The required addin name. - - - - Summary description for SetCultureAttribute. - - - - - Construct given the name of a culture - - - - - - Summary description for SetUICultureAttribute. - - - - - Construct given the name of a culture - - - - - - SetUpAttribute is used in a TestFixture to identify a method - that is called immediately before each test is run. It is - also used in a SetUpFixture to identify the method that is - called once, before any of the subordinate tests are run. - - - - - Attribute used to mark a class that contains one-time SetUp - and/or TearDown methods that apply to all the tests in a - namespace or an assembly. - - - - - Attribute used to mark a static (shared in VB) property - that returns a list of tests. - - - - - Attribute used in a TestFixture to identify a method that is - called immediately after each test is run. It is also used - in a SetUpFixture to identify the method that is called once, - after all subordinate tests have run. In either case, the method - is guaranteed to be called, even if an exception is thrown. - - - - - Provide actions to execute before and after tests. - - - - - When implemented by an attribute, this interface implemented to provide actions to execute before and after tests. - - - - - Executed before each test is run - - Provides details about the test that is going to be run. - - - - Executed after each test is run - - Provides details about the test that has just been run. - - - - Provides the target for the action attribute - - The target for the action attribute - - - - Adding this attribute to a method within a - class makes the method callable from the NUnit test runner. There is a property - called Description which is optional which you can provide a more detailed test - description. This class cannot be inherited. - - - - [TestFixture] - public class Fixture - { - [Test] - public void MethodToTest() - {} - - [Test(Description = "more detailed description")] - publc void TestDescriptionMethod() - {} - } - - - - - - Descriptive text for this test - - - - - TestCaseAttribute is used to mark parameterized test cases - and provide them with their arguments. - - - - - Construct a TestCaseAttribute with a list of arguments. - This constructor is not CLS-Compliant - - - - - - Construct a TestCaseAttribute with a single argument - - - - - - Construct a TestCaseAttribute with a two arguments - - - - - - - Construct a TestCaseAttribute with a three arguments - - - - - - - - Gets the list of arguments to a test case - - - - - Gets or sets the expected result. Use - ExpectedResult by preference. - - The result. - - - - Gets or sets the expected result. - - The result. - - - - Gets a flag indicating whether an expected - result has been set. - - - - - Gets a list of categories associated with this test; - - - - - Gets or sets the category associated with this test. - May be a single category or a comma-separated list. - - - - - Gets or sets the expected exception. - - The expected exception. - - - - Gets or sets the name the expected exception. - - The expected name of the exception. - - - - Gets or sets the expected message of the expected exception - - The expected message of the exception. - - - - Gets or sets the type of match to be performed on the expected message - - - - - Gets or sets the description. - - The description. - - - - Gets or sets the name of the test. - - The name of the test. - - - - Gets or sets the ignored status of the test - - - - - Gets or sets the ignored status of the test - - - - - Gets or sets the explicit status of the test - - - - - Gets or sets the reason for not running the test - - - - - Gets or sets the reason for not running the test. - Set has the side effect of marking the test as ignored. - - The ignore reason. - - - - FactoryAttribute indicates the source to be used to - provide test cases for a test method. - - - - - Construct with the name of the data source, which must - be a property, field or method of the test class itself. - - An array of the names of the factories that will provide data - - - - Construct with a Type, which must implement IEnumerable - - The Type that will provide data - - - - Construct with a Type and name. - that don't support params arrays. - - The Type that will provide data - The name of the method, property or field that will provide data - - - - The name of a the method, property or fiend to be used as a source - - - - - A Type to be used as a source - - - - - Gets or sets the category associated with this test. - May be a single category or a comma-separated list. - - - - - [TestFixture] - public class ExampleClass - {} - - - - - Default constructor - - - - - Construct with a object[] representing a set of arguments. - In .NET 2.0, the arguments may later be separated into - type arguments and constructor arguments. - - - - - - Descriptive text for this fixture - - - - - Gets and sets the category for this fixture. - May be a comma-separated list of categories. - - - - - Gets a list of categories for this fixture - - - - - The arguments originally provided to the attribute - - - - - Gets or sets a value indicating whether this should be ignored. - - true if ignore; otherwise, false. - - - - Gets or sets the ignore reason. May set Ignored as a side effect. - - The ignore reason. - - - - Get or set the type arguments. If not set - explicitly, any leading arguments that are - Types are taken as type arguments. - - - - - Attribute used to identify a method that is - called before any tests in a fixture are run. - - - - - Attribute used to identify a method that is called after - all the tests in a fixture have run. The method is - guaranteed to be called, even if an exception is thrown. - - - - - Adding this attribute to a method within a - class makes the method callable from the NUnit test runner. There is a property - called Description which is optional which you can provide a more detailed test - description. This class cannot be inherited. - - - - [TestFixture] - public class Fixture - { - [Test] - public void MethodToTest() - {} - - [Test(Description = "more detailed description")] - publc void TestDescriptionMethod() - {} - } - - - - - - Used on a method, marks the test with a timeout value in milliseconds. - The test will be run in a separate thread and is cancelled if the timeout - is exceeded. Used on a method or assembly, sets the default timeout - for all contained test methods. - - - - - Construct a TimeoutAttribute given a time in milliseconds - - The timeout value in milliseconds - - - - Marks a test that must run in the STA, causing it - to run in a separate thread if necessary. - - On methods, you may also use STAThreadAttribute - to serve the same purpose. - - - - - Construct a RequiresSTAAttribute - - - - - Marks a test that must run in the MTA, causing it - to run in a separate thread if necessary. - - On methods, you may also use MTAThreadAttribute - to serve the same purpose. - - - - - Construct a RequiresMTAAttribute - - - - - Marks a test that must run on a separate thread. - - - - - Construct a RequiresThreadAttribute - - - - - Construct a RequiresThreadAttribute, specifying the apartment - - - - - ValueSourceAttribute indicates the source to be used to - provide data for one parameter of a test method. - - - - - Construct with the name of the factory - for use with languages - that don't support params arrays. - - The name of the data source to be used - - - - Construct with a Type and name - for use with languages - that don't support params arrays. - - The Type that will provide data - The name of the method, property or field that will provide data - - - - The name of a the method, property or fiend to be used as a source - - - - - A Type to be used as a source - - - - - AllItemsConstraint applies another constraint to each - item in a collection, succeeding if they all succeed. - - - - - Abstract base class used for prefixes - - - - - The Constraint class is the base of all built-in constraints - within NUnit. It provides the operator overloads used to combine - constraints. - - - - - The IConstraintExpression interface is implemented by all - complete and resolvable constraints and expressions. - - - - - Return the top-level constraint for this expression - - - - - - Static UnsetObject used to detect derived constraints - failing to set the actual value. - - - - - The actual value being tested against a constraint - - - - - The display name of this Constraint for use by ToString() - - - - - Argument fields used by ToString(); - - - - - The builder holding this constraint - - - - - Construct a constraint with no arguments - - - - - Construct a constraint with one argument - - - - - Construct a constraint with two arguments - - - - - Sets the ConstraintBuilder holding this constraint - - - - - Write the failure message to the MessageWriter provided - as an argument. The default implementation simply passes - the constraint and the actual value to the writer, which - then displays the constraint description and the value. - - Constraints that need to provide additional details, - such as where the error occured can override this. - - The MessageWriter on which to display the message - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Test whether the constraint is satisfied by an - ActualValueDelegate that returns the value to be tested. - The default implementation simply evaluates the delegate - but derived classes may override it to provide for delayed - processing. - - An - True for success, false for failure - - - - Test whether the constraint is satisfied by a given reference. - The default implementation simply dereferences the value but - derived classes may override it to provide for delayed processing. - - A reference to the value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. The default implementation simply writes - the raw value of actual, leaving it to the writer to - perform any formatting. - - The writer on which the actual value is displayed - - - - Default override of ToString returns the constraint DisplayName - followed by any arguments within angle brackets. - - - - - - Returns the string representation of this constraint - - - - - This operator creates a constraint that is satisfied only if both - argument constraints are satisfied. - - - - - This operator creates a constraint that is satisfied if either - of the argument constraints is satisfied. - - - - - This operator creates a constraint that is satisfied if the - argument constraint is not satisfied. - - - - - Returns a DelayedConstraint with the specified delay time. - - The delay in milliseconds. - - - - - Returns a DelayedConstraint with the specified delay time - and polling interval. - - The delay in milliseconds. - The interval at which to test the constraint. - - - - - The display name of this Constraint for use by ToString(). - The default value is the name of the constraint with - trailing "Constraint" removed. Derived classes may set - this to another name in their constructors. - - - - - Returns a ConstraintExpression by appending And - to the current constraint. - - - - - Returns a ConstraintExpression by appending And - to the current constraint. - - - - - Returns a ConstraintExpression by appending Or - to the current constraint. - - - - - Class used to detect any derived constraints - that fail to set the actual value in their - Matches override. - - - - - The base constraint - - - - - Construct given a base constraint - - - - - - Construct an AllItemsConstraint on top of an existing constraint - - - - - - Apply the item constraint to each item in the collection, - failing if any item fails. - - - - - - - Write a description of this constraint to a MessageWriter - - - - - - AndConstraint succeeds only if both members succeed. - - - - - BinaryConstraint is the abstract base of all constraints - that combine two other constraints in some fashion. - - - - - The first constraint being combined - - - - - The second constraint being combined - - - - - Construct a BinaryConstraint from two other constraints - - The first constraint - The second constraint - - - - Create an AndConstraint from two other constraints - - The first constraint - The second constraint - - - - Apply both member constraints to an actual value, succeeding - succeeding only if both of them succeed. - - The actual value - True if the constraints both succeeded - - - - Write a description for this contraint to a MessageWriter - - The MessageWriter to receive the description - - - - Write the actual value for a failing constraint test to a - MessageWriter. The default implementation simply writes - the raw value of actual, leaving it to the writer to - perform any formatting. - - The writer on which the actual value is displayed - - - - AssignableFromConstraint is used to test that an object - can be assigned from a given Type. - - - - - TypeConstraint is the abstract base for constraints - that take a Type as their expected value. - - - - - The expected Type used by the constraint - - - - - Construct a TypeConstraint for a given Type - - - - - - Write the actual value for a failing constraint test to a - MessageWriter. TypeConstraints override this method to write - the name of the type. - - The writer on which the actual value is displayed - - - - Construct an AssignableFromConstraint for the type provided - - - - - - Test whether an object can be assigned from the specified type - - The object to be tested - True if the object can be assigned a value of the expected Type, otherwise false. - - - - Write a description of this constraint to a MessageWriter - - The MessageWriter to use - - - - AssignableToConstraint is used to test that an object - can be assigned to a given Type. - - - - - Construct an AssignableToConstraint for the type provided - - - - - - Test whether an object can be assigned to the specified type - - The object to be tested - True if the object can be assigned a value of the expected Type, otherwise false. - - - - Write a description of this constraint to a MessageWriter - - The MessageWriter to use - - - - AttributeConstraint tests that a specified attribute is present - on a Type or other provider and that the value of the attribute - satisfies some other constraint. - - - - - Constructs an AttributeConstraint for a specified attriute - Type and base constraint. - - - - - - - Determines whether the Type or other provider has the - expected attribute and if its value matches the - additional constraint specified. - - - - - Writes a description of the attribute to the specified writer. - - - - - Writes the actual value supplied to the specified writer. - - - - - Returns a string representation of the constraint. - - - - - AttributeExistsConstraint tests for the presence of a - specified attribute on a Type. - - - - - Constructs an AttributeExistsConstraint for a specific attribute Type - - - - - - Tests whether the object provides the expected attribute. - - A Type, MethodInfo, or other ICustomAttributeProvider - True if the expected attribute is present, otherwise false - - - - Writes the description of the constraint to the specified writer - - - - - BasicConstraint is the abstract base for constraints that - perform a simple comparison to a constant value. - - - - - Initializes a new instance of the class. - - The expected. - The description. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - BinarySerializableConstraint tests whether - an object is serializable in binary format. - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. The default implementation simply writes - the raw value of actual, leaving it to the writer to - perform any formatting. - - The writer on which the actual value is displayed - - - - Returns the string representation - - - - - CollectionConstraint is the abstract base class for - constraints that operate on collections. - - - - - Construct an empty CollectionConstraint - - - - - Construct a CollectionConstraint - - - - - - Determines whether the specified enumerable is empty. - - The enumerable. - - true if the specified enumerable is empty; otherwise, false. - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Protected method to be implemented by derived classes - - - - - - - CollectionContainsConstraint is used to test whether a collection - contains an expected object as a member. - - - - - CollectionItemsEqualConstraint is the abstract base class for all - collection constraints that apply some notion of item equality - as a part of their operation. - - - - - Construct an empty CollectionConstraint - - - - - Construct a CollectionConstraint - - - - - - Flag the constraint to use the supplied EqualityAdapter. - NOTE: For internal use only. - - The EqualityAdapter to use. - Self. - - - - Flag the constraint to use the supplied IComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied Comparison object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IEqualityComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IEqualityComparer object. - - The IComparer object to use. - Self. - - - - Compares two collection members for equality - - - - - Return a new CollectionTally for use in making tests - - The collection to be included in the tally - - - - Flag the constraint to ignore case and return self. - - - - - Construct a CollectionContainsConstraint - - - - - - Test whether the expected item is contained in the collection - - - - - - - Write a descripton of the constraint to a MessageWriter - - - - - - CollectionEquivalentCOnstraint is used to determine whether two - collections are equivalent. - - - - - Construct a CollectionEquivalentConstraint - - - - - - Test whether two collections are equivalent - - - - - - - Write a description of this constraint to a MessageWriter - - - - - - CollectionOrderedConstraint is used to test whether a collection is ordered. - - - - - Construct a CollectionOrderedConstraint - - - - - Modifies the constraint to use an IComparer and returns self. - - - - - Modifies the constraint to use an IComparer<T> and returns self. - - - - - Modifies the constraint to use a Comparison<T> and returns self. - - - - - Modifies the constraint to test ordering by the value of - a specified property and returns self. - - - - - Test whether the collection is ordered - - - - - - - Write a description of the constraint to a MessageWriter - - - - - - Returns the string representation of the constraint. - - - - - - If used performs a reverse comparison - - - - - CollectionSubsetConstraint is used to determine whether - one collection is a subset of another - - - - - Construct a CollectionSubsetConstraint - - The collection that the actual value is expected to be a subset of - - - - Test whether the actual collection is a subset of - the expected collection provided. - - - - - - - Write a description of this constraint to a MessageWriter - - - - - - CollectionTally counts (tallies) the number of - occurences of each object in one or more enumerations. - - - - - Construct a CollectionTally object from a comparer and a collection - - - - - Try to remove an object from the tally - - The object to remove - True if successful, false if the object was not found - - - - Try to remove a set of objects from the tally - - The objects to remove - True if successful, false if any object was not found - - - - The number of objects remaining in the tally - - - - - ComparisonAdapter class centralizes all comparisons of - values in NUnit, adapting to the use of any provided - IComparer, IComparer<T> or Comparison<T> - - - - - Returns a ComparisonAdapter that wraps an IComparer - - - - - Returns a ComparisonAdapter that wraps an IComparer<T> - - - - - Returns a ComparisonAdapter that wraps a Comparison<T> - - - - - Compares two objects - - - - - Gets the default ComparisonAdapter, which wraps an - NUnitComparer object. - - - - - Construct a ComparisonAdapter for an IComparer - - - - - Compares two objects - - - - - - - - Construct a default ComparisonAdapter - - - - - ComparisonAdapter<T> extends ComparisonAdapter and - allows use of an IComparer<T> or Comparison<T> - to actually perform the comparison. - - - - - Construct a ComparisonAdapter for an IComparer<T> - - - - - Compare a Type T to an object - - - - - Construct a ComparisonAdapter for a Comparison<T> - - - - - Compare a Type T to an object - - - - - Abstract base class for constraints that compare values to - determine if one is greater than, equal to or less than - the other. This class supplies the Using modifiers. - - - - - ComparisonAdapter to be used in making the comparison - - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the class. - - - - - Modifies the constraint to use an IComparer and returns self - - - - - Modifies the constraint to use an IComparer<T> and returns self - - - - - Modifies the constraint to use a Comparison<T> and returns self - - - - - Delegate used to delay evaluation of the actual value - to be used in evaluating a constraint - - - - - ConstraintBuilder maintains the stacks that are used in - processing a ConstraintExpression. An OperatorStack - is used to hold operators that are waiting for their - operands to be reognized. a ConstraintStack holds - input constraints as well as the results of each - operator applied. - - - - - Initializes a new instance of the class. - - - - - Appends the specified operator to the expression by first - reducing the operator stack and then pushing the new - operator on the stack. - - The operator to push. - - - - Appends the specified constraint to the expresson by pushing - it on the constraint stack. - - The constraint to push. - - - - Sets the top operator right context. - - The right context. - - - - Reduces the operator stack until the topmost item - precedence is greater than or equal to the target precedence. - - The target precedence. - - - - Resolves this instance, returning a Constraint. If the builder - is not currently in a resolvable state, an exception is thrown. - - The resolved constraint - - - - Gets a value indicating whether this instance is resolvable. - - - true if this instance is resolvable; otherwise, false. - - - - - OperatorStack is a type-safe stack for holding ConstraintOperators - - - - - Initializes a new instance of the class. - - The builder. - - - - Pushes the specified operator onto the stack. - - The op. - - - - Pops the topmost operator from the stack. - - - - - - Gets a value indicating whether this is empty. - - true if empty; otherwise, false. - - - - Gets the topmost operator without modifying the stack. - - The top. - - - - ConstraintStack is a type-safe stack for holding Constraints - - - - - Initializes a new instance of the class. - - The builder. - - - - Pushes the specified constraint. As a side effect, - the constraint's builder field is set to the - ConstraintBuilder owning this stack. - - The constraint. - - - - Pops this topmost constrait from the stack. - As a side effect, the constraint's builder - field is set to null. - - - - - - Gets a value indicating whether this is empty. - - true if empty; otherwise, false. - - - - Gets the topmost constraint without modifying the stack. - - The topmost constraint - - - - ConstraintExpression represents a compound constraint in the - process of being constructed from a series of syntactic elements. - - Individual elements are appended to the expression as they are - reognized. Once an actual Constraint is appended, the expression - returns a resolvable Constraint. - - - - - ConstraintExpressionBase is the abstract base class for the - ConstraintExpression class, which represents a - compound constraint in the process of being constructed - from a series of syntactic elements. - - NOTE: ConstraintExpressionBase is separate because the - ConstraintExpression class was generated in earlier - versions of NUnit. The two classes may be combined - in a future version. - - - - - The ConstraintBuilder holding the elements recognized so far - - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the - class passing in a ConstraintBuilder, which may be pre-populated. - - The builder. - - - - Returns a string representation of the expression as it - currently stands. This should only be used for testing, - since it has the side-effect of resolving the expression. - - - - - - Appends an operator to the expression and returns the - resulting expression itself. - - - - - Appends a self-resolving operator to the expression and - returns a new ResolvableConstraintExpression. - - - - - Appends a constraint to the expression and returns that - constraint, which is associated with the current state - of the expression being built. - - - - - Initializes a new instance of the class. - - - - - Initializes a new instance of the - class passing in a ConstraintBuilder, which may be pre-populated. - - The builder. - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding only if a specified number of them succeed. - - - - - Returns a new PropertyConstraintExpression, which will either - test for the existence of the named property on the object - being tested or apply any following constraint to that property. - - - - - Returns a new AttributeConstraint checking for the - presence of a particular attribute on an object. - - - - - Returns a new AttributeConstraint checking for the - presence of a particular attribute on an object. - - - - - Returns the constraint provided as an argument - used to allow custom - custom constraints to easily participate in the syntax. - - - - - Returns the constraint provided as an argument - used to allow custom - custom constraints to easily participate in the syntax. - - - - - Returns a constraint that tests two items for equality - - - - - Returns a constraint that tests that two references are the same object - - - - - Returns a constraint that tests whether the - actual value is greater than the suppled argument - - - - - Returns a constraint that tests whether the - actual value is greater than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is greater than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than or equal to the suppled argument - - - - - Returns a constraint that tests whether the - actual value is less than or equal to the suppled argument - - - - - Returns a constraint that tests whether the actual - value is of the exact type supplied as an argument. - - - - - Returns a constraint that tests whether the actual - value is of the exact type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is of the type supplied as an argument or a derived type. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is assignable from the type supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is a collection containing the same elements as the - collection supplied as an argument. - - - - - Returns a constraint that tests whether the actual value - is a subset of the collection supplied as an argument. - - - - - Returns a new CollectionContainsConstraint checking for the - presence of a particular object in the collection. - - - - - Returns a new CollectionContainsConstraint checking for the - presence of a particular object in the collection. - - - - - Returns a new ContainsConstraint. This constraint - will, in turn, make use of the appropriate second-level - constraint, depending on the type of the actual argument. - This overload is only used if the item sought is a string, - since any other type implies that we are looking for a - collection member. - - - - - Returns a constraint that succeeds if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value contains the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value starts with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value ends with the substring supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value matches the regular expression supplied as an argument. - - - - - Returns a constraint that succeeds if the actual - value matches the regular expression supplied as an argument. - - - - - Returns a constraint that tests whether the path provided - is the same as an expected path after canonicalization. - - - - - Returns a constraint that tests whether the path provided - is the same path or under an expected path after canonicalization. - - - - - Returns a constraint that tests whether the path provided - is the same path or under an expected path after canonicalization. - - - - - Returns a constraint that tests whether the actual value falls - within a specified range. - - - - - Returns a ConstraintExpression that negates any - following constraint. - - - - - Returns a ConstraintExpression that negates any - following constraint. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them succeed. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if at least one of them succeeds. - - - - - Returns a ConstraintExpression, which will apply - the following constraint to all members of a collection, - succeeding if all of them fail. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Length property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Count property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the Message property of the object being tested. - - - - - Returns a new ConstraintExpression, which will apply the following - constraint to the InnerException property of the object being tested. - - - - - With is currently a NOP - reserved for future use. - - - - - Returns a constraint that tests for null - - - - - Returns a constraint that tests for True - - - - - Returns a constraint that tests for False - - - - - Returns a constraint that tests for a positive value - - - - - Returns a constraint that tests for a negative value - - - - - Returns a constraint that tests for NaN - - - - - Returns a constraint that tests for empty - - - - - Returns a constraint that tests whether a collection - contains all unique items. - - - - - Returns a constraint that tests whether an object graph is serializable in binary format. - - - - - Returns a constraint that tests whether an object graph is serializable in xml format. - - - - - Returns a constraint that tests whether a collection is ordered - - - - - ContainsConstraint tests a whether a string contains a substring - or a collection contains an object. It postpones the decision of - which test to use until the type of the actual argument is known. - This allows testing whether a string is contained in a collection - or as a substring of another string using the same syntax. - - - - - Initializes a new instance of the class. - - The expected. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Flag the constraint to use the supplied IComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied Comparison object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IEqualityComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IEqualityComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to ignore case and return self. - - - - - Applies a delay to the match so that a match can be evaluated in the future. - - - - - Creates a new DelayedConstraint - - The inner constraint two decorate - The time interval after which the match is performed - If the value of is less than 0 - - - - Creates a new DelayedConstraint - - The inner constraint two decorate - The time interval after which the match is performed - The time interval used for polling - If the value of is less than 0 - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for if the base constraint fails, false if it succeeds - - - - Test whether the constraint is satisfied by a delegate - - The delegate whose value is to be tested - True for if the base constraint fails, false if it succeeds - - - - Test whether the constraint is satisfied by a given reference. - Overridden to wait for the specified delay period before - calling the base constraint with the dereferenced value. - - A reference to the value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a MessageWriter. - - The writer on which the actual value is displayed - - - - Returns the string representation of the constraint. - - - - - EmptyCollectionConstraint tests whether a collection is empty. - - - - - Check that the collection is empty - - - - - - - Write the constraint description to a MessageWriter - - - - - - EmptyConstraint tests a whether a string or collection is empty, - postponing the decision about which test is applied until the - type of the actual argument is known. - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - EmptyDirectoryConstraint is used to test that a directory is empty - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. The default implementation simply writes - the raw value of actual, leaving it to the writer to - perform any formatting. - - The writer on which the actual value is displayed - - - - EmptyStringConstraint tests whether a string is empty. - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - EndsWithConstraint can test whether a string ends - with an expected substring. - - - - - StringConstraint is the abstract base for constraints - that operate on strings. It supports the IgnoreCase - modifier for string operations. - - - - - The expected value - - - - - Indicates whether tests should be case-insensitive - - - - - Constructs a StringConstraint given an expected value - - The expected value - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Test whether the constraint is satisfied by a given string - - The string to be tested - True for success, false for failure - - - - Modify the constraint to ignore case in matching. - - - - - Initializes a new instance of the class. - - The expected string - - - - Test whether the constraint is matched by the actual value. - This is a template method, which calls the IsMatch method - of the derived class. - - - - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - EqualConstraint is able to compare an actual value with the - expected value provided in its constructor. Two objects are - considered equal if both are null, or if both have the same - value. NUnit has special semantics for some object types. - - - - - If true, strings in error messages will be clipped - - - - - NUnitEqualityComparer used to test equality. - - - - - Initializes a new instance of the class. - - The expected value. - - - - Flag the constraint to use a tolerance when determining equality. - - Tolerance value to be used - Self. - - - - Flag the constraint to use the supplied IComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied Comparison object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IEqualityComparer object. - - The IComparer object to use. - Self. - - - - Flag the constraint to use the supplied IEqualityComparer object. - - The IComparer object to use. - Self. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write a failure message. Overridden to provide custom - failure messages for EqualConstraint. - - The MessageWriter to write to - - - - Write description of this constraint - - The MessageWriter to write to - - - - Display the failure information for two collections that did not match. - - The MessageWriter on which to display - The expected collection. - The actual collection - The depth of this failure in a set of nested collections - - - - Displays a single line showing the types and sizes of the expected - and actual enumerations, collections or arrays. If both are identical, - the value is only shown once. - - The MessageWriter on which to display - The expected collection or array - The actual collection or array - The indentation level for the message line - - - - Displays a single line showing the point in the expected and actual - arrays at which the comparison failed. If the arrays have different - structures or dimensions, both values are shown. - - The MessageWriter on which to display - The expected array - The actual array - Index of the failure point in the underlying collections - The indentation level for the message line - - - - Display the failure information for two IEnumerables that did not match. - - The MessageWriter on which to display - The expected enumeration. - The actual enumeration - The depth of this failure in a set of nested collections - - - - Flag the constraint to ignore case and return self. - - - - - Flag the constraint to suppress string clipping - and return self. - - - - - Flag the constraint to compare arrays as collections - and return self. - - - - - Switches the .Within() modifier to interpret its tolerance as - a distance in representable values (see remarks). - - Self. - - Ulp stands for "unit in the last place" and describes the minimum - amount a given value can change. For any integers, an ulp is 1 whole - digit. For floating point values, the accuracy of which is better - for smaller numbers and worse for larger numbers, an ulp depends - on the size of the number. Using ulps for comparison of floating - point results instead of fixed tolerances is safer because it will - automatically compensate for the added inaccuracy of larger numbers. - - - - - Switches the .Within() modifier to interpret its tolerance as - a percentage that the actual values is allowed to deviate from - the expected value. - - Self - - - - Causes the tolerance to be interpreted as a TimeSpan in days. - - Self - - - - Causes the tolerance to be interpreted as a TimeSpan in hours. - - Self - - - - Causes the tolerance to be interpreted as a TimeSpan in minutes. - - Self - - - - Causes the tolerance to be interpreted as a TimeSpan in seconds. - - Self - - - - Causes the tolerance to be interpreted as a TimeSpan in milliseconds. - - Self - - - - Causes the tolerance to be interpreted as a TimeSpan in clock ticks. - - Self - - - - EqualityAdapter class handles all equality comparisons - that use an IEqualityComparer, IEqualityComparer<T> - or a ComparisonAdapter. - - - - - Compares two objects, returning true if they are equal - - - - - Returns true if the two objects can be compared by this adapter. - The base adapter cannot handle IEnumerables except for strings. - - - - - Returns an EqualityAdapter that wraps an IComparer. - - - - - Returns an EqualityAdapter that wraps an IEqualityComparer. - - - - - Returns an EqualityAdapter that wraps an IEqualityComparer<T>. - - - - - Returns an EqualityAdapter that wraps an IComparer<T>. - - - - - Returns an EqualityAdapter that wraps a Comparison<T>. - - - - - EqualityAdapter that wraps an IComparer. - - - - - Returns true if the two objects can be compared by this adapter. - Generic adapter requires objects of the specified type. - - - - - EqualityAdapter that wraps an IComparer. - - - - - EqualityAdapterList represents a list of EqualityAdapters - in a common class across platforms. - - - - - ExactCountConstraint applies another constraint to each - item in a collection, succeeding only if a specified - number of items succeed. - - - - - Construct an ExactCountConstraint on top of an existing constraint - - - - - - - Apply the item constraint to each item in the collection, - succeeding only if the expected number of items pass. - - - - - - - Write a description of this constraint to a MessageWriter - - - - - - ExactTypeConstraint is used to test that an object - is of the exact type provided in the constructor - - - - - Construct an ExactTypeConstraint for a given Type - - The expected Type. - - - - Test that an object is of the exact type specified - - The actual value. - True if the tested object is of the exact type provided, otherwise false. - - - - Write the description of this constraint to a MessageWriter - - The MessageWriter to use - - - - ExceptionTypeConstraint is a special version of ExactTypeConstraint - used to provided detailed info about the exception thrown in - an error message. - - - - - Constructs an ExceptionTypeConstraint - - - - - Write the actual value for a failing constraint test to a - MessageWriter. Overriden to write additional information - in the case of an Exception. - - The MessageWriter to use - - - - FailurePoint class represents one point of failure - in an equality test. - - - - - The location of the failure - - - - - The expected value - - - - - The actual value - - - - - Indicates whether the expected value is valid - - - - - Indicates whether the actual value is valid - - - - - FailurePointList represents a set of FailurePoints - in a cross-platform way. - - - - - FalseConstraint tests that the actual value is false - - - - - Initializes a new instance of the class. - - - - Helper routines for working with floating point numbers - - - The floating point comparison code is based on this excellent article: - http://www.cygnus-software.com/papers/comparingfloats/comparingfloats.htm - - - "ULP" means Unit in the Last Place and in the context of this library refers to - the distance between two adjacent floating point numbers. IEEE floating point - numbers can only represent a finite subset of natural numbers, with greater - accuracy for smaller numbers and lower accuracy for very large numbers. - - - If a comparison is allowed "2 ulps" of deviation, that means the values are - allowed to deviate by up to 2 adjacent floating point values, which might be - as low as 0.0000001 for small numbers or as high as 10.0 for large numbers. - - - - - Compares two floating point values for equality - First floating point value to be compared - Second floating point value t be compared - - Maximum number of representable floating point values that are allowed to - be between the left and the right floating point values - - True if both numbers are equal or close to being equal - - - Floating point values can only represent a finite subset of natural numbers. - For example, the values 2.00000000 and 2.00000024 can be stored in a float, - but nothing inbetween them. - - - This comparison will count how many possible floating point values are between - the left and the right number. If the number of possible values between both - numbers is less than or equal to maxUlps, then the numbers are considered as - being equal. - - - Implementation partially follows the code outlined here: - http://www.anttirt.net/2007/08/19/proper-floating-point-comparisons/ - - - - - Compares two double precision floating point values for equality - First double precision floating point value to be compared - Second double precision floating point value t be compared - - Maximum number of representable double precision floating point values that are - allowed to be between the left and the right double precision floating point values - - True if both numbers are equal or close to being equal - - - Double precision floating point values can only represent a limited series of - natural numbers. For example, the values 2.0000000000000000 and 2.0000000000000004 - can be stored in a double, but nothing inbetween them. - - - This comparison will count how many possible double precision floating point - values are between the left and the right number. If the number of possible - values between both numbers is less than or equal to maxUlps, then the numbers - are considered as being equal. - - - Implementation partially follows the code outlined here: - http://www.anttirt.net/2007/08/19/proper-floating-point-comparisons/ - - - - - - Reinterprets the memory contents of a floating point value as an integer value - - - Floating point value whose memory contents to reinterpret - - - The memory contents of the floating point value interpreted as an integer - - - - - Reinterprets the memory contents of a double precision floating point - value as an integer value - - - Double precision floating point value whose memory contents to reinterpret - - - The memory contents of the double precision floating point value - interpreted as an integer - - - - - Reinterprets the memory contents of an integer as a floating point value - - Integer value whose memory contents to reinterpret - - The memory contents of the integer value interpreted as a floating point value - - - - - Reinterprets the memory contents of an integer value as a double precision - floating point value - - Integer whose memory contents to reinterpret - - The memory contents of the integer interpreted as a double precision - floating point value - - - - Union of a floating point variable and an integer - - - The union's value as a floating point variable - - - The union's value as an integer - - - The union's value as an unsigned integer - - - Union of a double precision floating point variable and a long - - - The union's value as a double precision floating point variable - - - The union's value as a long - - - The union's value as an unsigned long - - - - Tests whether a value is greater than the value supplied to its constructor - - - - - The value against which a comparison is to be made - - - - - Initializes a new instance of the class. - - The expected value. - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Tests whether a value is greater than or equal to the value supplied to its constructor - - - - - The value against which a comparison is to be made - - - - - Initializes a new instance of the class. - - The expected value. - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - InstanceOfTypeConstraint is used to test that an object - is of the same type provided or derived from it. - - - - - Construct an InstanceOfTypeConstraint for the type provided - - The expected Type - - - - Test whether an object is of the specified type or a derived type - - The object to be tested - True if the object is of the provided type or derives from it, otherwise false. - - - - Write a description of this constraint to a MessageWriter - - The MessageWriter to use - - - - Tests whether a value is less than the value supplied to its constructor - - - - - The value against which a comparison is to be made - - - - - Initializes a new instance of the class. - - The expected value. - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Tests whether a value is less than or equal to the value supplied to its constructor - - - - - The value against which a comparison is to be made - - - - - Initializes a new instance of the class. - - The expected value. - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Static methods used in creating messages - - - - - Static string used when strings are clipped - - - - - Returns the representation of a type as used in NUnitLite. - This is the same as Type.ToString() except for arrays, - which are displayed with their declared sizes. - - - - - - - Converts any control characters in a string - to their escaped representation. - - The string to be converted - The converted string - - - - Return the a string representation for a set of indices into an array - - Array of indices for which a string is needed - - - - Get an array of indices representing the point in a enumerable, - collection or array corresponding to a single int index into the - collection. - - The collection to which the indices apply - Index in the collection - Array of indices - - - - Clip a string to a given length, starting at a particular offset, returning the clipped - string with ellipses representing the removed parts - - The string to be clipped - The maximum permitted length of the result string - The point at which to start clipping - The clipped string - - - - Clip the expected and actual strings in a coordinated fashion, - so that they may be displayed together. - - - - - - - - - Shows the position two strings start to differ. Comparison - starts at the start index. - - The expected string - The actual string - The index in the strings at which comparison should start - Boolean indicating whether case should be ignored - -1 if no mismatch found, or the index where mismatch found - - - - NaNConstraint tests that the actual value is a double or float NaN - - - - - Test that the actual value is an NaN - - - - - - - Write the constraint description to a specified writer - - - - - - NoItemConstraint applies another constraint to each - item in a collection, failing if any of them succeeds. - - - - - Construct a NoItemConstraint on top of an existing constraint - - - - - - Apply the item constraint to each item in the collection, - failing if any item fails. - - - - - - - Write a description of this constraint to a MessageWriter - - - - - - NotConstraint negates the effect of some other constraint - - - - - Initializes a new instance of the class. - - The base constraint to be negated. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for if the base constraint fails, false if it succeeds - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a MessageWriter. - - The writer on which the actual value is displayed - - - - NullConstraint tests that the actual value is null - - - - - Initializes a new instance of the class. - - - - - NullEmptyStringConstraint tests whether a string is either null or empty. - - - - - Constructs a new NullOrEmptyStringConstraint - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - The Numerics class contains common operations on numeric values. - - - - - Checks the type of the object, returning true if - the object is a numeric type. - - The object to check - true if the object is a numeric type - - - - Checks the type of the object, returning true if - the object is a floating point numeric type. - - The object to check - true if the object is a floating point numeric type - - - - Checks the type of the object, returning true if - the object is a fixed point numeric type. - - The object to check - true if the object is a fixed point numeric type - - - - Test two numeric values for equality, performing the usual numeric - conversions and using a provided or default tolerance. If the tolerance - provided is Empty, this method may set it to a default tolerance. - - The expected value - The actual value - A reference to the tolerance in effect - True if the values are equal - - - - Compare two numeric values, performing the usual numeric conversions. - - The expected value - The actual value - The relationship of the values to each other - - - - NUnitComparer encapsulates NUnit's default behavior - in comparing two objects. - - - - - Compares two objects - - - - - - - - Returns the default NUnitComparer. - - - - - Generic version of NUnitComparer - - - - - - Compare two objects of the same type - - - - - NUnitEqualityComparer encapsulates NUnit's handling of - equality tests between objects. - - - - - - - - - - Compares two objects for equality within a tolerance - - The first object to compare - The second object to compare - The tolerance to use in the comparison - - - - - If true, all string comparisons will ignore case - - - - - If true, arrays will be treated as collections, allowing - those of different dimensions to be compared - - - - - Comparison objects used in comparisons for some constraints. - - - - - List of points at which a failure occured. - - - - - RecursionDetector used to check for recursion when - evaluating self-referencing enumerables. - - - - - Compares two objects for equality within a tolerance, setting - the tolerance to the actual tolerance used if an empty - tolerance is supplied. - - - - - Helper method to compare two arrays - - - - - Method to compare two DirectoryInfo objects - - first directory to compare - second directory to compare - true if equivalent, false if not - - - - Returns the default NUnitEqualityComparer - - - - - Gets and sets a flag indicating whether case should - be ignored in determining equality. - - - - - Gets and sets a flag indicating that arrays should be - compared as collections, without regard to their shape. - - - - - Gets the list of external comparers to be used to - test for equality. They are applied to members of - collections, in place of NUnit's own logic. - - - - - Gets the list of failure points for the last Match performed. - The list consists of objects to be interpreted by the caller. - This generally means that the caller may only make use of - objects it has placed on the list at a particular depthy. - - - - - RecursionDetector detects when a comparison - between two enumerables has reached a point - where the same objects that were previously - compared are again being compared. This allows - the caller to stop the comparison if desired. - - - - - Check whether two objects have previously - been compared, returning true if they have. - The two objects are remembered, so that a - second call will always return true. - - - - - OrConstraint succeeds if either member succeeds - - - - - Create an OrConstraint from two other constraints - - The first constraint - The second constraint - - - - Apply the member constraints to an actual value, succeeding - succeeding as soon as one of them succeeds. - - The actual value - True if either constraint succeeded - - - - Write a description for this contraint to a MessageWriter - - The MessageWriter to receive the description - - - - PathConstraint serves as the abstract base of constraints - that operate on paths and provides several helper methods. - - - - - The expected path used in the constraint - - - - - Flag indicating whether a caseInsensitive comparison should be made - - - - - Construct a PathConstraint for a give expected path - - The expected path - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Returns true if the expected path and actual path match - - - - - Returns the string representation of this constraint - - - - - Transform the provided path to its canonical form so that it - may be more easily be compared with other paths. - - The original path - The path in canonical form - - - - Test whether one path in canonical form is under another. - - The first path - supposed to be the parent path - The second path - supposed to be the child path - Indicates whether case should be ignored - - - - - Modifies the current instance to be case-insensitve - and returns it. - - - - - Modifies the current instance to be case-sensitve - and returns it. - - - - - Predicate constraint wraps a Predicate in a constraint, - returning success if the predicate is true. - - - - - Construct a PredicateConstraint from a predicate - - - - - Determines whether the predicate succeeds when applied - to the actual value. - - - - - Writes the description to a MessageWriter - - - - - PropertyConstraint extracts a named property and uses - its value as the actual value for a chained constraint. - - - - - Initializes a new instance of the class. - - The name. - The constraint to apply to the property. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. The default implementation simply writes - the raw value of actual, leaving it to the writer to - perform any formatting. - - The writer on which the actual value is displayed - - - - Returns the string representation of the constraint. - - - - - - PropertyExistsConstraint tests that a named property - exists on the object provided through Match. - - Originally, PropertyConstraint provided this feature - in addition to making optional tests on the vaue - of the property. The two constraints are now separate. - - - - - Initializes a new instance of the class. - - The name of the property. - - - - Test whether the property exists for a given object - - The object to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. - - The writer on which the actual value is displayed - - - - Returns the string representation of the constraint. - - - - - - RangeConstraint tests whether two values are within a - specified range. - - - - - Initializes a new instance of the class. - - From. - To. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - RegexConstraint can test whether a string matches - the pattern provided. - - - - - Initializes a new instance of the class. - - The pattern. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - ResolvableConstraintExpression is used to represent a compound - constraint being constructed at a point where the last operator - may either terminate the expression or may have additional - qualifying constraints added to it. - - It is used, for example, for a Property element or for - an Exception element, either of which may be optionally - followed by constraints that apply to the property or - exception. - - - - - Create a new instance of ResolvableConstraintExpression - - - - - Create a new instance of ResolvableConstraintExpression, - passing in a pre-populated ConstraintBuilder. - - - - - Resolve the current expression to a Constraint - - - - - This operator creates a constraint that is satisfied only if both - argument constraints are satisfied. - - - - - This operator creates a constraint that is satisfied only if both - argument constraints are satisfied. - - - - - This operator creates a constraint that is satisfied only if both - argument constraints are satisfied. - - - - - This operator creates a constraint that is satisfied if either - of the argument constraints is satisfied. - - - - - This operator creates a constraint that is satisfied if either - of the argument constraints is satisfied. - - - - - This operator creates a constraint that is satisfied if either - of the argument constraints is satisfied. - - - - - This operator creates a constraint that is satisfied if the - argument constraint is not satisfied. - - - - - Appends an And Operator to the expression - - - - - Appends an Or operator to the expression. - - - - - ReusableConstraint wraps a constraint expression after - resolving it so that it can be reused consistently. - - - - - Construct a ReusableConstraint from a constraint expression - - The expression to be resolved and reused - - - - Converts a constraint to a ReusableConstraint - - The constraint to be converted - A ReusableConstraint - - - - Returns the string representation of the constraint. - - A string representing the constraint - - - - Resolves the ReusableConstraint by returning the constraint - that it originally wrapped. - - A resolved constraint - - - - SameAsConstraint tests whether an object is identical to - the object passed to its constructor - - - - - Initializes a new instance of the class. - - The expected object. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Summary description for SamePathConstraint. - - - - - Initializes a new instance of the class. - - The expected path - - - - Test whether the constraint is satisfied by a given value - - The expected path - The actual path - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - SamePathOrUnderConstraint tests that one path is under another - - - - - Initializes a new instance of the class. - - The expected path - - - - Test whether the constraint is satisfied by a given value - - The expected path - The actual path - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - SomeItemsConstraint applies another constraint to each - item in a collection, succeeding if any of them succeeds. - - - - - Construct a SomeItemsConstraint on top of an existing constraint - - - - - - Apply the item constraint to each item in the collection, - succeeding if any item succeeds. - - - - - - - Write a description of this constraint to a MessageWriter - - - - - - StartsWithConstraint can test whether a string starts - with an expected substring. - - - - - Initializes a new instance of the class. - - The expected string - - - - Test whether the constraint is matched by the actual value. - This is a template method, which calls the IsMatch method - of the derived class. - - - - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - SubPathConstraint tests that the actual path is under the expected path - - - - - Initializes a new instance of the class. - - The expected path - - - - Test whether the constraint is satisfied by a given value - - The expected path - The actual path - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - SubstringConstraint can test whether a string contains - the expected substring. - - - - - Initializes a new instance of the class. - - The expected. - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - ThrowsConstraint is used to test the exception thrown by - a delegate by applying a constraint to it. - - - - - Initializes a new instance of the class, - using a constraint to be applied to the exception. - - A constraint to apply to the caught exception. - - - - Executes the code of the delegate and captures any exception. - If a non-null base constraint was provided, it applies that - constraint to the exception. - - A delegate representing the code to be tested - True if an exception is thrown and the constraint succeeds, otherwise false - - - - Converts an ActualValueDelegate to a TestDelegate - before calling the primary overload. - - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. The default implementation simply writes - the raw value of actual, leaving it to the writer to - perform any formatting. - - The writer on which the actual value is displayed - - - - Returns the string representation of this constraint - - - - - Get the actual exception thrown - used by Assert.Throws. - - - - - ThrowsNothingConstraint tests that a delegate does not - throw an exception. - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True if no exception is thrown, otherwise false - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. Overridden in ThrowsNothingConstraint to write - information about the exception that was actually caught. - - The writer on which the actual value is displayed - - - - The Tolerance class generalizes the notion of a tolerance - within which an equality test succeeds. Normally, it is - used with numeric types, but it can be used with any - type that supports taking a difference between two - objects and comparing that difference to a value. - - - - - Constructs a linear tolerance of a specdified amount - - - - - Constructs a tolerance given an amount and ToleranceMode - - - - - Tests that the current Tolerance is linear with a - numeric value, throwing an exception if it is not. - - - - - Returns an empty Tolerance object, equivalent to - specifying no tolerance. In most cases, it results - in an exact match but for floats and doubles a - default tolerance may be used. - - - - - Returns a zero Tolerance object, equivalent to - specifying an exact match. - - - - - Gets the ToleranceMode for the current Tolerance - - - - - Gets the value of the current Tolerance instance. - - - - - Returns a new tolerance, using the current amount as a percentage. - - - - - Returns a new tolerance, using the current amount in Ulps. - - - - - Returns a new tolerance with a TimeSpan as the amount, using - the current amount as a number of days. - - - - - Returns a new tolerance with a TimeSpan as the amount, using - the current amount as a number of hours. - - - - - Returns a new tolerance with a TimeSpan as the amount, using - the current amount as a number of minutes. - - - - - Returns a new tolerance with a TimeSpan as the amount, using - the current amount as a number of seconds. - - - - - Returns a new tolerance with a TimeSpan as the amount, using - the current amount as a number of milliseconds. - - - - - Returns a new tolerance with a TimeSpan as the amount, using - the current amount as a number of clock ticks. - - - - - Returns true if the current tolerance is empty. - - - - - Modes in which the tolerance value for a comparison can be interpreted. - - - - - The tolerance was created with a value, without specifying - how the value would be used. This is used to prevent setting - the mode more than once and is generally changed to Linear - upon execution of the test. - - - - - The tolerance is used as a numeric range within which - two compared values are considered to be equal. - - - - - Interprets the tolerance as the percentage by which - the two compared values my deviate from each other. - - - - - Compares two values based in their distance in - representable numbers. - - - - - TrueConstraint tests that the actual value is true - - - - - Initializes a new instance of the class. - - - - - UniqueItemsConstraint tests whether all the items in a - collection are unique. - - - - - Check that all items are unique. - - - - - - - Write a description of this constraint to a MessageWriter - - - - - - XmlSerializableConstraint tests whether - an object is serializable in XML format. - - - - - Test whether the constraint is satisfied by a given value - - The value to be tested - True for success, false for failure - - - - Write the constraint description to a MessageWriter - - The writer on which the description is displayed - - - - Write the actual value for a failing constraint test to a - MessageWriter. The default implementation simply writes - the raw value of actual, leaving it to the writer to - perform any formatting. - - The writer on which the actual value is displayed - - - - Returns the string representation of this constraint - - - - - Represents a constraint that succeeds if all the - members of a collection match a base constraint. - - - - - Abstract base for operators that indicate how to - apply a constraint to items in a collection. - - - - - PrefixOperator takes a single constraint and modifies - it's action in some way. - - - - - The ConstraintOperator class is used internally by a - ConstraintBuilder to represent an operator that - modifies or combines constraints. - - Constraint operators use left and right precedence - values to determine whether the top operator on the - stack should be reduced before pushing a new operator. - - - - - The precedence value used when the operator - is about to be pushed to the stack. - - - - - The precedence value used when the operator - is on the top of the stack. - - - - - Reduce produces a constraint from the operator and - any arguments. It takes the arguments from the constraint - stack and pushes the resulting constraint on it. - - - - - - The syntax element preceding this operator - - - - - The syntax element folowing this operator - - - - - The precedence value used when the operator - is about to be pushed to the stack. - - - - - The precedence value used when the operator - is on the top of the stack. - - - - - Reduce produces a constraint from the operator and - any arguments. It takes the arguments from the constraint - stack and pushes the resulting constraint on it. - - - - - - Returns the constraint created by applying this - prefix to another constraint. - - - - - - - Constructs a CollectionOperator - - - - - Returns a constraint that will apply the argument - to the members of a collection, succeeding if - they all succeed. - - - - - Operator that requires both it's arguments to succeed - - - - - Abstract base class for all binary operators - - - - - Reduce produces a constraint from the operator and - any arguments. It takes the arguments from the constraint - stack and pushes the resulting constraint on it. - - - - - - Abstract method that produces a constraint by applying - the operator to its left and right constraint arguments. - - - - - Gets the left precedence of the operator - - - - - Gets the right precedence of the operator - - - - - Construct an AndOperator - - - - - Apply the operator to produce an AndConstraint - - - - - Operator that tests for the presence of a particular attribute - on a type and optionally applies further tests to the attribute. - - - - - Abstract base class for operators that are able to reduce to a - constraint whether or not another syntactic element follows. - - - - - Construct an AttributeOperator for a particular Type - - The Type of attribute tested - - - - Reduce produces a constraint from the operator and - any arguments. It takes the arguments from the constraint - stack and pushes the resulting constraint on it. - - - - - Represents a constraint that succeeds if the specified - count of members of a collection match a base constraint. - - - - - Construct an ExactCountOperator for a specified count - - The expected count - - - - Returns a constraint that will apply the argument - to the members of a collection, succeeding if - none of them succeed. - - - - - Represents a constraint that succeeds if none of the - members of a collection match a base constraint. - - - - - Returns a constraint that will apply the argument - to the members of a collection, succeeding if - none of them succeed. - - - - - Negates the test of the constraint it wraps. - - - - - Constructs a new NotOperator - - - - - Returns a NotConstraint applied to its argument. - - - - - Operator that requires at least one of it's arguments to succeed - - - - - Construct an OrOperator - - - - - Apply the operator to produce an OrConstraint - - - - - Operator used to test for the presence of a named Property - on an object and optionally apply further tests to the - value of that property. - - - - - Constructs a PropOperator for a particular named property - - - - - Reduce produces a constraint from the operator and - any arguments. It takes the arguments from the constraint - stack and pushes the resulting constraint on it. - - - - - - Gets the name of the property to which the operator applies - - - - - Represents a constraint that succeeds if any of the - members of a collection match a base constraint. - - - - - Returns a constraint that will apply the argument - to the members of a collection, succeeding if - any of them succeed. - - - - - Operator that tests that an exception is thrown and - optionally applies further tests to the exception. - - - - - Construct a ThrowsOperator - - - - - Reduce produces a constraint from the operator and - any arguments. It takes the arguments from the constraint - stack and pushes the resulting constraint on it. - - - - - Represents a constraint that simply wraps the - constraint provided as an argument, without any - further functionality, but which modifes the - order of evaluation because of its precedence. - - - - - Constructor for the WithOperator - - - - - Returns a constraint that wraps its argument - - - - - Thrown when an assertion failed. - - - - The error message that explains - the reason for the exception - - - The error message that explains - the reason for the exception - The exception that caused the - current exception - - - - Serialization Constructor - - - - - Thrown when an assertion failed. - - - - - - - The error message that explains - the reason for the exception - The exception that caused the - current exception - - - - Serialization Constructor - - - - - Thrown when a test executes inconclusively. - - - - The error message that explains - the reason for the exception - - - The error message that explains - the reason for the exception - The exception that caused the - current exception - - - - Serialization Constructor - - - - - Thrown when an assertion failed. - - - - - - - The error message that explains - the reason for the exception - The exception that caused the - current exception - - - - Serialization Constructor - - - - - - - - - - - Compares two objects of a given Type for equality within a tolerance - - The first object to compare - The second object to compare - The tolerance to use in the comparison - - - - + + + + nunit.framework + + + + + The different targets a test action attribute can be applied to + + + + + Default target, which is determined by where the action attribute is attached + + + + + Target a individual test case + + + + + Target a suite of test cases + + + + + Delegate used by tests that execute code and + capture any thrown exception. + + + + + The Assert class contains a collection of static methods that + implement the most common assertions used in NUnit. + + + + + We don't actually want any instances of this object, but some people + like to inherit from it to add other static methods. Hence, the + protected constructor disallows any instances of this object. + + + + + The Equals method throws an AssertionException. This is done + to make sure there is no mistake by calling this function. + + + + + + + override the default ReferenceEquals to throw an AssertionException. This + implementation makes sure there is no mistake in calling this function + as part of Assert. + + + + + + + Throws a with the message and arguments + that are passed in. This allows a test to be cut short, with a result + of success returned to NUnit. + + The message to initialize the with. + Arguments to be used in formatting the message + + + + Throws a with the message and arguments + that are passed in. This allows a test to be cut short, with a result + of success returned to NUnit. + + The message to initialize the with. + + + + Throws a with the message and arguments + that are passed in. This allows a test to be cut short, with a result + of success returned to NUnit. + + + + + Throws an with the message and arguments + that are passed in. This is used by the other Assert functions. + + The message to initialize the with. + Arguments to be used in formatting the message + + + + Throws an with the message that is + passed in. This is used by the other Assert functions. + + The message to initialize the with. + + + + Throws an . + This is used by the other Assert functions. + + + + + Throws an with the message and arguments + that are passed in. This causes the test to be reported as ignored. + + The message to initialize the with. + Arguments to be used in formatting the message + + + + Throws an with the message that is + passed in. This causes the test to be reported as ignored. + + The message to initialize the with. + + + + Throws an . + This causes the test to be reported as ignored. + + + + + Throws an with the message and arguments + that are passed in. This causes the test to be reported as inconclusive. + + The message to initialize the with. + Arguments to be used in formatting the message + + + + Throws an with the message that is + passed in. This causes the test to be reported as inconclusive. + + The message to initialize the with. + + + + Throws an . + This causes the test to be reported as Inconclusive. + + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + The message that will be displayed on failure + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint expression to be applied + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display if the condition is false + Arguments to be used in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display if the condition is false + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + An ActualValueDelegate returning the value to be tested + A Constraint expression to be applied + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + An ActualValueDelegate returning the value to be tested + A Constraint expression to be applied + The message that will be displayed on failure + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + An ActualValueDelegate returning the value to be tested + A Constraint expression to be applied + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + The message that will be displayed on failure + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that the code represented by a delegate throws an exception + that satisfies the constraint provided. + + A TestDelegate to be executed + A ThrowsConstraint used in the test + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + Used as a synonym for That in rare cases where a private setter + causes a Visual Basic compilation error. + + The actual value to test + A Constraint to be applied + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + Used as a synonym for That in rare cases where a private setter + causes a Visual Basic compilation error. + + The actual value to test + A Constraint to be applied + The message that will be displayed on failure + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + Used as a synonym for That in rare cases where a private setter + causes a Visual Basic compilation error. + + + This method is provided for use by VB developers needing to test + the value of properties with private setters. + + The actual value to test + A Constraint expression to be applied + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate throws a particular exception when called. + + A constraint to be satisfied by the exception + A TestDelegate + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate throws a particular exception when called. + + A constraint to be satisfied by the exception + A TestDelegate + The message that will be displayed on failure + + + + Verifies that a delegate throws a particular exception when called. + + A constraint to be satisfied by the exception + A TestDelegate + + + + Verifies that a delegate throws a particular exception when called. + + The exception Type expected + A TestDelegate + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate throws a particular exception when called. + + The exception Type expected + A TestDelegate + The message that will be displayed on failure + + + + Verifies that a delegate throws a particular exception when called. + + The exception Type expected + A TestDelegate + + + + Verifies that a delegate throws a particular exception when called. + + Type of the expected exception + A TestDelegate + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate throws a particular exception when called. + + Type of the expected exception + A TestDelegate + The message that will be displayed on failure + + + + Verifies that a delegate throws a particular exception when called. + + Type of the expected exception + A TestDelegate + + + + Verifies that a delegate throws an exception when called + and returns it. + + A TestDelegate + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate throws an exception when called + and returns it. + + A TestDelegate + The message that will be displayed on failure + + + + Verifies that a delegate throws an exception when called + and returns it. + + A TestDelegate + + + + Verifies that a delegate throws an exception of a certain Type + or one derived from it when called and returns it. + + The expected Exception Type + A TestDelegate + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate throws an exception of a certain Type + or one derived from it when called and returns it. + + The expected Exception Type + A TestDelegate + The message that will be displayed on failure + + + + Verifies that a delegate throws an exception of a certain Type + or one derived from it when called and returns it. + + The expected Exception Type + A TestDelegate + + + + Verifies that a delegate throws an exception of a certain Type + or one derived from it when called and returns it. + + The expected Exception Type + A TestDelegate + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate throws an exception of a certain Type + or one derived from it when called and returns it. + + The expected Exception Type + A TestDelegate + The message that will be displayed on failure + + + + Verifies that a delegate throws an exception of a certain Type + or one derived from it when called and returns it. + + The expected Exception Type + A TestDelegate + + + + Verifies that a delegate does not throw an exception + + A TestDelegate + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Verifies that a delegate does not throw an exception. + + A TestDelegate + The message that will be displayed on failure + + + + Verifies that a delegate does not throw an exception. + + A TestDelegate + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display in case of failure + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display in case of failure + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + + + + Asserts that a condition is false. If the condition is true the method throws + an . + + The evaluated condition + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that a condition is false. If the condition is true the method throws + an . + + The evaluated condition + The message to display in case of failure + + + + Asserts that a condition is false. If the condition is true the method throws + an . + + The evaluated condition + + + + Asserts that a condition is false. If the condition is true the method throws + an . + + The evaluated condition + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that a condition is false. If the condition is true the method throws + an . + + The evaluated condition + The message to display in case of failure + + + + Asserts that a condition is false. If the condition is true the method throws + an . + + The evaluated condition + + + + Verifies that the object that is passed in is not equal to null + If the object is null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the object that is passed in is not equal to null + If the object is null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + + + + Verifies that the object that is passed in is not equal to null + If the object is null then an + is thrown. + + The object that is to be tested + + + + Verifies that the object that is passed in is not equal to null + If the object is null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the object that is passed in is not equal to null + If the object is null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + + + + Verifies that the object that is passed in is not equal to null + If the object is null then an + is thrown. + + The object that is to be tested + + + + Verifies that the object that is passed in is equal to null + If the object is not null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the object that is passed in is equal to null + If the object is not null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + + + + Verifies that the object that is passed in is equal to null + If the object is not null then an + is thrown. + + The object that is to be tested + + + + Verifies that the object that is passed in is equal to null + If the object is not null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the object that is passed in is equal to null + If the object is not null then an + is thrown. + + The object that is to be tested + The message to display in case of failure + + + + Verifies that the object that is passed in is equal to null + If the object is not null then an + is thrown. + + The object that is to be tested + + + + Verifies that two ints are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two ints are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two ints are equal. If they are not, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two longs are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two longs are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two longs are equal. If they are not, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two unsigned ints are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two unsigned ints are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two unsigned ints are equal. If they are not, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two unsigned longs are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two unsigned longs are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two unsigned longs are equal. If they are not, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two decimals are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two decimals are equal. If they are not, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two decimals are equal. If they are not, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two doubles are equal considering a delta. If the + expected value is infinity then the delta value is ignored. If + they are not equal then an is + thrown. + + The expected value + The actual value + The maximum acceptable difference between the + the expected and the actual + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two doubles are equal considering a delta. If the + expected value is infinity then the delta value is ignored. If + they are not equal then an is + thrown. + + The expected value + The actual value + The maximum acceptable difference between the + the expected and the actual + The message to display in case of failure + + + + Verifies that two doubles are equal considering a delta. If the + expected value is infinity then the delta value is ignored. If + they are not equal then an is + thrown. + + The expected value + The actual value + The maximum acceptable difference between the + the expected and the actual + + + + Verifies that two doubles are equal considering a delta. If the + expected value is infinity then the delta value is ignored. If + they are not equal then an is + thrown. + + The expected value + The actual value + The maximum acceptable difference between the + the expected and the actual + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two doubles are equal considering a delta. If the + expected value is infinity then the delta value is ignored. If + they are not equal then an is + thrown. + + The expected value + The actual value + The maximum acceptable difference between the + the expected and the actual + The message to display in case of failure + + + + Verifies that two doubles are equal considering a delta. If the + expected value is infinity then the delta value is ignored. If + they are not equal then an is + thrown. + + The expected value + The actual value + The maximum acceptable difference between the + the expected and the actual + + + + Verifies that two objects are equal. Two objects are considered + equal if both are null, or if both have the same value. NUnit + has special semantics for some object types. + If they are not equal an is thrown. + + The value that is expected + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two objects are equal. Two objects are considered + equal if both are null, or if both have the same value. NUnit + has special semantics for some object types. + If they are not equal an is thrown. + + The value that is expected + The actual value + The message to display in case of failure + + + + Verifies that two objects are equal. Two objects are considered + equal if both are null, or if both have the same value. NUnit + has special semantics for some object types. + If they are not equal an is thrown. + + The value that is expected + The actual value + + + + Verifies that two ints are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two ints are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two ints are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two longs are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two longs are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two longs are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two unsigned ints are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two unsigned ints are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two unsigned ints are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two unsigned longs are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two unsigned longs are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two unsigned longs are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two decimals are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two decimals are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two decimals are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two floats are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two floats are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two floats are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two doubles are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two doubles are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + The message to display in case of failure + + + + Verifies that two doubles are not equal. If they are equal, then an + is thrown. + + The expected value + The actual value + + + + Verifies that two objects are not equal. Two objects are considered + equal if both are null, or if both have the same value. NUnit + has special semantics for some object types. + If they are equal an is thrown. + + The value that is expected + The actual value + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that two objects are not equal. Two objects are considered + equal if both are null, or if both have the same value. NUnit + has special semantics for some object types. + If they are equal an is thrown. + + The value that is expected + The actual value + The message to display in case of failure + + + + Verifies that two objects are not equal. Two objects are considered + equal if both are null, or if both have the same value. NUnit + has special semantics for some object types. + If they are equal an is thrown. + + The value that is expected + The actual value + + + + Asserts that two objects refer to the same object. If they + are not the same an is thrown. + + The expected object + The actual object + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that two objects refer to the same object. If they + are not the same an is thrown. + + The expected object + The actual object + The message to display in case of failure + + + + Asserts that two objects refer to the same object. If they + are not the same an is thrown. + + The expected object + The actual object + + + + Asserts that two objects do not refer to the same object. If they + are the same an is thrown. + + The expected object + The actual object + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that two objects do not refer to the same object. If they + are the same an is thrown. + + The expected object + The actual object + The message to display in case of failure + + + + Asserts that two objects do not refer to the same object. If they + are the same an is thrown. + + The expected object + The actual object + + + + Verifies that the double that is passed in is an NaN value. + If the object is not NaN then an + is thrown. + + The value that is to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the double that is passed in is an NaN value. + If the object is not NaN then an + is thrown. + + The value that is to be tested + The message to display in case of failure + + + + Verifies that the double that is passed in is an NaN value. + If the object is not NaN then an + is thrown. + + The value that is to be tested + + + + Verifies that the double that is passed in is an NaN value. + If the object is not NaN then an + is thrown. + + The value that is to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the double that is passed in is an NaN value. + If the object is not NaN then an + is thrown. + + The value that is to be tested + The message to display in case of failure + + + + Verifies that the double that is passed in is an NaN value. + If the object is not NaN then an + is thrown. + + The value that is to be tested + + + + Assert that a string is empty - that is equal to string.Empty + + The string to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Assert that a string is empty - that is equal to string.Empty + + The string to be tested + The message to display in case of failure + + + + Assert that a string is empty - that is equal to string.Empty + + The string to be tested + + + + Assert that an array, list or other collection is empty + + An array, list or other collection implementing ICollection + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Assert that an array, list or other collection is empty + + An array, list or other collection implementing ICollection + The message to display in case of failure + + + + Assert that an array, list or other collection is empty + + An array, list or other collection implementing ICollection + + + + Assert that a string is not empty - that is not equal to string.Empty + + The string to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Assert that a string is not empty - that is not equal to string.Empty + + The string to be tested + The message to display in case of failure + + + + Assert that a string is not empty - that is not equal to string.Empty + + The string to be tested + + + + Assert that an array, list or other collection is not empty + + An array, list or other collection implementing ICollection + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Assert that an array, list or other collection is not empty + + An array, list or other collection implementing ICollection + The message to display in case of failure + + + + Assert that an array, list or other collection is not empty + + An array, list or other collection implementing ICollection + + + + Assert that a string is either null or equal to string.Empty + + The string to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Assert that a string is either null or equal to string.Empty + + The string to be tested + The message to display in case of failure + + + + Assert that a string is either null or equal to string.Empty + + The string to be tested + + + + Assert that a string is not null or empty + + The string to be tested + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Assert that a string is not null or empty + + The string to be tested + The message to display in case of failure + + + + Assert that a string is not null or empty + + The string to be tested + + + + Asserts that an object may be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object may be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + + + + Asserts that an object may be assigned a value of a given Type. + + The expected Type. + The object under examination + + + + Asserts that an object may be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object may be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + + + + Asserts that an object may be assigned a value of a given Type. + + The expected Type. + The object under examination + + + + Asserts that an object may not be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object may not be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + + + + Asserts that an object may not be assigned a value of a given Type. + + The expected Type. + The object under examination + + + + Asserts that an object may not be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object may not be assigned a value of a given Type. + + The expected Type. + The object under examination + The message to display in case of failure + + + + Asserts that an object may not be assigned a value of a given Type. + + The expected Type. + The object under examination + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + + + + Asserts that an object is an instance of a given type. + + The expected Type + The object being examined + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + The message to display in case of failure + + + + Asserts that an object is not an instance of a given type. + + The expected Type + The object being examined + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than the second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + The message to display in case of failure + + + + Verifies that the first value is greater than or equal tothe second + value. If it is not, then an + is thrown. + + The first value, expected to be greater + The second value, expected to be less + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + The message to display in case of failure + + + + Verifies that the first value is less than or equal to the second + value. If it is not, then an + is thrown. + + The first value, expected to be less + The second value, expected to be greater + + + + Asserts that an object is contained in a list. + + The expected object + The list to be examined + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Asserts that an object is contained in a list. + + The expected object + The list to be examined + The message to display in case of failure + + + + Asserts that an object is contained in a list. + + The expected object + The list to be examined + + + + Helper for Assert.AreEqual(double expected, double actual, ...) + allowing code generation to work consistently. + + The expected value + The actual value + The maximum acceptable difference between the + the expected and the actual + The message to display in case of failure + Array of objects to be used in formatting the message + + + + Gets the number of assertions executed so far and + resets the counter to zero. + + + + + AssertionHelper is an optional base class for user tests, + allowing the use of shorter names for constraints and + asserts and avoiding conflict with the definition of + , from which it inherits much of its + behavior, in certain mock object frameworks. + + + + + Helper class with properties and methods that supply + a number of constraints used in Asserts. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding only if a specified number of them succeed. + + + + + Returns a new PropertyConstraintExpression, which will either + test for the existence of the named property on the object + being tested or apply any following constraint to that property. + + + + + Returns a new AttributeConstraint checking for the + presence of a particular attribute on an object. + + + + + Returns a new AttributeConstraint checking for the + presence of a particular attribute on an object. + + + + + Returns a constraint that tests two items for equality + + + + + Returns a constraint that tests that two references are the same object + + + + + Returns a constraint that tests whether the + actual value is greater than the suppled argument + + + + + Returns a constraint that tests whether the + actual value is greater than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is greater than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than or equal to the suppled argument + + + + + Returns a constraint that tests whether the actual + value is of the exact type supplied as an argument. + + + + + Returns a constraint that tests whether the actual + value is of the exact type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is a collection containing the same elements as the + collection supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is a subset of the collection supplied as an argument. + + + + + Returns a new CollectionContainsConstraint checking for the + presence of a particular object in the collection. + + + + + Returns a new CollectionContainsConstraint checking for the + presence of a particular object in the collection. + + + + + Returns a new ContainsConstraint. This constraint + will, in turn, make use of the appropriate second-level + constraint, depending on the type of the actual argument. + This overload is only used if the item sought is a string, + since any other type implies that we are looking for a + collection member. + + + + + Returns a constraint that succeeds if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that fails if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that fails if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that fails if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value matches the regular expression supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value matches the regular expression supplied as an argument. + + + + + Returns a constraint that fails if the actual + value matches the pattern supplied as an argument. + + + + + Returns a constraint that tests whether the path provided + is the same as an expected path after canonicalization. + + + + + Returns a constraint that tests whether the path provided + is the same path or under an expected path after canonicalization. + + + + + Returns a constraint that tests whether the path provided + is the same path or under an expected path after canonicalization. + + + + + Returns a constraint that tests whether the actual value falls + within a specified range. + + + + + Returns a ConstraintExpression that negates any + following constraint. + + + + + Returns a ConstraintExpression that negates any + following constraint. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them succeed. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if at least one of them succeeds. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them fail. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Length property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Count property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Message property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the InnerException property of the object being tested. + + + + + Returns a constraint that tests for null + + + + + Returns a constraint that tests for True + + + + + Returns a constraint that tests for False + + + + + Returns a constraint that tests for a positive value + + + + + Returns a constraint that tests for a negative value + + + + + Returns a constraint that tests for NaN + + + + + Returns a constraint that tests for empty + + + + + Returns a constraint that tests whether a collection + contains all unique items. + + + + + Returns a constraint that tests whether an object graph is serializable in binary format. + + + + + Returns a constraint that tests whether an object graph is serializable in xml format. + + + + + Returns a constraint that tests whether a collection is ordered + + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. Works + identically to Assert.That. + + The actual value to test + A Constraint to be applied + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. Works + identically to Assert.That. + + The actual value to test + A Constraint to be applied + The message to be displayed in case of failure + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. Works + identically to Assert.That. + + The actual value to test + A Constraint to be applied + The message to be displayed in case of failure + Arguments to use in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . Works Identically to + . + + The evaluated condition + The message to display if the condition is false + Arguments to be used in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . Works Identically to + . + + The evaluated condition + The message to display if the condition is false + + + + Asserts that a condition is true. If the condition is false the method throws + an . Works Identically to . + + The evaluated condition + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + A Constraint expression to be applied + An ActualValueDelegate returning the value to be tested + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + A Constraint expression to be applied + An ActualValueDelegate returning the value to be tested + The message that will be displayed on failure + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + An ActualValueDelegate returning the value to be tested + A Constraint expression to be applied + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + The message that will be displayed on failure + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an assertion exception on failure. + + The actual value to test + A Constraint to be applied + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that the code represented by a delegate throws an exception + that satisfies the constraint provided. + + A TestDelegate to be executed + A ThrowsConstraint used in the test + + + + Returns a ListMapper based on a collection. + + The original collection + + + + + Provides static methods to express the assumptions + that must be met for a test to give a meaningful + result. If an assumption is not met, the test + should produce an inconclusive result. + + + + + The Equals method throws an AssertionException. This is done + to make sure there is no mistake by calling this function. + + + + + + + override the default ReferenceEquals to throw an AssertionException. This + implementation makes sure there is no mistake in calling this function + as part of Assert. + + + + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + The actual value to test + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + The actual value to test + The message that will be displayed on failure + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + The actual value to test + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display if the condition is false + Arguments to be used in formatting the message + + + + Asserts that a condition is true. If the condition is false the method throws + an . + + The evaluated condition + The message to display if the condition is false + + + + Asserts that a condition is true. If the condition is false the + method throws an . + + The evaluated condition + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + An ActualValueDelegate returning the value to be tested + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + An ActualValueDelegate returning the value to be tested + The message that will be displayed on failure + + + + Apply a constraint to an actual value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + An ActualValueDelegate returning the value to be tested + A Constraint expression to be applied + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + The actual value to test + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + The actual value to test + The message that will be displayed on failure + + + + Apply a constraint to a referenced value, succeeding if the constraint + is satisfied and throwing an InconclusiveException on failure. + + A Constraint expression to be applied + The actual value to test + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that the code represented by a delegate throws an exception + that satisfies the constraint provided. + + A TestDelegate to be executed + A ThrowsConstraint used in the test + + + + Waits for pending asynchronous operations to complete, if appropriate, + and returns a proper result of the invocation by unwrapping task results + + The raw result of the method invocation + The unwrapped result, if necessary + + + + A set of Assert methods operationg on one or more collections + + + + + The Equals method throws an AssertionException. This is done + to make sure there is no mistake by calling this function. + + + + + + + override the default ReferenceEquals to throw an AssertionException. This + implementation makes sure there is no mistake in calling this function + as part of Assert. + + + + + + + Asserts that all items contained in collection are of the type specified by expectedType. + + IEnumerable containing objects to be considered + System.Type that all objects in collection must be instances of + + + + Asserts that all items contained in collection are of the type specified by expectedType. + + IEnumerable containing objects to be considered + System.Type that all objects in collection must be instances of + The message that will be displayed on failure + + + + Asserts that all items contained in collection are of the type specified by expectedType. + + IEnumerable containing objects to be considered + System.Type that all objects in collection must be instances of + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that all items contained in collection are not equal to null. + + IEnumerable containing objects to be considered + + + + Asserts that all items contained in collection are not equal to null. + + IEnumerable containing objects to be considered + The message that will be displayed on failure + + + + Asserts that all items contained in collection are not equal to null. + + IEnumerable of objects to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Ensures that every object contained in collection exists within the collection + once and only once. + + IEnumerable of objects to be considered + + + + Ensures that every object contained in collection exists within the collection + once and only once. + + IEnumerable of objects to be considered + The message that will be displayed on failure + + + + Ensures that every object contained in collection exists within the collection + once and only once. + + IEnumerable of objects to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that expected and actual are exactly equal. The collections must have the same count, + and contain the exact same objects in the same order. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + + + + Asserts that expected and actual are exactly equal. The collections must have the same count, + and contain the exact same objects in the same order. + If comparer is not null then it will be used to compare the objects. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The IComparer to use in comparing objects from each IEnumerable + + + + Asserts that expected and actual are exactly equal. The collections must have the same count, + and contain the exact same objects in the same order. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + + + + Asserts that expected and actual are exactly equal. The collections must have the same count, + and contain the exact same objects in the same order. + If comparer is not null then it will be used to compare the objects. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The IComparer to use in comparing objects from each IEnumerable + The message that will be displayed on failure + + + + Asserts that expected and actual are exactly equal. The collections must have the same count, + and contain the exact same objects in the same order. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that expected and actual are exactly equal. The collections must have the same count, + and contain the exact same objects in the same order. + If comparer is not null then it will be used to compare the objects. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The IComparer to use in comparing objects from each IEnumerable + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + + + + Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + + + + Asserts that expected and actual are equivalent, containing the same objects but the match may be in any order. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that expected and actual are not exactly equal. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + + + + Asserts that expected and actual are not exactly equal. + If comparer is not null then it will be used to compare the objects. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The IComparer to use in comparing objects from each IEnumerable + + + + Asserts that expected and actual are not exactly equal. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + + + + Asserts that expected and actual are not exactly equal. + If comparer is not null then it will be used to compare the objects. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The IComparer to use in comparing objects from each IEnumerable + The message that will be displayed on failure + + + + Asserts that expected and actual are not exactly equal. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that expected and actual are not exactly equal. + If comparer is not null then it will be used to compare the objects. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The IComparer to use in comparing objects from each IEnumerable + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that expected and actual are not equivalent. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + + + + Asserts that expected and actual are not equivalent. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + + + + Asserts that expected and actual are not equivalent. + + The first IEnumerable of objects to be considered + The second IEnumerable of objects to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that collection contains actual as an item. + + IEnumerable of objects to be considered + Object to be found within collection + + + + Asserts that collection contains actual as an item. + + IEnumerable of objects to be considered + Object to be found within collection + The message that will be displayed on failure + + + + Asserts that collection contains actual as an item. + + IEnumerable of objects to be considered + Object to be found within collection + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that collection does not contain actual as an item. + + IEnumerable of objects to be considered + Object that cannot exist within collection + + + + Asserts that collection does not contain actual as an item. + + IEnumerable of objects to be considered + Object that cannot exist within collection + The message that will be displayed on failure + + + + Asserts that collection does not contain actual as an item. + + IEnumerable of objects to be considered + Object that cannot exist within collection + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that superset is not a subject of subset. + + The IEnumerable superset to be considered + The IEnumerable subset to be considered + + + + Asserts that superset is not a subject of subset. + + The IEnumerable superset to be considered + The IEnumerable subset to be considered + The message that will be displayed on failure + + + + Asserts that superset is not a subject of subset. + + The IEnumerable superset to be considered + The IEnumerable subset to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Asserts that superset is a subset of subset. + + The IEnumerable superset to be considered + The IEnumerable subset to be considered + + + + Asserts that superset is a subset of subset. + + The IEnumerable superset to be considered + The IEnumerable subset to be considered + The message that will be displayed on failure + + + + Asserts that superset is a subset of subset. + + The IEnumerable superset to be considered + The IEnumerable subset to be considered + The message that will be displayed on failure + Arguments to be used in formatting the message + + + + Assert that an array, list or other collection is empty + + An array, list or other collection implementing IEnumerable + The message to be displayed on failure + Arguments to be used in formatting the message + + + + Assert that an array, list or other collection is empty + + An array, list or other collection implementing IEnumerable + The message to be displayed on failure + + + + Assert that an array,list or other collection is empty + + An array, list or other collection implementing IEnumerable + + + + Assert that an array, list or other collection is empty + + An array, list or other collection implementing IEnumerable + The message to be displayed on failure + Arguments to be used in formatting the message + + + + Assert that an array, list or other collection is empty + + An array, list or other collection implementing IEnumerable + The message to be displayed on failure + + + + Assert that an array,list or other collection is empty + + An array, list or other collection implementing IEnumerable + + + + Assert that an array, list or other collection is ordered + + An array, list or other collection implementing IEnumerable + The message to be displayed on failure + Arguments to be used in formatting the message + + + + Assert that an array, list or other collection is ordered + + An array, list or other collection implementing IEnumerable + The message to be displayed on failure + + + + Assert that an array, list or other collection is ordered + + An array, list or other collection implementing IEnumerable + + + + Assert that an array, list or other collection is ordered + + An array, list or other collection implementing IEnumerable + A custom comparer to perform the comparisons + The message to be displayed on failure + Arguments to be used in formatting the message + + + + Assert that an array, list or other collection is ordered + + An array, list or other collection implementing IEnumerable + A custom comparer to perform the comparisons + The message to be displayed on failure + + + + Assert that an array, list or other collection is ordered + + An array, list or other collection implementing IEnumerable + A custom comparer to perform the comparisons + + + + Helper class with properties and methods that supply + a number of constraints used in Asserts. + + + + + Returns a new CollectionContainsConstraint checking for the + presence of a particular object in the collection. + + + + + Returns a constraint that succeeds if the actual + value contains the substring supplied as an argument. + + + + + Summary description for DirectoryAssert + + + + + The Equals method throws an AssertionException. This is done + to make sure there is no mistake by calling this function. + + + + + + + override the default ReferenceEquals to throw an AssertionException. This + implementation makes sure there is no mistake in calling this function + as part of Assert. + + + + + + + We don't actually want any instances of this object, but some people + like to inherit from it to add other static methods. Hence, the + protected constructor disallows any instances of this object. + + + + + Verifies that two directories are equal. Two directories are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A directory containing the value that is expected + A directory containing the actual value + The message to display if directories are not equal + Arguments to be used in formatting the message + + + + Verifies that two directories are equal. Two directories are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A directory containing the value that is expected + A directory containing the actual value + The message to display if directories are not equal + + + + Verifies that two directories are equal. Two directories are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A directory containing the value that is expected + A directory containing the actual value + + + + Verifies that two directories are equal. Two directories are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A directory path string containing the value that is expected + A directory path string containing the actual value + The message to display if directories are not equal + Arguments to be used in formatting the message + + + + Verifies that two directories are equal. Two directories are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A directory path string containing the value that is expected + A directory path string containing the actual value + The message to display if directories are not equal + + + + Verifies that two directories are equal. Two directories are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A directory path string containing the value that is expected + A directory path string containing the actual value + + + + Asserts that two directories are not equal. If they are equal + an is thrown. + + A directory containing the value that is expected + A directory containing the actual value + The message to display if directories are not equal + Arguments to be used in formatting the message + + + + Asserts that two directories are not equal. If they are equal + an is thrown. + + A directory containing the value that is expected + A directory containing the actual value + The message to display if directories are not equal + + + + Asserts that two directories are not equal. If they are equal + an is thrown. + + A directory containing the value that is expected + A directory containing the actual value + + + + Asserts that two directories are not equal. If they are equal + an is thrown. + + A directory path string containing the value that is expected + A directory path string containing the actual value + The message to display if directories are equal + Arguments to be used in formatting the message + + + + Asserts that two directories are not equal. If they are equal + an is thrown. + + A directory path string containing the value that is expected + A directory path string containing the actual value + The message to display if directories are equal + + + + Asserts that two directories are not equal. If they are equal + an is thrown. + + A directory path string containing the value that is expected + A directory path string containing the actual value + + + + Asserts that the directory is empty. If it is not empty + an is thrown. + + A directory to search + The message to display if directories are not equal + Arguments to be used in formatting the message + + + + Asserts that the directory is empty. If it is not empty + an is thrown. + + A directory to search + The message to display if directories are not equal + + + + Asserts that the directory is empty. If it is not empty + an is thrown. + + A directory to search + + + + Asserts that the directory is empty. If it is not empty + an is thrown. + + A directory to search + The message to display if directories are not equal + Arguments to be used in formatting the message + + + + Asserts that the directory is empty. If it is not empty + an is thrown. + + A directory to search + The message to display if directories are not equal + + + + Asserts that the directory is empty. If it is not empty + an is thrown. + + A directory to search + + + + Asserts that the directory is not empty. If it is empty + an is thrown. + + A directory to search + The message to display if directories are not equal + Arguments to be used in formatting the message + + + + Asserts that the directory is not empty. If it is empty + an is thrown. + + A directory to search + The message to display if directories are not equal + + + + Asserts that the directory is not empty. If it is empty + an is thrown. + + A directory to search + + + + Asserts that the directory is not empty. If it is empty + an is thrown. + + A directory to search + The message to display if directories are not equal + Arguments to be used in formatting the message + + + + Asserts that the directory is not empty. If it is empty + an is thrown. + + A directory to search + The message to display if directories are not equal + + + + Asserts that the directory is not empty. If it is empty + an is thrown. + + A directory to search + + + + Asserts that path contains actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + Arguments to be used in formatting the message + + + + Asserts that path contains actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + + + + Asserts that path contains actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + + + + Asserts that path contains actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + Arguments to be used in formatting the message + + + + Asserts that path contains actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + + + + Asserts that path contains actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + + + + Asserts that path does not contain actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + Arguments to be used in formatting the message + + + + Asserts that path does not contain actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + + + + Asserts that path does not contain actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + + + + Asserts that path does not contain actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + Arguments to be used in formatting the message + + + + Asserts that path does not contain actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + The message to display if directory is not within the path + + + + Asserts that path does not contain actual as a subdirectory or + an is thrown. + + A directory to search + sub-directory asserted to exist under directory + + + + Summary description for FileAssert. + + + + + The Equals method throws an AssertionException. This is done + to make sure there is no mistake by calling this function. + + + + + + + override the default ReferenceEquals to throw an AssertionException. This + implementation makes sure there is no mistake in calling this function + as part of Assert. + + + + + + + We don't actually want any instances of this object, but some people + like to inherit from it to add other static methods. Hence, the + protected constructor disallows any instances of this object. + + + + + Verifies that two Streams are equal. Two Streams are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + The expected Stream + The actual Stream + The message to display if Streams are not equal + Arguments to be used in formatting the message + + + + Verifies that two Streams are equal. Two Streams are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + The expected Stream + The actual Stream + The message to display if objects are not equal + + + + Verifies that two Streams are equal. Two Streams are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + The expected Stream + The actual Stream + + + + Verifies that two files are equal. Two files are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A file containing the value that is expected + A file containing the actual value + The message to display if Streams are not equal + Arguments to be used in formatting the message + + + + Verifies that two files are equal. Two files are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A file containing the value that is expected + A file containing the actual value + The message to display if objects are not equal + + + + Verifies that two files are equal. Two files are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + A file containing the value that is expected + A file containing the actual value + + + + Verifies that two files are equal. Two files are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + The path to a file containing the value that is expected + The path to a file containing the actual value + The message to display if Streams are not equal + Arguments to be used in formatting the message + + + + Verifies that two files are equal. Two files are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + The path to a file containing the value that is expected + The path to a file containing the actual value + The message to display if objects are not equal + + + + Verifies that two files are equal. Two files are considered + equal if both are null, or if both have the same value byte for byte. + If they are not equal an is thrown. + + The path to a file containing the value that is expected + The path to a file containing the actual value + + + + Asserts that two Streams are not equal. If they are equal + an is thrown. + + The expected Stream + The actual Stream + The message to be displayed when the two Stream are the same. + Arguments to be used in formatting the message + + + + Asserts that two Streams are not equal. If they are equal + an is thrown. + + The expected Stream + The actual Stream + The message to be displayed when the Streams are the same. + + + + Asserts that two Streams are not equal. If they are equal + an is thrown. + + The expected Stream + The actual Stream + + + + Asserts that two files are not equal. If they are equal + an is thrown. + + A file containing the value that is expected + A file containing the actual value + The message to display if Streams are not equal + Arguments to be used in formatting the message + + + + Asserts that two files are not equal. If they are equal + an is thrown. + + A file containing the value that is expected + A file containing the actual value + The message to display if objects are not equal + + + + Asserts that two files are not equal. If they are equal + an is thrown. + + A file containing the value that is expected + A file containing the actual value + + + + Asserts that two files are not equal. If they are equal + an is thrown. + + The path to a file containing the value that is expected + The path to a file containing the actual value + The message to display if Streams are not equal + Arguments to be used in formatting the message + + + + Asserts that two files are not equal. If they are equal + an is thrown. + + The path to a file containing the value that is expected + The path to a file containing the actual value + The message to display if objects are not equal + + + + Asserts that two files are not equal. If they are equal + an is thrown. + + The path to a file containing the value that is expected + The path to a file containing the actual value + + + + GlobalSettings is a place for setting default values used + by the framework in performing asserts. + + + + + Default tolerance for floating point equality + + + + + Class used to guard against unexpected argument values + by throwing an appropriate exception. + + + + + Throws an exception if an argument is null + + The value to be tested + The name of the argument + + + + Throws an exception if a string argument is null or empty + + The value to be tested + The name of the argument + + + + Helper class with properties and methods that supply + a number of constraints used in Asserts. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding only if a specified number of them succeed. + + + + + Returns a new PropertyConstraintExpression, which will either + test for the existence of the named property on the object + being tested or apply any following constraint to that property. + + + + + Returns a new AttributeConstraint checking for the + presence of a particular attribute on an object. + + + + + Returns a new AttributeConstraint checking for the + presence of a particular attribute on an object. + + + + + Returns a new CollectionContainsConstraint checking for the + presence of a particular object in the collection. + + + + + Returns a ConstraintExpression that negates any + following constraint. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them succeed. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if at least one of them succeeds. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them fail. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Length property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Count property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Message property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the InnerException property of the object being tested. + + + + + Interface implemented by a user fixture in order to + validate any expected exceptions. It is only called + for test methods marked with the ExpectedException + attribute. + + + + + Method to handle an expected exception + + The exception to be handled + + + + Helper class with properties and methods that supply + a number of constraints used in Asserts. + + + + + Returns a constraint that tests two items for equality + + + + + Returns a constraint that tests that two references are the same object + + + + + Returns a constraint that tests whether the + actual value is greater than the suppled argument + + + + + Returns a constraint that tests whether the + actual value is greater than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is greater than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than or equal to the suppled argument + + + + + Returns a constraint that tests whether the actual + value is of the exact type supplied as an argument. + + + + + Returns a constraint that tests whether the actual + value is of the exact type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is a collection containing the same elements as the + collection supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is a subset of the collection supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value matches the regular expression supplied as an argument. + + + + + Returns a constraint that tests whether the path provided + is the same as an expected path after canonicalization. + + + + + Returns a constraint that tests whether the path provided + is under an expected path after canonicalization. + + + + + Returns a constraint that tests whether the path provided + is the same path or under an expected path after canonicalization. + + + + + Returns a constraint that tests whether the actual value falls + within a specified range. + + + + + Returns a ConstraintExpression that negates any + following constraint. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them succeed. + + + + + Returns a constraint that tests for null + + + + + Returns a constraint that tests for True + + + + + Returns a constraint that tests for False + + + + + Returns a constraint that tests for a positive value + + + + + Returns a constraint that tests for a negative value + + + + + Returns a constraint that tests for NaN + + + + + Returns a constraint that tests for empty + + + + + Returns a constraint that tests whether a collection + contains all unique items. + + + + + Returns a constraint that tests whether an object graph is serializable in binary format. + + + + + Returns a constraint that tests whether an object graph is serializable in xml format. + + + + + Returns a constraint that tests whether a collection is ordered + + + + + The ITestCaseData interface is implemented by a class + that is able to return complete testcases for use by + a parameterized test method. + + NOTE: This interface is used in both the framework + and the core, even though that results in two different + types. However, sharing the source code guarantees that + the various implementations will be compatible and that + the core is able to reflect successfully over the + framework implementations of ITestCaseData. + + + + + Gets the argument list to be provided to the test + + + + + Gets the expected result + + + + + Indicates whether a result has been specified. + This is necessary because the result may be + null, so it's value cannot be checked. + + + + + Gets the expected exception Type + + + + + Gets the FullName of the expected exception + + + + + Gets the name to be used for the test + + + + + Gets the description of the test + + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is explicit. + + true if explicit; otherwise, false. + + + + Gets the ignore reason. + + The ignore reason. + + + + The Iz class is a synonym for Is intended for use in VB, + which regards Is as a keyword. + + + + + The List class is a helper class with properties and methods + that supply a number of constraints used with lists and collections. + + + + + List.Map returns a ListMapper, which can be used to map + the original collection to another collection. + + + + + + + ListMapper is used to transform a collection used as an actual argument + producing another collection to be used in the assertion. + + + + + Construct a ListMapper based on a collection + + The collection to be transformed + + + + Produces a collection containing all the values of a property + + The collection of property values + + + + + Randomizer returns a set of random values in a repeatable + way, to allow re-running of tests if necessary. + + + + + Get a randomizer for a particular member, returning + one that has already been created if it exists. + This ensures that the same values are generated + each time the tests are reloaded. + + + + + Get a randomizer for a particular parameter, returning + one that has already been created if it exists. + This ensures that the same values are generated + each time the tests are reloaded. + + + + + Construct a randomizer using a random seed + + + + + Construct a randomizer using a specified seed + + + + + Return an array of random doubles between 0.0 and 1.0. + + + + + + + Return an array of random doubles with values in a specified range. + + + + + Return an array of random ints with values in a specified range. + + + + + Get a random seed for use in creating a randomizer. + + + + + The SpecialValue enum is used to represent TestCase arguments + that cannot be used as arguments to an Attribute. + + + + + Null represents a null value, which cannot be used as an + argument to an attribute under .NET 1.x + + + + + Basic Asserts on strings. + + + + + The Equals method throws an AssertionException. This is done + to make sure there is no mistake by calling this function. + + + + + + + override the default ReferenceEquals to throw an AssertionException. This + implementation makes sure there is no mistake in calling this function + as part of Assert. + + + + + + + Asserts that a string is found within another string. + + The expected string + The string to be examined + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string is found within another string. + + The expected string + The string to be examined + The message to display in case of failure + + + + Asserts that a string is found within another string. + + The expected string + The string to be examined + + + + Asserts that a string is not found within another string. + + The expected string + The string to be examined + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string is found within another string. + + The expected string + The string to be examined + The message to display in case of failure + + + + Asserts that a string is found within another string. + + The expected string + The string to be examined + + + + Asserts that a string starts with another string. + + The expected string + The string to be examined + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string starts with another string. + + The expected string + The string to be examined + The message to display in case of failure + + + + Asserts that a string starts with another string. + + The expected string + The string to be examined + + + + Asserts that a string does not start with another string. + + The expected string + The string to be examined + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string does not start with another string. + + The expected string + The string to be examined + The message to display in case of failure + + + + Asserts that a string does not start with another string. + + The expected string + The string to be examined + + + + Asserts that a string ends with another string. + + The expected string + The string to be examined + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string ends with another string. + + The expected string + The string to be examined + The message to display in case of failure + + + + Asserts that a string ends with another string. + + The expected string + The string to be examined + + + + Asserts that a string does not end with another string. + + The expected string + The string to be examined + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string does not end with another string. + + The expected string + The string to be examined + The message to display in case of failure + + + + Asserts that a string does not end with another string. + + The expected string + The string to be examined + + + + Asserts that two strings are equal, without regard to case. + + The expected string + The actual string + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that two strings are equal, without regard to case. + + The expected string + The actual string + The message to display in case of failure + + + + Asserts that two strings are equal, without regard to case. + + The expected string + The actual string + + + + Asserts that two strings are not equal, without regard to case. + + The expected string + The actual string + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that two strings are Notequal, without regard to case. + + The expected string + The actual string + The message to display in case of failure + + + + Asserts that two strings are not equal, without regard to case. + + The expected string + The actual string + + + + Asserts that a string matches an expected regular expression pattern. + + The regex pattern to be matched + The actual string + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string matches an expected regular expression pattern. + + The regex pattern to be matched + The actual string + The message to display in case of failure + + + + Asserts that a string matches an expected regular expression pattern. + + The regex pattern to be matched + The actual string + + + + Asserts that a string does not match an expected regular expression pattern. + + The regex pattern to be used + The actual string + The message to display in case of failure + Arguments used in formatting the message + + + + Asserts that a string does not match an expected regular expression pattern. + + The regex pattern to be used + The actual string + The message to display in case of failure + + + + Asserts that a string does not match an expected regular expression pattern. + + The regex pattern to be used + The actual string + + + + The TestCaseData class represents a set of arguments + and other parameter info to be used for a parameterized + test case. It provides a number of instance modifiers + for use in initializing the test case. + + Note: Instance modifiers are getters that return + the same instance after modifying it's state. + + + + + The argument list to be provided to the test + + + + + The expected result to be returned + + + + + Set to true if this has an expected result + + + + + The expected exception Type + + + + + The FullName of the expected exception + + + + + The name to be used for the test + + + + + The description of the test + + + + + A dictionary of properties, used to add information + to tests without requiring the class to change. + + + + + If true, indicates that the test case is to be ignored + + + + + If true, indicates that the test case is marked explicit + + + + + The reason for ignoring a test case + + + + + Initializes a new instance of the class. + + The arguments. + + + + Initializes a new instance of the class. + + The argument. + + + + Initializes a new instance of the class. + + The first argument. + The second argument. + + + + Initializes a new instance of the class. + + The first argument. + The second argument. + The third argument. + + + + Sets the expected result for the test + + The expected result + A modified TestCaseData + + + + Sets the expected exception type for the test + + Type of the expected exception. + The modified TestCaseData instance + + + + Sets the expected exception type for the test + + FullName of the expected exception. + The modified TestCaseData instance + + + + Sets the name of the test case + + The modified TestCaseData instance + + + + Sets the description for the test case + being constructed. + + The description. + The modified TestCaseData instance. + + + + Applies a category to the test + + + + + + + Applies a named property to the test + + + + + + + + Applies a named property to the test + + + + + + + + Applies a named property to the test + + + + + + + + Ignores this TestCase. + + + + + + Ignores this TestCase, specifying the reason. + + The reason. + + + + + Marks this TestCase as Explicit + + + + + + Marks this TestCase as Explicit, specifying the reason. + + The reason. + + + + + Gets the argument list to be provided to the test + + + + + Gets the expected result + + + + + Returns true if the result has been set + + + + + Gets the expected exception Type + + + + + Gets the FullName of the expected exception + + + + + Gets the name to be used for the test + + + + + Gets the description of the test + + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is explicit. + + true if explicit; otherwise, false. + + + + Gets the ignore reason. + + The ignore reason. + + + + Gets a list of categories associated with this test. + + + + + Gets the property dictionary for this test + + + + + Provide the context information of the current test + + + + + Constructs a TestContext using the provided context dictionary + + A context dictionary + + + + Get the current test context. This is created + as needed. The user may save the context for + use within a test, but it should not be used + outside the test for which it is created. + + + + + Gets a TestAdapter representing the currently executing test in this context. + + + + + Gets a ResultAdapter representing the current result for the test + executing in this context. + + + + + Gets the directory containing the current test assembly. + + + + + Gets the directory to be used for outputing files created + by this test run. + + + + + TestAdapter adapts a Test for consumption by + the user test code. + + + + + Constructs a TestAdapter for this context + + The context dictionary + + + + The name of the test. + + + + + The FullName of the test + + + + + The properties of the test. + + + + + ResultAdapter adapts a TestResult for consumption by + the user test code. + + + + + Construct a ResultAdapter for a context + + The context holding the result + + + + The TestState of current test. This maps to the ResultState + used in nunit.core and is subject to change in the future. + + + + + The TestStatus of current test. This enum will be used + in future versions of NUnit and so is to be preferred + to the TestState value. + + + + + Provides details about a test + + + + + Creates an instance of TestDetails + + The fixture that the test is a member of, if available. + The method that implements the test, if available. + The full name of the test. + A string representing the type of test, e.g. "Test Case". + Indicates if the test represents a suite of tests. + + + + The fixture that the test is a member of, if available. + + + + + The method that implements the test, if available. + + + + + The full name of the test. + + + + + A string representing the type of test, e.g. "Test Case". + + + + + Indicates if the test represents a suite of tests. + + + + + The ResultState enum indicates the result of running a test + + + + + The result is inconclusive + + + + + The test was not runnable. + + + + + The test has been skipped. + + + + + The test has been ignored. + + + + + The test succeeded + + + + + The test failed + + + + + The test encountered an unexpected exception + + + + + The test was cancelled by the user + + + + + The TestStatus enum indicates the result of running a test + + + + + The test was inconclusive + + + + + The test has skipped + + + + + The test succeeded + + + + + The test failed + + + + + Helper class with static methods used to supply constraints + that operate on strings. + + + + + Returns a constraint that succeeds if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that fails if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that fails if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that fails if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value matches the Regex pattern supplied as an argument. + + + + + Returns a constraint that fails if the actual + value matches the pattern supplied as an argument. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them succeed. + + + + + TextMessageWriter writes constraint descriptions and messages + in displayable form as a text stream. It tailors the display + of individual message components to form the standard message + format of NUnit assertion failure messages. + + + + + MessageWriter is the abstract base for classes that write + constraint descriptions and messages in some form. The + class has separate methods for writing various components + of a message, allowing implementations to tailor the + presentation as needed. + + + + + Construct a MessageWriter given a culture + + + + + Method to write single line message with optional args, usually + written to precede the general failure message. + + The message to be written + Any arguments used in formatting the message + + + + Method to write single line message with optional args, usually + written to precede the general failure message, at a givel + indentation level. + + The indentation level of the message + The message to be written + Any arguments used in formatting the message + + + + Display Expected and Actual lines for a constraint. This + is called by MessageWriter's default implementation of + WriteMessageTo and provides the generic two-line display. + + The constraint that failed + + + + Display Expected and Actual lines for given values. This + method may be called by constraints that need more control over + the display of actual and expected values than is provided + by the default implementation. + + The expected value + The actual value causing the failure + + + + Display Expected and Actual lines for given values, including + a tolerance value on the Expected line. + + The expected value + The actual value causing the failure + The tolerance within which the test was made + + + + Display the expected and actual string values on separate lines. + If the mismatch parameter is >=0, an additional line is displayed + line containing a caret that points to the mismatch point. + + The expected string value + The actual string value + The point at which the strings don't match or -1 + If true, case is ignored in locating the point where the strings differ + If true, the strings should be clipped to fit the line + + + + Writes the text for a connector. + + The connector. + + + + Writes the text for a predicate. + + The predicate. + + + + Writes the text for an expected value. + + The expected value. + + + + Writes the text for a modifier + + The modifier. + + + + Writes the text for an actual value. + + The actual value. + + + + Writes the text for a generalized value. + + The value. + + + + Writes the text for a collection value, + starting at a particular point, to a max length + + The collection containing elements to write. + The starting point of the elements to write + The maximum number of elements to write + + + + Abstract method to get the max line length + + + + + Prefix used for the expected value line of a message + + + + + Prefix used for the actual value line of a message + + + + + Length of a message prefix + + + + + Construct a TextMessageWriter + + + + + Construct a TextMessageWriter, specifying a user message + and optional formatting arguments. + + + + + + + Method to write single line message with optional args, usually + written to precede the general failure message, at a givel + indentation level. + + The indentation level of the message + The message to be written + Any arguments used in formatting the message + + + + Display Expected and Actual lines for a constraint. This + is called by MessageWriter's default implementation of + WriteMessageTo and provides the generic two-line display. + + The constraint that failed + + + + Display Expected and Actual lines for given values. This + method may be called by constraints that need more control over + the display of actual and expected values than is provided + by the default implementation. + + The expected value + The actual value causing the failure + + + + Display Expected and Actual lines for given values, including + a tolerance value on the expected line. + + The expected value + The actual value causing the failure + The tolerance within which the test was made + + + + Display the expected and actual string values on separate lines. + If the mismatch parameter is >=0, an additional line is displayed + line containing a caret that points to the mismatch point. + + The expected string value + The actual string value + The point at which the strings don't match or -1 + If true, case is ignored in string comparisons + If true, clip the strings to fit the max line length + + + + Writes the text for a connector. + + The connector. + + + + Writes the text for a predicate. + + The predicate. + + + + Write the text for a modifier. + + The modifier. + + + + Writes the text for an expected value. + + The expected value. + + + + Writes the text for an actual value. + + The actual value. + + + + Writes the text for a generalized value. + + The value. + + + + Writes the text for a collection value, + starting at a particular point, to a max length + + The collection containing elements to write. + The starting point of the elements to write + The maximum number of elements to write + + + + Write the generic 'Expected' line for a constraint + + The constraint that failed + + + + Write the generic 'Expected' line for a given value + + The expected value + + + + Write the generic 'Expected' line for a given value + and tolerance. + + The expected value + The tolerance within which the test was made + + + + Write the generic 'Actual' line for a constraint + + The constraint for which the actual value is to be written + + + + Write the generic 'Actual' line for a given value + + The actual value causing a failure + + + + Gets or sets the maximum line length for this writer + + + + + Helper class with properties and methods that supply + constraints that operate on exceptions. + + + + + Creates a constraint specifying the exact type of exception expected + + + + + Creates a constraint specifying the exact type of exception expected + + + + + Creates a constraint specifying the type of exception expected + + + + + Creates a constraint specifying the type of exception expected + + + + + Creates a constraint specifying an expected exception + + + + + Creates a constraint specifying an exception with a given InnerException + + + + + Creates a constraint specifying an expected TargetInvocationException + + + + + Creates a constraint specifying an expected TargetInvocationException + + + + + Creates a constraint specifying an expected TargetInvocationException + + + + + Creates a constraint specifying that no exception is thrown + + + + + Attribute used to apply a category to a test + + + + + The name of the category + + + + + Construct attribute for a given category based on + a name. The name may not contain the characters ',', + '+', '-' or '!'. However, this is not checked in the + constructor since it would cause an error to arise at + as the test was loaded without giving a clear indication + of where the problem is located. The error is handled + in NUnitFramework.cs by marking the test as not + runnable. + + The name of the category + + + + Protected constructor uses the Type name as the name + of the category. + + + + + The name of the category + + + + + Used to mark a field for use as a datapoint when executing a theory + within the same fixture that requires an argument of the field's Type. + + + + + Used to mark an array as containing a set of datapoints to be used + executing a theory within the same fixture that requires an argument + of the Type of the array elements. + + + + + Attribute used to provide descriptive text about a + test case or fixture. + + + + + Construct the attribute + + Text describing the test + + + + Gets the test description + + + + + Enumeration indicating how the expected message parameter is to be used + + + + Expect an exact match + + + Expect a message containing the parameter string + + + Match the regular expression provided as a parameter + + + Expect a message that starts with the parameter string + + + + ExpectedExceptionAttribute + + + + + + Constructor for a non-specific exception + + + + + Constructor for a given type of exception + + The type of the expected exception + + + + Constructor for a given exception name + + The full name of the expected exception + + + + Gets or sets the expected exception type + + + + + Gets or sets the full Type name of the expected exception + + + + + Gets or sets the expected message text + + + + + Gets or sets the user message displayed in case of failure + + + + + Gets or sets the type of match to be performed on the expected message + + + + + Gets the name of a method to be used as an exception handler + + + + + ExplicitAttribute marks a test or test fixture so that it will + only be run if explicitly executed from the gui or command line + or if it is included by use of a filter. The test will not be + run simply because an enclosing suite is run. + + + + + Default constructor + + + + + Constructor with a reason + + The reason test is marked explicit + + + + The reason test is marked explicit + + + + + Attribute used to mark a test that is to be ignored. + Ignored tests result in a warning message when the + tests are run. + + + + + Constructs the attribute without giving a reason + for ignoring the test. + + + + + Constructs the attribute giving a reason for ignoring the test + + The reason for ignoring the test + + + + The reason for ignoring a test + + + + + Abstract base for Attributes that are used to include tests + in the test run based on environmental settings. + + + + + Constructor with no included items specified, for use + with named property syntax. + + + + + Constructor taking one or more included items + + Comma-delimited list of included items + + + + Name of the item that is needed in order for + a test to run. Multiple itemss may be given, + separated by a comma. + + + + + Name of the item to be excluded. Multiple items + may be given, separated by a comma. + + + + + The reason for including or excluding the test + + + + + PlatformAttribute is used to mark a test fixture or an + individual method as applying to a particular platform only. + + + + + Constructor with no platforms specified, for use + with named property syntax. + + + + + Constructor taking one or more platforms + + Comma-deliminted list of platforms + + + + CultureAttribute is used to mark a test fixture or an + individual method as applying to a particular Culture only. + + + + + Constructor with no cultures specified, for use + with named property syntax. + + + + + Constructor taking one or more cultures + + Comma-deliminted list of cultures + + + + Marks a test to use a combinatorial join of any argument data + provided. NUnit will create a test case for every combination of + the arguments provided. This can result in a large number of test + cases and so should be used judiciously. This is the default join + type, so the attribute need not be used except as documentation. + + + + + PropertyAttribute is used to attach information to a test as a name/value pair.. + + + + + Construct a PropertyAttribute with a name and string value + + The name of the property + The property value + + + + Construct a PropertyAttribute with a name and int value + + The name of the property + The property value + + + + Construct a PropertyAttribute with a name and double value + + The name of the property + The property value + + + + Constructor for derived classes that set the + property dictionary directly. + + + + + Constructor for use by derived classes that use the + name of the type as the property name. Derived classes + must ensure that the Type of the property value is + a standard type supported by the BCL. Any custom + types will cause a serialization Exception when + in the client. + + + + + Gets the property dictionary for this attribute + + + + + Default constructor + + + + + Marks a test to use pairwise join of any argument data provided. + NUnit will attempt too excercise every pair of argument values at + least once, using as small a number of test cases as it can. With + only two arguments, this is the same as a combinatorial join. + + + + + Default constructor + + + + + Marks a test to use a sequential join of any argument data + provided. NUnit will use arguements for each parameter in + sequence, generating test cases up to the largest number + of argument values provided and using null for any arguments + for which it runs out of values. Normally, this should be + used with the same number of arguments for each parameter. + + + + + Default constructor + + + + + Summary description for MaxTimeAttribute. + + + + + Construct a MaxTimeAttribute, given a time in milliseconds. + + The maximum elapsed time in milliseconds + + + + RandomAttribute is used to supply a set of random values + to a single parameter of a parameterized test. + + + + + ValuesAttribute is used to provide literal arguments for + an individual parameter of a test. + + + + + Abstract base class for attributes that apply to parameters + and supply data for the parameter. + + + + + Gets the data to be provided to the specified parameter + + + + + The collection of data to be returned. Must + be set by any derived attribute classes. + We use an object[] so that the individual + elements may have their type changed in GetData + if necessary. + + + + + Construct with one argument + + + + + + Construct with two arguments + + + + + + + Construct with three arguments + + + + + + + + Construct with an array of arguments + + + + + + Get the collection of values to be used as arguments + + + + + Construct a set of doubles from 0.0 to 1.0, + specifying only the count. + + + + + + Construct a set of doubles from min to max + + + + + + + + Construct a set of ints from min to max + + + + + + + + Get the collection of values to be used as arguments + + + + + RangeAttribute is used to supply a range of values to an + individual parameter of a parameterized test. + + + + + Construct a range of ints using default step of 1 + + + + + + + Construct a range of ints specifying the step size + + + + + + + + Construct a range of longs + + + + + + + + Construct a range of doubles + + + + + + + + Construct a range of floats + + + + + + + + RepeatAttribute may be applied to test case in order + to run it multiple times. + + + + + Construct a RepeatAttribute + + The number of times to run the test + + + + RequiredAddinAttribute may be used to indicate the names of any addins + that must be present in order to run some or all of the tests in an + assembly. If the addin is not loaded, the entire assembly is marked + as NotRunnable. + + + + + Initializes a new instance of the class. + + The required addin. + + + + Gets the name of required addin. + + The required addin name. + + + + Summary description for SetCultureAttribute. + + + + + Construct given the name of a culture + + + + + + Summary description for SetUICultureAttribute. + + + + + Construct given the name of a culture + + + + + + SetUpAttribute is used in a TestFixture to identify a method + that is called immediately before each test is run. It is + also used in a SetUpFixture to identify the method that is + called once, before any of the subordinate tests are run. + + + + + Attribute used to mark a class that contains one-time SetUp + and/or TearDown methods that apply to all the tests in a + namespace or an assembly. + + + + + Attribute used to mark a static (shared in VB) property + that returns a list of tests. + + + + + Attribute used in a TestFixture to identify a method that is + called immediately after each test is run. It is also used + in a SetUpFixture to identify the method that is called once, + after all subordinate tests have run. In either case, the method + is guaranteed to be called, even if an exception is thrown. + + + + + Provide actions to execute before and after tests. + + + + + When implemented by an attribute, this interface implemented to provide actions to execute before and after tests. + + + + + Executed before each test is run + + Provides details about the test that is going to be run. + + + + Executed after each test is run + + Provides details about the test that has just been run. + + + + Provides the target for the action attribute + + The target for the action attribute + + + + Adding this attribute to a method within a + class makes the method callable from the NUnit test runner. There is a property + called Description which is optional which you can provide a more detailed test + description. This class cannot be inherited. + + + + [TestFixture] + public class Fixture + { + [Test] + public void MethodToTest() + {} + + [Test(Description = "more detailed description")] + publc void TestDescriptionMethod() + {} + } + + + + + + Descriptive text for this test + + + + + TestCaseAttribute is used to mark parameterized test cases + and provide them with their arguments. + + + + + Construct a TestCaseAttribute with a list of arguments. + This constructor is not CLS-Compliant + + + + + + Construct a TestCaseAttribute with a single argument + + + + + + Construct a TestCaseAttribute with a two arguments + + + + + + + Construct a TestCaseAttribute with a three arguments + + + + + + + + Gets the list of arguments to a test case + + + + + Gets or sets the expected result. Use + ExpectedResult by preference. + + The result. + + + + Gets or sets the expected result. + + The result. + + + + Gets a flag indicating whether an expected + result has been set. + + + + + Gets a list of categories associated with this test; + + + + + Gets or sets the category associated with this test. + May be a single category or a comma-separated list. + + + + + Gets or sets the expected exception. + + The expected exception. + + + + Gets or sets the name the expected exception. + + The expected name of the exception. + + + + Gets or sets the expected message of the expected exception + + The expected message of the exception. + + + + Gets or sets the type of match to be performed on the expected message + + + + + Gets or sets the description. + + The description. + + + + Gets or sets the name of the test. + + The name of the test. + + + + Gets or sets the ignored status of the test + + + + + Gets or sets the ignored status of the test + + + + + Gets or sets the explicit status of the test + + + + + Gets or sets the reason for not running the test + + + + + Gets or sets the reason for not running the test. + Set has the side effect of marking the test as ignored. + + The ignore reason. + + + + FactoryAttribute indicates the source to be used to + provide test cases for a test method. + + + + + Construct with the name of the data source, which must + be a property, field or method of the test class itself. + + An array of the names of the factories that will provide data + + + + Construct with a Type, which must implement IEnumerable + + The Type that will provide data + + + + Construct with a Type and name. + that don't support params arrays. + + The Type that will provide data + The name of the method, property or field that will provide data + + + + The name of a the method, property or fiend to be used as a source + + + + + A Type to be used as a source + + + + + Gets or sets the category associated with this test. + May be a single category or a comma-separated list. + + + + + [TestFixture] + public class ExampleClass + {} + + + + + Default constructor + + + + + Construct with a object[] representing a set of arguments. + In .NET 2.0, the arguments may later be separated into + type arguments and constructor arguments. + + + + + + Descriptive text for this fixture + + + + + Gets and sets the category for this fixture. + May be a comma-separated list of categories. + + + + + Gets a list of categories for this fixture + + + + + The arguments originally provided to the attribute + + + + + Gets or sets a value indicating whether this should be ignored. + + true if ignore; otherwise, false. + + + + Gets or sets the ignore reason. May set Ignored as a side effect. + + The ignore reason. + + + + Get or set the type arguments. If not set + explicitly, any leading arguments that are + Types are taken as type arguments. + + + + + Attribute used to identify a method that is + called before any tests in a fixture are run. + + + + + Attribute used to identify a method that is called after + all the tests in a fixture have run. The method is + guaranteed to be called, even if an exception is thrown. + + + + + Adding this attribute to a method within a + class makes the method callable from the NUnit test runner. There is a property + called Description which is optional which you can provide a more detailed test + description. This class cannot be inherited. + + + + [TestFixture] + public class Fixture + { + [Test] + public void MethodToTest() + {} + + [Test(Description = "more detailed description")] + publc void TestDescriptionMethod() + {} + } + + + + + + Used on a method, marks the test with a timeout value in milliseconds. + The test will be run in a separate thread and is cancelled if the timeout + is exceeded. Used on a method or assembly, sets the default timeout + for all contained test methods. + + + + + Construct a TimeoutAttribute given a time in milliseconds + + The timeout value in milliseconds + + + + Marks a test that must run in the STA, causing it + to run in a separate thread if necessary. + + On methods, you may also use STAThreadAttribute + to serve the same purpose. + + + + + Construct a RequiresSTAAttribute + + + + + Marks a test that must run in the MTA, causing it + to run in a separate thread if necessary. + + On methods, you may also use MTAThreadAttribute + to serve the same purpose. + + + + + Construct a RequiresMTAAttribute + + + + + Marks a test that must run on a separate thread. + + + + + Construct a RequiresThreadAttribute + + + + + Construct a RequiresThreadAttribute, specifying the apartment + + + + + ValueSourceAttribute indicates the source to be used to + provide data for one parameter of a test method. + + + + + Construct with the name of the factory - for use with languages + that don't support params arrays. + + The name of the data source to be used + + + + Construct with a Type and name - for use with languages + that don't support params arrays. + + The Type that will provide data + The name of the method, property or field that will provide data + + + + The name of a the method, property or fiend to be used as a source + + + + + A Type to be used as a source + + + + + AllItemsConstraint applies another constraint to each + item in a collection, succeeding if they all succeed. + + + + + Abstract base class used for prefixes + + + + + The Constraint class is the base of all built-in constraints + within NUnit. It provides the operator overloads used to combine + constraints. + + + + + The IConstraintExpression interface is implemented by all + complete and resolvable constraints and expressions. + + + + + Return the top-level constraint for this expression + + + + + + Static UnsetObject used to detect derived constraints + failing to set the actual value. + + + + + The actual value being tested against a constraint + + + + + The display name of this Constraint for use by ToString() + + + + + Argument fields used by ToString(); + + + + + The builder holding this constraint + + + + + Construct a constraint with no arguments + + + + + Construct a constraint with one argument + + + + + Construct a constraint with two arguments + + + + + Sets the ConstraintBuilder holding this constraint + + + + + Write the failure message to the MessageWriter provided + as an argument. The default implementation simply passes + the constraint and the actual value to the writer, which + then displays the constraint description and the value. + + Constraints that need to provide additional details, + such as where the error occured can override this. + + The MessageWriter on which to display the message + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Test whether the constraint is satisfied by an + ActualValueDelegate that returns the value to be tested. + The default implementation simply evaluates the delegate + but derived classes may override it to provide for delayed + processing. + + An + True for success, false for failure + + + + Test whether the constraint is satisfied by a given reference. + The default implementation simply dereferences the value but + derived classes may override it to provide for delayed processing. + + A reference to the value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. The default implementation simply writes + the raw value of actual, leaving it to the writer to + perform any formatting. + + The writer on which the actual value is displayed + + + + Default override of ToString returns the constraint DisplayName + followed by any arguments within angle brackets. + + + + + + Returns the string representation of this constraint + + + + + This operator creates a constraint that is satisfied only if both + argument constraints are satisfied. + + + + + This operator creates a constraint that is satisfied if either + of the argument constraints is satisfied. + + + + + This operator creates a constraint that is satisfied if the + argument constraint is not satisfied. + + + + + Returns a DelayedConstraint with the specified delay time. + + The delay in milliseconds. + + + + + Returns a DelayedConstraint with the specified delay time + and polling interval. + + The delay in milliseconds. + The interval at which to test the constraint. + + + + + The display name of this Constraint for use by ToString(). + The default value is the name of the constraint with + trailing "Constraint" removed. Derived classes may set + this to another name in their constructors. + + + + + Returns a ConstraintExpression by appending And + to the current constraint. + + + + + Returns a ConstraintExpression by appending And + to the current constraint. + + + + + Returns a ConstraintExpression by appending Or + to the current constraint. + + + + + Class used to detect any derived constraints + that fail to set the actual value in their + Matches override. + + + + + The base constraint + + + + + Construct given a base constraint + + + + + + Construct an AllItemsConstraint on top of an existing constraint + + + + + + Apply the item constraint to each item in the collection, + failing if any item fails. + + + + + + + Write a description of this constraint to a MessageWriter + + + + + + AndConstraint succeeds only if both members succeed. + + + + + BinaryConstraint is the abstract base of all constraints + that combine two other constraints in some fashion. + + + + + The first constraint being combined + + + + + The second constraint being combined + + + + + Construct a BinaryConstraint from two other constraints + + The first constraint + The second constraint + + + + Create an AndConstraint from two other constraints + + The first constraint + The second constraint + + + + Apply both member constraints to an actual value, succeeding + succeeding only if both of them succeed. + + The actual value + True if the constraints both succeeded + + + + Write a description for this contraint to a MessageWriter + + The MessageWriter to receive the description + + + + Write the actual value for a failing constraint test to a + MessageWriter. The default implementation simply writes + the raw value of actual, leaving it to the writer to + perform any formatting. + + The writer on which the actual value is displayed + + + + AssignableFromConstraint is used to test that an object + can be assigned from a given Type. + + + + + TypeConstraint is the abstract base for constraints + that take a Type as their expected value. + + + + + The expected Type used by the constraint + + + + + Construct a TypeConstraint for a given Type + + + + + + Write the actual value for a failing constraint test to a + MessageWriter. TypeConstraints override this method to write + the name of the type. + + The writer on which the actual value is displayed + + + + Construct an AssignableFromConstraint for the type provided + + + + + + Test whether an object can be assigned from the specified type + + The object to be tested + True if the object can be assigned a value of the expected Type, otherwise false. + + + + Write a description of this constraint to a MessageWriter + + The MessageWriter to use + + + + AssignableToConstraint is used to test that an object + can be assigned to a given Type. + + + + + Construct an AssignableToConstraint for the type provided + + + + + + Test whether an object can be assigned to the specified type + + The object to be tested + True if the object can be assigned a value of the expected Type, otherwise false. + + + + Write a description of this constraint to a MessageWriter + + The MessageWriter to use + + + + AttributeConstraint tests that a specified attribute is present + on a Type or other provider and that the value of the attribute + satisfies some other constraint. + + + + + Constructs an AttributeConstraint for a specified attriute + Type and base constraint. + + + + + + + Determines whether the Type or other provider has the + expected attribute and if its value matches the + additional constraint specified. + + + + + Writes a description of the attribute to the specified writer. + + + + + Writes the actual value supplied to the specified writer. + + + + + Returns a string representation of the constraint. + + + + + AttributeExistsConstraint tests for the presence of a + specified attribute on a Type. + + + + + Constructs an AttributeExistsConstraint for a specific attribute Type + + + + + + Tests whether the object provides the expected attribute. + + A Type, MethodInfo, or other ICustomAttributeProvider + True if the expected attribute is present, otherwise false + + + + Writes the description of the constraint to the specified writer + + + + + BasicConstraint is the abstract base for constraints that + perform a simple comparison to a constant value. + + + + + Initializes a new instance of the class. + + The expected. + The description. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + BinarySerializableConstraint tests whether + an object is serializable in binary format. + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. The default implementation simply writes + the raw value of actual, leaving it to the writer to + perform any formatting. + + The writer on which the actual value is displayed + + + + Returns the string representation + + + + + CollectionConstraint is the abstract base class for + constraints that operate on collections. + + + + + Construct an empty CollectionConstraint + + + + + Construct a CollectionConstraint + + + + + + Determines whether the specified enumerable is empty. + + The enumerable. + + true if the specified enumerable is empty; otherwise, false. + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Protected method to be implemented by derived classes + + + + + + + CollectionContainsConstraint is used to test whether a collection + contains an expected object as a member. + + + + + CollectionItemsEqualConstraint is the abstract base class for all + collection constraints that apply some notion of item equality + as a part of their operation. + + + + + Construct an empty CollectionConstraint + + + + + Construct a CollectionConstraint + + + + + + Flag the constraint to use the supplied EqualityAdapter. + NOTE: For internal use only. + + The EqualityAdapter to use. + Self. + + + + Flag the constraint to use the supplied IComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied Comparison object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IEqualityComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IEqualityComparer object. + + The IComparer object to use. + Self. + + + + Compares two collection members for equality + + + + + Return a new CollectionTally for use in making tests + + The collection to be included in the tally + + + + Flag the constraint to ignore case and return self. + + + + + Construct a CollectionContainsConstraint + + + + + + Test whether the expected item is contained in the collection + + + + + + + Write a descripton of the constraint to a MessageWriter + + + + + + CollectionEquivalentCOnstraint is used to determine whether two + collections are equivalent. + + + + + Construct a CollectionEquivalentConstraint + + + + + + Test whether two collections are equivalent + + + + + + + Write a description of this constraint to a MessageWriter + + + + + + CollectionOrderedConstraint is used to test whether a collection is ordered. + + + + + Construct a CollectionOrderedConstraint + + + + + Modifies the constraint to use an IComparer and returns self. + + + + + Modifies the constraint to use an IComparer<T> and returns self. + + + + + Modifies the constraint to use a Comparison<T> and returns self. + + + + + Modifies the constraint to test ordering by the value of + a specified property and returns self. + + + + + Test whether the collection is ordered + + + + + + + Write a description of the constraint to a MessageWriter + + + + + + Returns the string representation of the constraint. + + + + + + If used performs a reverse comparison + + + + + CollectionSubsetConstraint is used to determine whether + one collection is a subset of another + + + + + Construct a CollectionSubsetConstraint + + The collection that the actual value is expected to be a subset of + + + + Test whether the actual collection is a subset of + the expected collection provided. + + + + + + + Write a description of this constraint to a MessageWriter + + + + + + CollectionTally counts (tallies) the number of + occurences of each object in one or more enumerations. + + + + + Construct a CollectionTally object from a comparer and a collection + + + + + Try to remove an object from the tally + + The object to remove + True if successful, false if the object was not found + + + + Try to remove a set of objects from the tally + + The objects to remove + True if successful, false if any object was not found + + + + The number of objects remaining in the tally + + + + + ComparisonAdapter class centralizes all comparisons of + values in NUnit, adapting to the use of any provided + IComparer, IComparer<T> or Comparison<T> + + + + + Returns a ComparisonAdapter that wraps an IComparer + + + + + Returns a ComparisonAdapter that wraps an IComparer<T> + + + + + Returns a ComparisonAdapter that wraps a Comparison<T> + + + + + Compares two objects + + + + + Gets the default ComparisonAdapter, which wraps an + NUnitComparer object. + + + + + Construct a ComparisonAdapter for an IComparer + + + + + Compares two objects + + + + + + + + Construct a default ComparisonAdapter + + + + + ComparisonAdapter<T> extends ComparisonAdapter and + allows use of an IComparer<T> or Comparison<T> + to actually perform the comparison. + + + + + Construct a ComparisonAdapter for an IComparer<T> + + + + + Compare a Type T to an object + + + + + Construct a ComparisonAdapter for a Comparison<T> + + + + + Compare a Type T to an object + + + + + Abstract base class for constraints that compare values to + determine if one is greater than, equal to or less than + the other. This class supplies the Using modifiers. + + + + + ComparisonAdapter to be used in making the comparison + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + + + Modifies the constraint to use an IComparer and returns self + + + + + Modifies the constraint to use an IComparer<T> and returns self + + + + + Modifies the constraint to use a Comparison<T> and returns self + + + + + Delegate used to delay evaluation of the actual value + to be used in evaluating a constraint + + + + + ConstraintBuilder maintains the stacks that are used in + processing a ConstraintExpression. An OperatorStack + is used to hold operators that are waiting for their + operands to be reognized. a ConstraintStack holds + input constraints as well as the results of each + operator applied. + + + + + Initializes a new instance of the class. + + + + + Appends the specified operator to the expression by first + reducing the operator stack and then pushing the new + operator on the stack. + + The operator to push. + + + + Appends the specified constraint to the expresson by pushing + it on the constraint stack. + + The constraint to push. + + + + Sets the top operator right context. + + The right context. + + + + Reduces the operator stack until the topmost item + precedence is greater than or equal to the target precedence. + + The target precedence. + + + + Resolves this instance, returning a Constraint. If the builder + is not currently in a resolvable state, an exception is thrown. + + The resolved constraint + + + + Gets a value indicating whether this instance is resolvable. + + + true if this instance is resolvable; otherwise, false. + + + + + OperatorStack is a type-safe stack for holding ConstraintOperators + + + + + Initializes a new instance of the class. + + The builder. + + + + Pushes the specified operator onto the stack. + + The op. + + + + Pops the topmost operator from the stack. + + + + + + Gets a value indicating whether this is empty. + + true if empty; otherwise, false. + + + + Gets the topmost operator without modifying the stack. + + The top. + + + + ConstraintStack is a type-safe stack for holding Constraints + + + + + Initializes a new instance of the class. + + The builder. + + + + Pushes the specified constraint. As a side effect, + the constraint's builder field is set to the + ConstraintBuilder owning this stack. + + The constraint. + + + + Pops this topmost constrait from the stack. + As a side effect, the constraint's builder + field is set to null. + + + + + + Gets a value indicating whether this is empty. + + true if empty; otherwise, false. + + + + Gets the topmost constraint without modifying the stack. + + The topmost constraint + + + + ConstraintExpression represents a compound constraint in the + process of being constructed from a series of syntactic elements. + + Individual elements are appended to the expression as they are + reognized. Once an actual Constraint is appended, the expression + returns a resolvable Constraint. + + + + + ConstraintExpressionBase is the abstract base class for the + ConstraintExpression class, which represents a + compound constraint in the process of being constructed + from a series of syntactic elements. + + NOTE: ConstraintExpressionBase is separate because the + ConstraintExpression class was generated in earlier + versions of NUnit. The two classes may be combined + in a future version. + + + + + The ConstraintBuilder holding the elements recognized so far + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the + class passing in a ConstraintBuilder, which may be pre-populated. + + The builder. + + + + Returns a string representation of the expression as it + currently stands. This should only be used for testing, + since it has the side-effect of resolving the expression. + + + + + + Appends an operator to the expression and returns the + resulting expression itself. + + + + + Appends a self-resolving operator to the expression and + returns a new ResolvableConstraintExpression. + + + + + Appends a constraint to the expression and returns that + constraint, which is associated with the current state + of the expression being built. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the + class passing in a ConstraintBuilder, which may be pre-populated. + + The builder. + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding only if a specified number of them succeed. + + + + + Returns a new PropertyConstraintExpression, which will either + test for the existence of the named property on the object + being tested or apply any following constraint to that property. + + + + + Returns a new AttributeConstraint checking for the + presence of a particular attribute on an object. + + + + + Returns a new AttributeConstraint checking for the + presence of a particular attribute on an object. + + + + + Returns the constraint provided as an argument - used to allow custom + custom constraints to easily participate in the syntax. + + + + + Returns the constraint provided as an argument - used to allow custom + custom constraints to easily participate in the syntax. + + + + + Returns a constraint that tests two items for equality + + + + + Returns a constraint that tests that two references are the same object + + + + + Returns a constraint that tests whether the + actual value is greater than the suppled argument + + + + + Returns a constraint that tests whether the + actual value is greater than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is greater than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than or equal to the suppled argument + + + + + Returns a constraint that tests whether the + actual value is less than or equal to the suppled argument + + + + + Returns a constraint that tests whether the actual + value is of the exact type supplied as an argument. + + + + + Returns a constraint that tests whether the actual + value is of the exact type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is of the type supplied as an argument or a derived type. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is assignable from the type supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is a collection containing the same elements as the + collection supplied as an argument. + + + + + Returns a constraint that tests whether the actual value + is a subset of the collection supplied as an argument. + + + + + Returns a new CollectionContainsConstraint checking for the + presence of a particular object in the collection. + + + + + Returns a new CollectionContainsConstraint checking for the + presence of a particular object in the collection. + + + + + Returns a new ContainsConstraint. This constraint + will, in turn, make use of the appropriate second-level + constraint, depending on the type of the actual argument. + This overload is only used if the item sought is a string, + since any other type implies that we are looking for a + collection member. + + + + + Returns a constraint that succeeds if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value contains the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value starts with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value ends with the substring supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value matches the regular expression supplied as an argument. + + + + + Returns a constraint that succeeds if the actual + value matches the regular expression supplied as an argument. + + + + + Returns a constraint that tests whether the path provided + is the same as an expected path after canonicalization. + + + + + Returns a constraint that tests whether the path provided + is the same path or under an expected path after canonicalization. + + + + + Returns a constraint that tests whether the path provided + is the same path or under an expected path after canonicalization. + + + + + Returns a constraint that tests whether the actual value falls + within a specified range. + + + + + Returns a ConstraintExpression that negates any + following constraint. + + + + + Returns a ConstraintExpression that negates any + following constraint. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them succeed. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if at least one of them succeeds. + + + + + Returns a ConstraintExpression, which will apply + the following constraint to all members of a collection, + succeeding if all of them fail. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Length property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Count property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the Message property of the object being tested. + + + + + Returns a new ConstraintExpression, which will apply the following + constraint to the InnerException property of the object being tested. + + + + + With is currently a NOP - reserved for future use. + + + + + Returns a constraint that tests for null + + + + + Returns a constraint that tests for True + + + + + Returns a constraint that tests for False + + + + + Returns a constraint that tests for a positive value + + + + + Returns a constraint that tests for a negative value + + + + + Returns a constraint that tests for NaN + + + + + Returns a constraint that tests for empty + + + + + Returns a constraint that tests whether a collection + contains all unique items. + + + + + Returns a constraint that tests whether an object graph is serializable in binary format. + + + + + Returns a constraint that tests whether an object graph is serializable in xml format. + + + + + Returns a constraint that tests whether a collection is ordered + + + + + ContainsConstraint tests a whether a string contains a substring + or a collection contains an object. It postpones the decision of + which test to use until the type of the actual argument is known. + This allows testing whether a string is contained in a collection + or as a substring of another string using the same syntax. + + + + + Initializes a new instance of the class. + + The expected. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Flag the constraint to use the supplied IComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied Comparison object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IEqualityComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IEqualityComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to ignore case and return self. + + + + + Applies a delay to the match so that a match can be evaluated in the future. + + + + + Creates a new DelayedConstraint + + The inner constraint two decorate + The time interval after which the match is performed + If the value of is less than 0 + + + + Creates a new DelayedConstraint + + The inner constraint two decorate + The time interval after which the match is performed + The time interval used for polling + If the value of is less than 0 + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for if the base constraint fails, false if it succeeds + + + + Test whether the constraint is satisfied by a delegate + + The delegate whose value is to be tested + True for if the base constraint fails, false if it succeeds + + + + Test whether the constraint is satisfied by a given reference. + Overridden to wait for the specified delay period before + calling the base constraint with the dereferenced value. + + A reference to the value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a MessageWriter. + + The writer on which the actual value is displayed + + + + Returns the string representation of the constraint. + + + + + EmptyCollectionConstraint tests whether a collection is empty. + + + + + Check that the collection is empty + + + + + + + Write the constraint description to a MessageWriter + + + + + + EmptyConstraint tests a whether a string or collection is empty, + postponing the decision about which test is applied until the + type of the actual argument is known. + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + EmptyDirectoryConstraint is used to test that a directory is empty + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. The default implementation simply writes + the raw value of actual, leaving it to the writer to + perform any formatting. + + The writer on which the actual value is displayed + + + + EmptyStringConstraint tests whether a string is empty. + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + EndsWithConstraint can test whether a string ends + with an expected substring. + + + + + StringConstraint is the abstract base for constraints + that operate on strings. It supports the IgnoreCase + modifier for string operations. + + + + + The expected value + + + + + Indicates whether tests should be case-insensitive + + + + + Constructs a StringConstraint given an expected value + + The expected value + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Test whether the constraint is satisfied by a given string + + The string to be tested + True for success, false for failure + + + + Modify the constraint to ignore case in matching. + + + + + Initializes a new instance of the class. + + The expected string + + + + Test whether the constraint is matched by the actual value. + This is a template method, which calls the IsMatch method + of the derived class. + + + + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + EqualConstraint is able to compare an actual value with the + expected value provided in its constructor. Two objects are + considered equal if both are null, or if both have the same + value. NUnit has special semantics for some object types. + + + + + If true, strings in error messages will be clipped + + + + + NUnitEqualityComparer used to test equality. + + + + + Initializes a new instance of the class. + + The expected value. + + + + Flag the constraint to use a tolerance when determining equality. + + Tolerance value to be used + Self. + + + + Flag the constraint to use the supplied IComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied Comparison object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IEqualityComparer object. + + The IComparer object to use. + Self. + + + + Flag the constraint to use the supplied IEqualityComparer object. + + The IComparer object to use. + Self. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write a failure message. Overridden to provide custom + failure messages for EqualConstraint. + + The MessageWriter to write to + + + + Write description of this constraint + + The MessageWriter to write to + + + + Display the failure information for two collections that did not match. + + The MessageWriter on which to display + The expected collection. + The actual collection + The depth of this failure in a set of nested collections + + + + Displays a single line showing the types and sizes of the expected + and actual enumerations, collections or arrays. If both are identical, + the value is only shown once. + + The MessageWriter on which to display + The expected collection or array + The actual collection or array + The indentation level for the message line + + + + Displays a single line showing the point in the expected and actual + arrays at which the comparison failed. If the arrays have different + structures or dimensions, both values are shown. + + The MessageWriter on which to display + The expected array + The actual array + Index of the failure point in the underlying collections + The indentation level for the message line + + + + Display the failure information for two IEnumerables that did not match. + + The MessageWriter on which to display + The expected enumeration. + The actual enumeration + The depth of this failure in a set of nested collections + + + + Flag the constraint to ignore case and return self. + + + + + Flag the constraint to suppress string clipping + and return self. + + + + + Flag the constraint to compare arrays as collections + and return self. + + + + + Switches the .Within() modifier to interpret its tolerance as + a distance in representable values (see remarks). + + Self. + + Ulp stands for "unit in the last place" and describes the minimum + amount a given value can change. For any integers, an ulp is 1 whole + digit. For floating point values, the accuracy of which is better + for smaller numbers and worse for larger numbers, an ulp depends + on the size of the number. Using ulps for comparison of floating + point results instead of fixed tolerances is safer because it will + automatically compensate for the added inaccuracy of larger numbers. + + + + + Switches the .Within() modifier to interpret its tolerance as + a percentage that the actual values is allowed to deviate from + the expected value. + + Self + + + + Causes the tolerance to be interpreted as a TimeSpan in days. + + Self + + + + Causes the tolerance to be interpreted as a TimeSpan in hours. + + Self + + + + Causes the tolerance to be interpreted as a TimeSpan in minutes. + + Self + + + + Causes the tolerance to be interpreted as a TimeSpan in seconds. + + Self + + + + Causes the tolerance to be interpreted as a TimeSpan in milliseconds. + + Self + + + + Causes the tolerance to be interpreted as a TimeSpan in clock ticks. + + Self + + + + EqualityAdapter class handles all equality comparisons + that use an IEqualityComparer, IEqualityComparer<T> + or a ComparisonAdapter. + + + + + Compares two objects, returning true if they are equal + + + + + Returns true if the two objects can be compared by this adapter. + The base adapter cannot handle IEnumerables except for strings. + + + + + Returns an EqualityAdapter that wraps an IComparer. + + + + + Returns an EqualityAdapter that wraps an IEqualityComparer. + + + + + Returns an EqualityAdapter that wraps an IEqualityComparer<T>. + + + + + Returns an EqualityAdapter that wraps an IComparer<T>. + + + + + Returns an EqualityAdapter that wraps a Comparison<T>. + + + + + EqualityAdapter that wraps an IComparer. + + + + + Returns true if the two objects can be compared by this adapter. + Generic adapter requires objects of the specified type. + + + + + EqualityAdapter that wraps an IComparer. + + + + + EqualityAdapterList represents a list of EqualityAdapters + in a common class across platforms. + + + + + ExactCountConstraint applies another constraint to each + item in a collection, succeeding only if a specified + number of items succeed. + + + + + Construct an ExactCountConstraint on top of an existing constraint + + + + + + + Apply the item constraint to each item in the collection, + succeeding only if the expected number of items pass. + + + + + + + Write a description of this constraint to a MessageWriter + + + + + + ExactTypeConstraint is used to test that an object + is of the exact type provided in the constructor + + + + + Construct an ExactTypeConstraint for a given Type + + The expected Type. + + + + Test that an object is of the exact type specified + + The actual value. + True if the tested object is of the exact type provided, otherwise false. + + + + Write the description of this constraint to a MessageWriter + + The MessageWriter to use + + + + ExceptionTypeConstraint is a special version of ExactTypeConstraint + used to provided detailed info about the exception thrown in + an error message. + + + + + Constructs an ExceptionTypeConstraint + + + + + Write the actual value for a failing constraint test to a + MessageWriter. Overriden to write additional information + in the case of an Exception. + + The MessageWriter to use + + + + FailurePoint class represents one point of failure + in an equality test. + + + + + The location of the failure + + + + + The expected value + + + + + The actual value + + + + + Indicates whether the expected value is valid + + + + + Indicates whether the actual value is valid + + + + + FailurePointList represents a set of FailurePoints + in a cross-platform way. + + + + + FalseConstraint tests that the actual value is false + + + + + Initializes a new instance of the class. + + + + Helper routines for working with floating point numbers + + + The floating point comparison code is based on this excellent article: + http://www.cygnus-software.com/papers/comparingfloats/comparingfloats.htm + + + "ULP" means Unit in the Last Place and in the context of this library refers to + the distance between two adjacent floating point numbers. IEEE floating point + numbers can only represent a finite subset of natural numbers, with greater + accuracy for smaller numbers and lower accuracy for very large numbers. + + + If a comparison is allowed "2 ulps" of deviation, that means the values are + allowed to deviate by up to 2 adjacent floating point values, which might be + as low as 0.0000001 for small numbers or as high as 10.0 for large numbers. + + + + + Compares two floating point values for equality + First floating point value to be compared + Second floating point value t be compared + + Maximum number of representable floating point values that are allowed to + be between the left and the right floating point values + + True if both numbers are equal or close to being equal + + + Floating point values can only represent a finite subset of natural numbers. + For example, the values 2.00000000 and 2.00000024 can be stored in a float, + but nothing inbetween them. + + + This comparison will count how many possible floating point values are between + the left and the right number. If the number of possible values between both + numbers is less than or equal to maxUlps, then the numbers are considered as + being equal. + + + Implementation partially follows the code outlined here: + http://www.anttirt.net/2007/08/19/proper-floating-point-comparisons/ + + + + + Compares two double precision floating point values for equality + First double precision floating point value to be compared + Second double precision floating point value t be compared + + Maximum number of representable double precision floating point values that are + allowed to be between the left and the right double precision floating point values + + True if both numbers are equal or close to being equal + + + Double precision floating point values can only represent a limited series of + natural numbers. For example, the values 2.0000000000000000 and 2.0000000000000004 + can be stored in a double, but nothing inbetween them. + + + This comparison will count how many possible double precision floating point + values are between the left and the right number. If the number of possible + values between both numbers is less than or equal to maxUlps, then the numbers + are considered as being equal. + + + Implementation partially follows the code outlined here: + http://www.anttirt.net/2007/08/19/proper-floating-point-comparisons/ + + + + + + Reinterprets the memory contents of a floating point value as an integer value + + + Floating point value whose memory contents to reinterpret + + + The memory contents of the floating point value interpreted as an integer + + + + + Reinterprets the memory contents of a double precision floating point + value as an integer value + + + Double precision floating point value whose memory contents to reinterpret + + + The memory contents of the double precision floating point value + interpreted as an integer + + + + + Reinterprets the memory contents of an integer as a floating point value + + Integer value whose memory contents to reinterpret + + The memory contents of the integer value interpreted as a floating point value + + + + + Reinterprets the memory contents of an integer value as a double precision + floating point value + + Integer whose memory contents to reinterpret + + The memory contents of the integer interpreted as a double precision + floating point value + + + + Union of a floating point variable and an integer + + + The union's value as a floating point variable + + + The union's value as an integer + + + The union's value as an unsigned integer + + + Union of a double precision floating point variable and a long + + + The union's value as a double precision floating point variable + + + The union's value as a long + + + The union's value as an unsigned long + + + + Tests whether a value is greater than the value supplied to its constructor + + + + + The value against which a comparison is to be made + + + + + Initializes a new instance of the class. + + The expected value. + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Tests whether a value is greater than or equal to the value supplied to its constructor + + + + + The value against which a comparison is to be made + + + + + Initializes a new instance of the class. + + The expected value. + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + InstanceOfTypeConstraint is used to test that an object + is of the same type provided or derived from it. + + + + + Construct an InstanceOfTypeConstraint for the type provided + + The expected Type + + + + Test whether an object is of the specified type or a derived type + + The object to be tested + True if the object is of the provided type or derives from it, otherwise false. + + + + Write a description of this constraint to a MessageWriter + + The MessageWriter to use + + + + Tests whether a value is less than the value supplied to its constructor + + + + + The value against which a comparison is to be made + + + + + Initializes a new instance of the class. + + The expected value. + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Tests whether a value is less than or equal to the value supplied to its constructor + + + + + The value against which a comparison is to be made + + + + + Initializes a new instance of the class. + + The expected value. + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Static methods used in creating messages + + + + + Static string used when strings are clipped + + + + + Returns the representation of a type as used in NUnitLite. + This is the same as Type.ToString() except for arrays, + which are displayed with their declared sizes. + + + + + + + Converts any control characters in a string + to their escaped representation. + + The string to be converted + The converted string + + + + Return the a string representation for a set of indices into an array + + Array of indices for which a string is needed + + + + Get an array of indices representing the point in a enumerable, + collection or array corresponding to a single int index into the + collection. + + The collection to which the indices apply + Index in the collection + Array of indices + + + + Clip a string to a given length, starting at a particular offset, returning the clipped + string with ellipses representing the removed parts + + The string to be clipped + The maximum permitted length of the result string + The point at which to start clipping + The clipped string + + + + Clip the expected and actual strings in a coordinated fashion, + so that they may be displayed together. + + + + + + + + + Shows the position two strings start to differ. Comparison + starts at the start index. + + The expected string + The actual string + The index in the strings at which comparison should start + Boolean indicating whether case should be ignored + -1 if no mismatch found, or the index where mismatch found + + + + NaNConstraint tests that the actual value is a double or float NaN + + + + + Test that the actual value is an NaN + + + + + + + Write the constraint description to a specified writer + + + + + + NoItemConstraint applies another constraint to each + item in a collection, failing if any of them succeeds. + + + + + Construct a NoItemConstraint on top of an existing constraint + + + + + + Apply the item constraint to each item in the collection, + failing if any item fails. + + + + + + + Write a description of this constraint to a MessageWriter + + + + + + NotConstraint negates the effect of some other constraint + + + + + Initializes a new instance of the class. + + The base constraint to be negated. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for if the base constraint fails, false if it succeeds + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a MessageWriter. + + The writer on which the actual value is displayed + + + + NullConstraint tests that the actual value is null + + + + + Initializes a new instance of the class. + + + + + NullEmptyStringConstraint tests whether a string is either null or empty. + + + + + Constructs a new NullOrEmptyStringConstraint + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + The Numerics class contains common operations on numeric values. + + + + + Checks the type of the object, returning true if + the object is a numeric type. + + The object to check + true if the object is a numeric type + + + + Checks the type of the object, returning true if + the object is a floating point numeric type. + + The object to check + true if the object is a floating point numeric type + + + + Checks the type of the object, returning true if + the object is a fixed point numeric type. + + The object to check + true if the object is a fixed point numeric type + + + + Test two numeric values for equality, performing the usual numeric + conversions and using a provided or default tolerance. If the tolerance + provided is Empty, this method may set it to a default tolerance. + + The expected value + The actual value + A reference to the tolerance in effect + True if the values are equal + + + + Compare two numeric values, performing the usual numeric conversions. + + The expected value + The actual value + The relationship of the values to each other + + + + NUnitComparer encapsulates NUnit's default behavior + in comparing two objects. + + + + + Compares two objects + + + + + + + + Returns the default NUnitComparer. + + + + + Generic version of NUnitComparer + + + + + + Compare two objects of the same type + + + + + NUnitEqualityComparer encapsulates NUnit's handling of + equality tests between objects. + + + + + + + + + + Compares two objects for equality within a tolerance + + The first object to compare + The second object to compare + The tolerance to use in the comparison + + + + + If true, all string comparisons will ignore case + + + + + If true, arrays will be treated as collections, allowing + those of different dimensions to be compared + + + + + Comparison objects used in comparisons for some constraints. + + + + + List of points at which a failure occured. + + + + + RecursionDetector used to check for recursion when + evaluating self-referencing enumerables. + + + + + Compares two objects for equality within a tolerance, setting + the tolerance to the actual tolerance used if an empty + tolerance is supplied. + + + + + Helper method to compare two arrays + + + + + Method to compare two DirectoryInfo objects + + first directory to compare + second directory to compare + true if equivalent, false if not + + + + Returns the default NUnitEqualityComparer + + + + + Gets and sets a flag indicating whether case should + be ignored in determining equality. + + + + + Gets and sets a flag indicating that arrays should be + compared as collections, without regard to their shape. + + + + + Gets the list of external comparers to be used to + test for equality. They are applied to members of + collections, in place of NUnit's own logic. + + + + + Gets the list of failure points for the last Match performed. + The list consists of objects to be interpreted by the caller. + This generally means that the caller may only make use of + objects it has placed on the list at a particular depthy. + + + + + RecursionDetector detects when a comparison + between two enumerables has reached a point + where the same objects that were previously + compared are again being compared. This allows + the caller to stop the comparison if desired. + + + + + Check whether two objects have previously + been compared, returning true if they have. + The two objects are remembered, so that a + second call will always return true. + + + + + OrConstraint succeeds if either member succeeds + + + + + Create an OrConstraint from two other constraints + + The first constraint + The second constraint + + + + Apply the member constraints to an actual value, succeeding + succeeding as soon as one of them succeeds. + + The actual value + True if either constraint succeeded + + + + Write a description for this contraint to a MessageWriter + + The MessageWriter to receive the description + + + + PathConstraint serves as the abstract base of constraints + that operate on paths and provides several helper methods. + + + + + The expected path used in the constraint + + + + + Flag indicating whether a caseInsensitive comparison should be made + + + + + Construct a PathConstraint for a give expected path + + The expected path + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Returns true if the expected path and actual path match + + + + + Returns the string representation of this constraint + + + + + Transform the provided path to its canonical form so that it + may be more easily be compared with other paths. + + The original path + The path in canonical form + + + + Test whether one path in canonical form is under another. + + The first path - supposed to be the parent path + The second path - supposed to be the child path + Indicates whether case should be ignored + + + + + Modifies the current instance to be case-insensitve + and returns it. + + + + + Modifies the current instance to be case-sensitve + and returns it. + + + + + Predicate constraint wraps a Predicate in a constraint, + returning success if the predicate is true. + + + + + Construct a PredicateConstraint from a predicate + + + + + Determines whether the predicate succeeds when applied + to the actual value. + + + + + Writes the description to a MessageWriter + + + + + PropertyConstraint extracts a named property and uses + its value as the actual value for a chained constraint. + + + + + Initializes a new instance of the class. + + The name. + The constraint to apply to the property. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. The default implementation simply writes + the raw value of actual, leaving it to the writer to + perform any formatting. + + The writer on which the actual value is displayed + + + + Returns the string representation of the constraint. + + + + + + PropertyExistsConstraint tests that a named property + exists on the object provided through Match. + + Originally, PropertyConstraint provided this feature + in addition to making optional tests on the vaue + of the property. The two constraints are now separate. + + + + + Initializes a new instance of the class. + + The name of the property. + + + + Test whether the property exists for a given object + + The object to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. + + The writer on which the actual value is displayed + + + + Returns the string representation of the constraint. + + + + + + RangeConstraint tests whether two values are within a + specified range. + + + + + Initializes a new instance of the class. + + From. + To. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + RegexConstraint can test whether a string matches + the pattern provided. + + + + + Initializes a new instance of the class. + + The pattern. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + ResolvableConstraintExpression is used to represent a compound + constraint being constructed at a point where the last operator + may either terminate the expression or may have additional + qualifying constraints added to it. + + It is used, for example, for a Property element or for + an Exception element, either of which may be optionally + followed by constraints that apply to the property or + exception. + + + + + Create a new instance of ResolvableConstraintExpression + + + + + Create a new instance of ResolvableConstraintExpression, + passing in a pre-populated ConstraintBuilder. + + + + + Resolve the current expression to a Constraint + + + + + This operator creates a constraint that is satisfied only if both + argument constraints are satisfied. + + + + + This operator creates a constraint that is satisfied only if both + argument constraints are satisfied. + + + + + This operator creates a constraint that is satisfied only if both + argument constraints are satisfied. + + + + + This operator creates a constraint that is satisfied if either + of the argument constraints is satisfied. + + + + + This operator creates a constraint that is satisfied if either + of the argument constraints is satisfied. + + + + + This operator creates a constraint that is satisfied if either + of the argument constraints is satisfied. + + + + + This operator creates a constraint that is satisfied if the + argument constraint is not satisfied. + + + + + Appends an And Operator to the expression + + + + + Appends an Or operator to the expression. + + + + + ReusableConstraint wraps a constraint expression after + resolving it so that it can be reused consistently. + + + + + Construct a ReusableConstraint from a constraint expression + + The expression to be resolved and reused + + + + Converts a constraint to a ReusableConstraint + + The constraint to be converted + A ReusableConstraint + + + + Returns the string representation of the constraint. + + A string representing the constraint + + + + Resolves the ReusableConstraint by returning the constraint + that it originally wrapped. + + A resolved constraint + + + + SameAsConstraint tests whether an object is identical to + the object passed to its constructor + + + + + Initializes a new instance of the class. + + The expected object. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Summary description for SamePathConstraint. + + + + + Initializes a new instance of the class. + + The expected path + + + + Test whether the constraint is satisfied by a given value + + The expected path + The actual path + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + SamePathOrUnderConstraint tests that one path is under another + + + + + Initializes a new instance of the class. + + The expected path + + + + Test whether the constraint is satisfied by a given value + + The expected path + The actual path + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + SomeItemsConstraint applies another constraint to each + item in a collection, succeeding if any of them succeeds. + + + + + Construct a SomeItemsConstraint on top of an existing constraint + + + + + + Apply the item constraint to each item in the collection, + succeeding if any item succeeds. + + + + + + + Write a description of this constraint to a MessageWriter + + + + + + StartsWithConstraint can test whether a string starts + with an expected substring. + + + + + Initializes a new instance of the class. + + The expected string + + + + Test whether the constraint is matched by the actual value. + This is a template method, which calls the IsMatch method + of the derived class. + + + + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + SubPathConstraint tests that the actual path is under the expected path + + + + + Initializes a new instance of the class. + + The expected path + + + + Test whether the constraint is satisfied by a given value + + The expected path + The actual path + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + SubstringConstraint can test whether a string contains + the expected substring. + + + + + Initializes a new instance of the class. + + The expected. + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + ThrowsConstraint is used to test the exception thrown by + a delegate by applying a constraint to it. + + + + + Initializes a new instance of the class, + using a constraint to be applied to the exception. + + A constraint to apply to the caught exception. + + + + Executes the code of the delegate and captures any exception. + If a non-null base constraint was provided, it applies that + constraint to the exception. + + A delegate representing the code to be tested + True if an exception is thrown and the constraint succeeds, otherwise false + + + + Converts an ActualValueDelegate to a TestDelegate + before calling the primary overload. + + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. The default implementation simply writes + the raw value of actual, leaving it to the writer to + perform any formatting. + + The writer on which the actual value is displayed + + + + Returns the string representation of this constraint + + + + + Get the actual exception thrown - used by Assert.Throws. + + + + + ThrowsNothingConstraint tests that a delegate does not + throw an exception. + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True if no exception is thrown, otherwise false + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. Overridden in ThrowsNothingConstraint to write + information about the exception that was actually caught. + + The writer on which the actual value is displayed + + + + The Tolerance class generalizes the notion of a tolerance + within which an equality test succeeds. Normally, it is + used with numeric types, but it can be used with any + type that supports taking a difference between two + objects and comparing that difference to a value. + + + + + Constructs a linear tolerance of a specdified amount + + + + + Constructs a tolerance given an amount and ToleranceMode + + + + + Tests that the current Tolerance is linear with a + numeric value, throwing an exception if it is not. + + + + + Returns an empty Tolerance object, equivalent to + specifying no tolerance. In most cases, it results + in an exact match but for floats and doubles a + default tolerance may be used. + + + + + Returns a zero Tolerance object, equivalent to + specifying an exact match. + + + + + Gets the ToleranceMode for the current Tolerance + + + + + Gets the value of the current Tolerance instance. + + + + + Returns a new tolerance, using the current amount as a percentage. + + + + + Returns a new tolerance, using the current amount in Ulps. + + + + + Returns a new tolerance with a TimeSpan as the amount, using + the current amount as a number of days. + + + + + Returns a new tolerance with a TimeSpan as the amount, using + the current amount as a number of hours. + + + + + Returns a new tolerance with a TimeSpan as the amount, using + the current amount as a number of minutes. + + + + + Returns a new tolerance with a TimeSpan as the amount, using + the current amount as a number of seconds. + + + + + Returns a new tolerance with a TimeSpan as the amount, using + the current amount as a number of milliseconds. + + + + + Returns a new tolerance with a TimeSpan as the amount, using + the current amount as a number of clock ticks. + + + + + Returns true if the current tolerance is empty. + + + + + Modes in which the tolerance value for a comparison can be interpreted. + + + + + The tolerance was created with a value, without specifying + how the value would be used. This is used to prevent setting + the mode more than once and is generally changed to Linear + upon execution of the test. + + + + + The tolerance is used as a numeric range within which + two compared values are considered to be equal. + + + + + Interprets the tolerance as the percentage by which + the two compared values my deviate from each other. + + + + + Compares two values based in their distance in + representable numbers. + + + + + TrueConstraint tests that the actual value is true + + + + + Initializes a new instance of the class. + + + + + UniqueItemsConstraint tests whether all the items in a + collection are unique. + + + + + Check that all items are unique. + + + + + + + Write a description of this constraint to a MessageWriter + + + + + + XmlSerializableConstraint tests whether + an object is serializable in XML format. + + + + + Test whether the constraint is satisfied by a given value + + The value to be tested + True for success, false for failure + + + + Write the constraint description to a MessageWriter + + The writer on which the description is displayed + + + + Write the actual value for a failing constraint test to a + MessageWriter. The default implementation simply writes + the raw value of actual, leaving it to the writer to + perform any formatting. + + The writer on which the actual value is displayed + + + + Returns the string representation of this constraint + + + + + Represents a constraint that succeeds if all the + members of a collection match a base constraint. + + + + + Abstract base for operators that indicate how to + apply a constraint to items in a collection. + + + + + PrefixOperator takes a single constraint and modifies + it's action in some way. + + + + + The ConstraintOperator class is used internally by a + ConstraintBuilder to represent an operator that + modifies or combines constraints. + + Constraint operators use left and right precedence + values to determine whether the top operator on the + stack should be reduced before pushing a new operator. + + + + + The precedence value used when the operator + is about to be pushed to the stack. + + + + + The precedence value used when the operator + is on the top of the stack. + + + + + Reduce produces a constraint from the operator and + any arguments. It takes the arguments from the constraint + stack and pushes the resulting constraint on it. + + + + + + The syntax element preceding this operator + + + + + The syntax element folowing this operator + + + + + The precedence value used when the operator + is about to be pushed to the stack. + + + + + The precedence value used when the operator + is on the top of the stack. + + + + + Reduce produces a constraint from the operator and + any arguments. It takes the arguments from the constraint + stack and pushes the resulting constraint on it. + + + + + + Returns the constraint created by applying this + prefix to another constraint. + + + + + + + Constructs a CollectionOperator + + + + + Returns a constraint that will apply the argument + to the members of a collection, succeeding if + they all succeed. + + + + + Operator that requires both it's arguments to succeed + + + + + Abstract base class for all binary operators + + + + + Reduce produces a constraint from the operator and + any arguments. It takes the arguments from the constraint + stack and pushes the resulting constraint on it. + + + + + + Abstract method that produces a constraint by applying + the operator to its left and right constraint arguments. + + + + + Gets the left precedence of the operator + + + + + Gets the right precedence of the operator + + + + + Construct an AndOperator + + + + + Apply the operator to produce an AndConstraint + + + + + Operator that tests for the presence of a particular attribute + on a type and optionally applies further tests to the attribute. + + + + + Abstract base class for operators that are able to reduce to a + constraint whether or not another syntactic element follows. + + + + + Construct an AttributeOperator for a particular Type + + The Type of attribute tested + + + + Reduce produces a constraint from the operator and + any arguments. It takes the arguments from the constraint + stack and pushes the resulting constraint on it. + + + + + Represents a constraint that succeeds if the specified + count of members of a collection match a base constraint. + + + + + Construct an ExactCountOperator for a specified count + + The expected count + + + + Returns a constraint that will apply the argument + to the members of a collection, succeeding if + none of them succeed. + + + + + Represents a constraint that succeeds if none of the + members of a collection match a base constraint. + + + + + Returns a constraint that will apply the argument + to the members of a collection, succeeding if + none of them succeed. + + + + + Negates the test of the constraint it wraps. + + + + + Constructs a new NotOperator + + + + + Returns a NotConstraint applied to its argument. + + + + + Operator that requires at least one of it's arguments to succeed + + + + + Construct an OrOperator + + + + + Apply the operator to produce an OrConstraint + + + + + Operator used to test for the presence of a named Property + on an object and optionally apply further tests to the + value of that property. + + + + + Constructs a PropOperator for a particular named property + + + + + Reduce produces a constraint from the operator and + any arguments. It takes the arguments from the constraint + stack and pushes the resulting constraint on it. + + + + + + Gets the name of the property to which the operator applies + + + + + Represents a constraint that succeeds if any of the + members of a collection match a base constraint. + + + + + Returns a constraint that will apply the argument + to the members of a collection, succeeding if + any of them succeed. + + + + + Operator that tests that an exception is thrown and + optionally applies further tests to the exception. + + + + + Construct a ThrowsOperator + + + + + Reduce produces a constraint from the operator and + any arguments. It takes the arguments from the constraint + stack and pushes the resulting constraint on it. + + + + + Represents a constraint that simply wraps the + constraint provided as an argument, without any + further functionality, but which modifes the + order of evaluation because of its precedence. + + + + + Constructor for the WithOperator + + + + + Returns a constraint that wraps its argument + + + + + Thrown when an assertion failed. + + + + The error message that explains + the reason for the exception + + + The error message that explains + the reason for the exception + The exception that caused the + current exception + + + + Serialization Constructor + + + + + Thrown when an assertion failed. + + + + + + + The error message that explains + the reason for the exception + The exception that caused the + current exception + + + + Serialization Constructor + + + + + Thrown when a test executes inconclusively. + + + + The error message that explains + the reason for the exception + + + The error message that explains + the reason for the exception + The exception that caused the + current exception + + + + Serialization Constructor + + + + + Thrown when an assertion failed. + + + + + + + The error message that explains + the reason for the exception + The exception that caused the + current exception + + + + Serialization Constructor + + + + + + + + + + + Compares two objects of a given Type for equality within a tolerance + + The first object to compare + The second object to compare + The tolerance to use in the comparison + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/Newtonsoft.Json.4.5.11.nupkg b/packages/Newtonsoft.Json.4.5.11/Newtonsoft.Json.4.5.11.nupkg new file mode 100644 index 000000000..0b6dc21a5 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/Newtonsoft.Json.4.5.11.nupkg differ diff --git a/packages/Newtonsoft.Json.4.5.11/Newtonsoft.Json.4.5.11.nuspec b/packages/Newtonsoft.Json.4.5.11/Newtonsoft.Json.4.5.11.nuspec new file mode 100644 index 000000000..5236069c1 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/Newtonsoft.Json.4.5.11.nuspec @@ -0,0 +1,19 @@ + + + + Newtonsoft.Json + 4.5.11 + Json.NET + James Newton-King + James Newton-King + http://json.codeplex.com/license + http://james.newtonking.com/projects/json-net.aspx + false + Json.NET is a popular high-performance JSON framework for .NET + en-US + json + + + + + \ No newline at end of file diff --git a/packages/Newtonsoft.Json.4.5.11/lib/net20/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/net20/Newtonsoft.Json.dll new file mode 100644 index 000000000..1ff7b36ac Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/net20/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/net20/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/net20/Newtonsoft.Json.xml new file mode 100644 index 000000000..c923197e2 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/net20/Newtonsoft.Json.xml @@ -0,0 +1,8526 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a binary value to and from a base 64 string value. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Represents a trace writer that writes to the application's instances. + + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Provides a set of static (Shared in Visual Basic) methods for + querying objects that implement . + + + + + Returns the input typed as . + + + + + Returns an empty that has the + specified type argument. + + + + + Converts the elements of an to the + specified type. + + + + + Filters the elements of an based on a specified type. + + + + + Generates a sequence of integral numbers within a specified range. + + The value of the first integer in the sequence. + The number of sequential integers to generate. + + + + Generates a sequence that contains one repeated value. + + + + + Filters a sequence of values based on a predicate. + + + + + Filters a sequence of values based on a predicate. + Each element's index is used in the logic of the predicate function. + + + + + Projects each element of a sequence into a new form. + + + + + Projects each element of a sequence into a new form by + incorporating the element's index. + + + + + Projects each element of a sequence to an + and flattens the resulting sequences into one sequence. + + + + + Projects each element of a sequence to an , + and flattens the resulting sequences into one sequence. The + index of each source element is used in the projected form of + that element. + + + + + Projects each element of a sequence to an , + flattens the resulting sequences into one sequence, and invokes + a result selector function on each element therein. + + + + + Projects each element of a sequence to an , + flattens the resulting sequences into one sequence, and invokes + a result selector function on each element therein. The index of + each source element is used in the intermediate projected form + of that element. + + + + + Returns elements from a sequence as long as a specified condition is true. + + + + + Returns elements from a sequence as long as a specified condition is true. + The element's index is used in the logic of the predicate function. + + + + + Base implementation of First operator. + + + + + Returns the first element of a sequence. + + + + + Returns the first element in a sequence that satisfies a specified condition. + + + + + Returns the first element of a sequence, or a default value if + the sequence contains no elements. + + + + + Returns the first element of the sequence that satisfies a + condition or a default value if no such element is found. + + + + + Base implementation of Last operator. + + + + + Returns the last element of a sequence. + + + + + Returns the last element of a sequence that satisfies a + specified condition. + + + + + Returns the last element of a sequence, or a default value if + the sequence contains no elements. + + + + + Returns the last element of a sequence that satisfies a + condition or a default value if no such element is found. + + + + + Base implementation of Single operator. + + + + + Returns the only element of a sequence, and throws an exception + if there is not exactly one element in the sequence. + + + + + Returns the only element of a sequence that satisfies a + specified condition, and throws an exception if more than one + such element exists. + + + + + Returns the only element of a sequence, or a default value if + the sequence is empty; this method throws an exception if there + is more than one element in the sequence. + + + + + Returns the only element of a sequence that satisfies a + specified condition or a default value if no such element + exists; this method throws an exception if more than one element + satisfies the condition. + + + + + Returns the element at a specified index in a sequence. + + + + + Returns the element at a specified index in a sequence or a + default value if the index is out of range. + + + + + Inverts the order of the elements in a sequence. + + + + + Returns a specified number of contiguous elements from the start + of a sequence. + + + + + Bypasses a specified number of elements in a sequence and then + returns the remaining elements. + + + + + Bypasses elements in a sequence as long as a specified condition + is true and then returns the remaining elements. + + + + + Bypasses elements in a sequence as long as a specified condition + is true and then returns the remaining elements. The element's + index is used in the logic of the predicate function. + + + + + Returns the number of elements in a sequence. + + + + + Returns a number that represents how many elements in the + specified sequence satisfy a condition. + + + + + Returns an that represents the total number + of elements in a sequence. + + + + + Returns an that represents how many elements + in a sequence satisfy a condition. + + + + + Concatenates two sequences. + + + + + Creates a from an . + + + + + Creates an array from an . + + + + + Returns distinct elements from a sequence by using the default + equality comparer to compare values. + + + + + Returns distinct elements from a sequence by using a specified + to compare values. + + + + + Creates a from an + according to a specified key + selector function. + + + + + Creates a from an + according to a specified key + selector function and a key comparer. + + + + + Creates a from an + according to specified key + and element selector functions. + + + + + Creates a from an + according to a specified key + selector function, a comparer and an element selector function. + + + + + Groups the elements of a sequence according to a specified key + selector function. + + + + + Groups the elements of a sequence according to a specified key + selector function and compares the keys by using a specified + comparer. + + + + + Groups the elements of a sequence according to a specified key + selector function and projects the elements for each group by + using a specified function. + + + + + Groups the elements of a sequence according to a specified key + selector function and creates a result value from each group and + its key. + + + + + Groups the elements of a sequence according to a key selector + function. The keys are compared by using a comparer and each + group's elements are projected by using a specified function. + + + + + Groups the elements of a sequence according to a specified key + selector function and creates a result value from each group and + its key. The elements of each group are projected by using a + specified function. + + + + + Groups the elements of a sequence according to a specified key + selector function and creates a result value from each group and + its key. The keys are compared by using a specified comparer. + + + + + Groups the elements of a sequence according to a specified key + selector function and creates a result value from each group and + its key. Key values are compared by using a specified comparer, + and the elements of each group are projected by using a + specified function. + + + + + Applies an accumulator function over a sequence. + + + + + Applies an accumulator function over a sequence. The specified + seed value is used as the initial accumulator value. + + + + + Applies an accumulator function over a sequence. The specified + seed value is used as the initial accumulator value, and the + specified function is used to select the result value. + + + + + Produces the set union of two sequences by using the default + equality comparer. + + + + + Produces the set union of two sequences by using a specified + . + + + + + Returns the elements of the specified sequence or the type + parameter's default value in a singleton collection if the + sequence is empty. + + + + + Returns the elements of the specified sequence or the specified + value in a singleton collection if the sequence is empty. + + + + + Determines whether all elements of a sequence satisfy a condition. + + + + + Determines whether a sequence contains any elements. + + + + + Determines whether any element of a sequence satisfies a + condition. + + + + + Determines whether a sequence contains a specified element by + using the default equality comparer. + + + + + Determines whether a sequence contains a specified element by + using a specified . + + + + + Determines whether two sequences are equal by comparing the + elements by using the default equality comparer for their type. + + + + + Determines whether two sequences are equal by comparing their + elements by using a specified . + + + + + Base implementation for Min/Max operator. + + + + + Base implementation for Min/Max operator for nullable types. + + + + + Returns the minimum value in a generic sequence. + + + + + Invokes a transform function on each element of a generic + sequence and returns the minimum resulting value. + + + + + Returns the maximum value in a generic sequence. + + + + + Invokes a transform function on each element of a generic + sequence and returns the maximum resulting value. + + + + + Makes an enumerator seen as enumerable once more. + + + The supplied enumerator must have been started. The first element + returned is the element the enumerator was on when passed in. + DO NOT use this method if the caller must be a generator. It is + mostly safe among aggregate operations. + + + + + Sorts the elements of a sequence in ascending order according to a key. + + + + + Sorts the elements of a sequence in ascending order by using a + specified comparer. + + + + + Sorts the elements of a sequence in descending order according to a key. + + + + + Sorts the elements of a sequence in descending order by using a + specified comparer. + + + + + Performs a subsequent ordering of the elements in a sequence in + ascending order according to a key. + + + + + Performs a subsequent ordering of the elements in a sequence in + ascending order by using a specified comparer. + + + + + Performs a subsequent ordering of the elements in a sequence in + descending order, according to a key. + + + + + Performs a subsequent ordering of the elements in a sequence in + descending order by using a specified comparer. + + + + + Base implementation for Intersect and Except operators. + + + + + Produces the set intersection of two sequences by using the + default equality comparer to compare values. + + + + + Produces the set intersection of two sequences by using the + specified to compare values. + + + + + Produces the set difference of two sequences by using the + default equality comparer to compare values. + + + + + Produces the set difference of two sequences by using the + specified to compare values. + + + + + Creates a from an + according to a specified key + selector function. + + + + + Creates a from an + according to a specified key + selector function and key comparer. + + + + + Creates a from an + according to specified key + selector and element selector functions. + + + + + Creates a from an + according to a specified key + selector function, a comparer, and an element selector function. + + + + + Correlates the elements of two sequences based on matching keys. + The default equality comparer is used to compare keys. + + + + + Correlates the elements of two sequences based on matching keys. + The default equality comparer is used to compare keys. A + specified is used to compare keys. + + + + + Correlates the elements of two sequences based on equality of + keys and groups the results. The default equality comparer is + used to compare keys. + + + + + Correlates the elements of two sequences based on equality of + keys and groups the results. The default equality comparer is + used to compare keys. A specified + is used to compare keys. + + + + + Computes the sum of a sequence of nullable values. + + + + + Computes the sum of a sequence of nullable + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of nullable values. + + + + + Computes the average of a sequence of nullable values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Computes the sum of a sequence of values. + + + + + Computes the sum of a sequence of + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of values. + + + + + Computes the average of a sequence of values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Returns the minimum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the minimum nullable value. + + + + + Returns the maximum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the maximum nullable value. + + + + + Computes the sum of a sequence of nullable values. + + + + + Computes the sum of a sequence of nullable + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of nullable values. + + + + + Computes the average of a sequence of nullable values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Computes the sum of a sequence of values. + + + + + Computes the sum of a sequence of + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of values. + + + + + Computes the average of a sequence of values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Returns the minimum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the minimum nullable value. + + + + + Returns the maximum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the maximum nullable value. + + + + + Computes the sum of a sequence of nullable values. + + + + + Computes the sum of a sequence of nullable + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of nullable values. + + + + + Computes the average of a sequence of nullable values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Computes the sum of a sequence of values. + + + + + Computes the sum of a sequence of + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of values. + + + + + Computes the average of a sequence of values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Returns the minimum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the minimum nullable value. + + + + + Returns the maximum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the maximum nullable value. + + + + + Computes the sum of a sequence of nullable values. + + + + + Computes the sum of a sequence of nullable + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of nullable values. + + + + + Computes the average of a sequence of nullable values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Computes the sum of a sequence of values. + + + + + Computes the sum of a sequence of + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of values. + + + + + Computes the average of a sequence of values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Returns the minimum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the minimum nullable value. + + + + + Returns the maximum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the maximum nullable value. + + + + + Computes the sum of a sequence of nullable values. + + + + + Computes the sum of a sequence of nullable + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of nullable values. + + + + + Computes the average of a sequence of nullable values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Computes the sum of a sequence of values. + + + + + Computes the sum of a sequence of + values that are obtained by invoking a transform function on + each element of the input sequence. + + + + + Computes the average of a sequence of values. + + + + + Computes the average of a sequence of values + that are obtained by invoking a transform function on each + element of the input sequence. + + + + + Returns the minimum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the minimum nullable value. + + + + + Returns the maximum value in a sequence of nullable + values. + + + + + Invokes a transform function on each element of a sequence and + returns the maximum nullable value. + + + + + Represents a collection of objects that have a common key. + + + + + Gets the key of the . + + + + + Defines an indexer, size property, and Boolean search method for + data structures that map keys to + sequences of values. + + + + + Represents a sorted sequence. + + + + + Performs a subsequent ordering on the elements of an + according to a key. + + + + + Represents a collection of keys each mapped to one or more values. + + + + + Determines whether a specified key is in the . + + + + + Applies a transform function to each key and its associated + values and returns the results. + + + + + Returns a generic enumerator that iterates through the . + + + + + Gets the number of key/value collection pairs in the . + + + + + Gets the collection of values indexed by the specified key. + + + + + See issue #11 + for why this method is needed and cannot be expressed as a + lambda at the call site. + + + + + See issue #11 + for why this method is needed and cannot be expressed as a + lambda at the call site. + + + + + This attribute allows us to define extension methods without + requiring .NET Framework 3.5. For more information, see the section, + Extension Methods in .NET Framework 2.0 Apps, + of Basic Instincts: Extension Methods + column in MSDN Magazine, + issue Nov 2007. + + + + + Represents a view of a . + + + + + Initializes a new instance of the class. + + The name. + Type of the property. + + + + When overridden in a derived class, returns whether resetting an object changes its value. + + + true if resetting the component changes its value; otherwise, false. + + The component to test for reset capability. + + + + + When overridden in a derived class, gets the current value of the property on a component. + + + The value of a property for a given component. + + The component with the property for which to retrieve the value. + + + + + When overridden in a derived class, resets the value for this property of the component to the default value. + + The component with the property value that is to be reset to the default value. + + + + + When overridden in a derived class, sets the value of the component to a different value. + + The component with the property value that is to be set. + The new value. + + + + + When overridden in a derived class, determines a value indicating whether the value of this property needs to be persisted. + + + true if the property should be persisted; otherwise, false. + + The component with the property to be examined for persistence. + + + + + When overridden in a derived class, gets the type of the component this property is bound to. + + + A that represents the type of component this property is bound to. When the or methods are invoked, the object specified might be an instance of this type. + + + + + When overridden in a derived class, gets a value indicating whether this property is read-only. + + + true if the property is read-only; otherwise, false. + + + + + When overridden in a derived class, gets the type of the property. + + + A that represents the type of the property. + + + + + Gets the hash code for the name of the member. + + + + The hash code for the name of the member. + + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Represents an abstract JSON token. + + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts XML to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Represents a collection of . + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Serializes the XML node to a JSON string. + + The node to serialize. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XmlNode. + + + + Deserializes the XmlNode from a JSON string. + + The JSON string. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XmlNode + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a JSON constructor. + + + + + Represents a token that can contain other tokens. + + + + + Raises the event. + + The instance containing the event data. + + + + Raises the event. + + The instance containing the event data. + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Occurs when the list changes or an item in the list changes. + + + + + Occurs before an item is added to the collection. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the properties for this instance of a component. + + + A that represents the properties for this component instance. + + + + + Returns the properties for this instance of a component using the attribute array as a filter. + + An array of type that is used as a filter. + + A that represents the filtered properties for this component instance. + + + + + Returns a collection of custom attributes for this instance of a component. + + + An containing the attributes for this object. + + + + + Returns the class name of this instance of a component. + + + The class name of the object, or null if the class does not have a name. + + + + + Returns the name of this instance of a component. + + + The name of the object, or null if the object does not have a name. + + + + + Returns a type converter for this instance of a component. + + + A that is the converter for this object, or null if there is no for this object. + + + + + Returns the default event for this instance of a component. + + + An that represents the default event for this object, or null if this object does not have events. + + + + + Returns the default property for this instance of a component. + + + A that represents the default property for this object, or null if this object does not have properties. + + + + + Returns an editor of the specified type for this instance of a component. + + A that represents the editor for this object. + + An of the specified type that is the editor for this object, or null if the editor cannot be found. + + + + + Returns the events for this instance of a component using the specified attribute array as a filter. + + An array of type that is used as a filter. + + An that represents the filtered events for this component instance. + + + + + Returns the events for this instance of a component. + + + An that represents the events for this component instance. + + + + + Returns an object that contains the property described by the specified property descriptor. + + A that represents the property whose owner is to be found. + + An that represents the owner of the specified property. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON array. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the interface when serializing and deserializing types. + + + true if the interface will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the attribute when serializing and deserializing types. + + + true if the attribute will be ignored when serializing and deserializing types; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + Get and set values for a using dynamic methods. + + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the ISerializable object constructor. + + The ISerializable object constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/lib/net35/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/net35/Newtonsoft.Json.dll new file mode 100644 index 000000000..0b07407f6 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/net35/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/net35/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/net35/Newtonsoft.Json.xml new file mode 100644 index 000000000..814735b84 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/net35/Newtonsoft.Json.xml @@ -0,0 +1,7662 @@ + + + + Newtonsoft.Json + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + + A . This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Converts a binary value to and from a base 64 string value. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an Entity Framework EntityKey to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Represents a view of a . + + + + + Initializes a new instance of the class. + + The name. + Type of the property. + + + + When overridden in a derived class, returns whether resetting an object changes its value. + + + true if resetting the component changes its value; otherwise, false. + + The component to test for reset capability. + + + + + When overridden in a derived class, gets the current value of the property on a component. + + + The value of a property for a given component. + + The component with the property for which to retrieve the value. + + + + + When overridden in a derived class, resets the value for this property of the component to the default value. + + The component with the property value that is to be reset to the default value. + + + + + When overridden in a derived class, sets the value of the component to a different value. + + The component with the property value that is to be set. + The new value. + + + + + When overridden in a derived class, determines a value indicating whether the value of this property needs to be persisted. + + + true if the property should be persisted; otherwise, false. + + The component with the property to be examined for persistence. + + + + + When overridden in a derived class, gets the type of the component this property is bound to. + + + A that represents the type of component this property is bound to. When the or methods are invoked, the object specified might be an instance of this type. + + + + + When overridden in a derived class, gets a value indicating whether this property is read-only. + + + true if the property is read-only; otherwise, false. + + + + + When overridden in a derived class, gets the type of the property. + + + A that represents the type of the property. + + + + + Gets the hash code for the name of the member. + + + + The hash code for the name of the member. + + + + + Represents a trace writer that writes to the application's instances. + + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Represents an abstract JSON token. + + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the ISerializable object constructor. + + The ISerializable object constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Get and set values for a using dynamic methods. + + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts XML to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Represents a collection of . + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Serializes the XML node to a JSON string. + + The node to serialize. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XmlNode. + + + + Deserializes the XmlNode from a JSON string. + + The JSON string. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XmlNode + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to convert to JSON. + Indicates how the output is formatted. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XNode. + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XNode + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a JSON constructor. + + + + + Represents a token that can contain other tokens. + + + + + Raises the event. + + The instance containing the event data. + + + + Raises the event. + + The instance containing the event data. + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Occurs when the list changes or an item in the list changes. + + + + + Occurs before an item is added to the collection. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the properties for this instance of a component. + + + A that represents the properties for this component instance. + + + + + Returns the properties for this instance of a component using the attribute array as a filter. + + An array of type that is used as a filter. + + A that represents the filtered properties for this component instance. + + + + + Returns a collection of custom attributes for this instance of a component. + + + An containing the attributes for this object. + + + + + Returns the class name of this instance of a component. + + + The class name of the object, or null if the class does not have a name. + + + + + Returns the name of this instance of a component. + + + The name of the object, or null if the object does not have a name. + + + + + Returns a type converter for this instance of a component. + + + A that is the converter for this object, or null if there is no for this object. + + + + + Returns the default event for this instance of a component. + + + An that represents the default event for this object, or null if this object does not have events. + + + + + Returns the default property for this instance of a component. + + + A that represents the default property for this object, or null if this object does not have properties. + + + + + Returns an editor of the specified type for this instance of a component. + + A that represents the editor for this object. + + An of the specified type that is the editor for this object, or null if the editor cannot be found. + + + + + Returns the events for this instance of a component using the specified attribute array as a filter. + + An array of type that is used as a filter. + + An that represents the filtered events for this component instance. + + + + + Returns the events for this instance of a component. + + + An that represents the events for this component instance. + + + + + Returns an object that contains the property described by the specified property descriptor. + + A that represents the property whose owner is to be found. + + An that represents the owner of the specified property. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Occurs when a property value is changing. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON array. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the interface when serializing and deserializing types. + + + true if the interface will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the attribute when serializing and deserializing types. + + + true if the attribute will be ignored when serializing and deserializing types; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Represents a method that constructs an object. + + The object type to create. + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/lib/net40/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/net40/Newtonsoft.Json.dll new file mode 100644 index 000000000..81639f9b1 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/net40/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/net40/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/net40/Newtonsoft.Json.xml new file mode 100644 index 000000000..fd3b523d8 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/net40/Newtonsoft.Json.xml @@ -0,0 +1,7905 @@ + + + + Newtonsoft.Json + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + + A . This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Converts a binary value to and from a base 64 string value. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an Entity Framework EntityKey to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an ExpandoObject to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Represents a trace writer that writes to the application's instances. + + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Represents an abstract JSON token. + + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the object's properties. + + The object's properties. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the ISerializable object constructor. + + The ISerializable object constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Get and set values for a using dynamic methods. + + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Represents a view of a . + + + + + Initializes a new instance of the class. + + The name. + Type of the property. + + + + When overridden in a derived class, returns whether resetting an object changes its value. + + + true if resetting the component changes its value; otherwise, false. + + The component to test for reset capability. + + + + + When overridden in a derived class, gets the current value of the property on a component. + + + The value of a property for a given component. + + The component with the property for which to retrieve the value. + + + + + When overridden in a derived class, resets the value for this property of the component to the default value. + + The component with the property value that is to be reset to the default value. + + + + + When overridden in a derived class, sets the value of the component to a different value. + + The component with the property value that is to be set. + The new value. + + + + + When overridden in a derived class, determines a value indicating whether the value of this property needs to be persisted. + + + true if the property should be persisted; otherwise, false. + + The component with the property to be examined for persistence. + + + + + When overridden in a derived class, gets the type of the component this property is bound to. + + + A that represents the type of component this property is bound to. When the or methods are invoked, the object specified might be an instance of this type. + + + + + When overridden in a derived class, gets a value indicating whether this property is read-only. + + + true if the property is read-only; otherwise, false. + + + + + When overridden in a derived class, gets the type of the property. + + + A that represents the type of the property. + + + + + Gets the hash code for the name of the member. + + + + The hash code for the name of the member. + + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts XML to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Represents a collection of . + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using a collection of . + + The object to serialize. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Asynchronously populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + A task that represents the asynchronous populate operation. + + + + + Serializes the XML node to a JSON string. + + The node to serialize. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + A JSON string of the XmlNode. + + + + Serializes the XML node to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XmlNode. + + + + Deserializes the XmlNode from a JSON string. + + The JSON string. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XmlNode + + + + Deserializes the XmlNode from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XmlNode + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to convert to JSON. + Indicates how the output is formatted. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XNode. + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XNode + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a JSON constructor. + + + + + Represents a token that can contain other tokens. + + + + + Raises the event. + + The instance containing the event data. + + + + Raises the event. + + The instance containing the event data. + + + + Raises the event. + + The instance containing the event data. + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Occurs when the list changes or an item in the list changes. + + + + + Occurs before an item is added to the collection. + + + + + Occurs when the items list of the collection has changed, or the collection is reset. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the properties for this instance of a component. + + + A that represents the properties for this component instance. + + + + + Returns the properties for this instance of a component using the attribute array as a filter. + + An array of type that is used as a filter. + + A that represents the filtered properties for this component instance. + + + + + Returns a collection of custom attributes for this instance of a component. + + + An containing the attributes for this object. + + + + + Returns the class name of this instance of a component. + + + The class name of the object, or null if the class does not have a name. + + + + + Returns the name of this instance of a component. + + + The name of the object, or null if the object does not have a name. + + + + + Returns a type converter for this instance of a component. + + + A that is the converter for this object, or null if there is no for this object. + + + + + Returns the default event for this instance of a component. + + + An that represents the default event for this object, or null if this object does not have events. + + + + + Returns the default property for this instance of a component. + + + A that represents the default property for this object, or null if this object does not have properties. + + + + + Returns an editor of the specified type for this instance of a component. + + A that represents the editor for this object. + + An of the specified type that is the editor for this object, or null if the editor cannot be found. + + + + + Returns the events for this instance of a component using the specified attribute array as a filter. + + An array of type that is used as a filter. + + An that represents the filtered events for this component instance. + + + + + Returns the events for this instance of a component. + + + An that represents the events for this component instance. + + + + + Returns an object that contains the property described by the specified property descriptor. + + A that represents the property whose owner is to be found. + + An that represents the owner of the specified property. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Occurs when a property value is changing. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON array. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Initializes a new instance of the class. + + The that holds the serialized object data about the exception being thrown. + The that contains contextual information about the source or destination. + The parameter is null. + The class name is null or is zero (0). + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the interface when serializing and deserializing types. + + + true if the interface will be ignored when serializing and deserializing types; otherwise, false. + + + + + Gets or sets a value indicating whether to ignore the attribute when serializing and deserializing types. + + + true if the attribute will be ignored when serializing and deserializing types; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic that returns a result + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Returns a Restrictions object which includes our current restrictions merged + with a restriction limiting our type + + + + + Represents a method that constructs an object. + + The object type to create. + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/lib/portable-net40+sl4+wp7+win8/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/portable-net40+sl4+wp7+win8/Newtonsoft.Json.dll new file mode 100644 index 000000000..40646a892 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/portable-net40+sl4+wp7+win8/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/portable-net40+sl4+wp7+win8/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/portable-net40+sl4+wp7+win8/Newtonsoft.Json.xml new file mode 100644 index 000000000..7ce6fd564 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/portable-net40+sl4+wp7+win8/Newtonsoft.Json.xml @@ -0,0 +1,7091 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + + A . This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from JSON and BSON. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Indicates the method that will be used during deserialization for locating and loading assemblies. + + + + + In simple mode, the assembly used during deserialization need not match exactly the assembly used during serialization. Specifically, the version numbers need not match as the LoadWithPartialName method is used to load the assembly. + + + + + In full mode, the assembly used during deserialization must match exactly the assembly used during serialization. The Load method of the Assembly class is used to load the assembly. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Represents a collection of . + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Represents a JSON array. + + + + + + + + Represents a token that can contain other tokens. + + + + + Represents an abstract JSON token. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a JSON constructor. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + Allows users to control class loading and mandate what class to load. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object + The type of the object the formatter creates a new instance of. + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Specifies what messages to output for the class. + + + + + Output no tracing and debugging messages. + + + + + Output error-handling messages. + + + + + Output warnings and error-handling messages. + + + + + Output informational messages, warnings, and error-handling messages. + + + + + Output all debugging and tracing messages. + + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/lib/sl3-wp/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/sl3-wp/Newtonsoft.Json.dll new file mode 100644 index 000000000..93e740db3 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/sl3-wp/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/sl3-wp/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/sl3-wp/Newtonsoft.Json.xml new file mode 100644 index 000000000..c72659524 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/sl3-wp/Newtonsoft.Json.xml @@ -0,0 +1,7212 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + + A . This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from JSON and BSON. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts XML to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Indicates the method that will be used during deserialization for locating and loading assemblies. + + + + + In simple mode, the assembly used during deserialization need not match exactly the assembly used during serialization. Specifically, the version numbers need not match as the LoadWithPartialName method is used to load the assembly. + + + + + In full mode, the assembly used during deserialization must match exactly the assembly used during serialization. The Load method of the Assembly class is used to load the assembly. + + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to convert to JSON. + Indicates how the output is formatted. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XNode. + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XNode + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Represents a collection of . + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Represents a JSON array. + + + + + + + + Represents a token that can contain other tokens. + + + + + Represents an abstract JSON token. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Raises the event. + + The instance containing the event data. + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Occurs when the items list of the collection has changed, or the collection is reset. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a JSON constructor. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Allows users to control class loading and mandate what class to load. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object + The type of the object the formatter creates a new instance of. + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Specifies what messages to output for the class. + + + + + Output no tracing and debugging messages. + + + + + Output error-handling messages. + + + + + Output warnings and error-handling messages. + + + + + Output informational messages, warnings, and error-handling messages. + + + + + Output all debugging and tracing messages. + + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/lib/sl4-windowsphone71/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/sl4-windowsphone71/Newtonsoft.Json.dll new file mode 100644 index 000000000..93e740db3 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/sl4-windowsphone71/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/sl4-windowsphone71/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/sl4-windowsphone71/Newtonsoft.Json.xml new file mode 100644 index 000000000..c72659524 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/sl4-windowsphone71/Newtonsoft.Json.xml @@ -0,0 +1,7212 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + + A . This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from JSON and BSON. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts XML to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Indicates the method that will be used during deserialization for locating and loading assemblies. + + + + + In simple mode, the assembly used during deserialization need not match exactly the assembly used during serialization. Specifically, the version numbers need not match as the LoadWithPartialName method is used to load the assembly. + + + + + In full mode, the assembly used during deserialization must match exactly the assembly used during serialization. The Load method of the Assembly class is used to load the assembly. + + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to convert to JSON. + Indicates how the output is formatted. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XNode. + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XNode + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Represents a collection of . + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Represents a JSON array. + + + + + + + + Represents a token that can contain other tokens. + + + + + Represents an abstract JSON token. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Raises the event. + + The instance containing the event data. + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Occurs when the items list of the collection has changed, or the collection is reset. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a JSON constructor. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Allows users to control class loading and mandate what class to load. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object + The type of the object the formatter creates a new instance of. + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Specifies what messages to output for the class. + + + + + Output no tracing and debugging messages. + + + + + Output error-handling messages. + + + + + Output warnings and error-handling messages. + + + + + Output informational messages, warnings, and error-handling messages. + + + + + Output all debugging and tracing messages. + + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/lib/sl4/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/sl4/Newtonsoft.Json.dll new file mode 100644 index 000000000..f44757ae3 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/sl4/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/sl4/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/sl4/Newtonsoft.Json.xml new file mode 100644 index 000000000..3d63c3b2f --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/sl4/Newtonsoft.Json.xml @@ -0,0 +1,7234 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + + A . This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from JSON and BSON. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an ExpandoObject to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Indicates the method that will be used during deserialization for locating and loading assemblies. + + + + + In simple mode, the assembly used during deserialization need not match exactly the assembly used during serialization. Specifically, the version numbers need not match as the LoadWithPartialName method is used to load the assembly. + + + + + In full mode, the assembly used during deserialization must match exactly the assembly used during serialization. The Load method of the Assembly class is used to load the assembly. + + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Represents a collection of . + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Represents a JSON array. + + + + + + + + Represents a token that can contain other tokens. + + + + + Represents an abstract JSON token. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Raises the event. + + The instance containing the event data. + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Occurs when the items list of the collection has changed, or the collection is reset. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a JSON constructor. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Allows users to control class loading and mandate what class to load. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object + The type of the object the formatter creates a new instance of. + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets the default members search flags. + + The default members search flags. + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the object's properties. + + The object's properties. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Specifies what messages to output for the class. + + + + + Output no tracing and debugging messages. + + + + + Output error-handling messages. + + + + + Output warnings and error-handling messages. + + + + + Output informational messages, warnings, and error-handling messages. + + + + + Output all debugging and tracing messages. + + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic that returns a result + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Returns a Restrictions object which includes our current restrictions merged + with a restriction limiting our type + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/Newtonsoft.Json.4.5.11/lib/winrt45/Newtonsoft.Json.dll b/packages/Newtonsoft.Json.4.5.11/lib/winrt45/Newtonsoft.Json.dll new file mode 100644 index 000000000..0ec801d69 Binary files /dev/null and b/packages/Newtonsoft.Json.4.5.11/lib/winrt45/Newtonsoft.Json.dll differ diff --git a/packages/Newtonsoft.Json.4.5.11/lib/winrt45/Newtonsoft.Json.xml b/packages/Newtonsoft.Json.4.5.11/lib/winrt45/Newtonsoft.Json.xml new file mode 100644 index 000000000..21b048950 --- /dev/null +++ b/packages/Newtonsoft.Json.4.5.11/lib/winrt45/Newtonsoft.Json.xml @@ -0,0 +1,7430 @@ + + + + Newtonsoft.Json + + + + + Represents a BSON Oid (object id). + + + + + Initializes a new instance of the class. + + The Oid value. + + + + Gets or sets the value of the Oid. + + The value of the Oid. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class with the specified . + + + + + Reads the next JSON token from the stream. + + true if the next token was read successfully; false if there are no more tokens to read. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Skips the children of the current token. + + + + + Sets the current token. + + The new token. + + + + Sets the current token and value. + + The new token. + The value. + + + + Sets the state based on current token type. + + + + + Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. + + + + + Releases unmanaged and - optionally - managed resources + + true to release both managed and unmanaged resources; false to release only unmanaged resources. + + + + Changes the to Closed. + + + + + Gets the current reader state. + + The current reader state. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the reader is closed. + + + true to close the underlying stream or when + the reader is closed; otherwise false. The default is true. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + Get or set how time zones are handling when reading JSON. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets the type of the current JSON token. + + + + + Gets the text value of the current JSON token. + + + + + Gets The Common Language Runtime (CLR) type for the current JSON token. + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Specifies the state of the reader. + + + + + The Read method has not been called. + + + + + The end of the file has been reached successfully. + + + + + Reader is at a property. + + + + + Reader is at the start of an object. + + + + + Reader is in an object. + + + + + Reader is at the start of an array. + + + + + Reader is in an array. + + + + + The Close method has been called. + + + + + Reader has just read a value. + + + + + Reader is at the start of a constructor. + + + + + Reader in a constructor. + + + + + An error occurred that prevents the read operation from continuing. + + + + + The end of the file has been reached successfully. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The reader. + + + + Initializes a new instance of the class. + + The stream. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Initializes a new instance of the class. + + The reader. + if set to true the root object will be read as a JSON array. + The used when reading values from BSON. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + + A . This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Changes the to Closed. + + + + + Gets or sets a value indicating whether binary data reading should compatible with incorrect Json.NET 3.5 written binary. + + + true if binary data reading will be compatible with incorrect Json.NET 3.5 written binary; otherwise, false. + + + + + Gets or sets a value indicating whether the root object will be read as a JSON array. + + + true if the root object will be read as a JSON array; otherwise, false. + + + + + Gets or sets the used when reading values from BSON. + + The used when reading values from BSON. + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the end of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the end of an array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end constructor. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes the end of the current Json object or array. + + + + + Writes the current token. + + The to read the token from. + + + + Writes the specified end token. + + The end token to write. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON without changing the writer's state. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + An error will raised if the value cannot be written as a single JSON token. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets a value indicating whether the underlying stream or + should be closed when the writer is closed. + + + true to close the underlying stream or when + the writer is closed; otherwise false. The default is true. + + + + + Gets the top. + + The top. + + + + Gets the state of the writer. + + + + + Gets the path of the writer. + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling when writing JSON text. + + + + + Get or set how strings are escaped when writing JSON text. + + + + + Initializes a new instance of the class. + + The stream. + + + + Initializes a new instance of the class. + + The writer. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Writes the end. + + The token. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes raw JSON where a value is expected and updates the writer's state. + + The raw JSON to write. + + + + Writes the beginning of a Json array. + + + + + Writes the beginning of a Json object. + + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Closes this stream and the underlying stream. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value that represents a BSON object id. + + The Object ID value to write. + + + + Writes a BSON regex. + + The regex pattern. + The regex options. + + + + Gets or sets the used when writing values to BSON. + When set to no conversion will occur. + + The used when writing values to BSON. + + + + Specifies how constructors are used when initializing objects during deserialization by the . + + + + + First attempt to use the public default constructor, then fall back to single paramatized constructor, then the non-public default constructor. + + + + + Json.NET will use a non-public default constructor before falling back to a paramatized constructor. + + + + + Converts a to and from JSON and BSON. + + + + + Converts an object to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets the of the JSON produced by the JsonConverter. + + The of the JSON produced by the JsonConverter. + + + + Gets a value indicating whether this can read JSON. + + true if this can read JSON; otherwise, false. + + + + Gets a value indicating whether this can write JSON. + + true if this can write JSON; otherwise, false. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Create a custom object + + The object type to convert. + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Creates an object which will then be populated by the serializer. + + Type of the object. + The created object. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Provides a base class for converting a to and from JSON. + + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an ExpandoObject to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets a value indicating whether this can write JSON. + + + true if this can write JSON; otherwise, false. + + + + + Converts a to and from the ISO 8601 date format (e.g. 2008-04-12T12:53Z). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Gets or sets the date time styles used when converting a date to and from JSON. + + The date time styles used when converting a date to and from JSON. + + + + Gets or sets the date time format used when converting a date to and from JSON. + + The date time format used when converting a date to and from JSON. + + + + Gets or sets the culture used when converting a date to and from JSON. + + The culture used when converting a date to and from JSON. + + + + Converts a to and from a JavaScript date constructor (e.g. new Date(52231943)). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Converts a to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts a to and from JSON and BSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts an to and from its name string value. + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + A cached representation of the Enum string representation to respect per Enum field name. + + The type of the Enum. + A map of enum field name to either the field name, or the configured enum member name (). + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Gets or sets a value indicating whether the written enum text should be camel case. + + true if the written enum text will be camel case; otherwise, false. + + + + Converts a to and from a string (e.g. "1.2.3.4"). + + + + + Writes the JSON representation of the object. + + The to write to. + The value. + The calling serializer. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing property value of the JSON that is being converted. + The calling serializer. + The object value. + + + + Determines whether this instance can convert the specified object type. + + Type of the object. + + true if this instance can convert the specified object type; otherwise, false. + + + + + Converts XML to and from JSON. + + + + + Writes the JSON representation of the object. + + The to write to. + The calling serializer. + The value. + + + + Reads the JSON representation of the object. + + The to read from. + Type of the object. + The existing value of object being read. + The calling serializer. + The object value. + + + + Checks if the attributeName is a namespace attribute. + + Attribute name to test. + The attribute name prefix if it has one, otherwise an empty string. + True if attribute name is for a namespace attribute, otherwise false. + + + + Determines whether this instance can convert the specified value type. + + Type of the value. + + true if this instance can convert the specified value type; otherwise, false. + + + + + Gets or sets the name of the root element to insert when deserializing to XML if the JSON structure has produces multiple root elements. + + The name of the deserialize root element. + + + + Gets or sets a flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + true if the array attibute is written to the XML; otherwise, false. + + + + Gets or sets a value indicating whether to write the root JSON object. + + true if the JSON root object is omitted; otherwise, false. + + + + Specifies how dates are formatted when writing JSON text. + + + + + Dates are written in the ISO 8601 format, e.g. "2012-03-21T05:40Z". + + + + + Dates are written in the Microsoft JSON format, e.g. "\/Date(1198908717056)\/". + + + + + Specifies how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON text. + + + + + Date formatted strings are not parsed to a date type and are read as strings. + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed to . + + + + + Specifies how to treat the time value when converting between string and . + + + + + Treat as local time. If the object represents a Coordinated Universal Time (UTC), it is converted to the local time. + + + + + Treat as a UTC. If the object represents a local time, it is converted to a UTC. + + + + + Treat as a local time if a is being converted to a string. + If a string is being converted to , convert to a local time if a time zone is specified. + + + + + Time zone information should be preserved when converting. + + + + + Specifies default value handling options for the . + + + + + + + + + Include members where the member value is the same as the member's default value when serializing objects. + Included members are written to JSON. Has no effect when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + so that is is not written to JSON. + This option will ignore all default values (e.g. null for objects and nullable typesl; 0 for integers, + decimals and floating point numbers; and false for booleans). The default value ignored can be changed by + placing the on the property. + + + + + Members with a default value but no JSON will be set to their default value when deserializing. + + + + + Ignore members where the member value is the same as the member's default value when serializing objects + and sets members to their default value when deserializing. + + + + + Indicates the method that will be used during deserialization for locating and loading assemblies. + + + + + In simple mode, the assembly used during deserialization need not match exactly the assembly used during serialization. Specifically, the version numbers need not match as the LoadWithPartialName method is used to load the assembly. + + + + + In full mode, the assembly used during deserialization must match exactly the assembly used during serialization. The Load method of the Assembly class is used to load the assembly. + + + + + Specifies formatting options for the . + + + + + No special formatting is applied. This is the default. + + + + + Causes child objects to be indented according to the and settings. + + + + + Provides an interface to enable a class to return line and position information. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Gets the current line position. + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + Instructs the how to serialize the collection. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the id. + + The id. + + + + Gets or sets the title. + + The title. + + + + Gets or sets the description. + + The description. + + + + Gets the collection's items converter. + + The collection's items converter. + + + + Gets or sets a value that indicates whether to preserve object references. + + + true to keep object reference; otherwise, false. The default is false. + + + + + Gets or sets a value that indicates whether to preserve collection's items references. + + + true to keep collection's items object references; otherwise, false. The default is false. + + + + + Gets or sets the reference loop handling used when serializing the collection's items. + + The reference loop handling. + + + + Gets or sets the type name handling used when serializing the collection's items. + + The type name handling. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with a flag indicating whether the array can contain null items + + A flag indicating whether the array can contain null items. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets a value indicating whether null items are allowed in the collection. + + true if null items are allowed in the collection; otherwise, false. + + + + Instructs the to use the specified constructor when deserializing that object. + + + + + Provides methods for converting between common language runtime types and JSON types. + + + + + + + + Represents JavaScript's boolean value true as a string. This field is read-only. + + + + + Represents JavaScript's boolean value false as a string. This field is read-only. + + + + + Represents JavaScript's null as a string. This field is read-only. + + + + + Represents JavaScript's undefined as a string. This field is read-only. + + + + + Represents JavaScript's positive infinity as a string. This field is read-only. + + + + + Represents JavaScript's negative infinity as a string. This field is read-only. + + + + + Represents JavaScript's NaN as a string. This field is read-only. + + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + The time zone handling when the date is converted to a string. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation using the specified. + + The value to convert. + The format the date will be converted to. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + The string delimiter character. + A JSON string representation of the . + + + + Converts the to its JSON string representation. + + The value to convert. + A JSON string representation of the . + + + + Serializes the specified object to a JSON string. + + The object to serialize. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string. + + The object to serialize. + Indicates how the output is formatted. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + A collection converters used while serializing. + A JSON string representation of the object. + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using a collection of . + + The object to serialize. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Asynchronously serializes the specified object to a JSON string using a collection of . + + The object to serialize. + Indicates how the output is formatted. + The used to serialize the object. + If this is null, default serialization settings will be is used. + + A task that represents the asynchronous serialize operation. The value of the TResult parameter contains a JSON string representation of the object. + + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to a .NET object. + + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The of object being deserialized. + The deserialized object from the Json string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + The deserialized object from the Json string. + + + + Deserializes the JSON to the given anonymous type. + + + The anonymous type to deserialize to. This can't be specified + traditionally and must be infered from the anonymous type passed + as a parameter. + + The JSON to deserialize. + The anonymous type object. + The deserialized anonymous type from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The object to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize. + Converters to use while deserializing. + The deserialized object from the JSON string. + + + + Deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + The deserialized object from the JSON string. + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The type of the object to deserialize to. + The JSON to deserialize. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Asynchronously deserializes the JSON to the specified .NET type. + + The JSON to deserialize. + The type of the object to deserialize to. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + A task that represents the asynchronous deserialize operation. The value of the TResult parameter contains the deserialized object from the JSON string. + + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + + + Populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + + + Asynchronously populates the object with values from the JSON string. + + The JSON to populate values from. + The target object to populate values onto. + + The used to deserialize the object. + If this is null, default serialization settings will be is used. + + + A task that represents the asynchronous populate operation. + + + + + Serializes the to a JSON string. + + The node to convert to JSON. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to convert to JSON. + Indicates how the output is formatted. + A JSON string of the XNode. + + + + Serializes the to a JSON string. + + The node to serialize. + Indicates how the output is formatted. + Omits writing the root object. + A JSON string of the XNode. + + + + Deserializes the from a JSON string. + + The JSON string. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + The deserialized XNode + + + + Deserializes the from a JSON string nested in a root elment. + + The JSON string. + The name of the root element to append when deserializing. + + A flag to indicate whether to write the Json.NET array attribute. + This attribute helps preserve arrays when converting the written XML back to JSON. + + The deserialized XNode + + + + Instructs the to use the specified when serializing the member or class. + + + + + Initializes a new instance of the class. + + Type of the converter. + + + + Gets the type of the converter. + + The type of the converter. + + + + Represents a collection of . + + + + + Instructs the how to serialize the collection. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Instructs the not to serialize the public field or public read/write property value. + + + + + Instructs the how to serialize the object. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified member serialization. + + The member serialization. + + + + Initializes a new instance of the class with the specified container Id. + + The container Id. + + + + Gets or sets the member serialization. + + The member serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Instructs the to always serialize the member with the specified name. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class with the specified name. + + Name of the property. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets the null value handling used when serializing this property. + + The null value handling. + + + + Gets or sets the default value handling used when serializing this property. + + The default value handling. + + + + Gets or sets the reference loop handling used when serializing this property. + + The reference loop handling. + + + + Gets or sets the object creation handling used when deserializing this property. + + The object creation handling. + + + + Gets or sets the type name handling used when serializing this property. + + The type name handling. + + + + Gets or sets whether this property's value is serialized as a reference. + + Whether this property's value is serialized as a reference. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets a value indicating whether this property is required. + + + A value indicating whether this property is required. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + The exception thrown when an error occurs during Json serialization or deserialization. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Serializes and deserializes objects into and from the JSON format. + The enables you to control how objects are encoded into JSON. + + + + + Initializes a new instance of the class. + + + + + Creates a new instance using the specified . + + The settings to be applied to the . + A new instance using the specified . + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Populates the JSON values onto the target object. + + The that contains the JSON structure to reader values from. + The target object to populate values onto. + + + + Deserializes the Json structure contained by the specified . + + The that contains the JSON structure to deserialize. + The being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The type of the object to deserialize. + The instance of being deserialized. + + + + Deserializes the Json structure contained by the specified + into an instance of the specified type. + + The containing the object. + The of object being deserialized. + The instance of being deserialized. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Serializes the specified and writes the Json structure + to a Stream using the specified . + + The used to write the Json structure. + The to serialize. + + + + Occurs when the errors during serialization and deserialization. + + + + + Gets or sets the used by the serializer when resolving references. + + + + + Gets or sets the used by the serializer when resolving type names. + + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how object references are preserved by the serializer. + + + + + Get or set how reference loops (e.g. a class referencing itself) is handled. + + + + + Get or set how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + + + + Get or set how null values are handled during serialization and deserialization. + + + + + Get or set how null default are handled during serialization and deserialization. + + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets a collection that will be used during serialization. + + Collection that will be used during serialization. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Gets a value indicating whether there will be a check for additional JSON content after deserializing an object. + + + true if there will be a check for additional JSON content after deserializing an object; otherwise, false. + + + + + Specifies the settings on a object. + + + + + Initializes a new instance of the class. + + + + + Gets or sets how reference loops (e.g. a class referencing itself) is handled. + + Reference loop handling. + + + + Gets or sets how missing members (e.g. JSON contains a property that isn't a member on the object) are handled during deserialization. + + Missing member handling. + + + + Gets or sets how objects are created during deserialization. + + The object creation handling. + + + + Gets or sets how null values are handled during serialization and deserialization. + + Null value handling. + + + + Gets or sets how null default are handled during serialization and deserialization. + + The default value handling. + + + + Gets or sets a collection that will be used during serialization. + + The converters. + + + + Gets or sets how object references are preserved by the serializer. + + The preserve references handling. + + + + Gets or sets how type name writing and reading is handled by the serializer. + + The type name handling. + + + + Gets or sets how a type name assembly is written and resolved by the serializer. + + The type name assembly format. + + + + Gets or sets how constructors are used during deserialization. + + The constructor handling. + + + + Gets or sets the contract resolver used by the serializer when + serializing .NET objects to JSON and vice versa. + + The contract resolver. + + + + Gets or sets the used by the serializer when resolving references. + + The reference resolver. + + + + Gets or sets the used by the serializer when writing trace messages. + + The trace writer. + + + + Gets or sets the used by the serializer when resolving type names. + + The binder. + + + + Gets or sets the error handler called during serialization and deserialization. + + The error handler called during serialization and deserialization. + + + + Gets or sets the used by the serializer when invoking serialization callback methods. + + The context. + + + + Gets or sets the maximum depth allowed when reading JSON. Reading past this depth will throw a . + + + + + Indicates how JSON text output is formatted. + + + + + Get or set how dates are written to JSON text. + + + + + Get or set how time zones are handling during serialization and deserialization. + + + + + Get or set how date formatted strings, e.g. "\/Date(1198908717056)\/" and "2012-03-21T05:40Z", are parsed when reading JSON. + + + + + Gets or sets the culture used when reading JSON. Defaults to . + + + + + Gets a value indicating whether there will be a check for additional content after deserializing an object. + + + true if there will be a check for additional content after deserializing an object; otherwise, false. + + + + + Represents a reader that provides fast, non-cached, forward-only access to JSON text data. + + + + + Initializes a new instance of the class with the specified . + + The TextReader containing the XML data to read. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Changes the state to closed. + + + + + Gets a value indicating whether the class can return line information. + + + true if LineNumber and LinePosition can be provided; otherwise, false. + + + + + Gets the current line number. + + + The current line number or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Gets the current line position. + + + The current line position or 0 if no line information is available (for example, HasLineInfo returns false). + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Creates an instance of the JsonWriter class using the specified . + + The TextWriter to write to. + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the specified end token. + + The end token to write. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes indent characters. + + + + + Writes the JSON value delimiter. + + + + + Writes an indent space. + + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes out the given white space. + + The string of white space characters. + + + + Gets or sets how many IndentChars to write for each level in the hierarchy when is set to Formatting.Indented. + + + + + Gets or sets which character to use to quote attribute values. + + + + + Gets or sets which character to use for indenting when is set to Formatting.Indented. + + + + + Gets or sets a value indicating whether object names will be surrounded with quotes. + + + + + Specifies the type of Json token. + + + + + This is returned by the if a method has not been called. + + + + + An object start token. + + + + + An array start token. + + + + + A constructor start token. + + + + + An object property name. + + + + + A comment. + + + + + Raw JSON. + + + + + An integer. + + + + + A float. + + + + + A string. + + + + + A boolean. + + + + + A null token. + + + + + An undefined token. + + + + + An object end token. + + + + + An array end token. + + + + + A constructor end token. + + + + + A Date. + + + + + Byte data. + + + + + Represents a reader that provides validation. + + + + + Initializes a new instance of the class that + validates the content returned from the given . + + The to read from while validating. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. + + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Sets an event handler for receiving schema validation errors. + + + + + Gets the text value of the current Json token. + + + + + + Gets the depth of the current token in the JSON document. + + The depth of the current token in the JSON document. + + + + Gets the path of the current JSON token. + + + + + Gets the quotation mark character used to enclose the value of a string. + + + + + + Gets the type of the current Json token. + + + + + + Gets the Common Language Runtime (CLR) type for the current Json token. + + + + + + Gets or sets the schema. + + The schema. + + + + Gets the used to construct this . + + The specified in the constructor. + + + + The exception thrown when an error occurs while reading Json text. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Contains the LINQ to JSON extension methods. + + + + + Returns a collection of tokens that contains the ancestors of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the ancestors of every node in the source collection. + + + + Returns a collection of tokens that contains the descendants of every token in the source collection. + + The type of the objects in source, constrained to . + An of that contains the source collection. + An of that contains the descendants of every node in the source collection. + + + + Returns a collection of child properties of every object in the source collection. + + An of that contains the source collection. + An of that contains the properties of every object in the source collection. + + + + Returns a collection of child values of every object in the source collection with the given key. + + An of that contains the source collection. + The token key. + An of that contains the values of every node in the source collection with the given key. + + + + Returns a collection of child values of every object in the source collection. + + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child values of every object in the source collection with the given key. + + The type to convert the values to. + An of that contains the source collection. + The token key. + An that contains the converted values of every node in the source collection with the given key. + + + + Returns a collection of converted child values of every object in the source collection. + + The type to convert the values to. + An of that contains the source collection. + An that contains the converted values of every node in the source collection. + + + + Converts the value. + + The type to convert the value to. + A cast as a of . + A converted value. + + + + Converts the value. + + The source collection type. + The type to convert the value to. + A cast as a of . + A converted value. + + + + Returns a collection of child tokens of every array in the source collection. + + The source collection type. + An of that contains the source collection. + An of that contains the values of every node in the source collection. + + + + Returns a collection of converted child tokens of every array in the source collection. + + An of that contains the source collection. + The type to convert the values to. + The source collection type. + An that contains the converted values of every node in the source collection. + + + + Returns the input typed as . + + An of that contains the source collection. + The input typed as . + + + + Returns the input typed as . + + The source collection type. + An of that contains the source collection. + The input typed as . + + + + Represents a collection of objects. + + The type of token + + + + Gets the with the specified key. + + + + + + Represents a JSON array. + + + + + + + + Represents a token that can contain other tokens. + + + + + Represents an abstract JSON token. + + + + + Compares the values of two tokens, including the values of all descendant tokens. + + The first to compare. + The second to compare. + true if the tokens are equal; otherwise false. + + + + Adds the specified content immediately after this token. + + A content object that contains simple content or a collection of content objects to be added after this token. + + + + Adds the specified content immediately before this token. + + A content object that contains simple content or a collection of content objects to be added before this token. + + + + Returns a collection of the ancestor tokens of this token. + + A collection of the ancestor tokens of this token. + + + + Returns a collection of the sibling tokens after this token, in document order. + + A collection of the sibling tokens after this tokens, in document order. + + + + Returns a collection of the sibling tokens before this token, in document order. + + A collection of the sibling tokens before this token, in document order. + + + + Gets the with the specified key converted to the specified type. + + The type to convert the token to. + The token key. + The converted token value. + + + + Returns a collection of the child tokens of this token, in document order. + + An of containing the child tokens of this , in document order. + + + + Returns a collection of the child tokens of this token, in document order, filtered by the specified type. + + The type to filter the child tokens on. + A containing the child tokens of this , in document order. + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + A containing the child values of this , in document order. + + + + Removes this token from its parent. + + + + + Replaces this token with the specified token. + + The value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Returns the indented JSON for this token. + + + The indented JSON for this token. + + + + + Returns the JSON for this token using the given formatting and converters. + + Indicates how the output is formatted. + A collection of which will be used when writing the token. + The JSON for this token using the given formatting and converters. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an explicit conversion from to . + + The value. + The result of the conversion. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Performs an implicit conversion from to . + + The value to create a from. + The initialized with the specified value. + + + + Creates an for this token. + + An that can be used to read this token and its descendants. + + + + Creates a from an object. + + The object that will be used to create . + A with the value of the specified object + + + + Creates a from an object using the specified . + + The object that will be used to create . + The that will be used when reading the object. + A with the value of the specified object + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the . + + The object type that the token will be deserialized to. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates the specified .NET type from the using the specified . + + The object type that the token will be deserialized to. + The that will be used when creating the object. + The new object created from the JSON value. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Creates a from a . + + An positioned at the token to read into this . + + An that contains the token and its descendant tokens + that were read from the reader. The runtime type of the token is determined + by the token type of the first token encountered in the reader. + + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + The that matches the object path or a null reference if no matching token is found. + + + + Selects the token that matches the object path. + + + The object path from the current to the + to be returned. This must be a string of property names or array indexes separated + by periods, such as Tables[0].DefaultView[0].Price in C# or + Tables(0).DefaultView(0).Price in Visual Basic. + + A flag to indicate whether an error should be thrown if no token is found. + The that matches the object path. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Creates a new instance of the . All child tokens are recursively cloned. + + A new instance of the . + + + + Gets a comparer that can compare two tokens for value equality. + + A that can compare two nodes for value equality. + + + + Gets or sets the parent. + + The parent. + + + + Gets the root of this . + + The root of this . + + + + Gets the node type for this . + + The type. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the next sibling token of this node. + + The that contains the next sibling token. + + + + Gets the previous sibling token of this node. + + The that contains the previous sibling token. + + + + Gets the with the specified key. + + The with the specified key. + + + + Get the first child token of this token. + + A containing the first child token of the . + + + + Get the last child token of this token. + + A containing the last child token of the . + + + + Raises the event. + + The instance containing the event data. + + + + Returns a collection of the child tokens of this token, in document order. + + + An of containing the child tokens of this , in document order. + + + + + Returns a collection of the child values of this token, in document order. + + The type to convert the values to. + + A containing the child values of this , in document order. + + + + + Returns a collection of the descendant tokens for this token in document order. + + An containing the descendant tokens of the . + + + + Adds the specified content as children of this . + + The content to be added. + + + + Adds the specified content as the first children of this . + + The content to be added. + + + + Creates an that can be used to add tokens to the . + + An that is ready to have content written to it. + + + + Replaces the children nodes of this token with the specified content. + + The content. + + + + Removes the child nodes from this token. + + + + + Occurs when the items list of the collection has changed, or the collection is reset. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Get the first child token of this token. + + + A containing the first child token of the . + + + + + Get the last child token of this token. + + + A containing the last child token of the . + + + + + Gets the count of child JSON tokens. + + The count of child JSON tokens + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Initializes a new instance of the class with the specified content. + + The contents of the array. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Determines the index of a specific item in the . + + The object to locate in the . + + The index of if found in the list; otherwise, -1. + + + + + Inserts an item to the at the specified index. + + The zero-based index at which should be inserted. + The object to insert into the . + + is not a valid index in the . + The is read-only. + + + + Removes the item at the specified index. + + The zero-based index of the item to remove. + + is not a valid index in the . + The is read-only. + + + + Adds an item to the . + + The object to add to the . + The is read-only. + + + + Removes all items from the . + + The is read-only. + + + + Determines whether the contains a specific value. + + The object to locate in the . + + true if is found in the ; otherwise, false. + + + + + Removes the first occurrence of a specific object from the . + + The object to remove from the . + + true if was successfully removed from the ; otherwise, false. This method also returns false if is not found in the original . + + The is read-only. + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the at the specified index. + + + + + + Represents a JSON constructor. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name and content. + + The constructor name. + The contents of the constructor. + + + + Initializes a new instance of the class with the specified name. + + The constructor name. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets or sets the name of this constructor. + + The constructor name. + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Represents a collection of objects. + + The type of token + + + + An empty collection of objects. + + + + + Initializes a new instance of the struct. + + The enumerable. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Returns an enumerator that iterates through a collection. + + + An object that can be used to iterate through the collection. + + + + + Determines whether the specified is equal to this instance. + + The to compare with this instance. + + true if the specified is equal to this instance; otherwise, false. + + + + + Returns a hash code for this instance. + + + A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table. + + + + + Gets the with the specified key. + + + + + + Represents a JSON object. + + + + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Initializes a new instance of the class with the specified content. + + The contents of the object. + + + + Gets an of this object's properties. + + An of this object's properties. + + + + Gets a the specified name. + + The property name. + A with the specified name or null. + + + + Gets an of this object's property values. + + An of this object's property values. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Load a from a string that contains JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + + + + Creates a from an object. + + The object that will be used to create . + A with the values of the specified object + + + + Creates a from an object. + + The object that will be used to create . + The that will be used to read the object. + A with the values of the specified object + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Gets the with the specified property name. + + Name of the property. + The with the specified property name. + + + + Gets the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + One of the enumeration values that specifies how the strings will be compared. + The with the specified property name. + + + + Tries to get the with the specified property name. + The exact property name will be searched for first and if no matching property is found then + the will be used to match a property. + + Name of the property. + The value. + One of the enumeration values that specifies how the strings will be compared. + true if a value was successfully retrieved; otherwise, false. + + + + Adds the specified property name. + + Name of the property. + The value. + + + + Removes the property with the specified name. + + Name of the property. + true if item was successfully removed; otherwise, false. + + + + Tries the get value. + + Name of the property. + The value. + true if a value was successfully retrieved; otherwise, false. + + + + Returns an enumerator that iterates through the collection. + + + A that can be used to iterate through the collection. + + + + + Raises the event with the provided arguments. + + Name of the property. + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Occurs when a property value changes. + + + + + Gets the node type for this . + + The type. + + + + Gets the with the specified key. + + The with the specified key. + + + + Gets or sets the with the specified property name. + + + + + + Represents a JSON property. + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Initializes a new instance of the class. + + The property name. + The property content. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Loads an from a . + + A that will be read for the content of the . + A that contains the JSON that was read from the specified . + + + + Gets the container's children tokens. + + The container's children tokens. + + + + Gets the property name. + + The property name. + + + + Gets or sets the property value. + + The property value. + + + + Gets the node type for this . + + The type. + + + + Represents a raw JSON string. + + + + + Represents a value in JSON (string, integer, date, etc). + + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Initializes a new instance of the class with the given value. + + The value. + + + + Creates a comment with the given value. + + The value. + A comment with the given value. + + + + Creates a string with the given value. + + The value. + A string with the given value. + + + + Writes this token to a . + + A into which this method will write. + A collection of which will be used when writing the token. + + + + Indicates whether the current object is equal to another object of the same type. + + + true if the current object is equal to the parameter; otherwise, false. + + An object to compare with this object. + + + + Determines whether the specified is equal to the current . + + The to compare with the current . + + true if the specified is equal to the current ; otherwise, false. + + + The parameter is null. + + + + + Serves as a hash function for a particular type. + + + A hash code for the current . + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format provider. + + A that represents this instance. + + + + + Returns a that represents this instance. + + The format. + The format provider. + + A that represents this instance. + + + + + Returns the responsible for binding operations performed on this object. + + The expression tree representation of the runtime value. + + The to bind this object. + + + + + Compares the current instance with another object of the same type and returns an integer that indicates whether the current instance precedes, follows, or occurs in the same position in the sort order as the other object. + + An object to compare with this instance. + + A 32-bit signed integer that indicates the relative order of the objects being compared. The return value has these meanings: + Value + Meaning + Less than zero + This instance is less than . + Zero + This instance is equal to . + Greater than zero + This instance is greater than . + + + is not the same type as this instance. + + + + + Gets a value indicating whether this token has childen tokens. + + + true if this token has child values; otherwise, false. + + + + + Gets the node type for this . + + The type. + + + + Gets or sets the underlying token value. + + The underlying token value. + + + + Initializes a new instance of the class from another object. + + A object to copy from. + + + + Initializes a new instance of the class. + + The raw json. + + + + Creates an instance of with the content of the reader's current token. + + The reader. + An instance of with the content of the reader's current token. + + + + Compares tokens to determine whether they are equal. + + + + + Determines whether the specified objects are equal. + + The first object of type to compare. + The second object of type to compare. + + true if the specified objects are equal; otherwise, false. + + + + + Returns a hash code for the specified object. + + The for which a hash code is to be returned. + A hash code for the specified object. + The type of is a reference type and is null. + + + + Represents a reader that provides fast, non-cached, forward-only access to serialized Json data. + + + + + Initializes a new instance of the class. + + The token to read from. + + + + Reads the next JSON token from the stream as a . + + + A or a null reference if the next JSON token is null. This method will return null at the end of an array. + + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream as a . + + A . This method will return null at the end of an array. + + + + Reads the next JSON token from the stream. + + + true if the next token was read successfully; false if there are no more tokens to read. + + + + + Specifies the type of token. + + + + + No token type has been set. + + + + + A JSON object. + + + + + A JSON array. + + + + + A JSON constructor. + + + + + A JSON object property. + + + + + A comment. + + + + + An integer value. + + + + + A float value. + + + + + A string value. + + + + + A boolean value. + + + + + A null value. + + + + + An undefined value. + + + + + A date value. + + + + + A raw JSON value. + + + + + A collection of bytes value. + + + + + A Guid value. + + + + + A Uri value. + + + + + A TimeSpan value. + + + + + Represents a writer that provides a fast, non-cached, forward-only way of generating Json data. + + + + + Initializes a new instance of the class writing to the given . + + The container being written to. + + + + Initializes a new instance of the class. + + + + + Flushes whatever is in the buffer to the underlying streams and also flushes the underlying stream. + + + + + Closes this stream and the underlying stream. + + + + + Writes the beginning of a Json object. + + + + + Writes the beginning of a Json array. + + + + + Writes the start of a constructor with the given name. + + The name of the constructor. + + + + Writes the end. + + The token. + + + + Writes the property name of a name/value pair on a Json object. + + The name of the property. + + + + Writes a null value. + + + + + Writes an undefined value. + + + + + Writes raw JSON. + + The raw JSON to write. + + + + Writes out a comment /*...*/ containing the specified text. + + Text to place inside the comment. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Writes a value. + + The value to write. + + + + Gets the token being writen. + + The token being writen. + + + + Specifies the member serialization options for the . + + + + + All public members are serialized by default. Members can be excluded using or . + This is the default member serialization mode. + + + + + Only members must be marked with or are serialized. + This member serialization mode can also be set by marking the class with . + + + + + All public and private fields are serialized. Members can be excluded using or . + This member serialization mode can also be set by marking the class with + and setting IgnoreSerializableAttribute on to false. + + + + + Specifies missing member handling options for the . + + + + + Ignore a missing member and do not attempt to deserialize it. + + + + + Throw a when a missing member is encountered during deserialization. + + + + + Specifies null value handling options for the . + + + + + + + + + Include null values when serializing and deserializing objects. + + + + + Ignore null values when serializing and deserializing objects. + + + + + Specifies how object creation is handled by the . + + + + + Reuse existing objects, create new objects when needed. + + + + + Only reuse existing objects. + + + + + Always create new objects. + + + + + Specifies reference handling options for the . + + + + + + + + Do not preserve references when serializing types. + + + + + Preserve references when serializing into a JSON object structure. + + + + + Preserve references when serializing into a JSON array structure. + + + + + Preserve references when serializing. + + + + + Specifies reference loop handling options for the . + + + + + Throw a when a loop is encountered. + + + + + Ignore loop references and do not serialize. + + + + + Serialize loop references. + + + + + Indicating whether a property is required. + + + + + The property is not required. The default state. + + + + + The property must be defined in JSON but can be a null value. + + + + + The property must be defined in JSON and cannot be a null value. + + + + + Contains the JSON schema extension methods. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + + true if the specified is valid; otherwise, false. + + + + + Determines whether the is valid. + + The source to test. + The schema to test with. + When this method returns, contains any error messages generated while validating. + + true if the specified is valid; otherwise, false. + + + + + Validates the specified . + + The source to test. + The schema to test with. + + + + Validates the specified . + + The source to test. + The schema to test with. + The validation event handler. + + + + An in-memory representation of a JSON Schema. + + + + + Initializes a new instance of the class. + + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The object representing the JSON Schema. + + + + Reads a from the specified . + + The containing the JSON Schema to read. + The to use when resolving schema references. + The object representing the JSON Schema. + + + + Load a from a string that contains schema JSON. + + A that contains JSON. + A populated from the string that contains JSON. + + + + Parses the specified json. + + The json. + The resolver. + A populated from the string that contains JSON. + + + + Writes this schema to a . + + A into which this method will write. + + + + Writes this schema to a using the specified . + + A into which this method will write. + The resolver used. + + + + Returns a that represents the current . + + + A that represents the current . + + + + + Gets or sets the id. + + + + + Gets or sets the title. + + + + + Gets or sets whether the object is required. + + + + + Gets or sets whether the object is read only. + + + + + Gets or sets whether the object is visible to users. + + + + + Gets or sets whether the object is transient. + + + + + Gets or sets the description of the object. + + + + + Gets or sets the types of values allowed by the object. + + The type. + + + + Gets or sets the pattern. + + The pattern. + + + + Gets or sets the minimum length. + + The minimum length. + + + + Gets or sets the maximum length. + + The maximum length. + + + + Gets or sets a number that the value should be divisble by. + + A number that the value should be divisble by. + + + + Gets or sets the minimum. + + The minimum. + + + + Gets or sets the maximum. + + The maximum. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + A flag indicating whether the value can not equal the number defined by the "minimum" attribute. + + + + Gets or sets a flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + A flag indicating whether the value can not equal the number defined by the "maximum" attribute. + + + + Gets or sets the minimum number of items. + + The minimum number of items. + + + + Gets or sets the maximum number of items. + + The maximum number of items. + + + + Gets or sets the of items. + + The of items. + + + + Gets or sets the of properties. + + The of properties. + + + + Gets or sets the of additional properties. + + The of additional properties. + + + + Gets or sets the pattern properties. + + The pattern properties. + + + + Gets or sets a value indicating whether additional properties are allowed. + + + true if additional properties are allowed; otherwise, false. + + + + + Gets or sets the required property if this property is present. + + The required property if this property is present. + + + + Gets or sets the identity. + + The identity. + + + + Gets or sets the a collection of valid enum values allowed. + + A collection of valid enum values allowed. + + + + Gets or sets a collection of options. + + A collection of options. + + + + Gets or sets disallowed types. + + The disallow types. + + + + Gets or sets the default value. + + The default value. + + + + Gets or sets the extend . + + The extended . + + + + Gets or sets the format. + + The format. + + + + Returns detailed information about the schema exception. + + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class + with a specified error message. + + The error message that explains the reason for the exception. + + + + Initializes a new instance of the class + with a specified error message and a reference to the inner exception that is the cause of this exception. + + The error message that explains the reason for the exception. + The exception that is the cause of the current exception, or a null reference (Nothing in Visual Basic) if no inner exception is specified. + + + + Gets the line number indicating where the error occurred. + + The line number indicating where the error occurred. + + + + Gets the line position indicating where the error occurred. + + The line position indicating where the error occurred. + + + + Gets the path to the JSON where the error occurred. + + The path to the JSON where the error occurred. + + + + Generates a from a specified . + + + + + Generate a from the specified type. + + The type to generate a from. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Generate a from the specified type. + + The type to generate a from. + The used to resolve schema references. + Specify whether the generated root will be nullable. + A generated from the specified type. + + + + Gets or sets how undefined schemas are handled by the serializer. + + + + + Gets or sets the contract resolver. + + The contract resolver. + + + + Resolves from an id. + + + + + Initializes a new instance of the class. + + + + + Gets a for the specified id. + + The id. + A for the specified id. + + + + Gets or sets the loaded schemas. + + The loaded schemas. + + + + The value types allowed by the . + + + + + No type specified. + + + + + String type. + + + + + Float type. + + + + + Integer type. + + + + + Boolean type. + + + + + Object type. + + + + + Array type. + + + + + Null type. + + + + + Any type. + + + + + Specifies undefined schema Id handling options for the . + + + + + Do not infer a schema Id. + + + + + Use the .NET type name as the schema Id. + + + + + Use the assembly qualified .NET type name as the schema Id. + + + + + Returns detailed information related to the . + + + + + Gets the associated with the validation error. + + The JsonSchemaException associated with the validation error. + + + + Gets the path of the JSON location where the validation error occurred. + + The path of the JSON location where the validation error occurred. + + + + Gets the text description corresponding to the validation error. + + The text description. + + + + Represents the callback method that will handle JSON schema validation events and the . + + + + + Allows users to control class loading and mandate what class to load. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object + The type of the object the formatter creates a new instance of. + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Resolves member mappings for a type, camel casing property names. + + + + + Used by to resolves a for a given . + + + + + Used by to resolves a for a given . + + + + + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Initializes a new instance of the class. + + + + + Initializes a new instance of the class. + + + If set to true the will use a cached shared with other resolvers of the same type. + Sharing the cache will significantly performance because expensive reflection will only happen once but could cause unexpected + behavior if different instances of the resolver are suppose to produce different results. When set to false it is highly + recommended to reuse instances with the . + + + + + Resolves the contract for a given type. + + The type to resolve a contract for. + The contract for a given type. + + + + Gets the serializable members for the type. + + The type to get serializable members for. + The serializable members for the type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates the constructor parameters. + + The constructor to create properties for. + The type's member properties. + Properties for the given . + + + + Creates a for the given . + + The matching member property. + The constructor parameter. + A created for the given . + + + + Resolves the default for the contract. + + Type of the object. + The contract's default . + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Creates a for the given type. + + Type of the object. + A for the given type. + + + + Determines which contract type is created for the given type. + + Type of the object. + A for the given type. + + + + Creates properties for the given . + + The type to create properties for. + /// The member serialization mode for the type. + Properties for the given . + + + + Creates the used by the serializer to get and set values from a member. + + The member. + The used by the serializer to get and set values from a member. + + + + Creates a for the given . + + The member's parent . + The member to create a for. + A created for the given . + + + + Resolves the name of the property. + + Name of the property. + Name of the property. + + + + Gets the resolved name of the property. + + Name of the property. + Name of the property. + + + + Gets a value indicating whether members are being get and set using dynamic code generation. + This value is determined by the runtime permissions available. + + + true if using dynamic code generation; otherwise, false. + + + + + Gets or sets a value indicating whether compiler generated members should be serialized. + + + true if serialized compiler generated members; otherwise, false. + + + + + Initializes a new instance of the class. + + + + + Resolves the name of the property. + + Name of the property. + The property name camel cased. + + + + Used to resolve references when serializing and deserializing JSON by the . + + + + + Resolves a reference to its object. + + The serialization context. + The reference to resolve. + The object that + + + + Gets the reference for the sepecified object. + + The serialization context. + The object to get a reference for. + The reference to the object. + + + + Determines whether the specified object is referenced. + + The serialization context. + The object to test for a reference. + + true if the specified object is referenced; otherwise, false. + + + + + Adds a reference to the specified object. + + The serialization context. + The reference. + The object to reference. + + + + The default serialization binder used when resolving and loading classes from type names. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + The type of the object the formatter creates a new instance of. + + + + + When overridden in a derived class, controls the binding of a serialized object to a type. + + The type of the object the formatter creates a new instance of. + Specifies the name of the serialized object. + Specifies the name of the serialized object. + + + + Provides information surrounding an error. + + + + + Gets or sets the error. + + The error. + + + + Gets the original object that caused the error. + + The original object that caused the error. + + + + Gets the member that caused the error. + + The member that caused the error. + + + + Gets the path of the JSON location where the error occurred. + + The path of the JSON location where the error occurred. + + + + Gets or sets a value indicating whether this is handled. + + true if handled; otherwise, false. + + + + Provides data for the Error event. + + + + + Initializes a new instance of the class. + + The current object. + The error context. + + + + Gets the current object the error event is being raised against. + + The current object the error event is being raised against. + + + + Gets the error context. + + The error context. + + + + Represents a trace writer. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + The that will be used to filter the trace messages passed to the writer. + + + + Provides methods to get and set values. + + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Contract details for a used by the . + + + + + Gets the underlying type for the contract. + + The underlying type for the contract. + + + + Gets or sets the type created during deserialization. + + The type created during deserialization. + + + + Gets or sets whether this type contract is serialized as a reference. + + Whether this type contract is serialized as a reference. + + + + Gets or sets the default for this contract. + + The converter. + + + + Gets or sets the method called immediately after deserialization of the object. + + The method called immediately after deserialization of the object. + + + + Gets or sets the method called during deserialization of the object. + + The method called during deserialization of the object. + + + + Gets or sets the method called after serialization of the object graph. + + The method called after serialization of the object graph. + + + + Gets or sets the method called before serialization of the object. + + The method called before serialization of the object. + + + + Gets or sets the default creator method used to create the object. + + The default creator method used to create the object. + + + + Gets or sets a value indicating whether the default creator is non public. + + true if the default object creator is non-public; otherwise, false. + + + + Gets or sets the method called when an error is thrown during the serialization of the object. + + The method called when an error is thrown during the serialization of the object. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the default collection items . + + The converter. + + + + Gets or sets a value indicating whether the collection items preserve object references. + + true if collection items preserve object references; otherwise, false. + + + + Gets or sets the collection item reference loop handling. + + The reference loop handling. + + + + Gets or sets the collection item type name handling. + + The type name handling. + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the of the collection items. + + The of the collection items. + + + + Gets a value indicating whether the collection type is a multidimensional array. + + true if the collection type is a multidimensional array; otherwise, false. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Gets the of the dictionary keys. + + The of the dictionary keys. + + + + Gets the of the dictionary values. + + The of the dictionary values. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets the object's properties. + + The object's properties. + + + + Gets or sets the property name resolver. + + The property name resolver. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Gets or sets the object member serialization. + + The member object serialization. + + + + Gets or sets a value that indicates whether the object's properties are required. + + + A value indicating whether the object's properties are required. + + + + + Gets the object's properties. + + The object's properties. + + + + Gets the constructor parameters required for any non-default constructor + + + + + Gets or sets the override constructor used to create the object. + This is set when a constructor is marked up using the + JsonConstructor attribute. + + The override constructor. + + + + Gets or sets the parametrized constructor used to create the object. + + The parametrized constructor. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Maps a JSON property to a .NET member or constructor parameter. + + + + + Returns a that represents this instance. + + + A that represents this instance. + + + + + Gets or sets the name of the property. + + The name of the property. + + + + Gets or sets the type that declared this property. + + The type that declared this property. + + + + Gets or sets the order of serialization and deserialization of a member. + + The numeric order of serialization or deserialization. + + + + Gets or sets the name of the underlying member or parameter. + + The name of the underlying member or parameter. + + + + Gets the that will get and set the during serialization. + + The that will get and set the during serialization. + + + + Gets or sets the type of the property. + + The type of the property. + + + + Gets or sets the for the property. + If set this converter takes presidence over the contract converter for the property type. + + The converter. + + + + Gets the member converter. + + The member converter. + + + + Gets a value indicating whether this is ignored. + + true if ignored; otherwise, false. + + + + Gets a value indicating whether this is readable. + + true if readable; otherwise, false. + + + + Gets a value indicating whether this is writable. + + true if writable; otherwise, false. + + + + Gets a value indicating whether this has a member attribute. + + true if has a member attribute; otherwise, false. + + + + Gets the default value. + + The default value. + + + + Gets a value indicating whether this is required. + + A value indicating whether this is required. + + + + Gets a value indicating whether this property preserves object references. + + + true if this instance is reference; otherwise, false. + + + + + Gets the property null value handling. + + The null value handling. + + + + Gets the property default value handling. + + The default value handling. + + + + Gets the property reference loop handling. + + The reference loop handling. + + + + Gets the property object creation handling. + + The object creation handling. + + + + Gets or sets the type name handling. + + The type name handling. + + + + Gets or sets a predicate used to determine whether the property should be serialize. + + A predicate used to determine whether the property should be serialize. + + + + Gets or sets a predicate used to determine whether the property should be serialized. + + A predicate used to determine whether the property should be serialized. + + + + Gets or sets an action used to set whether the property has been deserialized. + + An action used to set whether the property has been deserialized. + + + + Gets or sets the converter used when serializing the property's collection items. + + The collection's items converter. + + + + Gets or sets whether this property's collection items are serialized as a reference. + + Whether this property's collection items are serialized as a reference. + + + + Gets or sets the the type name handling used when serializing the property's collection items. + + The collection's items type name handling. + + + + Gets or sets the the reference loop handling used when serializing the property's collection items. + + The collection's items reference loop handling. + + + + A collection of objects. + + + + + Initializes a new instance of the class. + + The type. + + + + When implemented in a derived class, extracts the key from the specified element. + + The element from which to extract the key. + The key for the specified element. + + + + Adds a object. + + The property to add to the collection. + + + + Gets the closest matching object. + First attempts to get an exact case match of propertyName and then + a case insensitive match. + + Name of the property. + A matching property if found. + + + + Gets a property by property name. + + The name of the property to get. + Type property name string comparison. + A matching property if found. + + + + Contract details for a used by the . + + + + + Initializes a new instance of the class. + + The underlying type for the contract. + + + + Represents a method that constructs an object. + + The object type to create. + + + + When applied to a method, specifies that the method is called when an error occurs serializing an object. + + + + + Get and set values for a using reflection. + + + + + Initializes a new instance of the class. + + The member info. + + + + Sets the value. + + The target to set the value on. + The value to set on the target. + + + + Gets the value. + + The target to get the value from. + The value. + + + + Represents a trace writer that writes to memory. When the trace message limit is + reached then old trace messages will be removed as new messages are added. + + + + + Initializes a new instance of the class. + + + + + Writes the specified trace level, message and optional exception. + + The at which to write this trace. + The trace message. + The trace exception. This parameter is optional. + + + + Returns an enumeration of the most recent trace messages. + + An enumeration of the most recent trace messages. + + + + Returns a of the most recent trace messages. + + + A of the most recent trace messages. + + + + + Gets the that will be used to filter the trace messages passed to the writer. + For example a filter level of Info will exclude Verbose messages and include Info, + Warning and Error messages. + + + The that will be used to filter the trace messages passed to the writer. + + + + + Specifies how strings are escaped when writing JSON text. + + + + + Only control characters (e.g. newline) are escaped. + + + + + All non-ASCII and control characters (e.g. newline) are escaped. + + + + + HTML (<, >, &, ', ") and control characters (e.g. newline) are escaped. + + + + + Specifies what messages to output for the class. + + + + + Output no tracing and debugging messages. + + + + + Output error-handling messages. + + + + + Output warnings and error-handling messages. + + + + + Output informational messages, warnings, and error-handling messages. + + + + + Output all debugging and tracing messages. + + + + + Specifies type name handling options for the . + + + + + Do not include the .NET type name when serializing types. + + + + + Include the .NET type name when serializing into a JSON object structure. + + + + + Include the .NET type name when serializing into a JSON array structure. + + + + + Always include the .NET type name when serializing. + + + + + Include the .NET type name when the type of the object being serialized is not the same as its declared type. + + + + + Determines whether the collection is null or empty. + + The collection. + + true if the collection is null or empty; otherwise, false. + + + + + Adds the elements of the specified collection to the specified generic IList. + + The list to add to. + The collection of elements to add. + + + + Returns the index of the first occurrence in a sequence by using a specified IEqualityComparer. + + The type of the elements of source. + A sequence in which to locate a value. + The object to locate in the sequence + An equality comparer to compare values. + The zero-based index of the first occurrence of value within the entire sequence, if found; otherwise, –1. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted type. + + + + Converts the value to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert the value to. + The converted value if the conversion was successful or the default value of T if it failed. + + true if initialValue was converted successfully; otherwise, false. + + + + + Converts the value to the specified type. If the value is unable to be converted, the + value is checked whether it assignable to the specified type. + + The value to convert. + The culture to use when converting. + The type to convert or cast the value to. + + The converted type. If conversion was unsuccessful, the initial value + is returned if assignable to the target type. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic that returns a result + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Helper method for generating a MetaObject which calls a + specific method on Dynamic, but uses one of the arguments for + the result. + + + + + Returns a Restrictions object which includes our current restrictions merged + with a restriction limiting our type + + + + + Gets a dictionary of the names and values of an Enum type. + + + + + + Gets a dictionary of the names and values of an Enum type. + + The enum type to get names and values for. + + + + + Gets the type of the typed collection's items. + + The type. + The type of the typed collection's items. + + + + Gets the member's underlying type. + + The member. + The underlying type of the member. + + + + Determines whether the member is an indexed property. + + The member. + + true if the member is an indexed property; otherwise, false. + + + + + Determines whether the property is an indexed property. + + The property. + + true if the property is an indexed property; otherwise, false. + + + + + Gets the member's value on the object. + + The member. + The target object. + The member's value on the object. + + + + Sets the member's value on the target object. + + The member. + The target. + The value. + + + + Determines whether the specified MemberInfo can be read. + + The MemberInfo to determine whether can be read. + /// if set to true then allow the member to be gotten non-publicly. + + true if the specified MemberInfo can be read; otherwise, false. + + + + + Determines whether the specified MemberInfo can be set. + + The MemberInfo to determine whether can be set. + if set to true then allow the member to be set non-publicly. + if set to true then allow the member to be set if read-only. + + true if the specified MemberInfo can be set; otherwise, false. + + + + + Builds a string. Unlike StringBuilder this class lets you reuse it's internal buffer. + + + + + Determines whether the string is all white space. Empty string will return false. + + The string to test whether it is all white space. + + true if the string is all white space; otherwise, false. + + + + + Nulls an empty string. + + The string. + Null if the string was null, otherwise the string unchanged. + + + + Specifies the state of the . + + + + + An exception has been thrown, which has left the in an invalid state. + You may call the method to put the in the Closed state. + Any other method calls results in an being thrown. + + + + + The method has been called. + + + + + An object is being written. + + + + + A array is being written. + + + + + A constructor is being written. + + + + + A property is being written. + + + + + A write method has not been called. + + + + diff --git a/packages/dotConnect.Express.for.Oracle.8.1.36/content/app.config.transform b/packages/dotConnect.Express.for.Oracle.8.1.36/content/app.config.transform index b13d9334e..0386e6489 100644 --- a/packages/dotConnect.Express.for.Oracle.8.1.36/content/app.config.transform +++ b/packages/dotConnect.Express.for.Oracle.8.1.36/content/app.config.transform @@ -1,8 +1,8 @@ - - - - - - - + + + + + + + \ No newline at end of file diff --git a/packages/dotConnect.Express.for.Oracle.8.1.36/content/web.config.transform b/packages/dotConnect.Express.for.Oracle.8.1.36/content/web.config.transform index 31cbcefe7..3a3a1a7a9 100644 --- a/packages/dotConnect.Express.for.Oracle.8.1.36/content/web.config.transform +++ b/packages/dotConnect.Express.for.Oracle.8.1.36/content/web.config.transform @@ -1,8 +1,8 @@ - - - - - - - + + + + + + + \ No newline at end of file diff --git a/packages/dotConnect.Express.for.Oracle.8.1.36/dotConnect.Express.for.Oracle.8.1.36.nuspec b/packages/dotConnect.Express.for.Oracle.8.1.36/dotConnect.Express.for.Oracle.8.1.36.nuspec index c2ba4b728..e8e7527f4 100644 --- a/packages/dotConnect.Express.for.Oracle.8.1.36/dotConnect.Express.for.Oracle.8.1.36.nuspec +++ b/packages/dotConnect.Express.for.Oracle.8.1.36/dotConnect.Express.for.Oracle.8.1.36.nuspec @@ -1,18 +1,18 @@ - - - - dotConnect.Express.for.Oracle - 8.1.36 - dotConnect Express for Oracle - Devart Software - Devart Software - http://www.devart.com/dotconnect/oracle - http://www.devart.com/content/images/logos/dcoracle-white_fb.png - false - dotConnect Express for Oracle is a free of charge enhanced database connectivity solution built over ADO.NET architecture and a development framework with a number of innovative technologies. dotConnect offers a complete solution for developing database-related applications and web sites. It introduces new approaches for designing applications and boosts productivity of database application development. - dotConnect Express for Oracle is a free of charge enhanced database connectivity solution built over ADO.NET architecture and a development framework with a number of innovative technologies. - Copyright � 1998 - 2013 Devart - en-US - Oracle ADO.NET provider Database - + + + + dotConnect.Express.for.Oracle + 8.1.36 + dotConnect Express for Oracle + Devart Software + Devart Software + http://www.devart.com/dotconnect/oracle + http://www.devart.com/content/images/logos/dcoracle-white_fb.png + false + dotConnect Express for Oracle is a free of charge enhanced database connectivity solution built over ADO.NET architecture and a development framework with a number of innovative technologies. dotConnect offers a complete solution for developing database-related applications and web sites. It introduces new approaches for designing applications and boosts productivity of database application development. + dotConnect Express for Oracle is a free of charge enhanced database connectivity solution built over ADO.NET architecture and a development framework with a number of innovative technologies. + Copyright � 1998 - 2013 Devart + en-US + Oracle ADO.NET provider Database + \ No newline at end of file diff --git a/packages/repositories.config b/packages/repositories.config index 47b3cde7e..6da51e5f2 100644 --- a/packages/repositories.config +++ b/packages/repositories.config @@ -12,6 +12,7 @@ +