diff options
author | Jon Skeet <skeet@pobox.com> | 2008-08-14 20:33:27 +0100 |
---|---|---|
committer | unknown <Jon@.(none)> | 2008-08-14 20:33:27 +0100 |
commit | baa2bf54c2d8d493444fd3d58bd8a89927300a50 (patch) | |
tree | 2b293b640a1ac5ee0d44178e5b0e22ddfaccdc6f /csharp | |
parent | 3c38991607e993bc90c307c7a680fba97b77ecb4 (diff) | |
download | protobuf-baa2bf54c2d8d493444fd3d58bd8a89927300a50.tar.gz protobuf-baa2bf54c2d8d493444fd3d58bd8a89927300a50.tar.bz2 protobuf-baa2bf54c2d8d493444fd3d58bd8a89927300a50.zip |
First part of dotnet library
committer: Jon Skeet <skeet@pobox.com>
Diffstat (limited to 'csharp')
21 files changed, 6940 insertions, 0 deletions
diff --git a/csharp/ProtocolBuffers.Test/ByteStringTest.cs b/csharp/ProtocolBuffers.Test/ByteStringTest.cs new file mode 100644 index 00000000..5f701731 --- /dev/null +++ b/csharp/ProtocolBuffers.Test/ByteStringTest.cs @@ -0,0 +1,85 @@ +using System; +using System.Collections.Generic; +using System.Text; +using NUnit.Framework; + +namespace Google.ProtocolBuffers { + [TestFixture] + public class ByteStringTest { + [Test] + public void EmptyByteStringHasZeroSize() { + Assert.AreEqual(0, ByteString.Empty.Length); + } + + [Test] + public void CopyFromStringWithExplicitEncoding() { + ByteString bs = ByteString.CopyFrom("AB", Encoding.Unicode); + Assert.AreEqual(4, bs.Length); + Assert.AreEqual(65, bs[0]); + Assert.AreEqual(0, bs[1]); + Assert.AreEqual(66, bs[2]); + Assert.AreEqual(0, bs[3]); + } + + [Test] + public void IsEmptyWhenEmpty() { + Assert.IsTrue(ByteString.CopyFromUtf8("").IsEmpty); + } + + [Test] + public void IsEmptyWhenNotEmpty() { + Assert.IsFalse(ByteString.CopyFromUtf8("X").IsEmpty); + } + + [Test] + public void CopyFromByteArrayCopiesContents() { + byte[] data = new byte[1]; + data[0] = 10; + ByteString bs = ByteString.CopyFrom(data); + Assert.AreEqual(10, bs[0]); + data[0] = 5; + Assert.AreEqual(10, bs[0]); + } + + [Test] + public void ToByteArrayCopiesContents() { + ByteString bs = ByteString.CopyFromUtf8("Hello"); + byte[] data = bs.ToByteArray(); + Assert.AreEqual('H', data[0]); + Assert.AreEqual('H', bs[0]); + data[0] = 0; + Assert.AreEqual(0, data[0]); + Assert.AreEqual('H', bs[0]); + } + + [Test] + public void CopyFromUtf8UsesUtf8() { + ByteString bs = ByteString.CopyFromUtf8("\u20ac"); + Assert.AreEqual(3, bs.Length); + Assert.AreEqual(0xe2, bs[0]); + Assert.AreEqual(0x82, bs[1]); + Assert.AreEqual(0xac, bs[2]); + } + + [Test] + public void CopyFromPortion() { + byte[] data = new byte[]{0, 1, 2, 3, 4, 5, 6}; + ByteString bs = ByteString.CopyFrom(data, 2, 3); + Assert.AreEqual(3, bs.Length); + Assert.AreEqual(2, bs[0]); + Assert.AreEqual(3, bs[1]); + } + + [Test] + public void ToStringUtf8() { + ByteString bs = ByteString.CopyFromUtf8("\u20ac"); + Assert.AreEqual("\u20ac", bs.ToStringUtf8()); + } + + [Test] + public void ToStringWithExplicitEncoding() { + ByteString bs = ByteString.CopyFrom("\u20ac", Encoding.Unicode); + Assert.AreEqual("\u20ac", bs.ToString(Encoding.Unicode)); + } + } +} diff --git a/csharp/ProtocolBuffers.Test/CodedInputStreamTest.cs b/csharp/ProtocolBuffers.Test/CodedInputStreamTest.cs new file mode 100644 index 00000000..56b17a35 --- /dev/null +++ b/csharp/ProtocolBuffers.Test/CodedInputStreamTest.cs @@ -0,0 +1,36 @@ +using System; +using System.Collections.Generic; +using System.Text; +using NUnit.Framework; + +namespace Google.ProtocolBuffers { + [TestFixture] + public class CodedInputStreamTest { + + [Test] + public void DecodeZigZag32() { + Assert.AreEqual( 0, CodedInputStream.DecodeZigZag32(0)); + Assert.AreEqual(-1, CodedInputStream.DecodeZigZag32(1)); + Assert.AreEqual( 1, CodedInputStream.DecodeZigZag32(2)); + Assert.AreEqual(-2, CodedInputStream.DecodeZigZag32(3)); + Assert.AreEqual(0x3FFFFFFF, CodedInputStream.DecodeZigZag32(0x7FFFFFFE)); + Assert.AreEqual(unchecked((int)0xC0000000), CodedInputStream.DecodeZigZag32(0x7FFFFFFF)); + Assert.AreEqual(0x7FFFFFFF, CodedInputStream.DecodeZigZag32(0xFFFFFFFE)); + Assert.AreEqual(unchecked((int)0x80000000), CodedInputStream.DecodeZigZag32(0xFFFFFFFF)); + } + + [Test] + public void DecodeZigZag64() { + Assert.AreEqual( 0, CodedInputStream.DecodeZigZag64(0)); + Assert.AreEqual(-1, CodedInputStream.DecodeZigZag64(1)); + Assert.AreEqual( 1, CodedInputStream.DecodeZigZag64(2)); + Assert.AreEqual(-2, CodedInputStream.DecodeZigZag64(3)); + Assert.AreEqual(0x000000003FFFFFFFL, CodedInputStream.DecodeZigZag64(0x000000007FFFFFFEL)); + Assert.AreEqual(unchecked((long)0xFFFFFFFFC0000000L), CodedInputStream.DecodeZigZag64(0x000000007FFFFFFFL)); + Assert.AreEqual(0x000000007FFFFFFFL, CodedInputStream.DecodeZigZag64(0x00000000FFFFFFFEL)); + Assert.AreEqual(unchecked((long)0xFFFFFFFF80000000L), CodedInputStream.DecodeZigZag64(0x00000000FFFFFFFFL)); + Assert.AreEqual(0x7FFFFFFFFFFFFFFFL, CodedInputStream.DecodeZigZag64(0xFFFFFFFFFFFFFFFEL)); + Assert.AreEqual(unchecked((long)0x8000000000000000L),CodedInputStream.DecodeZigZag64(0xFFFFFFFFFFFFFFFFL)); + } + } +} diff --git a/csharp/ProtocolBuffers.Test/CodedOutputStreamTest.cs b/csharp/ProtocolBuffers.Test/CodedOutputStreamTest.cs new file mode 100644 index 00000000..c2042d9e --- /dev/null +++ b/csharp/ProtocolBuffers.Test/CodedOutputStreamTest.cs @@ -0,0 +1,237 @@ +using NUnit.Framework; +using System.IO; + +namespace Google.ProtocolBuffers { + [TestFixture] + public class CodedOutputStreamTest { + + /// <summary> + /// Helper to construct a byte array from a bunch of bytes. The inputs are + /// actually ints so that I can use hex notation and not get stupid errors + /// about precision. + /// </summary> + private static byte[] Bytes(params int[] bytesAsInts) { + byte[] bytes = new byte[bytesAsInts.Length]; + for (int i = 0; i < bytesAsInts.Length; i++) { + bytes[i] = (byte) bytesAsInts[i]; + } + return bytes; + } + + /// <summary> + /// Writes the given value using WriteRawVarint32() and WriteRawVarint64() and + /// checks that the result matches the given bytes + /// </summary> + private static void AssertWriteVarint(byte[] data, ulong value) { + // Only do 32-bit write if the value fits in 32 bits. + if ((value >> 32) == 0) { + MemoryStream rawOutput = new MemoryStream(); + CodedOutputStream output = CodedOutputStream.CreateInstance(rawOutput); + output.WriteRawVarint32((uint) value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + // Also try computing size. + Assert.AreEqual(data.Length, CodedOutputStream.ComputeRawVarint32Size((uint) value)); + } + + { + MemoryStream rawOutput = new MemoryStream(); + CodedOutputStream output = CodedOutputStream.CreateInstance(rawOutput); + output.WriteRawVarint64(value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + + // Also try computing size. + Assert.AreEqual(data.Length, CodedOutputStream.ComputeRawVarint64Size(value)); + } + + // Try different buffer sizes. + for (int bufferSize = 1; bufferSize <= 16; bufferSize *= 2) { + // Only do 32-bit write if the value fits in 32 bits. + if ((value >> 32) == 0) { + MemoryStream rawOutput = new MemoryStream(); + CodedOutputStream output = + CodedOutputStream.CreateInstance(rawOutput, bufferSize); + output.WriteRawVarint32((uint) value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + } + + { + MemoryStream rawOutput = new MemoryStream(); + CodedOutputStream output = CodedOutputStream.CreateInstance(rawOutput, bufferSize); + output.WriteRawVarint64(value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + } + } + } + + /// <summary> + /// Tests WriteRawVarint32() and WriteRawVarint64() + /// </summary> + [Test] + public void WriteVarint() { + AssertWriteVarint(Bytes(0x00), 0); + AssertWriteVarint(Bytes(0x01), 1); + AssertWriteVarint(Bytes(0x7f), 127); + // 14882 + AssertWriteVarint(Bytes(0xa2, 0x74), (0x22 << 0) | (0x74 << 7)); + // 2961488830 + AssertWriteVarint(Bytes(0xbe, 0xf7, 0x92, 0x84, 0x0b), + (0x3e << 0) | (0x77 << 7) | (0x12 << 14) | (0x04 << 21) | + (0x0bL << 28)); + + // 64-bit + // 7256456126 + AssertWriteVarint(Bytes(0xbe, 0xf7, 0x92, 0x84, 0x1b), + (0x3e << 0) | (0x77 << 7) | (0x12 << 14) | (0x04 << 21) | + (0x1bL << 28)); + // 41256202580718336 + AssertWriteVarint( + Bytes(0x80, 0xe6, 0xeb, 0x9c, 0xc3, 0xc9, 0xa4, 0x49), + (0x00 << 0) | (0x66 << 7) | (0x6b << 14) | (0x1c << 21) | + (0x43L << 28) | (0x49L << 35) | (0x24L << 42) | (0x49L << 49)); + // 11964378330978735131 + AssertWriteVarint( + Bytes(0x9b, 0xa8, 0xf9, 0xc2, 0xbb, 0xd6, 0x80, 0x85, 0xa6, 0x01), + unchecked((ulong) + ((0x1b << 0) | (0x28 << 7) | (0x79 << 14) | (0x42 << 21) | + (0x3bL << 28) | (0x56L << 35) | (0x00L << 42) | + (0x05L << 49) | (0x26L << 56) | (0x01L << 63)))); + } + + /// <summary> + /// Parses the given bytes using WriteRawLittleEndian32() and checks + /// that the result matches the given value. + /// </summary> + private static void AssertWriteLittleEndian32(byte[] data, int value) { + MemoryStream rawOutput = new MemoryStream(); + CodedOutputStream output = CodedOutputStream.CreateInstance(rawOutput); + output.WriteRawLittleEndian32(value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + + // Try different buffer sizes. + for (int bufferSize = 1; bufferSize <= 16; bufferSize *= 2) { + rawOutput = new MemoryStream(); + output = CodedOutputStream.CreateInstance(rawOutput, bufferSize); + output.WriteRawLittleEndian32(value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + } + } + + /// <summary> + /// Parses the given bytes using WriteRawLittleEndian64() and checks + /// that the result matches the given value. + /// </summary> + private static void AssertWriteLittleEndian64(byte[] data, long value) { + MemoryStream rawOutput = new MemoryStream(); + CodedOutputStream output = CodedOutputStream.CreateInstance(rawOutput); + output.WriteRawLittleEndian64(value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + + // Try different block sizes. + for (int blockSize = 1; blockSize <= 16; blockSize *= 2) { + rawOutput = new MemoryStream(); + output = CodedOutputStream.CreateInstance(rawOutput, blockSize); + output.WriteRawLittleEndian64(value); + output.Flush(); + Assert.AreEqual(data, rawOutput.ToArray()); + } + } + + /// <summary> + /// Tests writeRawLittleEndian32() and writeRawLittleEndian64(). + /// </summary> + [Test] + public void WriteLittleEndian() { + AssertWriteLittleEndian32(Bytes(0x78, 0x56, 0x34, 0x12), 0x12345678); + AssertWriteLittleEndian32(Bytes(0xf0, 0xde, 0xbc, 0x9a), unchecked((int)0x9abcdef0)); + + AssertWriteLittleEndian64( + Bytes(0xf0, 0xde, 0xbc, 0x9a, 0x78, 0x56, 0x34, 0x12), + 0x123456789abcdef0L); + AssertWriteLittleEndian64( + Bytes(0x78, 0x56, 0x34, 0x12, 0xf0, 0xde, 0xbc, 0x9a), + unchecked((long)0x9abcdef012345678L)); + } + + /* TODO(jonskeet): Put this back when we've got the rest working! + [Test] + public void testWriteWholeMessage() throws Exception { + TestAllTypes message = TestUtil.getAllSet(); + + byte[] rawBytes = message.toByteArray(); + assertEqualBytes(TestUtil.getGoldenMessage().toByteArray(), rawBytes); + + // Try different block sizes. + for (int blockSize = 1; blockSize < 256; blockSize *= 2) { + MemoryStream rawOutput = new MemoryStream(); + CodedOutputStream output = + CodedOutputStream.newInstance(rawOutput, blockSize); + message.writeTo(output); + output.flush(); + assertEqualBytes(rawBytes, rawOutput.toByteArray()); + } + } */ + + + [Test] + public void EncodeZigZag32() { + Assert.AreEqual(0, CodedOutputStream.EncodeZigZag32( 0)); + Assert.AreEqual(1, CodedOutputStream.EncodeZigZag32(-1)); + Assert.AreEqual(2, CodedOutputStream.EncodeZigZag32( 1)); + Assert.AreEqual(3, CodedOutputStream.EncodeZigZag32(-2)); + Assert.AreEqual(0x7FFFFFFE, CodedOutputStream.EncodeZigZag32(0x3FFFFFFF)); + Assert.AreEqual(0x7FFFFFFF, CodedOutputStream.EncodeZigZag32(unchecked((int)0xC0000000))); + Assert.AreEqual(0xFFFFFFFE, CodedOutputStream.EncodeZigZag32(0x7FFFFFFF)); + Assert.AreEqual(0xFFFFFFFF, CodedOutputStream.EncodeZigZag32(unchecked((int)0x80000000))); + } + + [Test] + public void EncodeZigZag64() { + Assert.AreEqual(0, CodedOutputStream.EncodeZigZag64( 0)); + Assert.AreEqual(1, CodedOutputStream.EncodeZigZag64(-1)); + Assert.AreEqual(2, CodedOutputStream.EncodeZigZag64( 1)); + Assert.AreEqual(3, CodedOutputStream.EncodeZigZag64(-2)); + Assert.AreEqual(0x000000007FFFFFFEL, + CodedOutputStream.EncodeZigZag64(unchecked((long)0x000000003FFFFFFFUL))); + Assert.AreEqual(0x000000007FFFFFFFL, + CodedOutputStream.EncodeZigZag64(unchecked((long)0xFFFFFFFFC0000000UL))); + Assert.AreEqual(0x00000000FFFFFFFEL, + CodedOutputStream.EncodeZigZag64(unchecked((long)0x000000007FFFFFFFUL))); + Assert.AreEqual(0x00000000FFFFFFFFL, + CodedOutputStream.EncodeZigZag64(unchecked((long)0xFFFFFFFF80000000UL))); + Assert.AreEqual(0xFFFFFFFFFFFFFFFEL, + CodedOutputStream.EncodeZigZag64(unchecked((long)0x7FFFFFFFFFFFFFFFUL))); + Assert.AreEqual(0xFFFFFFFFFFFFFFFFL, + CodedOutputStream.EncodeZigZag64(unchecked((long)0x8000000000000000UL))); + } + + [Test] + public void RoundTripZigZag32() { + // Some easier-to-verify round-trip tests. The inputs (other than 0, 1, -1) + // were chosen semi-randomly via keyboard bashing. + Assert.AreEqual(0, CodedInputStream.DecodeZigZag32(CodedOutputStream.EncodeZigZag32(0))); + Assert.AreEqual(1, CodedInputStream.DecodeZigZag32(CodedOutputStream.EncodeZigZag32(1))); + Assert.AreEqual(-1, CodedInputStream.DecodeZigZag32(CodedOutputStream.EncodeZigZag32(-1))); + Assert.AreEqual(14927, CodedInputStream.DecodeZigZag32(CodedOutputStream.EncodeZigZag32(14927))); + Assert.AreEqual(-3612, CodedInputStream.DecodeZigZag32(CodedOutputStream.EncodeZigZag32(-3612))); + } + + [Test] + public void RoundTripZigZag64() { + Assert.AreEqual(0, CodedInputStream.DecodeZigZag64(CodedOutputStream.EncodeZigZag64(0))); + Assert.AreEqual(1, CodedInputStream.DecodeZigZag64(CodedOutputStream.EncodeZigZag64(1))); + Assert.AreEqual(-1, CodedInputStream.DecodeZigZag64(CodedOutputStream.EncodeZigZag64(-1))); + Assert.AreEqual(14927, CodedInputStream.DecodeZigZag64(CodedOutputStream.EncodeZigZag64(14927))); + Assert.AreEqual(-3612, CodedInputStream.DecodeZigZag64(CodedOutputStream.EncodeZigZag64(-3612))); + + Assert.AreEqual(856912304801416L, CodedInputStream.DecodeZigZag64(CodedOutputStream.EncodeZigZag64(856912304801416L))); + Assert.AreEqual(-75123905439571256L, CodedInputStream.DecodeZigZag64(CodedOutputStream.EncodeZigZag64(-75123905439571256L))); + } + } +} diff --git a/csharp/ProtocolBuffers.Test/Properties/AssemblyInfo.cs b/csharp/ProtocolBuffers.Test/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..93ff802f --- /dev/null +++ b/csharp/ProtocolBuffers.Test/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +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("ProtocolBuffers.Test")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("ProtocolBuffers.Test")] +[assembly: AssemblyCopyright("Copyright © 2008")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. 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("54e627c3-daaa-4850-82cf-f25b7f097e78")] + +// 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 Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/csharp/ProtocolBuffers.Test/ProtocolBuffers.Test.csproj b/csharp/ProtocolBuffers.Test/ProtocolBuffers.Test.csproj new file mode 100644 index 00000000..89c5507a --- /dev/null +++ b/csharp/ProtocolBuffers.Test/ProtocolBuffers.Test.csproj @@ -0,0 +1,66 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <PropertyGroup> + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> + <ProductVersion>9.0.21022</ProductVersion> + <SchemaVersion>2.0</SchemaVersion> + <ProjectGuid>{DD01ED24-3750-4567-9A23-1DB676A15610}</ProjectGuid> + <OutputType>Library</OutputType> + <AppDesignerFolder>Properties</AppDesignerFolder> + <RootNamespace>Google.ProtocolBuffers</RootNamespace> + <AssemblyName>Google.ProtocolBuffers.Test</AssemblyName> + <TargetFrameworkVersion>v2.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>DEBUG;TRACE</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> + <DebugType>pdbonly</DebugType> + <Optimize>true</Optimize> + <OutputPath>bin\Release\</OutputPath> + <DefineConstants>TRACE</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + </PropertyGroup> + <ItemGroup> + <Reference Include="nunit.framework, Version=2.2.8.0, Culture=neutral, PublicKeyToken=96d09a1eb7f44a77"> + <SpecificVersion>False</SpecificVersion> + <HintPath>lib\nunit.framework.dll</HintPath> + </Reference> + <Reference Include="Rhino.Mocks, Version=3.5.0.2, Culture=neutral, PublicKeyToken=0b3305902db7183f, processorArchitecture=MSIL"> + <SpecificVersion>False</SpecificVersion> + <HintPath>lib\Rhino.Mocks.dll</HintPath> + </Reference> + <Reference Include="System" /> + <Reference Include="System.Data" /> + <Reference Include="System.Xml" /> + </ItemGroup> + <ItemGroup> + <Compile Include="ByteStringTest.cs" /> + <Compile Include="CodedInputStreamTest.cs" /> + <Compile Include="CodedOutputStreamTest.cs" /> + <Compile Include="Properties\AssemblyInfo.cs" /> + </ItemGroup> + <ItemGroup> + <ProjectReference Include="..\ProtocolBuffers\ProtocolBuffers.csproj"> + <Project>{6908BDCE-D925-43F3-94AC-A531E6DF2591}</Project> + <Name>ProtocolBuffers</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/csharp/ProtocolBuffers.Test/lib/Rhino.Mocks.dll b/csharp/ProtocolBuffers.Test/lib/Rhino.Mocks.dll Binary files differnew file mode 100644 index 00000000..16ff5e82 --- /dev/null +++ b/csharp/ProtocolBuffers.Test/lib/Rhino.Mocks.dll diff --git a/csharp/ProtocolBuffers.Test/lib/Rhino.Mocks.xml b/csharp/ProtocolBuffers.Test/lib/Rhino.Mocks.xml new file mode 100644 index 00000000..caace138 --- /dev/null +++ b/csharp/ProtocolBuffers.Test/lib/Rhino.Mocks.xml @@ -0,0 +1,5062 @@ +<?xml version="1.0"?> +<doc> + <assembly> + <name>Rhino.Mocks</name> + </assembly> + <members> + <member name="T:Rhino.Mocks.Constraints.AbstractConstraint"> + <summary> + Interface for constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.AbstractConstraint.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.AbstractConstraint.op_BitwiseAnd(Rhino.Mocks.Constraints.AbstractConstraint,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + And operator for constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.AbstractConstraint.op_LogicalNot(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Not operator for constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.AbstractConstraint.op_BitwiseOr(Rhino.Mocks.Constraints.AbstractConstraint,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Or operator for constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.AbstractConstraint.op_False(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Allow overriding of || or && + </summary> + <param name="c"></param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.AbstractConstraint.op_True(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Allow overriding of || or && + </summary> + <param name="c"></param> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.Constraints.AbstractConstraint.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.#ctor(System.Object)"> + <summary> + Initializes a new constraint object. + </summary> + <param name="expected">The expected object, The actual object is passed in as a parameter to the <see cref="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.Eval(System.Object)"/> method</param> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.Eval(System.Object)"> + <summary> + Evaluate this constraint. + </summary> + <param name="obj">The actual object that was passed in the method call to the mock.</param> + <returns>True when the constraint is met, else false.</returns> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.CheckReferenceType(System.Object,System.Object)"> + <summary> + Checks if the properties of the <paramref name="actual"/> object + are the same as the properies of the <paramref name="expected"/> object. + </summary> + <param name="expected">The expected object</param> + <param name="actual">The actual object</param> + <returns>True when both objects have the same values, else False.</returns> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.CheckValue(System.Object,System.Object)"> + <summary> + + </summary> + <param name="expected"></param> + <param name="actual"></param> + <returns></returns> + <remarks>This is the real heart of the beast.</remarks> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.CheckProperties(System.Object,System.Object)"> + <summary> + Used by CheckReferenceType to check all properties of the reference type. + </summary> + <param name="expected">The expected object</param> + <param name="actual">The actual object</param> + <returns>True when both objects have the same values, else False.</returns> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.CheckFields(System.Object,System.Object)"> + <summary> + Used by CheckReferenceType to check all fields of the reference type. + </summary> + <param name="expected">The expected object</param> + <param name="actual">The actual object</param> + <returns>True when both objects have the same values, else False.</returns> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.CheckCollection(System.Collections.IEnumerable,System.Collections.IEnumerable)"> + <summary> + Checks the items of both collections + </summary> + <param name="expectedCollection">The expected collection</param> + <param name="actualCollection"></param> + <returns>True if both collections contain the same items in the same order.</returns> + </member> + <member name="M:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.BuildPropertyName"> + <summary> + Builds a propertyname from the Stack _properties like 'Order.Product.Price' + to be used in the error message. + </summary> + <returns>A nested property name.</returns> + </member> + <member name="P:Rhino.Mocks.Constraints.AllPropertiesMatchConstraint.Message"> + <summary> + Rhino.Mocks uses this property to generate an error message. + </summary> + <value> + A message telling the tester why the constraint failed. + </value> + </member> + <member name="T:Rhino.Mocks.Constraints.PublicFieldIs"> + <summary> + Constrain that the public field has a specified value + </summary> + </member> + <member name="T:Rhino.Mocks.Constraints.PublicFieldConstraint"> + <summary> + Constrain that the public field matches another constraint. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicFieldConstraint.#ctor(System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PublicFieldConstraint"/> instance. + </summary> + <param name="publicFieldName">Name of the public field.</param> + <param name="constraint">Constraint to place on the public field value.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicFieldConstraint.#ctor(System.Type,System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PublicFieldConstraint"/> instance, specifying a disambiguating + <paramref name="declaringType"/> for the public field. + </summary> + <param name="declaringType">The type that declares the public field, used to disambiguate between public fields.</param> + <param name="publicFieldName">Name of the public field.</param> + <param name="constraint">Constraint to place on the public field value.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicFieldConstraint.Eval(System.Object)"> + <summary> + Determines if the object passes the constraint. + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.PublicFieldConstraint.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicFieldIs.#ctor(System.String,System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PublicFieldIs"/> instance. + </summary> + <param name="publicFieldName">Name of the public field.</param> + <param name="expectedValue">Expected value.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicFieldIs.#ctor(System.Type,System.String,System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PublicFieldIs"/> instance, specifying a disambiguating + <paramref name="declaringType"/> for the public field. + </summary> + <param name="declaringType">The type that declares the public field, used to disambiguate between public fields.</param> + <param name="publicFieldName">Name of the public field.</param> + <param name="expectedValue">Expected value.</param> + </member> + <member name="T:Rhino.Mocks.Constraints.PropertyIs"> + <summary> + Constrain that the property has a specified value + </summary> + </member> + <member name="T:Rhino.Mocks.Constraints.PropertyConstraint"> + <summary> + Constrain that the property matches another constraint. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.PropertyConstraint.#ctor(System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PropertyConstraint"/> instance. + </summary> + <param name="propertyName">Name of the property.</param> + <param name="constraint">Constraint to place on the property value.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PropertyConstraint.#ctor(System.Type,System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PropertyConstraint"/> instance, specifying a disambiguating + <paramref name="declaringType"/> for the property. + </summary> + <param name="declaringType">The type that declares the property, used to disambiguate between properties.</param> + <param name="propertyName">Name of the property.</param> + <param name="constraint">Constraint to place on the property value.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PropertyConstraint.Eval(System.Object)"> + <summary> + Determines if the object passes the constraint. + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.PropertyConstraint.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="M:Rhino.Mocks.Constraints.PropertyIs.#ctor(System.String,System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PropertyIs"/> instance. + </summary> + <param name="propertyName">Name of the property.</param> + <param name="expectedValue">Expected value.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PropertyIs.#ctor(System.Type,System.String,System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.PropertyIs"/> instance, specifying a disambiguating + <paramref name="declaringType"/> for the property. + </summary> + <param name="declaringType">The type that declares the property, used to disambiguate between properties.</param> + <param name="propertyName">Name of the property.</param> + <param name="expectedValue">Expected value.</param> + </member> + <member name="T:Rhino.Mocks.Constraints.TypeOf"> + <summary> + Constrain that the parameter must be of the specified type + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.TypeOf.#ctor(System.Type)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.TypeOf"/> instance. + </summary> + <param name="type">Type.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.TypeOf.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.TypeOf.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Same"> + <summary> + Constraint that determines whether an object is the same object as another. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Same.#ctor(System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.Equal"/> instance. + </summary> + <param name="obj">Obj.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Same.Eval(System.Object)"> + <summary> + Determines if the object passes the constraints. + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.Same.Message"> + <summary> + Gets the message for this constraint. + </summary> + </member> + <member name="T:Rhino.Mocks.Constraints.PredicateConstraint`1"> + <summary> + Evaluate a parameter using constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.PredicateConstraint`1.#ctor(System.Predicate{`0})"> + <summary> + Create new instance + </summary> + <param name="predicate"></param> + </member> + <member name="M:Rhino.Mocks.Constraints.PredicateConstraint`1.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.PredicateConstraint`1.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.LambdaConstraint"> + <summary> + A constraint based on lambda expression, we are using Expression{T} + because we want to be able to get good error reporting on that. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.LambdaConstraint.#ctor(System.Linq.Expressions.Expression)"> + <summary> + Initializes a new instance of the <see cref="T:Rhino.Mocks.Constraints.LambdaConstraint"/> class. + </summary> + <param name="expr">The expr.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.LambdaConstraint.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + <param name="obj"></param> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.Constraints.LambdaConstraint.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.CollectionEqual"> + <summary> + Constrain that the list contains the same items as the parameter list + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.CollectionEqual.#ctor(System.Collections.IEnumerable)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.CollectionEqual"/> instance. + </summary> + <param name="collection">In list.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.CollectionEqual.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.CollectionEqual.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.OneOf"> + <summary> + Constrain that the parameter is one of the items in the list + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.OneOf.#ctor(System.Collections.IEnumerable)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.OneOf"/> instance. + </summary> + <param name="collection">In list.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.OneOf.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.OneOf.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.IsIn"> + <summary> + Constrain that the object is inside the parameter list + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.IsIn.#ctor(System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.IsIn"/> instance. + </summary> + <param name="inList">In list.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsIn.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.IsIn.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.CollectionCount"> + <summary> + Applies another AbstractConstraint to the collection count. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.CollectionCount.#ctor(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.CollectionCount"/> instance. + </summary> + <param name="constraint">The constraint that should be applied to the collection count.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.CollectionCount.Eval(System.Object)"> + <summary> + Determines if the parameter conforms to this constraint. + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.CollectionCount.Message"> + <summary> + Gets the message for this constraint. + </summary> + </member> + <member name="T:Rhino.Mocks.Constraints.ListElement"> + <summary> + Applies another AbstractConstraint to a specific list element. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.ListElement.#ctor(System.Int32,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.ListElement"/> instance. + </summary> + <param name="index">The zero-based index of the list element.</param> + <param name="constraint">The constraint that should be applied to the list element.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.ListElement.Eval(System.Object)"> + <summary> + Determines if the parameter conforms to this constraint. + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.ListElement.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.ContainsAll"> + <summary> + Constrains that all elements are in the parameter list + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.ContainsAll.#ctor(System.Collections.IEnumerable)"> + <summary> + Initializes a new instance of the <see cref="T:Rhino.Mocks.Constraints.ContainsAll"/> class. + </summary> + <param name="these">The these.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.ContainsAll.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + <param name="obj"></param> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.Constraints.ContainsAll.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Or"> + <summary> + Combines two constraints, constraint pass if either is fine. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Or.#ctor(Rhino.Mocks.Constraints.AbstractConstraint,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.And"/> instance. + </summary> + <param name="c1">C1.</param> + <param name="c2">C2.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Or.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.Or.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Not"> + <summary> + Negate a constraint + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Not.#ctor(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.And"/> instance. + </summary> + <param name="c1">C1.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Not.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.Not.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.And"> + <summary> + Combines two constraints + </summary> + <remarks></remarks> + </member> + <member name="M:Rhino.Mocks.Constraints.And.#ctor(Rhino.Mocks.Constraints.AbstractConstraint,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.And"/> instance. + </summary> + <param name="c1">C1.</param> + <param name="c2">C2.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.And.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.And.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Like"> + <summary> + Constrain the argument to validate according to regex pattern + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Like.#ctor(System.String)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.Like"/> instance. + </summary> + <param name="pattern">Pattern.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Like.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.Like.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Contains"> + <summary> + Constraint that evaluate whatever an argument contains the specified string. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Contains.#ctor(System.String)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.Contains"/> instance. + </summary> + <param name="innerString">Inner string.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Contains.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.Contains.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.EndsWith"> + <summary> + Constraint that evaluate whatever an argument ends with the specified string + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.EndsWith.#ctor(System.String)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.EndsWith"/> instance. + </summary> + <param name="end">End.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.EndsWith.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.EndsWith.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.StartsWith"> + <summary> + Constraint that evaluate whatever an argument start with the specified string + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.StartsWith.#ctor(System.String)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.StartsWith"/> instance. + </summary> + <param name="start">Start.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.StartsWith.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.StartsWith.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Equal"> + <summary> + Constraint that evaluate whatever an object equals another + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Equal.#ctor(System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.Equal"/> instance. + </summary> + <param name="obj">Obj.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Equal.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.Equal.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Anything"> + <summary> + Constraint that always returns true + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Anything.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.Anything.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.ComparingConstraint"> + <summary> + Constraint that evaluate whatever a comparable is greater than another + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.ComparingConstraint.#ctor(System.IComparable,System.Boolean,System.Boolean)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Constraints.ComparingConstraint"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.ComparingConstraint.Eval(System.Object)"> + <summary> + determains if the object pass the constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Constraints.ComparingConstraint.Message"> + <summary> + Gets the message for this constraint + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Constraints.Is"> + <summary> + Central location for constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.GreaterThan(System.IComparable)"> + <summary> + Evaluate a greater than constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be greater than</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.LessThan(System.IComparable)"> + <summary> + Evaluate a less than constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be less than</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.LessThanOrEqual(System.IComparable)"> + <summary> + Evaluate a less than or equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be less than or equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.GreaterThanOrEqual(System.IComparable)"> + <summary> + Evaluate a greater than or equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be greater than or equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.Equal(System.Object)"> + <summary> + Evaluate an equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="obj">The object the parameter should equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.NotEqual(System.Object)"> + <summary> + Evaluate a not equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="obj">The object the parameter should not equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.Same(System.Object)"> + <summary> + Evaluate a same as constraint. + </summary> + <param name="obj">The object the parameter should the same as.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.NotSame(System.Object)"> + <summary> + Evaluate a not same as constraint. + </summary> + <param name="obj">The object the parameter should not be the same as.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.Anything"> + <summary> + A constraints that accept anything + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.Null"> + <summary> + A constraint that accept only nulls + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.NotNull"> + <summary> + A constraint that accept only non null values + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.TypeOf(System.Type)"> + <summary> + A constraint that accept only value of the specified type + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.TypeOf``1"> + <summary> + A constraint that accept only value of the specified type + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Is.Matching``1(System.Predicate{``0})"> + <summary> + Evaluate a parameter using a predicate + </summary> + <param name="predicate">The predicate to use</param> + </member> + <member name="T:Rhino.Mocks.Constraints.IsArg`1"> + <summary> + Provides access to the constraintes defined in the class <see cref="T:Rhino.Mocks.Constraints.Is"/> to be used in context + with the <see cref="T:Rhino.Mocks.Arg`1"/> syntax. + </summary> + <typeparam name="T">The type of the argument</typeparam> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.GreaterThan(System.IComparable)"> + <summary> + Evaluate a greater than constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be greater than</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.LessThan(System.IComparable)"> + <summary> + Evaluate a less than constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be less than</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.LessThanOrEqual(System.IComparable)"> + <summary> + Evaluate a less than or equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be less than or equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.GreaterThanOrEqual(System.IComparable)"> + <summary> + Evaluate a greater than or equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="objToCompare">The object the parameter should be greater than or equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.Equal(System.Object)"> + <summary> + Evaluate an equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="obj">The object the parameter should equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.NotEqual(System.Object)"> + <summary> + Evaluate a not equal constraint for <see cref="T:System.IComparable"/>. + </summary> + <param name="obj">The object the parameter should not equal to</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.Same(System.Object)"> + <summary> + Evaluate a same as constraint. + </summary> + <param name="obj">The object the parameter should the same as.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.NotSame(System.Object)"> + <summary> + Evaluate a not same as constraint. + </summary> + <param name="obj">The object the parameter should not be the same as.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.Equals(System.Object)"> + <summary> + Throws NotSupportedException. Don't use Equals to define constraints. Use Equal instead. + </summary> + <param name="obj"></param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.IsArg`1.GetHashCode"> + <summary> + Serves as a hash function for a particular type. + </summary> + <returns> + A hash code for the current <see cref="T:System.Object"/>. + </returns> + </member> + <member name="P:Rhino.Mocks.Constraints.IsArg`1.Anything"> + <summary> + A constraints that accept anything + </summary> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.Constraints.IsArg`1.Null"> + <summary> + A constraint that accept only nulls + </summary> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.Constraints.IsArg`1.NotNull"> + <summary> + A constraint that accept only non null values + </summary> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.Constraints.IsArg`1.TypeOf"> + <summary> + A constraint that accept only value of the specified type. + The check is performed on the type that has been defined + as the argument type. + </summary> + </member> + <member name="T:Rhino.Mocks.Constraints.List"> + <summary> + Central location for constraints about lists and collections + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.List.IsIn(System.Object)"> + <summary> + Determines whether the specified obj is in the paramter. + The parameter must be IEnumerable. + </summary> + <param name="obj">Obj.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.List.OneOf(System.Collections.IEnumerable)"> + <summary> + Determains whatever the parameter is in the collection. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.List.Equal(System.Collections.IEnumerable)"> + <summary> + Determains that the parameter collection is identical to the specified collection + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.List.Count(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Determines that the parameter collection has the specified number of elements. + </summary> + <param name="constraint">The constraint that should be applied to the collection count.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.List.Element(System.Int32,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Determines that an element of the parameter collections conforms to another AbstractConstraint. + </summary> + <param name="index">The zero-based index of the list element.</param> + <param name="constraint">The constraint which should be applied to the list element.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.List.ContainsAll(System.Collections.IEnumerable)"> + <summary> + Determines that all elements of the specified collection are in the the parameter collection + </summary> + <param name="collection">The collection to compare against</param> + <returns>The constraint which should be applied to the list parameter.</returns> + </member> + <member name="T:Rhino.Mocks.Constraints.ListArg`1"> + <summary> + Provides access to the constraintes defined in the class <see cref="T:Rhino.Mocks.Constraints.Text"/> to be used in context + with the <see cref="T:Rhino.Mocks.Arg`1"/> syntax. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.IsIn(System.Object)"> + <summary> + Determines whether the specified object is in the paramter. + The parameter must be IEnumerable. + </summary> + <param name="obj">Obj.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.OneOf(System.Collections.IEnumerable)"> + <summary> + Determains whatever the parameter is in the collection. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.Equal(System.Collections.IEnumerable)"> + <summary> + Determains that the parameter collection is identical to the specified collection + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.Count(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Determines that the parameter collection has the specified number of elements. + </summary> + <param name="constraint">The constraint that should be applied to the collection count.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.Element(System.Int32,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Determines that an element of the parameter collections conforms to another AbstractConstraint. + </summary> + <param name="index">The zero-based index of the list element.</param> + <param name="constraint">The constraint which should be applied to the list element.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.ContainsAll(System.Collections.IEnumerable)"> + <summary> + Determines that all elements of the specified collection are in the the parameter collection + </summary> + <param name="collection">The collection to compare against</param> + <returns>The constraint which should be applied to the list parameter.</returns> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.Equals(System.Object)"> + <summary> + Throws NotSupportedException. Don't use Equals to define constraints. Use Equal instead. + </summary> + <param name="obj"></param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.ListArg`1.GetHashCode"> + <summary> + Serves as a hash function for a particular type. + </summary> + <returns> + A hash code for the current <see cref="T:System.Object"/>. + </returns> + </member> + <member name="T:Rhino.Mocks.Constraints.OutRefArgDummy`1"> + <summary> + Provides a dummy field to pass as out or ref argument. + </summary> + <typeparam name="T"></typeparam> + </member> + <member name="F:Rhino.Mocks.Constraints.OutRefArgDummy`1.Dummy"> + <summary> + Dummy field to satisfy the compiler. Used for out and ref arguments. + </summary> + </member> + <member name="T:Rhino.Mocks.Constraints.Property"> + <summary> + Central location for constraints for object's properties + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.Value(System.String,System.Object)"> + <summary> + Constrains the parameter to have property with the specified value + </summary> + <param name="propertyName">Name of the property.</param> + <param name="expectedValue">Expected value.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.Value(System.Type,System.String,System.Object)"> + <summary> + Constrains the parameter to have property with the specified value. + </summary> + <param name="declaringType">The type that declares the property, used to disambiguate between properties.</param> + <param name="propertyName">Name of the property.</param> + <param name="expectedValue">Expected value.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.ValueConstraint(System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Constrains the parameter to have a property satisfying a specified constraint. + </summary> + <param name="propertyName">Name of the property.</param> + <param name="propertyConstraint">Constraint for the property.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.ValueConstraint(System.Type,System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Constrains the parameter to have a property satisfying a specified constraint. + </summary> + <param name="declaringType">The type that declares the property, used to disambiguate between properties.</param> + <param name="propertyName">Name of the property.</param> + <param name="propertyConstraint">Constraint for the property.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.IsNull(System.String)"> + <summary> + Determines whether the parameter has the specified property and that it is null. + </summary> + <param name="propertyName">Name of the property.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.IsNull(System.Type,System.String)"> + <summary> + Determines whether the parameter has the specified property and that it is null. + </summary> + <param name="declaringType">The type that declares the property, used to disambiguate between properties.</param> + <param name="propertyName">Name of the property.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.IsNotNull(System.String)"> + <summary> + Determines whether the parameter has the specified property and that it is not null. + </summary> + <param name="propertyName">Name of the property.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.IsNotNull(System.Type,System.String)"> + <summary> + Determines whether the parameter has the specified property and that it is not null. + </summary> + <param name="declaringType">The type that declares the property, used to disambiguate between properties.</param> + <param name="propertyName">Name of the property.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.Property.AllPropertiesMatch(System.Object)"> + <summary> + constraints the parameter to have the exact same property values as the expected object. + </summary> + <param name="expected">An object, of the same type as the parameter, whose properties are set with the expected values.</param> + <returns>An instance of the constraint that will do the actual check.</returns> + <remarks> + The parameter's public property values and public field values will be matched against the expected object's + public property values and public field values. The first mismatch will be reported and no further matching is done. + The matching is recursive for any property or field that has properties or fields of it's own. + Collections are supported through IEnumerable, which means the constraint will check if the actual and expected + collection contain the same values in the same order, where the values contained by the collection can have properties + and fields of their own that will be checked as well because of the recursive nature of this constraint. + </remarks> + </member> + <member name="T:Rhino.Mocks.Constraints.PublicField"> + <summary> + Central location for constraints for object's public fields + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.Value(System.String,System.Object)"> + <summary> + Constrains the parameter to have a public field with the specified value + </summary> + <param name="publicFieldName">Name of the public field.</param> + <param name="expectedValue">Expected value.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.Value(System.Type,System.String,System.Object)"> + <summary> + Constrains the parameter to have a public field with the specified value. + </summary> + <param name="declaringType">The type that declares the public field, used to disambiguate between public fields.</param> + <param name="publicFieldName">Name of the public field.</param> + <param name="expectedValue">Expected value.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.ValueConstraint(System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Constrains the parameter to have a public field satisfying a specified constraint. + </summary> + <param name="publicFieldName">Name of the public field.</param> + <param name="publicFieldConstraint">Constraint for the public field.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.ValueConstraint(System.Type,System.String,Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Constrains the parameter to have a public field satisfying a specified constraint. + </summary> + <param name="declaringType">The type that declares the public field, used to disambiguate between public fields.</param> + <param name="publicFieldName">Name of the public field.</param> + <param name="publicFieldConstraint">Constraint for the public field.</param> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.IsNull(System.String)"> + <summary> + Determines whether the parameter has the specified public field and that it is null. + </summary> + <param name="publicFieldName">Name of the public field.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.IsNull(System.Type,System.String)"> + <summary> + Determines whether the parameter has the specified public field and that it is null. + </summary> + <param name="declaringType">The type that declares the public field, used to disambiguate between public fields.</param> + <param name="publicFieldName">Name of the public field.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.IsNotNull(System.String)"> + <summary> + Determines whether the parameter has the specified public field and that it is not null. + </summary> + <param name="publicFieldName">Name of the public field.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.PublicField.IsNotNull(System.Type,System.String)"> + <summary> + Determines whether the parameter has the specified public field and that it is not null. + </summary> + <param name="declaringType">The type that declares the public field, used to disambiguate between public fields.</param> + <param name="publicFieldName">Name of the public field.</param> + <returns></returns> + </member> + <member name="T:Rhino.Mocks.Constraints.Text"> + <summary> + Central location for all text related constraints + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Text.StartsWith(System.String)"> + <summary> + Constrain the argument to starts with the specified string + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Text.EndsWith(System.String)"> + <summary> + Constrain the argument to end with the specified string + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Text.Contains(System.String)"> + <summary> + Constrain the argument to contain the specified string + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.Text.Like(System.String)"> + <summary> + Constrain the argument to validate according to regex pattern + </summary> + </member> + <member name="T:Rhino.Mocks.Constraints.TextArg"> + <summary> + Provides access to the constraintes defined in the class <see cref="T:Rhino.Mocks.Constraints.Text"/> to be used in context + with the <see cref="T:Rhino.Mocks.Arg"/> syntax. + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.TextArg.StartsWith(System.String)"> + <summary> + Constrain the argument to starts with the specified string + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.TextArg.EndsWith(System.String)"> + <summary> + Constrain the argument to end with the specified string + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.TextArg.Contains(System.String)"> + <summary> + Constrain the argument to contain the specified string + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.TextArg.Like(System.String)"> + <summary> + Constrain the argument to validate according to regex pattern + </summary> + </member> + <member name="M:Rhino.Mocks.Constraints.TextArg.Equals(System.Object)"> + <summary> + Throws NotSupportedException. Don't use Equals to define constraints. Use Equal instead. + </summary> + <param name="obj"></param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Constraints.TextArg.GetHashCode"> + <summary> + Serves as a hash function for a particular type. + </summary> + <returns> + A hash code for the current <see cref="T:System.Object"/>. + </returns> + </member> + <member name="T:Rhino.Mocks.Exceptions.ExpectationViolationException"> + <summary> + An expectaton violation was detected. + </summary> + </member> + <member name="M:Rhino.Mocks.Exceptions.ExpectationViolationException.#ctor(System.String)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Exceptions.ExpectationViolationException"/> instance. + </summary> + <param name="message">Message.</param> + </member> + <member name="M:Rhino.Mocks.Exceptions.ExpectationViolationException.#ctor(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)"> + <summary> + Serialization constructor + </summary> + </member> + <member name="T:Rhino.Mocks.Exceptions.ObjectNotMockFromThisRepositoryException"> + <summary> + Signals that an object was call on a mock repostiroy which doesn't + belong to this mock repository or not a mock + </summary> + </member> + <member name="M:Rhino.Mocks.Exceptions.ObjectNotMockFromThisRepositoryException.#ctor(System.String)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Exceptions.ObjectNotMockFromThisRepositoryException"/> instance. + </summary> + <param name="message">Message.</param> + </member> + <member name="M:Rhino.Mocks.Exceptions.ObjectNotMockFromThisRepositoryException.#ctor(System.Runtime.Serialization.SerializationInfo,System.Runtime.Serialization.StreamingContext)"> + <summary> + Serialization constructor + </summary> + </member> + <member name="T:Rhino.Mocks.Expectations.AbstractExpectation"> + <summary> + Abstract class that holds common information for + expectations. + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IExpectation"> + <summary> + Interface to validate that a method call is correct. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IExpectation.IsExpected(System.Object[])"> + <summary> + Validate the arguments for the method. + This method can be called numerous times, so be careful about side effects + </summary> + <param name="args">The arguments with which the method was called</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IExpectation.AddActualCall"> + <summary> + Add an actual method call to this expectation + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IExpectation.ReturnOrThrow(Castle.Core.Interceptor.IInvocation,System.Object[])"> + <summary> + Returns the return value or throw the exception and setup any output / ref parameters + that has been set. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IExpectation.IgnoreMissingReturnValueUntilExecuteTime"> + <summary> + Allow to set the return value in the future, if it was already set. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.ErrorMessage"> + <summary> + Gets the error message. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.Expected"> + <summary> + Range of expected calls + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.ActualCallsCount"> + <summary> + Number of call actually made for this method + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.CanAcceptCalls"> + <summary> + If this expectation is still waiting for calls. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.ReturnValue"> + <summary> + The return value for a method matching this expectation + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.ExceptionToThrow"> + <summary> + Gets or sets the exception to throw on a method matching this expectation. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.ActionsSatisfied"> + <summary> + Gets a value indicating whether this instance's action is staisfied. + A staisfied instance means that there are no more requirements from + this method. A method with non void return value must register either + a return value or an exception to throw. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.Method"> + <summary> + Gets the method this expectation is for. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.RepeatableOption"> + <summary> + Gets or sets what special condtions there are for this method + repeating. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.ExpectationSatisfied"> + <summary> + Gets a value indicating whether this expectation was satisfied + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.HasReturnValue"> + <summary> + Specify whatever this expectation has a return value set + You can't check ReturnValue for this because a valid return value include null. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.ActionToExecute"> + <summary> + An action to execute when the method is matched. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.OutRefParams"> + <summary> + Set the out / ref parameters for the method call. + The indexing is zero based and ignores any non out/ref parameter. + It is possible not to pass all the parameters. This method can be called only once. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.Message"> + <summary> + Documentation Message + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IExpectation.Originalinvocation"> + <summary> + Gets the invocation for this expectation + </summary> + <value>The invocation.</value> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.actualCallsCount"> + <summary> + Number of actuall calls made that passed this expectation + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.expected"> + <summary> + Range of expected calls that should pass this expectation. + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.returnValue"> + <summary> + The return value for a method matching this expectation + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.exceptionToThrow"> + <summary> + The exception to throw on a method matching this expectation. + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.method"> + <summary> + The method this expectation is for. + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.returnValueSet"> + <summary> + The return value for this method was set + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.repeatableOption"> + <summary> + Whether this method will repeat + unlimited number of times. + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.actionToExecute"> + <summary> + A delegate that will be run when the + expectation is matched. + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.matchingArgs"> + <summary> + The arguments that matched this expectation. + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.message"> + <summary> + Documentation message + </summary> + </member> + <member name="F:Rhino.Mocks.Expectations.AbstractExpectation.originalInvocation"> + <summary> + The method originalInvocation + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.GetHashCode"> + <summary> + Get the hash code + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.AddActualCall"> + <summary> + Add an actual actualMethodCall call to this expectation + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.IgnoreMissingReturnValueUntilExecuteTime"> + <summary> + Allow to set the return value in the future, if it was already set. + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.ReturnOrThrow(Castle.Core.Interceptor.IInvocation,System.Object[])"> + <summary> + Returns the return value or throw the exception and setup output / ref parameters + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.IsExpected(System.Object[])"> + <summary> + Validate the arguments for the method on the child methods + </summary> + <param name="args">The arguments with which the method was called</param> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.#ctor(Castle.Core.Interceptor.IInvocation)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.AbstractExpectation"/> instance. + </summary> + <param name="invocation">The originalInvocation for this method, required because it contains the generic type infromation</param> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.#ctor(Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.AbstractExpectation"/> instance. + </summary> + <param name="expectation">Expectation.</param> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.DoIsExpected(System.Object[])"> + <summary> + Validate the arguments for the method on the child methods + </summary> + <param name="args">The arguments with which the method was called</param> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.Equals(System.Object)"> + <summary> + Determines if this object equal to obj + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.CreateErrorMessage(System.String)"> + <summary> + The error message for these arguments + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AbstractExpectation.AssertDelegateArgumentsMatchMethod(System.Delegate)"> + <summary> + Asserts that the delegate has the same parameters as the expectation's method call + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.OutRefParams"> + <summary> + Setter for the outpur / ref parameters for this expecataion. + Can only be set once. + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.HasReturnValue"> + <summary> + Specify whatever this expectation has a return value set + You can't check ReturnValue for this because a valid return value include null. + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.Method"> + <summary> + Gets the method this expectation is for. + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.Originalinvocation"> + <summary> + Gets the originalInvocation for this expectation + </summary> + <value>The originalInvocation.</value> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.RepeatableOption"> + <summary> + Gets or sets what special condtions there are for this method + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.Expected"> + <summary> + Range of expected calls + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.ActualCallsCount"> + <summary> + Number of call actually made for this method + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.CanAcceptCalls"> + <summary> + If this expectation is still waiting for calls. + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.ExpectationSatisfied"> + <summary> + Gets a value indicating whether this expectation was satisfied + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.ReturnValue"> + <summary> + The return value for a method matching this expectation + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.ActionToExecute"> + <summary> + An action to execute when the method is matched. + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.ExceptionToThrow"> + <summary> + Gets or sets the exception to throw on a method matching this expectation. + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.ActionsSatisfied"> + <summary> + Gets a value indicating whether this instance's action is staisfied. + A staisfied instance means that there are no more requirements from + this method. A method with non void return value must register either + a return value or an exception to throw or an action to execute. + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.Message"> + <summary> + Documentation message + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AbstractExpectation.ErrorMessage"> + <summary> + Gets the error message. + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Expectations.AnyArgsExpectation"> + <summary> + Expectation that matchs any arguments for the method. + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AnyArgsExpectation.#ctor(Castle.Core.Interceptor.IInvocation)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.AnyArgsExpectation"/> instance. + </summary> + <param name="invocation">Invocation for this expectation</param> + </member> + <member name="M:Rhino.Mocks.Expectations.AnyArgsExpectation.#ctor(Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.AnyArgsExpectation"/> instance. + </summary> + <param name="expectation">Expectation.</param> + </member> + <member name="M:Rhino.Mocks.Expectations.AnyArgsExpectation.DoIsExpected(System.Object[])"> + <summary> + Validate the arguments for the method. + </summary> + <param name="args">The arguments with which the method was called</param> + </member> + <member name="M:Rhino.Mocks.Expectations.AnyArgsExpectation.Equals(System.Object)"> + <summary> + Determines if the object equal to expectation + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.AnyArgsExpectation.GetHashCode"> + <summary> + Get the hash code + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.AnyArgsExpectation.ErrorMessage"> + <summary> + Gets the error message. + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Expectations.ArgsEqualExpectation"> + <summary> + Summary description for ArgsEqualExpectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.ArgsEqualExpectation.#ctor(Castle.Core.Interceptor.IInvocation,System.Object[])"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.ArgsEqualExpectation"/> instance. + </summary> + <param name="expectedArgs">Expected args.</param> + <param name="invocation">The invocation for this expectation</param> + </member> + <member name="M:Rhino.Mocks.Expectations.ArgsEqualExpectation.DoIsExpected(System.Object[])"> + <summary> + Validate the arguments for the method. + </summary> + <param name="args">The arguments with which the method was called</param> + </member> + <member name="M:Rhino.Mocks.Expectations.ArgsEqualExpectation.Equals(System.Object)"> + <summary> + Determines if the object equal to expectation + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.ArgsEqualExpectation.GetHashCode"> + <summary> + Get the hash code + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.ArgsEqualExpectation.ErrorMessage"> + <summary> + Gets the error message. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.Expectations.ArgsEqualExpectation.ExpectedArgs"> + <summary> + Get the expected args. + </summary> + </member> + <member name="T:Rhino.Mocks.Expectations.CallbackExpectation"> + <summary> + Call a specified callback to verify the expectation + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.CallbackExpectation.#ctor(Rhino.Mocks.Interfaces.IExpectation,System.Delegate)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.CallbackExpectation"/> instance. + </summary> + <param name="expectation">Expectation.</param> + <param name="callback">Callback.</param> + </member> + <member name="M:Rhino.Mocks.Expectations.CallbackExpectation.#ctor(Castle.Core.Interceptor.IInvocation,System.Delegate)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.CallbackExpectation"/> instance. + </summary> + <param name="invocation">Invocation for this expectation</param> + <param name="callback">Callback.</param> + </member> + <member name="M:Rhino.Mocks.Expectations.CallbackExpectation.DoIsExpected(System.Object[])"> + <summary> + Validate the arguments for the method on the child methods + </summary> + <param name="args">The arguments with which the method was called</param> + </member> + <member name="M:Rhino.Mocks.Expectations.CallbackExpectation.Equals(System.Object)"> + <summary> + Determines if the object equal to expectation + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.CallbackExpectation.GetHashCode"> + <summary> + Get the hash code + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.CallbackExpectation.ErrorMessage"> + <summary> + Gets the error message. + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Expectations.ConstraintsExpectation"> + <summary> + Expect the method's arguments to match the contraints + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.ConstraintsExpectation.#ctor(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Constraints.AbstractConstraint[])"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.ConstraintsExpectation"/> instance. + </summary> + <param name="invocation">Invocation for this expectation</param> + <param name="constraints">Constraints.</param> + </member> + <member name="M:Rhino.Mocks.Expectations.ConstraintsExpectation.#ctor(Rhino.Mocks.Interfaces.IExpectation,Rhino.Mocks.Constraints.AbstractConstraint[])"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Expectations.ConstraintsExpectation"/> instance. + </summary> + <param name="expectation">Expectation.</param> + <param name="constraints">Constraints.</param> + </member> + <member name="M:Rhino.Mocks.Expectations.ConstraintsExpectation.DoIsExpected(System.Object[])"> + <summary> + Validate the arguments for the method. + </summary> + <param name="args">The arguments with which the method was called</param> + </member> + <member name="M:Rhino.Mocks.Expectations.ConstraintsExpectation.Equals(System.Object)"> + <summary> + Determines if the object equal to expectation + </summary> + </member> + <member name="M:Rhino.Mocks.Expectations.ConstraintsExpectation.GetHashCode"> + <summary> + Get the hash code + </summary> + </member> + <member name="P:Rhino.Mocks.Expectations.ConstraintsExpectation.ErrorMessage"> + <summary> + Gets the error message. + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Generated.ExpectationsList"> + <summary> + ExpectationsList + </summary> + </member> + <member name="T:Rhino.Mocks.Generated.ProxyMethodExpectationsDictionary"> + <summary> + Dictionary + </summary> + </member> + <member name="T:Rhino.Mocks.Generated.ProxyStateDictionary"> + <summary> + Dictionary class + </summary> + </member> + <member name="M:Rhino.Mocks.Generated.ProxyStateDictionary.#ctor"> + <summary> + Create a new instance of <c>ProxyStateDictionary</c> + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.RemotingMock.IRemotingProxyOperation"> + <summary> + Operation on a remoting proxy + </summary> + <remarks> + It is not possible to directly communicate to a real proxy via transparent proxy. + Transparent proxy impersonates a user type and only methods of that user type are callable. + The only methods that are guaranteed to exist on any transparent proxy are methods defined + in Object: namely ToString(), GetHashCode(), and Equals()). + + These three methods are the only way to tell the real proxy to do something. + Equals() is the most suitable of all, since it accepts an arbitrary object parameter. + The RemotingProxy code is built so that if it is compared to an IRemotingProxyOperation, + transparentProxy.Equals(operation) will call operation.Process(realProxy). + This way we can retrieve a real proxy from transparent proxy and perform + arbitrary operation on it. + </remarks> + </member> + <member name="T:Rhino.Mocks.Impl.RemotingMock.RemotingInvocation"> + <summary> + Implementation of IInvocation based on remoting proxy + </summary> + <remarks>Some methods are marked NotSupported since they either don't make sense + for remoting proxies, or they are never called by Rhino Mocks</remarks> + </member> + <member name="T:Rhino.Mocks.Impl.RemotingMock.RemotingMockGenerator"> + <summary> + Generates remoting proxies and provides utility functions + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RemotingMock.RemotingMockGenerator.CreateRemotingMock(System.Type,Castle.Core.Interceptor.IInterceptor,Rhino.Mocks.Interfaces.IMockedObject)"> + <summary> + Create the proxy using remoting + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RemotingMock.RemotingMockGenerator.IsRemotingProxy(System.Object)"> + <summary> + Check whether an object is a transparent proxy with a RemotingProxy behind it + </summary> + <param name="obj">Object to check</param> + <returns>true if the object is a transparent proxy with a RemotingProxy instance behind it, false otherwise</returns> + <remarks>We use Equals() method to communicate with the real proxy behind the object. + See IRemotingProxyOperation for more details</remarks> + </member> + <member name="M:Rhino.Mocks.Impl.RemotingMock.RemotingMockGenerator.GetMockedObjectFromProxy(System.Object)"> + <summary> + Retrieve a mocked object from a transparent proxy + </summary> + <param name="proxy">Transparent proxy with a RemotingProxy instance behind it</param> + <returns>Mocked object associated with the proxy</returns> + <remarks>We use Equals() method to communicate with the real proxy behind the object. + See IRemotingProxyOperation for more details</remarks> + </member> + <member name="T:Rhino.Mocks.Impl.CreateMethodExpectation"> + <summary> + Allows to call a method and immediatly get it's options. + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.ICreateMethodExpectation"> + <summary> + Interface to allows to call a method and immediatly get it's options. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.ICreateMethodExpectation.Call``1(``0)"> + <summary> + Get the method options for the call + </summary> + <param name="ignored">The method call should go here, the return value is ignored</param> + </member> + <member name="M:Rhino.Mocks.Impl.CreateMethodExpectation.#ctor(Rhino.Mocks.Interfaces.IMockedObject,System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.CreateMethodExpectation"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.CreateMethodExpectation.Call``1(``0)"> + <summary> + Get the method options for the call + </summary> + <param name="ignored">The method call should go here, the return value is ignored</param> + </member> + <member name="T:Rhino.Mocks.Impl.CreateMethodExpectationForSetupResult"> + <summary> + Allows to call a method and immediatly get it's options. + Set the expected number for the call to Any() + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.CreateMethodExpectationForSetupResult.#ctor(Rhino.Mocks.Interfaces.IMockedObject,System.Object)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.CreateMethodExpectationForSetupResult"/> instance. + </summary> + <param name="mockedObject">Proxy.</param> + <param name="mockedInstance">Mocked instance.</param> + </member> + <member name="M:Rhino.Mocks.Impl.CreateMethodExpectationForSetupResult.Call``1(``0)"> + <summary> + Get the method options for the call + </summary> + <param name="ignored">The method call should go here, the return value is ignored</param> + </member> + <member name="T:Rhino.Mocks.Impl.DelegateTargetInterfaceCreator"> + <summary> + This class is reponsible for taking a delegate and creating a wrapper + interface around it, so it can be mocked. + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.DelegateTargetInterfaceCreator.moduleScope"> + <summary> + The scope for all the delegate interfaces create by this mock repositroy. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.DelegateTargetInterfaceCreator.GetDelegateTargetInterface(System.Type)"> + <summary> + Gets a type with an "Invoke" method suitable for use as a target of the + specified delegate type. + </summary> + <param name="delegateType"></param> + <returns></returns> + </member> + <member name="T:Rhino.Mocks.Impl.EventRaiser"> + <summary> + Raise events for all subscribers for an event + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IEventRaiser"> + <summary> + Raise events for all subscribers for an event + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IEventRaiser.Raise(System.Object[])"> + <summary> + Raise the event + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IEventRaiser.Raise(System.Object,System.EventArgs)"> + <summary> + The most common form for the event handler signature + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.EventRaiser.Create(System.Object,System.String)"> + <summary> + Create an event raise for the specified event on this instance. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.EventRaiser.#ctor(Rhino.Mocks.Interfaces.IMockedObject,System.String)"> + <summary> + Creates a new instance of <c>EventRaiser</c> + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.EventRaiser.Raise(System.Object[])"> + <summary> + Raise the event + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.EventRaiser.Raise(System.Object,System.EventArgs)"> + <summary> + The most common signature for events + Here to allow intellisense to make better guesses about how + it should suggest parameters. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.MethodOptions`1"> + <summary> + Allows to define what would happen when a method + is called. + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IMethodOptions`1"> + <summary> + Allows to define what would happen when a method + is called. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Return(`0)"> + <summary> + Set the return value for the method. + </summary> + <param name="objToReturn">The object the method will return</param> + <returns>IRepeat that defines how many times the method will return this value</returns> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.TentativeReturn"> + <summary> + Allow to override this return value in the future + </summary> + <returns>IRepeat that defines how many times the method will return this value</returns> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Throw(System.Exception)"> + <summary> + Throws the specified exception when the method is called. + </summary> + <param name="exception">Exception to throw</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.IgnoreArguments"> + <summary> + Ignores the arguments for this method. Any argument will be matched + againt this method. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Constraints(Rhino.Mocks.Constraints.AbstractConstraint[])"> + <summary> + Add constraints for the method's arguments. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback(System.Delegate)"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback(Rhino.Mocks.Delegates.Function{System.Boolean})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``1(Rhino.Mocks.Delegates.Function{System.Boolean,``0})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``2(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``3(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``4(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``5(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``6(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``7(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``8(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``9(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7,``8})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Callback``10(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7,``8,``9})"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Do(System.Delegate)"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.CallOriginalMethod"> + <summary> + Call the original method on the class, bypassing the mocking layers. + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.CallOriginalMethod(Rhino.Mocks.Interfaces.OriginalCallOptions)"> + <summary> + Call the original method on the class, optionally bypassing the mocking layers. + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.PropertyBehavior"> + <summary> + Use the property as a simple property, getting/setting the values without + causing mock expectations. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.GetEventRaiser"> + <summary> + Get an event raiser for the last subscribed event. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.OutRef(System.Object[])"> + <summary> + Set the parameter values for out and ref parameters. + This is done using zero based indexing, and _ignoring_ any non out/ref parameter. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodOptions`1.Message(System.String)"> + <summary> + Documentation message for the expectation + </summary> + <param name="documentationMessage">Message</param> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMethodOptions`1.Repeat"> + <summary> + Better syntax to define repeats. + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IRepeat`1"> + <summary> + Allows to specify the number of time for method calls + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IRepeat`1.Twice"> + <summary> + Repeat the method twice. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IRepeat`1.Once"> + <summary> + Repeat the method once. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IRepeat`1.AtLeastOnce"> + <summary> + Repeat the method at least once, then repeat as many time as it would like. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IRepeat`1.Any"> + <summary> + Repeat the method any number of times. + This has special affects in that this method would now ignore orderring. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IRepeat`1.Times(System.Int32,System.Int32)"> + <summary> + Set the range to repeat an action. + </summary> + <param name="min">Min.</param> + <param name="max">Max.</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IRepeat`1.Times(System.Int32)"> + <summary> + Set the amount of times to repeat an action. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IRepeat`1.Never"> + <summary> + This method must not appear in the replay state. + This has special affects in that this method would now ignore orderring. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.#ctor(Rhino.Mocks.MockRepository,Rhino.Mocks.Impl.RecordMockState,Rhino.Mocks.Interfaces.IMockedObject,Rhino.Mocks.Interfaces.IExpectation,System.Boolean)"> + <summary> + Creates a new <see cref="T:MethodOptions`1"/> instance. + </summary> + <param name="repository">the repository for this expectation</param> + <param name="record">the recorder for this proxy</param> + <param name="proxy">the proxy for this expectation</param> + <param name="expectation">Expectation.</param> + <param name="expectationReplacable">If the expectation still can be replaced by a Constraint call</param> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Constraints(Rhino.Mocks.Constraints.AbstractConstraint[])"> + <summary> + Add constraints for the method's arguments. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback(System.Delegate)"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback(Rhino.Mocks.Delegates.Function{System.Boolean})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``1(Rhino.Mocks.Delegates.Function{System.Boolean,``0})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``2(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``3(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``4(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``5(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``6(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``7(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``8(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``9(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7,``8})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Callback``10(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7,``8,``9})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Do(System.Delegate)"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Return(`0)"> + <summary> + Set the return value for the method. + </summary> + <param name="objToReturn">The object the method will return</param> + <returns>IRepeat that defines how many times the method will return this value</returns> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.TentativeReturn"> + <summary> + Set the return value for the method, but allow to override this return value in the future + </summary> + <returns>IRepeat that defines how many times the method will return this value</returns> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Throw(System.Exception)"> + <summary> + Throws the specified exception when the method is called. + </summary> + <param name="exception">Exception to throw</param> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.IgnoreArguments"> + <summary> + Ignores the arguments for this method. Any argument will be matched + againt this method. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.CallOriginalMethod"> + <summary> + Call the original method on the class, bypassing the mocking layers. + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.CallOriginalMethod(Rhino.Mocks.Interfaces.OriginalCallOptions)"> + <summary> + Call the original method on the class, optionally bypassing the mocking layers + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.PropertyBehavior"> + <summary> + Use the property as a simple property, getting/setting the values without + causing mock expectations. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.GetEventRaiser"> + <summary> + Gets the event raiser for the last event + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.OutRef(System.Object[])"> + <summary> + Set the parameter values for out and ref parameters. + This is done using zero based indexing, and _ignoring_ any non out/ref parameter. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Twice"> + <summary> + Repeat the method twice. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Once"> + <summary> + Repeat the method once. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.AtLeastOnce"> + <summary> + Repeat the method at least once, then repeat as many time as it would like. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Never"> + <summary> + This method must not appear in the replay state. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Message(System.String)"> + <summary> + Documentation message for the expectation + </summary> + <param name="documentationMessage">Message</param> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Any"> + <summary> + Repeat the method any number of times. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Times(System.Int32,System.Int32)"> + <summary> + Set the range to repeat an action. + </summary> + <param name="min">Min.</param> + <param name="max">Max.</param> + </member> + <member name="M:Rhino.Mocks.Impl.MethodOptions`1.Times(System.Int32)"> + <summary> + Set the amount of times to repeat an action. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.MethodOptions`1.Repeat"> + <summary> + Better syntax to define repeats. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.MockedObjectsEquality"> + <summary> + This class will provide hash code for hashtables without needing + to call the GetHashCode() on the object, which may very well be mocked. + This class has no state so it is a singelton to avoid creating a lot of objects + that does the exact same thing. See flyweight patterns. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MockedObjectsEquality.GetHashCode(System.Object)"> + <summary> + Get the hash code for a proxy object without calling GetHashCode() + on the object. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MockedObjectsEquality.Compare(System.Object,System.Object)"> + <summary> + Compares two instances of mocked objects + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.MockedObjectsEquality.Equals(System.Object,System.Object)"> + <summary> + Compare two mocked objects + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.MockedObjectsEquality.NextHashCode"> + <summary> + The next hash code value for a mock object. + This is safe for multi threading. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.MockedObjectsEquality.Instance"> + <summary> + The sole instance of <see cref="T:Rhino.Mocks.Impl.MockedObjectsEquality"/> + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.NullLogger"> + <summary> + Doesn't log anything, just makes happy noises + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IExpectationLogger"> + <summary> + Log expectations - allows to see what is going on inside Rhino Mocks + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IExpectationLogger.LogRecordedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as is was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IExpectationLogger.LogReplayedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as it was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IExpectationLogger.LogUnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.String)"> + <summary> + Logs the unexpected method call. + </summary> + <param name="invocation">The invocation.</param> + <param name="message">The message.</param> + </member> + <member name="M:Rhino.Mocks.Impl.NullLogger.LogRecordedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as is was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.NullLogger.LogReplayedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as it was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.NullLogger.LogUnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.String)"> + <summary> + Logs the unexpected method call. + </summary> + <param name="invocation">The invocation.</param> + <param name="message">The message.</param> + </member> + <member name="T:Rhino.Mocks.Impl.ProxyInstance"> + <summary> + This is a dummy type that is used merely to give DynamicProxy the proxy instance that + it needs to create IProxy's types. + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IMockedObject"> + <summary> + Interface to find the repository of a mocked object + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.ShouldCallOriginal(System.Reflection.MethodInfo)"> + <summary> + Return true if it should call the original method on the object + instead of pass it to the message chain. + </summary> + <param name="method">The method to call</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.RegisterMethodForCallingOriginal(System.Reflection.MethodInfo)"> + <summary> + Register a method to be called on the object directly + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.RegisterPropertyBehaviorFor(System.Reflection.PropertyInfo)"> + <summary> + Register a property on the object that will behave as a simple property + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.IsPropertyMethod(System.Reflection.MethodInfo)"> + <summary> + Check if the method was registered as a property method. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.HandleProperty(System.Reflection.MethodInfo,System.Object[])"> + <summary> + Do get/set on the property, according to need. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.HandleEvent(System.Reflection.MethodInfo,System.Object[])"> + <summary> + Do add/remove on the event + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.GetEventSubscribers(System.String)"> + <summary> + Get the subscribers of a spesific event + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.GetDeclaringType(System.Reflection.MethodInfo)"> + <summary> + Gets the declaring type of the method, taking into acccount the possible generic + parameters that it was created with. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.ClearState(Rhino.Mocks.BackToRecordOptions)"> + <summary> + Clears the state of the object, remove original calls, property behavior, subscribed events, etc. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.GetCallArgumentsFor(System.Reflection.MethodInfo)"> + <summary> + Get all the method calls arguments that were made against this object with the specificed + method. + </summary> + <remarks> + Only method calls in replay mode are counted + </remarks> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockedObject.MethodCall(System.Reflection.MethodInfo,System.Object[])"> + <summary> + Records the method call + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMockedObject.ProxyHash"> + <summary> + The unique hash code of this mock, which is not related + to the value of the GetHashCode() call on the object. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMockedObject.Repository"> + <summary> + Gets the repository. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMockedObject.ImplementedTypes"> + <summary> + Gets the implemented types by this mocked object + </summary> + <value>The implemented.</value> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMockedObject.ConstructorArguments"> + <summary> + Gets or sets the constructor arguments. + </summary> + <value>The constructor arguments.</value> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.#ctor(Rhino.Mocks.MockRepository,System.Type[])"> + <summary> + Create a new instance of <see cref="T:Rhino.Mocks.Impl.ProxyInstance"/> + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.ShouldCallOriginal(System.Reflection.MethodInfo)"> + <summary> + Return true if it should call the original method on the object + instead of pass it to the message chain. + </summary> + <param name="method">The method to call</param> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.RegisterMethodForCallingOriginal(System.Reflection.MethodInfo)"> + <summary> + Register a method to be called on the object directly + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.RegisterPropertyBehaviorFor(System.Reflection.PropertyInfo)"> + <summary> + Register a property on the object that will behave as a simple property + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.IsPropertyMethod(System.Reflection.MethodInfo)"> + <summary> + Check if the method was registered as a property method. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.HandleProperty(System.Reflection.MethodInfo,System.Object[])"> + <summary> + Do get/set on the property, according to need. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.HandleEvent(System.Reflection.MethodInfo,System.Object[])"> + <summary> + Do add/remove on the event + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.GetEventSubscribers(System.String)"> + <summary> + Get the subscribers of a spesific event + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.GetDeclaringType(System.Reflection.MethodInfo)"> + <summary> + Gets the declaring type of the method, taking into acccount the possible generic + parameters that it was created with. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.GetCallArgumentsFor(System.Reflection.MethodInfo)"> + <summary> + Get all the method calls arguments that were made against this object with the specificed + method. + </summary> + <param name="method"></param> + <returns></returns> + <remarks> + Only method calls in replay mode are counted + </remarks> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.MethodCall(System.Reflection.MethodInfo,System.Object[])"> + <summary> + Records the method call + </summary> + <param name="method"></param> + <param name="args"></param> + </member> + <member name="M:Rhino.Mocks.Impl.ProxyInstance.ClearState(Rhino.Mocks.BackToRecordOptions)"> + <summary> + Clears the state of the object, remove original calls, property behavior, subscribed events, etc. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.ProxyInstance.ProxyHash"> + <summary> + The unique hash code of this proxy, which is not related + to the value of the GetHashCode() call on the object. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.ProxyInstance.Repository"> + <summary> + Gets the repository. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.ProxyInstance.ConstructorArguments"> + <summary> + Gets or sets the constructor arguments. + </summary> + <value>The constructor arguments.</value> + </member> + <member name="P:Rhino.Mocks.Impl.ProxyInstance.ImplementedTypes"> + <summary> + Gets the implemented types by this mocked object + </summary> + <value>The implemented.</value> + </member> + <member name="T:Rhino.Mocks.Impl.Range"> + <summary> + Range for expected method calls + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.Range.#ctor(System.Int32,System.Int32)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.Range"/> instance. + </summary> + <param name="min">Min.</param> + <param name="max">Max.</param> + </member> + <member name="M:Rhino.Mocks.Impl.Range.ToString"> + <summary> + Return the string representation of this range. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.Range.Min"> + <summary> + Gets or sets the min. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.Impl.Range.Max"> + <summary> + Gets or sets the max. + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.Impl.RecordDynamicMockState"> + <summary> + Records all the expectations for a mock and + return a ReplayDynamicMockState when Replay() + is called. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.RecordMockState"> + <summary> + Records all the expectations for a mock + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IMockState"> + <summary> + Different actions on this mock + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockState.MethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockState.Verify"> + <summary> + Verify that this mock expectations have passed. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockState.Replay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockState.GetLastMethodOptions``1"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMockState.SetExceptionToThrowOnVerify(System.Exception)"> + <summary> + Set the exception to throw when Verify is called. + This is used to report exception that may have happened but where caught in the code. + This way, they are reported anyway when Verify() is called. + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMockState.VerifyState"> + <summary> + Gets the matching verify state for this state + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMockState.LastMethodOptions"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.GetLastMethodOptions``1"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.SetExceptionToThrowOnVerify(System.Exception)"> + <summary> + Set the exception to throw when Verify is called. + This is used to report exception that may have happened but where caught in the code. + This way, they are reported anyway when Verify() is called. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.#ctor(Rhino.Mocks.Interfaces.IMockedObject,Rhino.Mocks.MockRepository)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.RecordMockState"/> instance. + </summary> + <param name="repository">Repository.</param> + <param name="mockedObject">The proxy that generates the method calls</param> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.MethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.Replay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.DoReplay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.Verify"> + <summary> + Verify that this mock expectations have passed. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordMockState.AssertPreviousMethodIsClose"> + <summary> + Asserts the previous method is closed (had an expectation set on it so we can replay it correctly) + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.RecordMockState.LastExpectation"> + <summary> + Gets the last expectation. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.RecordMockState.MethodCallsCount"> + <summary> + Gets the total method calls count. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.RecordMockState.LastMethodOptions"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.RecordMockState.VerifyState"> + <summary> + Gets the matching verify state for this state + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordDynamicMockState.#ctor(Rhino.Mocks.Interfaces.IMockedObject,Rhino.Mocks.MockRepository)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.RecordDynamicMockState"/> instance. + </summary> + <param name="repository">Repository.</param> + <param name="mockedObject">The proxy that generates the method calls</param> + </member> + <member name="M:Rhino.Mocks.Impl.RecordDynamicMockState.DoReplay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordDynamicMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.RecordPartialMockState"> + <summary> + Records all the expectations for a mock and + return a ReplayPartialMockState when Replay() + is called. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordPartialMockState.#ctor(Rhino.Mocks.Interfaces.IMockedObject,Rhino.Mocks.MockRepository)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.RecordDynamicMockState"/> instance. + </summary> + <param name="repository">Repository.</param> + <param name="mockedObject">The proxy that generates the method calls</param> + </member> + <member name="M:Rhino.Mocks.Impl.RecordPartialMockState.DoReplay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RecordPartialMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.RepeatableOption"> + <summary> + Options for special repeat option + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.RepeatableOption.Normal"> + <summary> + This method can be called only as many times as the IMethodOptions.Expect allows. + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.RepeatableOption.Never"> + <summary> + This method should never be called + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.RepeatableOption.Any"> + <summary> + This method can be call any number of times + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.RepeatableOption.OriginalCall"> + <summary> + This method will call the original method + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.RepeatableOption.OriginalCallBypassingMocking"> + <summary> + This method will call the original method, bypassing the mocking layer + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.RepeatableOption.PropertyBehavior"> + <summary> + This method will simulate simple property behavior + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.ReplayDynamicMockState"> + <summary> + Validate all expectations on a mock and ignores calls to + any method that was not setup properly. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.ReplayMockState"> + <summary> + Validate all expectations on a mock + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.ReplayMockState.repository"> + <summary> + The repository for this state + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.ReplayMockState.proxy"> + <summary> + The proxy object for this state + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.GetLastMethodOptions``1"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.#ctor(Rhino.Mocks.Impl.RecordMockState)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.ReplayMockState"/> instance. + </summary> + <param name="previousState">The previous state for this method</param> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.MethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.DoMethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + This allows derived method to cleanly get a the setupresult behavior while adding + their own. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.SetExceptionToThrowOnVerify(System.Exception)"> + <summary> + Set the exception to throw when Verify is called. + This is used to report exception that may have happened but where caught in the code. + This way, they are reported anyway when Verify() is called. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.Verify"> + <summary> + Verify that this mock expectations have passed. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.Replay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.ReplayMockState.LastMethodOptions"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.ReplayMockState.VerifyState"> + <summary> + Gets the matching verify state for this state + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayDynamicMockState.#ctor(Rhino.Mocks.Impl.RecordDynamicMockState)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.ReplayDynamicMockState"/> instance. + </summary> + <param name="previousState">The previous state for this method</param> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayDynamicMockState.DoMethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayDynamicMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.ReplayPartialMockState"> + <summary> + Validate all expectations on a mock and ignores calls to + any method that was not setup properly. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayPartialMockState.#ctor(Rhino.Mocks.Impl.RecordPartialMockState)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.ReplayDynamicMockState"/> instance. + </summary> + <param name="previousState">The previous state for this method</param> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayPartialMockState.DoMethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Impl.ReplayPartialMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.RhinoInterceptor"> + <summary> + Summary description for RhinoInterceptor. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RhinoInterceptor.#ctor(Rhino.Mocks.MockRepository,Rhino.Mocks.Interfaces.IMockedObject)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.Impl.RhinoInterceptor"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.RhinoInterceptor.Intercept(Castle.Core.Interceptor.IInvocation)"> + <summary> + Intercept a method call and direct it to the repository. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.StubRecordMockState"> + <summary> + Behave like a stub, all properties and events acts normally, methods calls + return default values by default (but can use expectations to set them up), etc. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.StubRecordMockState.#ctor(Rhino.Mocks.Interfaces.IMockedObject,Rhino.Mocks.MockRepository)"> + <summary> + Initializes a new instance of the <see cref="T:Rhino.Mocks.Impl.StubRecordMockState"/> class. + </summary> + <param name="mockedObject">The proxy that generates the method calls</param> + <param name="repository">Repository.</param> + </member> + <member name="M:Rhino.Mocks.Impl.StubRecordMockState.AssertPreviousMethodIsClose"> + <summary> + We don't care much about expectations here, so we will remove the exepctation if + it is not closed. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.StubRecordMockState.Replay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + <returns></returns> + </member> + <member name="T:Rhino.Mocks.Impl.StubReplayMockState"> + <summary> + Validate expectations on recorded methods, but in general completely ignoring them. + Similar to <seealso cref="T:Rhino.Mocks.Impl.ReplayDynamicMockState"/> except that it would return a + <seealso cref="T:Rhino.Mocks.Impl.StubRecordMockState"/> when BackToRecord is called. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.StubReplayMockState.#ctor(Rhino.Mocks.Impl.RecordMockState)"> + <summary> + Initializes a new instance of the <see cref="T:Rhino.Mocks.Impl.StubReplayMockState"/> class. + </summary> + <param name="previousState">The previous state for this method</param> + </member> + <member name="M:Rhino.Mocks.Impl.StubReplayMockState.DoMethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Impl.StubReplayMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.TextWriterExpectationLogger"> + <summary> + Rudimetry implementation that simply logs methods calls as text. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.TextWriterExpectationLogger.#ctor(System.IO.TextWriter)"> + <summary> + Initializes a new instance of the <see cref="T:Rhino.Mocks.Impl.TextWriterExpectationLogger"/> class. + </summary> + <param name="writer">The writer.</param> + </member> + <member name="M:Rhino.Mocks.Impl.TextWriterExpectationLogger.LogRecordedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as is was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.TextWriterExpectationLogger.LogReplayedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as it was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.TextWriterExpectationLogger.LogUnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.String)"> + <summary> + Logs the unexpected method call. + </summary> + <param name="invocation">The invocation.</param> + <param name="message">The message.</param> + </member> + <member name="T:Rhino.Mocks.Impl.TraceWriterExpectationLogger"> + <summary> + Write rhino mocks log info to the trace + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterExpectationLogger.#ctor"> + <summary> + Initializes a new instance of the <see cref="T:Rhino.Mocks.Impl.TraceWriterExpectationLogger"/> class. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterExpectationLogger.#ctor(System.Boolean,System.Boolean,System.Boolean)"> + <summary> + Initializes a new instance of the <see cref="T:Rhino.Mocks.Impl.TraceWriterExpectationLogger"/> class. + </summary> + <param name="logRecorded">if set to <c>true</c> [log recorded].</param> + <param name="logReplayed">if set to <c>true</c> [log replayed].</param> + <param name="logUnexpected">if set to <c>true</c> [log unexpected].</param> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterExpectationLogger.LogRecordedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as is was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterExpectationLogger.LogReplayedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as it was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterExpectationLogger.LogUnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.String)"> + <summary> + Logs the unexpected method call. + </summary> + <param name="invocation">The invocation.</param> + <param name="message">The message.</param> + </member> + <member name="T:Rhino.Mocks.Impl.TraceWriterWithStackTraceExpectationWriter"> + <summary> + Writes log information as stack traces about rhino mocks activity + </summary> + </member> + <member name="F:Rhino.Mocks.Impl.TraceWriterWithStackTraceExpectationWriter.AlternativeWriter"> + <summary> + Allows to redirect output to a different location. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterWithStackTraceExpectationWriter.LogRecordedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as is was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterWithStackTraceExpectationWriter.LogReplayedExpectation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Logs the expectation as it was recorded + </summary> + <param name="invocation">The invocation.</param> + <param name="expectation">The expectation.</param> + </member> + <member name="M:Rhino.Mocks.Impl.TraceWriterWithStackTraceExpectationWriter.LogUnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.String)"> + <summary> + Logs the unexpected method call. + </summary> + <param name="invocation">The invocation.</param> + <param name="message">The message.</param> + </member> + <member name="T:Rhino.Mocks.Impl.Validate"> + <summary> + Validate arguments for methods + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.Validate.IsNotNull(System.Object,System.String)"> + <summary> + Validate that the passed argument is not null. + </summary> + <param name="obj">The object to validate</param> + <param name="name">The name of the argument</param> + <exception cref="T:System.ArgumentNullException"> + If the obj is null, an ArgumentNullException with the passed name + is thrown. + </exception> + </member> + <member name="M:Rhino.Mocks.Impl.Validate.ArgsEqual(System.Object[],System.Object[])"> + <summary> + Validate that the arguments are equal. + </summary> + <param name="expectedArgs">Expected args.</param> + <param name="actualArgs">Actual Args.</param> + </member> + <member name="M:Rhino.Mocks.Impl.Validate.AreEqual(System.Object,System.Object)"> + <summary> + Validate that the two argument are equals, including validation for + when the arguments are collections, in which case it will validate their values. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.Validate.SafeEquals(System.Object,System.Object)"> + <summary> + This method is safe for use even if any of the objects is a mocked object + that override equals. + </summary> + </member> + <member name="T:Rhino.Mocks.Impl.VerifiedMockState"> + <summary> + Throw an object already verified when accessed + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.VerifiedMockState.#ctor(Rhino.Mocks.Interfaces.IMockState)"> + <summary> + Create a new instance of VerifiedMockState + </summary> + <param name="previous">The previous mock state, used to get the initial record state</param> + </member> + <member name="M:Rhino.Mocks.Impl.VerifiedMockState.MethodCall(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Add a method call for this state' mock. + </summary> + <param name="invocation">The invocation for this method</param> + <param name="method">The method that was called</param> + <param name="args">The arguments this method was called with</param> + </member> + <member name="M:Rhino.Mocks.Impl.VerifiedMockState.Verify"> + <summary> + Verify that this mock expectations have passed. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.VerifiedMockState.Replay"> + <summary> + Verify that we can move to replay state and move + to the reply state. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.VerifiedMockState.BackToRecord"> + <summary> + Gets a mock state that match the original mock state of the object. + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.VerifiedMockState.GetLastMethodOptions``1"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="M:Rhino.Mocks.Impl.VerifiedMockState.SetExceptionToThrowOnVerify(System.Exception)"> + <summary> + Set the exception to throw when Verify is called. + This is used to report exception that may have happened but where caught in the code. + This way, they are reported anyway when Verify() is called. + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.VerifiedMockState.VerifyState"> + <summary> + Gets the matching verify state for this state + </summary> + </member> + <member name="P:Rhino.Mocks.Impl.VerifiedMockState.LastMethodOptions"> + <summary> + Get the options for the last method call + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.IMethodRecorder"> + <summary> + Records the actions on all the mocks created by a repository. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.Record(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Records the specified call with the specified args on the mocked object. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.GetRecordedExpectation(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Get the expectation for this method on this object with this arguments + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.GetRepeatableExpectation(System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + This check the methods that were setup using the SetupResult.For() + or LastCall.Repeat.Any() and that bypass the whole expectation model. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.GetAllExpectationsForProxyAndMethod(System.Object,System.Reflection.MethodInfo)"> + <summary> + Gets the all expectations for a mocked object and method combination, + regardless of the expected arguments / callbacks / contraints. + </summary> + <param name="proxy">Mocked object.</param> + <param name="method">Method.</param> + <returns>List of all relevant expectation</returns> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.GetAllExpectationsForProxy(System.Object)"> + <summary> + Gets the all expectations for proxy. + </summary> + <param name="proxy">Mocked object.</param> + <returns>List of all relevant expectation</returns> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.RemoveAllRepeatableExpectationsForProxy(System.Object)"> + <summary> + Removes all the repeatable expectations for proxy. + </summary> + <param name="proxy">Mocked object.</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.ReplaceExpectation(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Replaces the old expectation with the new expectation for the specified proxy/method pair. + This replace ALL expectations that equal to old expectations. + </summary> + <param name="proxy">Proxy.</param> + <param name="method">Method.</param> + <param name="oldExpectation">Old expectation.</param> + <param name="newExpectation">New expectation.</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.AddRecorder(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Adds the recorder and turn it into the active recorder. + </summary> + <param name="recorder">Recorder.</param> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.MoveToPreviousRecorder"> + <summary> + Moves to previous recorder. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.GetRecordedExpectationOrNull(System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Gets the recorded expectation or null. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.GetExpectedCallsMessage"> + <summary> + Gets the next expected calls string. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.MoveToParentReplayer"> + <summary> + Moves to parent recorder. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.AddToRepeatableMethods(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Set the expectation so it can repeat any number of times. + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.RemoveExpectation(Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Removes the expectation from the recorder + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.ClearReplayerToCall(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Clear the replayer to call (and all its chain of replayers) + This also removes it from the list of expectations, so it will never be considered again + </summary> + </member> + <member name="M:Rhino.Mocks.Interfaces.IMethodRecorder.UnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Get the expectation for this method on this object with this arguments + </summary> + </member> + <member name="P:Rhino.Mocks.Interfaces.IMethodRecorder.HasExpectations"> + <summary> + Gets a value indicating whether this instance has expectations that weren't satisfied yet. + </summary> + <value> + <c>true</c> if this instance has expectations; otherwise, <c>false</c>. + </value> + </member> + <member name="T:Rhino.Mocks.Interfaces.IPartialMockMarker"> + <summary> + Marker interface used to indicate that this is a partial mock. + </summary> + </member> + <member name="T:Rhino.Mocks.Interfaces.OriginalCallOptions"> + <summary> + Options for CallOriginalMethod + </summary> + </member> + <member name="F:Rhino.Mocks.Interfaces.OriginalCallOptions.NoExpectation"> + <summary> + No expectation is created, the method will be called directly + </summary> + </member> + <member name="F:Rhino.Mocks.Interfaces.OriginalCallOptions.CreateExpectation"> + <summary> + Normal expectation is created, but when the method is later called, it will also call the original method + </summary> + </member> + <member name="T:Rhino.Mocks.MethodRecorders.MethodRecorderBase"> + <summary> + Base class for method recorders, handle delegating to inner recorder if needed. + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.MethodRecorderBase.recordedActions"> + <summary> + List of the expected actions on for this recorder + The legal values are: + * Expectations + * Method Recorders + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.MethodRecorderBase.recorderToCall"> + <summary> + The current recorder. + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.MethodRecorderBase.replayerToCall"> + <summary> + The current replayer; + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.MethodRecorderBase.parentRecorder"> + <summary> + The parent recorder of this one, may be null. + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.MethodRecorderBase.replayersToIgnoreForThisCall"> + <summary> + This contains a list of all the replayers that should be ignored + for a spesific method call. A replayer gets into this list by calling + ClearReplayerToCall() on its parent. This list is Clear()ed on each new invocation. + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.MethodRecorderBase.repeatableMethods"> + <summary> + All the repeatable methods calls. + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.MethodRecorderBase.recursionDepth"> + <summary> + Counts the recursion depth of the current expectation search stack + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.#ctor(Rhino.Mocks.Generated.ProxyMethodExpectationsDictionary)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.MethodRecorderBase"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.#ctor(Rhino.Mocks.Interfaces.IMethodRecorder,Rhino.Mocks.Generated.ProxyMethodExpectationsDictionary)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.MethodRecorderBase"/> instance. + </summary> + <param name="parentRecorder">Parent recorder.</param> + <param name="repeatableMethods">Repeatable methods</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.Record(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Records the specified call with the specified args on the mocked object. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.GetRecordedExpectation(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Get the expectation for this method on this object with this arguments + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.GetAllExpectationsForProxyAndMethod(System.Object,System.Reflection.MethodInfo)"> + <summary> + Gets the all expectations for a mocked object and method combination, + regardless of the expected arguments / callbacks / contraints. + </summary> + <param name="proxy">Mocked object.</param> + <param name="method">Method.</param> + <returns>List of all relevant expectation</returns> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.GetAllExpectationsForProxy(System.Object)"> + <summary> + Gets the all expectations for proxy. + </summary> + <param name="proxy">Mocked object.</param> + <returns>List of all relevant expectation</returns> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.ReplaceExpectation(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Replaces the old expectation with the new expectation for the specified proxy/method pair. + This replace ALL expectations that equal to old expectations. + </summary> + <param name="proxy">Proxy.</param> + <param name="method">Method.</param> + <param name="oldExpectation">Old expectation.</param> + <param name="newExpectation">New expectation.</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.RemoveAllRepeatableExpectationsForProxy(System.Object)"> + <summary> + Remove the all repeatable expectations for proxy. + </summary> + <param name="proxy">Mocked object.</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.AddToRepeatableMethods(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Set the expectation so it can repeat any number of times. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.RemoveExpectation(Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Removes the expectation from the recorder + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.AddRecorder(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Adds the recorder and turn it into the active recorder. + </summary> + <param name="recorder">Recorder.</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.MoveToPreviousRecorder"> + <summary> + Moves to previous recorder. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.MoveToParentReplayer"> + <summary> + Moves to parent recorder. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.GetRecordedExpectationOrNull(System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Gets the recorded expectation or null. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.ClearReplayerToCall(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Clear the replayer to call (and all its chain of replayers). + This also removes it from the list of expectations, so it will never be considered again + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.UnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Get the expectation for this method on this object with this arguments + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.GetExpectedCallsMessage"> + <summary> + Gets the next expected calls string. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoGetRecordedExpectationOrNull(System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Handles the real getting of the recorded expectation or null. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoRecord(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoGetRecordedExpectation(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoGetAllExpectationsForProxy(System.Object)"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoReplaceExpectation(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoRemoveExpectation(Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoAddRecorder(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.ShouldConsiderThisReplayer(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Should this replayer be considered valid for this call? + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.MethodRecorderBase.GetRepeatableExpectation(System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + This check the methods that were setup using the SetupResult.For() + or LastCall.Repeat.Any() and that bypass the whole expectation model. + </summary> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.MethodRecorderBase.HasExpectations"> + <summary> + Gets a value indicating whether this instance has expectations that weren't satisfied yet. + </summary> + <value> + <c>true</c> if this instance has expectations; otherwise, <c>false</c>. + </value> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.MethodRecorderBase.DoHasExpectations"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="T:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder"> + <summary> + Ordered collection of methods, methods must arrive in specified order + in order to pass. + </summary> + </member> + <member name="T:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder"> + <summary> + Unordered collection of method records, any expectation that exist + will be matched. + </summary> + </member> + <member name="F:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.parentRecorderRedirection"> + <summary> + The parent recorder we have redirected to. + Useful for certain edge cases in orderring. + See: FieldProblem_Entropy for the details. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.#ctor(Rhino.Mocks.Interfaces.IMethodRecorder,Rhino.Mocks.Generated.ProxyMethodExpectationsDictionary)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder"/> instance. + </summary> + <param name="parentRecorder">Parent recorder.</param> + <param name="repeatableMethods">Repeatable methods</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.#ctor(Rhino.Mocks.Generated.ProxyMethodExpectationsDictionary)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoRecord(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Records the specified call with the specified args on the mocked object. + </summary> + <param name="proxy">Mocked object.</param> + <param name="method">Method.</param> + <param name="expectation">Expectation.</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoGetRecordedExpectation(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Get the expectation for this method on this object with this arguments + </summary> + <param name="invocation">Invocation for this method</param> + <param name="proxy">Mocked object.</param> + <param name="method">Method.</param> + <param name="args">Args.</param> + <returns>True is the call was recorded, false otherwise</returns> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.GetAllExpectationsForProxyAndMethod(System.Object,System.Reflection.MethodInfo)"> + <summary> + Gets the all expectations for a mocked object and method combination, + regardless of the expected arguments / callbacks / contraints. + </summary> + <param name="proxy">Mocked object.</param> + <param name="method">Method.</param> + <returns>List of all relevant expectation</returns> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoGetAllExpectationsForProxy(System.Object)"> + <summary> + Gets the all expectations for proxy. + </summary> + <param name="proxy">Mocked object.</param> + <returns>List of all relevant expectation</returns> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoReplaceExpectation(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Replaces the old expectation with the new expectation for the specified proxy/method pair. + This replace ALL expectations that equal to old expectations. + </summary> + <param name="proxy">Proxy.</param> + <param name="method">Method.</param> + <param name="oldExpectation">Old expectation.</param> + <param name="newExpectation">New expectation.</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoRemoveExpectation(Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoGetRecordedExpectationOrNull(System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Handles the real getting of the recorded expectation or null. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoAddRecorder(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Handle the real execution of this method for the derived class + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.GetExpectedCallsMessage"> + <summary> + Gets the next expected calls string. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.UnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Create an exception for an unexpected method call. + </summary> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.UnorderedMethodRecorder.DoHasExpectations"> + <summary> + Gets a value indicating whether this instance has expectations that weren't satisfied yet. + </summary> + <value> + <c>true</c> if this instance has expectations; otherwise, <c>false</c>. + </value> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder.#ctor(Rhino.Mocks.Interfaces.IMethodRecorder,Rhino.Mocks.Generated.ProxyMethodExpectationsDictionary)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder"/> instance. + </summary> + <param name="parentRecorder">Parent recorder.</param> + <param name="repeatableMethods">Repetable methods</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder.#ctor(Rhino.Mocks.Generated.ProxyMethodExpectationsDictionary)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder.DoGetRecordedExpectationOrNull(System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Handles the real getting of the recorded expectation or null. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder.UnexpectedMethodCall(Castle.Core.Interceptor.IInvocation,System.Object,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Get the expectation for this method on this object with this arguments + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.OrderedMethodRecorder.GetExpectedCallsMessage"> + <summary> + Gets the next expected calls string. + </summary> + </member> + <member name="T:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet"> + <summary> + Hold an expectation for a method call on an object + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet.#ctor(System.Object,System.Reflection.MethodInfo,Rhino.Mocks.Interfaces.IExpectation)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet"/> instance. + </summary> + <param name="proxy">Proxy.</param> + <param name="method">Method.</param> + <param name="expectation">Expectation.</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet.Equals(System.Object)"> + <summary> + Determains if the object equal to this instance + </summary> + <param name="obj">Obj.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet.GetHashCode"> + <summary> + Gets the hash code. + </summary> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet.Proxy"> + <summary> + Gets the proxy. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet.Method"> + <summary> + Gets the method. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.ProxyMethodExpectationTriplet.Expectation"> + <summary> + Gets the expectation. + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.MethodRecorders.ProxyMethodPair"> + <summary> + Holds a pair of mocked object and a method + and allows to compare them against each other. + This allows us to have a distinction between mockOne.MyMethod() and + mockTwo.MyMethod()... + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.ProxyMethodPair.#ctor(System.Object,System.Reflection.MethodInfo)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.ProxyMethodPair"/> instance. + </summary> + <param name="proxy">Proxy.</param> + <param name="method">Method.</param> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.ProxyMethodPair.Equals(System.Object)"> + <summary> + Determains whatever obj equals to this instance. + ProxyMethodPairs are equals when they point to the same /instance/ of + an object, and to the same method. + </summary> + <param name="obj">Obj.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.ProxyMethodPair.GetHashCode"> + <summary> + Gets the hash code. + </summary> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.ProxyMethodPair.Proxy"> + <summary> + Gets the proxy. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.MethodRecorders.ProxyMethodPair.Method"> + <summary> + Gets the method. + </summary> + <value></value> + </member> + <member name="T:Rhino.Mocks.MethodRecorders.RecorderChanger"> + <summary> + Change the recorder from ordered to unordered and vice versa + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.RecorderChanger.#ctor(Rhino.Mocks.MockRepository,Rhino.Mocks.Interfaces.IMethodRecorder,Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MethodRecorders.RecorderChanger"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.MethodRecorders.RecorderChanger.Dispose"> + <summary> + Disposes this instance. + </summary> + </member> + <member name="T:Rhino.Mocks.Utilities.GenericsUtil"> + <summary> + Utility class for dealing with messing generics scenarios. + </summary> + </member> + <member name="M:Rhino.Mocks.Utilities.GenericsUtil.HasOpenGenericParam(System.Type)"> + <summary> + There are issues with trying to get this to work correctly with open generic types, since this is an edge case, + I am letting the runtime handle it. + </summary> + </member> + <member name="M:Rhino.Mocks.Utilities.GenericsUtil.GetRealType(System.Type,Castle.Core.Interceptor.IInvocation)"> + <summary> + Gets the real type, including de-constructing and constructing the type of generic + methods parameters. + </summary> + <param name="type">The type.</param> + <param name="invocation">The invocation.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Utilities.GenericsUtil.ReconstructGenericType(System.Type,System.Collections.Generic.Dictionary{System.String,System.Type})"> + <summary> + Because we need to support complex types here (simple generics were handled above) we + need to be aware of the following scenarios: + List[T] and List[Foo[T]] + </summary> + </member> + <member name="T:Rhino.Mocks.Utilities.MethodCallUtil"> + <summary> + Utility class for working with method calls. + </summary> + </member> + <member name="M:Rhino.Mocks.Utilities.MethodCallUtil.StringPresentation(Castle.Core.Interceptor.IInvocation,Rhino.Mocks.Utilities.MethodCallUtil.FormatArgumnet,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Return the string representation of a method call and its arguments. + </summary> + <param name="method">The method</param> + <param name="args">The method arguments</param> + <param name="invocation">Invocation of the method, used to get the generics arguments</param> + <param name="format">Delegate to format the parameter</param> + <returns>The string representation of this method call</returns> + </member> + <member name="M:Rhino.Mocks.Utilities.MethodCallUtil.StringPresentation(Castle.Core.Interceptor.IInvocation,System.Reflection.MethodInfo,System.Object[])"> + <summary> + Return the string representation of a method call and its arguments. + </summary> + <param name="invocation">The invocation of the method, used to get the generic parameters</param> + <param name="method">The method</param> + <param name="args">The method arguments</param> + <returns>The string representation of this method call</returns> + </member> + <member name="T:Rhino.Mocks.Utilities.MethodCallUtil.FormatArgumnet"> + <summary> + Delegate to format the argument for the string representation of + the method call. + </summary> + </member> + <member name="T:Rhino.Mocks.Utilities.ReturnValueUtil"> + <summary> + Utility to get the default value for a type + </summary> + </member> + <member name="M:Rhino.Mocks.Utilities.ReturnValueUtil.DefaultValue(System.Type,Castle.Core.Interceptor.IInvocation)"> + <summary> + The default value for a type. + Null for reference types and void + 0 for value types. + First element for enums + Note that we need to get the value even for opened generic types, such as those from + generic methods. + </summary> + <param name="type">Type.</param> + <param name="invocation">The invocation.</param> + <returns>the default value</returns> + </member> + <member name="T:Rhino.Mocks.Arg`1"> + <summary> + Defines constraints and return values for arguments of a mock. + Only use Arg inside a method call on a mock that is recording. + Example: + ExpectCall( + mock.foo( + Arg<int>.Is.GreaterThan(2), + Arg<string>.Is.Anything + )); + Use Arg.Text for string specific constraints + Use Arg<ListClass>.List for list specific constraints + </summary> + <typeparam name="T"></typeparam> + </member> + <member name="M:Rhino.Mocks.Arg`1.Matches(System.Linq.Expressions.Expression{System.Predicate{`0}})"> + <summary> + Register the predicate as a constraint for the current call. + </summary> + <param name="predicate">The predicate.</param> + <returns>default(T)</returns> + <example> + Allow you to use code to create constraints + <code> + demo.AssertWasCalled(x => x.Bar(Arg{string}.Matches(a => a.StartsWith("b") && a.Contains("ba")))); + </code> + </example> + </member> + <member name="M:Rhino.Mocks.Arg`1.Matches(Rhino.Mocks.Constraints.AbstractConstraint)"> + <summary> + Define a complex constraint for this argument by passing several constraints + combined with operators. (Use Is in simple cases.) + Example: Arg<string>.Matches(Is.Equal("Hello") || Text.EndsWith("u")); + </summary> + <param name="constraint">Constraints using Is, Text and List</param> + <returns>Dummy to satisfy the compiler</returns> + </member> + <member name="M:Rhino.Mocks.Arg`1.Ref(Rhino.Mocks.Constraints.AbstractConstraint,`0)"> + <summary> + Define a Ref argument. + </summary> + <param name="constraint">Constraints for this argument</param> + <param name="returnValue">value returned by the mock</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.Arg`1.Out(`0)"> + <summary> + Define a out parameter. Use it together with the keyword out and use the + Dummy field available by the return value. + Example: mock.foo( out Arg<string>.Out("hello").Dummy ); + </summary> + <param name="returnValue"></param> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.Arg`1.Is"> + <summary> + Define a simple constraint for this argument. (Use Matches in simple cases.) + Example: + Arg<int>.Is.Anthing + Arg<string>.Is.Equal("hello") + </summary> + </member> + <member name="P:Rhino.Mocks.Arg`1.List"> + <summary> + Define Constraints on list arguments. + </summary> + </member> + <member name="T:Rhino.Mocks.Arg"> + <summary> + Use the Arg class (without generic) to define Text constraints + </summary> + </member> + <member name="P:Rhino.Mocks.Arg.Text"> + <summary> + Define constraints on text arguments. + </summary> + </member> + <member name="T:Rhino.Mocks.ArgManager"> + <summary> + Used to manage the static state of the Arg<T> class"/> + </summary> + </member> + <member name="M:Rhino.Mocks.ArgManager.Clear"> + <summary> + Resets the static state + </summary> + </member> + <member name="M:Rhino.Mocks.ArgManager.GetAllReturnValues"> + <summary> + Returns return values for the out and ref parameters + Note: the array returned has the size of the number of out and ref + argument definitions + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.ArgManager.GetAllConstraints"> + <summary> + Returns the constraints for all arguments. + Out arguments have an Is.Anything constraint and are also in the list. + </summary> + <returns></returns> + </member> + <member name="T:Rhino.Mocks.BackToRecordOptions"> + <summary> + What should BackToRecord clear + </summary> + </member> + <member name="F:Rhino.Mocks.BackToRecordOptions.None"> + <summary> + Retain all expectations and behaviors and return to mock + </summary> + </member> + <member name="F:Rhino.Mocks.BackToRecordOptions.Expectations"> + <summary> + All expectations + </summary> + </member> + <member name="F:Rhino.Mocks.BackToRecordOptions.EventSubscribers"> + <summary> + Event subscribers for this instance + </summary> + </member> + <member name="F:Rhino.Mocks.BackToRecordOptions.OriginalMethodsToCall"> + <summary> + Methods that should be forwarded to the base class implementation + </summary> + </member> + <member name="F:Rhino.Mocks.BackToRecordOptions.PropertyBehavior"> + <summary> + Properties that should behave like properties + </summary> + </member> + <member name="F:Rhino.Mocks.BackToRecordOptions.All"> + <summary> + Remove all the behavior of the object + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates"> + <summary> + This class defines a lot of method signatures, which we will use + to allow compatability on net-2.0 + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`1"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`2"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`2"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`3"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`3"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`4"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`4"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`5"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`5"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`6"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`6"> + <summary> + dummy + </summary> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`7"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`7"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`8"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`8"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`9"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`9"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`10"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Action`10"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.Delegates.Function`11"> + <summary> + dummy + </summary> + </member> + <member name="T:Rhino.Mocks.DoNotExpect"> + <summary> + Allows expectations to be set on methods that should never be called. + For methods with void return value, you need to use LastCall or + DoNotExpect.Call() with a delegate. + </summary> + </member> + <member name="M:Rhino.Mocks.DoNotExpect.Call(System.Object)"> + <summary> + Sets LastCall.Repeat.Never() on /any/ proxy on /any/ repository on the current thread. + This method if not safe for multi threading scenarios. + </summary> + </member> + <member name="M:Rhino.Mocks.DoNotExpect.Call(Rhino.Mocks.Expect.Action)"> + <summary> + Accepts a delegate that will execute inside the method which + LastCall.Repeat.Never() will be applied to. + It is expected to be used with anonymous delegates / lambda expressions and only one + method should be called. + </summary> + <example> + IService mockSrv = mocks.CreateMock(typeof(IService)) as IService; + DoNotExpect.Call(delegate{ mockSrv.Stop(); }); + ... + </example> + </member> + <member name="T:Rhino.Mocks.Expect"> + <summary> + Allows to set expectation on methods that has return values. + For methods with void return value, you need to use LastCall + </summary> + </member> + <member name="M:Rhino.Mocks.Expect.Call``1(``0)"> + <summary> + The method options for the last call on /any/ proxy on /any/ repository on the current thread. + This method if not safe for multi threading scenarios, use <see cref="M:Rhino.Mocks.Expect.On(System.Object)"/>. + </summary> + </member> + <member name="M:Rhino.Mocks.Expect.Call(Rhino.Mocks.Expect.Action)"> + <summary> + Accepts a delegate that will execute inside the method, and then return the resulting + <see cref="T:Rhino.Mocks.Interfaces.IMethodOptions`1"/> instance. + It is expected to be used with anonymous delegates / lambda expressions and only one + method should be called. + </summary> + <example> + IService mockSrv = mocks.CreateMock(typeof(IService)) as IService; + Expect.Call(delegate{ mockSrv.Start(); }).Throw(new NetworkException()); + ... + </example> + </member> + <member name="M:Rhino.Mocks.Expect.On(System.Object)"> + <summary> + Get the method options for the last method call on the mockInstance. + </summary> + </member> + <member name="T:Rhino.Mocks.Expect.Action"> + <summary> + A delegate that can be used to get better syntax on Expect.Call(delegate { foo.DoSomething(); }); + </summary> + </member> + <member name="T:Rhino.Mocks.LastCall"> + <summary> + Allows to set various options for the last method call on + a specified object. + If the method has a return value, it's recommended to use Expect + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.On(System.Object)"> + <summary> + Allows to get an interface to work on the last call. + </summary> + <param name="mockedInstance">The mocked object</param> + <returns>Interface that allows to set options for the last method call on this object</returns> + </member> + <member name="M:Rhino.Mocks.LastCall.Return``1(``0)"> + <summary> + Set the return value for the method. + </summary> + <param name="objToReturn">The object the method will return</param> + <returns>IRepeat that defines how many times the method will return this value</returns> + </member> + <member name="M:Rhino.Mocks.LastCall.Return(System.Object)"> + <summary> + Set the return value for the method. This overload is needed for LastCall.Return(null) + </summary> + <param name="objToReturn">The object the method will return</param> + <returns>IRepeat that defines how many times the method will return this value</returns> + </member> + <member name="M:Rhino.Mocks.LastCall.Throw(System.Exception)"> + <summary> + Throws the specified exception when the method is called. + </summary> + <param name="exception">Exception to throw</param> + </member> + <member name="M:Rhino.Mocks.LastCall.IgnoreArguments"> + <summary> + Ignores the arguments for this method. Any argument will be matched + againt this method. + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Constraints(Rhino.Mocks.Constraints.AbstractConstraint[])"> + <summary> + Add constraints for the method's arguments. + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback(System.Delegate)"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback(Rhino.Mocks.Delegates.Function{System.Boolean})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``1(Rhino.Mocks.Delegates.Function{System.Boolean,``0})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``2(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``3(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``4(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``5(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``6(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``7(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``8(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``9(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7,``8})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Callback``10(Rhino.Mocks.Delegates.Function{System.Boolean,``0,``1,``2,``3,``4,``5,``6,``7,``8,``9})"> + <summary> + Set a callback method for the last call + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.CallOriginalMethod"> + <summary> + Call the original method on the class, bypassing the mocking layers, for the last call. + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.CallOriginalMethod(Rhino.Mocks.Interfaces.OriginalCallOptions)"> + <summary> + Call the original method on the class, optionally bypassing the mocking layers, for the last call. + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Do(System.Delegate)"> + <summary> + Set a delegate to be called when the expectation is matched. + The delegate return value will be returned from the expectation. + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.GetEventRaiser"> + <summary> + Gets an interface that will raise the last event when called. + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.OutRef(System.Object[])"> + <summary> + Set the parameter values for out and ref parameters. + This is done using zero based indexing, and _ignoring_ any non out/ref parameter. + </summary> + </member> + <member name="M:Rhino.Mocks.LastCall.Message(System.String)"> + <summary> + Documentation message for the expectation + </summary> + <param name="documentationMessage">Message</param> + </member> + <member name="M:Rhino.Mocks.LastCall.PropertyBehavior"> + <summary> + Use the property as a simple property, getting/setting the values without + causing mock expectations. + </summary> + </member> + <member name="P:Rhino.Mocks.LastCall.Repeat"> + <summary> + Better syntax to define repeats. + </summary> + </member> + <member name="T:Rhino.Mocks.Mocker"> + <summary> + Accessor for the current mocker + </summary> + </member> + <member name="P:Rhino.Mocks.Mocker.Current"> + <summary> + The current mocker + </summary> + </member> + <member name="T:Rhino.Mocks.MockRepository"> + <summary> + Creates proxied instances of types. + </summary> + <summary> + Adds optional new usage: + using(mockRepository.Record()) { + Expect.Call(mock.Method()).Return(retVal); + } + using(mockRepository.Playback()) { + // Execute code + } + N.B. mockRepository.ReplayAll() and mockRepository.VerifyAll() + calls are taken care of by Record/Playback + </summary> + </member> + <member name="F:Rhino.Mocks.MockRepository.generatorMap"> + <summary> + This is a map of types to ProxyGenerators. + </summary> + </member> + <member name="F:Rhino.Mocks.MockRepository.lastRepository"> + <summary> + This is used to record the last repository that has a method called on it. + </summary> + </member> + <member name="F:Rhino.Mocks.MockRepository.lastMockedObject"> + <summary> + this is used to get to the last proxy on this repository. + </summary> + </member> + <member name="F:Rhino.Mocks.MockRepository.delegateProxies"> + <summary> + For mock delegates, maps the proxy instance from intercepted invocations + back to the delegate that was originally returned to client code, if any. + </summary> + </member> + <member name="F:Rhino.Mocks.MockRepository.proxies"> + <summary> + All the proxies in the mock repositories + </summary> + </member> + <member name="F:Rhino.Mocks.MockRepository.repeatableMethods"> + <summary> + This is here because we can't put it in any of the recorders, since repeatable methods + have no orderring, and if we try to handle them using the usual manner, we would get into + wierd situations where repeatable method that was defined in an orderring block doesn't + exists until we enter this block. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.#ctor"> + <summary> + Creates a new <see cref="T:Rhino.Mocks.MockRepository"/> instance. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.Ordered"> + <summary> + Move the repository to ordered mode + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.Unordered"> + <summary> + Move the repository to un-ordered mode + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMock(System.Type,System.Object[])"> + <summary> + Creates a mock for the specified type. + </summary> + <param name="type">Type.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMock(System.Type,System.Object[])"> + <summary> + Creates a strict mock for the specified type. + </summary> + <param name="type">Type.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMockWithRemoting(System.Type,System.Object[])"> + <summary> + Creates a remoting mock for the specified type. + </summary> + <param name="type">Type.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMockWithRemoting(System.Type,System.Object[])"> + <summary> + Creates a strict remoting mock for the specified type. + </summary> + <param name="type">Type.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMockWithRemoting``1(System.Object[])"> + <summary> + Creates a remoting mock for the specified type. + </summary> + <typeparam name="T"></typeparam> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMockWithRemoting``1(System.Object[])"> + <summary> + Creates a strict remoting mock for the specified type. + </summary> + <typeparam name="T"></typeparam> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMultiMock(System.Type,System.Type[])"> + <summary> + Creates a mock from several types, with strict semantics. + Only <paramref name="mainType"/> may be a class. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMultiMock(System.Type,System.Type[])"> + <summary> + Creates a strict mock from several types, with strict semantics. + Only <paramref name="mainType"/> may be a class. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMultiMock(System.Type,System.Type[],System.Object[])"> + <summary> + Creates a mock from several types, with strict semantics. + Only <paramref name="mainType"/> may be a class. + </summary> + <param name="mainType">The main type to mock.</param> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMultiMock(System.Type,System.Type[],System.Object[])"> + <summary> + Creates a strict mock from several types, with strict semantics. + Only <paramref name="mainType"/> may be a class. + </summary> + <param name="mainType">The main type to mock.</param> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMultiMock(System.Type,System.Type[])"> + <summary> + Creates a mock from several types, with dynamic semantics. + Only <paramref name="mainType"/> may be a class. + </summary> + <param name="mainType">The main type to mock.</param> + <param name="extraTypes">Extra interface types to mock.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMultiMock(System.Type,System.Type[],System.Object[])"> + <summary> + Creates a mock from several types, with dynamic semantics. + Only <paramref name="mainType"/> may be a class. + </summary> + <param name="mainType">The main type to mock.</param> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMock(System.Type,System.Object[])"> + <summary> + Creates a dynamic mock for the specified type. + </summary> + <param name="type">Type.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMockWithRemoting(System.Type,System.Object[])"> + <summary> + Creates a dynamic mock for the specified type. + </summary> + <param name="type">Type.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMockWithRemoting``1(System.Object[])"> + <summary> + Creates a dynamic mock for the specified type. + </summary> + <typeparam name="T"></typeparam> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.PartialMock(System.Type,System.Object[])"> + <summary> + Creates a mock object that defaults to calling the class methods. + </summary> + <param name="type">Type.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.PartialMultiMock(System.Type,System.Type[])"> + <summary> + Creates a mock object that defaults to calling the class methods. + </summary> + <param name="type">Type.</param> + <param name="extraTypes">Extra interface types to mock.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.PartialMultiMock(System.Type,System.Type[],System.Object[])"> + <summary> + Creates a mock object that defaults to calling the class methods. + </summary> + <param name="type">Type.</param> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.RemotingMock(System.Type,Rhino.Mocks.MockRepository.CreateMockState)"> + <summary> + Creates a mock object using remoting proxies + </summary> + <param name="type">Type to mock - must be MarshalByRefObject</param> + <returns>Mock object</returns> + <remarks>Proxy mock can mock non-virtual methods, but not static methods</remarks> + <param name="factory">Creates the mock state for this proxy</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.Replay(System.Object)"> + <summary> + Cause the mock state to change to replay, any further call is compared to the + ones that were called in the record state. + </summary> + <param name="obj">the object to move to replay state</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.ReplayCore(System.Object,System.Boolean)"> + <summary> + Cause the mock state to change to replay, any further call is compared to the + ones that were called in the record state. + </summary> + <param name="obj">the object to move to replay state</param> + <param name="checkInsideOrdering"></param> + </member> + <member name="M:Rhino.Mocks.MockRepository.BackToRecord(System.Object)"> + <summary> + Move the mocked object back to record state. + Will delete all current expectations! + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.BackToRecord(System.Object,Rhino.Mocks.BackToRecordOptions)"> + <summary> + Move the mocked object back to record state. + Optionally, can delete all current expectations, but allows more granularity about how + it would behave with regard to the object state. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.Verify(System.Object)"> + <summary> + Verify that all the expectations for this object were fulfilled. + </summary> + <param name="obj">the object to verify the expectations for</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.LastMethodCall``1(System.Object)"> + <summary> + Get the method options for the last call on + mockedInstance. + </summary> + <param name="mockedInstance">The mock object</param> + <returns>Method options for the last call</returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.GetMockObjectFromInvocationProxy(System.Object)"> + <summary> + Maps an invocation proxy back to the mock object instance that was originally + returned to client code which might have been a delegate to this proxy. + </summary> + <param name="invocationProxy">The mock object proxy from the intercepted invocation</param> + <returns>The mock object</returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMockObject(System.Type,Rhino.Mocks.MockRepository.CreateMockState,System.Type[],System.Object[])"> + <summary> + This is provided to allow advance extention functionality, where Rhino Mocks standard + functionality is not enough. + </summary> + <param name="type">The type to mock</param> + <param name="factory">Delegate that create the first state of the mocked object (usualy the record state).</param> + <param name="extras">Additional types to be implemented, this can be only interfaces </param> + <param name="argumentsForConstructor">optional arguments for the constructor</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.GetMockedObject(System.Object)"> + <summary> + Method: GetMockedObject + Get an IProxy from a mocked object instance, or throws if the + object is not a mock object. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.GetMockedObjectOrNull(System.Object)"> + <summary> + Method: GetMockedObjectOrNull + Get an IProxy from a mocked object instance, or null if the + object is not a mock object. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.PopRecorder"> + <summary> + Pops the recorder. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.PushRecorder(Rhino.Mocks.Interfaces.IMethodRecorder)"> + <summary> + Pushes the recorder. + </summary> + <param name="newRecorder">New recorder.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.BackToRecordAll"> + <summary> + All the mock objects in this repository will be moved + to record state. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.BackToRecordAll(Rhino.Mocks.BackToRecordOptions)"> + <summary> + All the mock objects in this repository will be moved + to record state. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.ReplayAll"> + <summary> + Replay all the mocks from this repository + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.VerifyAll"> + <summary> + Verify all the mocks from this repository + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.GetProxyGenerator(System.Type)"> + <summary> + Gets the proxy generator for a specific type. Having a single ProxyGenerator + with multiple types linearly degrades the performance so this implementation + keeps one ProxyGenerator per type. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.SetExceptionToBeThrownOnVerify(System.Object,Rhino.Mocks.Exceptions.ExpectationViolationException)"> + <summary> + Set the exception to be thrown when verified is called. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMock``1(System.Object[])"> + <summary> + Creates a mock for the spesified type. + </summary> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMock``1(System.Object[])"> + <summary> + Creates a strict mock for the spesified type. + </summary> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMock``1(System.Object[])"> + <summary> + Creates a dynamic mock for the specified type. + </summary> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMultiMock``1(System.Type[])"> + <summary> + Creates a mock object from several types. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMultiMock``1(System.Type[])"> + <summary> + Creates a strict mock object from several types. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMultiMock``1(System.Type[])"> + <summary> + Create a mock object from several types with dynamic semantics. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.PartialMultiMock``1(System.Type[])"> + <summary> + Create a mock object from several types with partial semantics. + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.CreateMultiMock``1(System.Type[],System.Object[])"> + <summary> + Create a mock object from several types with strict semantics. + </summary> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.StrictMultiMock``1(System.Type[],System.Object[])"> + <summary> + Create a strict mock object from several types with strict semantics. + </summary> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.DynamicMultiMock``1(System.Type[],System.Object[])"> + <summary> + Create a mock object from several types with dynamic semantics. + </summary> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.PartialMultiMock``1(System.Type[],System.Object[])"> + <summary> + Create a mock object from several types with partial semantics. + </summary> + <param name="extraTypes">Extra interface types to mock.</param> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.PartialMock``1(System.Object[])"> + <summary> + Create a mock object with from a class that defaults to calling the class methods + </summary> + <param name="argumentsForConstructor">Arguments for the class' constructor, if mocking a concrete class</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.Stub``1(System.Object[])"> + <summary> + Create a stub object, one that has properties and events ready for use, and + can have methods called on it. It requires an explicit step in order to create + an expectation for a stub. + </summary> + <param name="argumentsForConstructor">The arguments for constructor.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.Stub(System.Type,System.Object[])"> + <summary> + Create a stub object, one that has properties and events ready for use, and + can have methods called on it. It requires an explicit step in order to create + an expectation for a stub. + </summary> + <param name="type">The type.</param> + <param name="argumentsForConstructor">The arguments for constructor.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.GenerateStub``1(System.Object[])"> + <summary> + Generates a stub without mock repository + </summary> + <param name="argumentsForConstructor">The arguments for constructor.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.GenerateStub(System.Type,System.Object[])"> + <summary> + Generates the stub without mock repository + </summary> + <param name="type">The type.</param> + <param name="argumentsForConstructor">The arguments for constructor.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.IsInReplayMode(System.Object)"> + <summary> + Returns true if the passed mock is currently in replay mode. + </summary> + <param name="mock">The mock to test.</param> + <returns>True if the mock is in replay mode, false otherwise.</returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.GenerateMock``1"> + <summary> + Generate a mock object without needing the mock repository + </summary> + </member> + <member name="M:Rhino.Mocks.MockRepository.IsStub(System.Object)"> + <summary> + Determines whether the specified proxy is a stub. + </summary> + <param name="proxy">The proxy.</param> + </member> + <member name="M:Rhino.Mocks.MockRepository.Record"> + <summary> + </summary> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.MockRepository.Playback"> + <summary> + </summary> + <returns></returns> + </member> + <member name="P:Rhino.Mocks.MockRepository.Recorder"> + <summary> + Gets the recorder. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.MockRepository.Replayer"> + <summary> + Gets the replayer for this repository. + </summary> + <value></value> + </member> + <member name="P:Rhino.Mocks.MockRepository.LastMockedObject"> + <summary> + Gets the last proxy which had a method call. + </summary> + </member> + <member name="T:Rhino.Mocks.MockRepository.CreateMockState"> + <summary> + Delegate: CreateMockState + This is used internally to cleanly handle the creation of different + RecordMockStates. + </summary> + </member> + <member name="T:Rhino.Mocks.RhinoMocks"> + <summary> + Used for [assembly: InternalsVisibleTo(RhinoMocks.StrongName)] + Used for [assembly: InternalsVisibleTo(RhinoMocks.NormalName)] + </summary> + </member> + <member name="F:Rhino.Mocks.RhinoMocks.StrongName"> + <summary> + Strong name for the Dynamic Proxy assemblies. Used for InternalsVisibleTo specification. + </summary> + </member> + <member name="F:Rhino.Mocks.RhinoMocks.NormalName"> + <summary> + Normal name for dynamic proxy assemblies. Used for InternalsVisibleTo specification. + </summary> + </member> + <member name="F:Rhino.Mocks.RhinoMocks.Logger"> + <summary> + Logs all method calls for methods + </summary> + </member> + <member name="T:Rhino.Mocks.RhinoMocksExtensions"> + <summary> + A set of extension methods that adds Arrange Act Assert mode to Rhino Mocks + </summary> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.Expect``1(``0,System.Action{``0})"> + <summary> + Create an expectation on this mock for this action to occur + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.BackToRecord``1(``0)"> + <summary> + Reset all expectations on this mock object + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.BackToRecord``1(``0,Rhino.Mocks.BackToRecordOptions)"> + <summary> + Reset the selected expectation on this mock object + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="options">The options to reset the expectations on this mock.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.Replay``1(``0)"> + <summary> + Cause the mock state to change to replay, any further call is compared to the + ones that were called in the record state. + </summary> + <param name="mock">the mocked object to move to replay state</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.GetMockRepository``1(``0)"> + <summary> + Gets the mock repository for this specificied mock object + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.Expect``2(``0,System.Func{``0,``1})"> + <summary> + Create an expectation on this mock for this action to occur + </summary> + <typeparam name="T"></typeparam> + <typeparam name="R"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.Stub``1(``0,System.Action{``0})"> + <summary> + Tell the mock object to perform a certain action when a matching + method is called. + Does not create an expectation for this method. + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.Stub``2(``0,System.Func{``0,``1})"> + <summary> + Tell the mock object to perform a certain action when a matching + method is called. + Does not create an expectation for this method. + </summary> + <typeparam name="T"></typeparam> + <typeparam name="R"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.GetArgumentsForCallsMadeOn``1(``0,System.Action{``0})"> + <summary> + Gets the arguments for calls made on this mock object and the method that was called + in the action. + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <returns></returns> + <example> + Here we will get all the arguments for all the calls made to DoSomething(int) + <code> + var argsForCalls = foo54.GetArgumentsForCallsMadeOn(x => x.DoSomething(0)) + </code> + </example> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.GetArgumentsForCallsMadeOn``1(``0,System.Action{``0},System.Action{Rhino.Mocks.Interfaces.IMethodOptions{System.Object}})"> + <summary> + Gets the arguments for calls made on this mock object and the method that was called + in the action and matches the given constraints + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <param name="setupConstraints">The setup constraints.</param> + <returns></returns> + <example> + Here we will get all the arguments for all the calls made to DoSomething(int) + <code> + var argsForCalls = foo54.GetArgumentsForCallsMadeOn(x => x.DoSomething(0)) + </code> + </example> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.AssertWasCalled``1(``0,System.Action{``0})"> + <summary> + Asserts that a particular method was called on this mock object + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.AssertWasCalled``1(``0,System.Action{``0},System.Action{Rhino.Mocks.Interfaces.IMethodOptions{System.Object}})"> + <summary> + Asserts that a particular method was called on this mock object that match + a particular constraint set. + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <param name="setupConstraints">The setup constraints.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.AssertWasNotCalled``1(``0,System.Action{``0})"> + <summary> + Asserts that a particular method was NOT called on this mock object + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.AssertWasNotCalled``1(``0,System.Action{``0},System.Action{Rhino.Mocks.Interfaces.IMethodOptions{System.Object}})"> + <summary> + Asserts that a particular method was NOT called on this mock object that match + a particular constraint set. + </summary> + <typeparam name="T"></typeparam> + <param name="mock">The mock.</param> + <param name="action">The action.</param> + <param name="setupConstraints">The setup constraints.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.VerifyAllExpectations(System.Object)"> + <summary> + Verifies all expectations on this mock object + </summary> + <param name="mockObject">The mock object.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.GetEventRaiser``1(``0,System.Action{``0})"> + <summary> + Gets the event raiser for the event that was called in the action passed + </summary> + <typeparam name="TEventSource">The type of the event source.</typeparam> + <param name="mockObject">The mock object.</param> + <param name="eventSubscription">The event subscription.</param> + <returns></returns> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.Raise``1(``0,System.Action{``0},System.Object,System.EventArgs)"> + <summary> + Raise the specified event using the passed arguments. + The even is extracted from the passed labmda + </summary> + <typeparam name="TEventSource">The type of the event source.</typeparam> + <param name="mockObject">The mock object.</param> + <param name="eventSubscription">The event subscription.</param> + <param name="sender">The sender.</param> + <param name="args">The <see cref="T:System.EventArgs"/> instance containing the event data.</param> + </member> + <member name="M:Rhino.Mocks.RhinoMocksExtensions.Raise``1(``0,System.Action{``0},System.Object[])"> + <summary> + Raise the specified event using the passed arguments. + The even is extracted from the passed labmda + </summary> + <typeparam name="TEventSource">The type of the event source.</typeparam> + <param name="mockObject">The mock object.</param> + <param name="eventSubscription">The event subscription.</param> + <param name="args">The args.</param> + </member> + <member name="T:Rhino.Mocks.RhinoMocksExtensions.VoidType"> + <summary> + Fake type that disallow creating it. + Should have been System.Type, but we can't use it. + </summary> + </member> + <member name="T:Rhino.Mocks.SetupResult"> + <summary> + Setup method calls to repeat any number of times. + </summary> + </member> + <member name="M:Rhino.Mocks.SetupResult.For``1(``0)"> + <summary> + Get the method options and set the last method call to repeat + any number of times. + This also means that the method would transcend ordering + </summary> + </member> + <member name="M:Rhino.Mocks.SetupResult.On(System.Object)"> + <summary> + Get the method options for the last method call on the mockInstance and set it + to repeat any number of times. + This also means that the method would transcend ordering + </summary> + </member> + <member name="T:Rhino.Mocks.With"> + <summary> + Allows easier access to MockRepository, works closely with Mocker.Current to + allow access to a context where the mock repository is automatially verified at + the end of the code block. + </summary> + </member> + <member name="M:Rhino.Mocks.With.Mocks(Rhino.Mocks.With.Proc)"> + <summary> + Initialize a code block where Mocker.Current is initialized. + At the end of the code block, all the expectation will be verified. + This overload will create a new MockRepository. + </summary> + <param name="methodCallThatHasMocks">The code that will be executed under the mock context</param> + </member> + <member name="M:Rhino.Mocks.With.Mocks(Rhino.Mocks.MockRepository,Rhino.Mocks.With.Proc)"> + <summary> + Initialize a code block where Mocker.Current is initialized. + At the end of the code block, all the expectation will be verified. + This overload will create a new MockRepository. + </summary> + <param name="mocks">The mock repository to use, at the end of the code block, VerifyAll() will be called on the repository.</param> + <param name="methodCallThatHasMocks">The code that will be executed under the mock context</param> + </member> + <member name="M:Rhino.Mocks.With.Mocks(Rhino.Mocks.MockRepository)"> + <summary> + Create a FluentMocker + </summary> + <param name="mocks">The mock repository to use.</param> + </member> + <member name="T:Rhino.Mocks.With.Proc"> + <summary> + A method with no arguments and no return value that will be called under the mock context. + </summary> + </member> + <member name="T:Rhino.Mocks.With.FluentMocker"> + <summary> + FluentMocker implements some kind of fluent interface attempt + for saying "With the Mocks [mocks], Expecting (in same order) [things] verify [that]." + </summary> + </member> + <member name="T:Rhino.Mocks.With.IMockVerifier"> + <summary> + Interface to verify previously defined expectations + </summary> + </member> + <member name="M:Rhino.Mocks.With.IMockVerifier.Verify(Rhino.Mocks.With.Proc)"> + <summary> + Verifies if a piece of code + </summary> + </member> + <member name="M:Rhino.Mocks.With.FluentMocker.Expecting(Rhino.Mocks.With.Proc)"> + <summary> + Defines unordered expectations + </summary> + <param name="methodCallsDescribingExpectations">A delegate describing the expectations</param> + <returns>an IMockVerifier</returns> + </member> + <member name="M:Rhino.Mocks.With.FluentMocker.ExpectingInSameOrder(Rhino.Mocks.With.Proc)"> + <summary> + Defines ordered expectations + </summary> + <param name="methodCallsDescribingExpectations">A delegate describing the expectations</param> + <returns>an IMockVerifier</returns> + </member> + <member name="M:Rhino.Mocks.With.FluentMocker.Verify(Rhino.Mocks.With.Proc)"> + <summary> + Verifies previously defined expectations + </summary> + </member> + </members> +</doc> diff --git a/csharp/ProtocolBuffers.Test/lib/nunit.framework.dll b/csharp/ProtocolBuffers.Test/lib/nunit.framework.dll Binary files differnew file mode 100644 index 00000000..3c401e69 --- /dev/null +++ b/csharp/ProtocolBuffers.Test/lib/nunit.framework.dll diff --git a/csharp/ProtocolBuffers/ByteString.cs b/csharp/ProtocolBuffers/ByteString.cs new file mode 100644 index 00000000..1ce2453e --- /dev/null +++ b/csharp/ProtocolBuffers/ByteString.cs @@ -0,0 +1,96 @@ +using System.Text; +using System; + +namespace Google.ProtocolBuffers { + /// <summary> + /// Immutable array of bytes. + /// TODO(jonskeet): Implement the common collection interfaces? + /// </summary> + public sealed class ByteString { + + private static readonly ByteString empty = new ByteString(new byte[0]); + + private byte[] bytes; + + /// <summary> + /// Constructs a new ByteString from the given byte array. The array is + /// *not* copied, and must not be modified after this constructor is called. + /// </summary> + private ByteString(byte[] bytes) { + this.bytes = bytes; + } + + /// <summary> + /// Returns an empty ByteString. + /// </summary> + public static ByteString Empty { + get { return empty; } + } + + /// <summary> + /// Returns the length of this ByteString in bytes. + /// </summary> + public int Length { + get { return bytes.Length; } + } + + public bool IsEmpty { + get { return Length == 0; } + } + + public byte[] ToByteArray() { + return (byte[])bytes.Clone(); + } + + /// <summary> + /// Constructs a ByteString from the given array. The contents + /// are copied, so further modifications to the array will not + /// be reflected in the returned ByteString. + /// </summary> + public static ByteString CopyFrom(byte[] bytes) { + return new ByteString((byte[]) bytes.Clone()); + } + + /// <summary> + /// Constructs a ByteString from a portion of a byte array. + /// </summary> + public static ByteString CopyFrom(byte[] bytes, int offset, int count) { + byte[] portion = new byte[count]; + Array.Copy(bytes, offset, portion, 0, count); + return new ByteString(portion); + } + + /// <summary> + /// Creates a new ByteString by encoding the specified text with + /// the given encoding. + /// </summary> + public static ByteString CopyFrom(string text, Encoding encoding) { + return new ByteString(encoding.GetBytes(text)); + } + + /// <summary> + /// Creates a new ByteString by encoding the specified text in UTF-8. + /// </summary> + public static ByteString CopyFromUtf8(string text) { + return CopyFrom(text, Encoding.UTF8); + } + + /// <summary> + /// Retuns the byte at the given index. + /// </summary> + public byte this[int index] { + get { return bytes[index]; } + } + + public string ToString(Encoding encoding) { + return encoding.GetString(bytes); + } + + public string ToStringUtf8() { + return ToString(Encoding.UTF8); + } + + // TODO(jonskeet): CopyTo, Equals, GetHashCode if they turn out to be required + // TODO(jonskeet): Input/Output stuff + } +} diff --git a/csharp/ProtocolBuffers/CodedInputStream.cs b/csharp/ProtocolBuffers/CodedInputStream.cs new file mode 100644 index 00000000..66dae52c --- /dev/null +++ b/csharp/ProtocolBuffers/CodedInputStream.cs @@ -0,0 +1,31 @@ + +namespace Google.ProtocolBuffers { + public sealed class CodedInputStream { + + /// <summary> + /// Decode a 32-bit value with ZigZag encoding. + /// </summary> + /// <remarks> + /// ZigZag encodes signed integers into values that can be efficiently + /// encoded with varint. (Otherwise, negative values must be + /// sign-extended to 64 bits to be varint encoded, thus always taking + /// 10 bytes on the wire.) + /// </remarks> + public static int DecodeZigZag32(uint n) { + return (int)(n >> 1) ^ -(int)(n & 1); + } + + /// <summary> + /// Decode a 32-bit value with ZigZag encoding. + /// </summary> + /// <remarks> + /// ZigZag encodes signed integers into values that can be efficiently + /// encoded with varint. (Otherwise, negative values must be + /// sign-extended to 64 bits to be varint encoded, thus always taking + /// 10 bytes on the wire.) + /// </remarks> + public static long DecodeZigZag64(ulong n) { + return (long)(n >> 1) ^ -(long)(n & 1); + } + } +} diff --git a/csharp/ProtocolBuffers/CodedOutputStream.cs b/csharp/ProtocolBuffers/CodedOutputStream.cs new file mode 100644 index 00000000..51d5d657 --- /dev/null +++ b/csharp/ProtocolBuffers/CodedOutputStream.cs @@ -0,0 +1,708 @@ +// Protocol Buffers - Google's data interchange format +// Copyright 2008 Google Inc. +// http://code.google.com/p/protobuf/ +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. +using System; +using System.IO; +using System.Text; + +namespace Google.ProtocolBuffers { + + /// <summary> + /// Encodes and writes protocol message fields. + /// </summary> + /// <remarks> + /// This class contains two kinds of methods: methods that write specific + /// protocol message constructs and field types (e.g. WriteTag and + /// WriteInt32) and methods that write low-level values (e.g. + /// WriteRawVarint32 and WriteRawBytes). If you are writing encoded protocol + /// messages, you should use the former methods, but if you are writing some + /// other format of your own design, use the latter. The names of the former + /// methods are taken from the protocol buffer type names, not .NET types. + /// (Hence WriteFloat instead of WriteSingle, and WriteBool instead of WriteBoolean.) + /// </remarks> + public sealed class CodedOutputStream { + /// <summary> + /// The buffer size used by CreateInstance(Stream). + /// </summary> + public static readonly int DefaultBufferSize = 4096; + + private readonly byte[] buffer; + private readonly int limit; + private int position; + private readonly Stream output; + + #region Construction + private CodedOutputStream(byte[] buffer, int offset, int length) { + this.output = null; + this.buffer = buffer; + this.position = offset; + this.limit = offset + length; + } + + private CodedOutputStream(Stream output, byte[] buffer) { + this.output = output; + this.buffer = buffer; + this.position = 0; + this.limit = buffer.Length; + } + + /// <summary> + /// Creates a new CodedOutputStream which write to the given stream. + /// </summary> + public static CodedOutputStream CreateInstance(Stream output) { + return CreateInstance(output, DefaultBufferSize); + } + + /// <summary> + /// Creates a new CodedOutputStream which write to the given stream and uses + /// the specified buffer size. + /// </summary> + public static CodedOutputStream CreateInstance(Stream output, int bufferSize) { + return new CodedOutputStream(output, new byte[bufferSize]); + } + + /// <summary> + /// Creates a new CodedOutputStream that writes directly to the given + /// byte array. If more bytes are written than fit in the array, + /// OutOfSpaceException will be thrown. + /// </summary> + public static CodedOutputStream CreateInstance(byte[] flatArray) { + return CreateInstance(flatArray, 0, flatArray.Length); + } + + /// <summary> + /// Creates a new CodedOutputStream that writes directly to the given + /// byte array slice. If more bytes are written than fit in the array, + /// OutOfSpaceException will be thrown. + /// </summary> + public static CodedOutputStream CreateInstance(byte[] flatArray, int offset, int length) { + return new CodedOutputStream(flatArray, offset, length); + } + #endregion + + #region Writing of tags etc + /// <summary> + /// Writes a double field value, including tag, to the stream. + /// </summary> + public void WriteDouble(int fieldNumber, double value) { + WriteTag(fieldNumber, WireFormat.WireType.Fixed64); + WriteRawLittleEndian64(BitConverter.DoubleToInt64Bits(value)); + } + + /// <summary> + /// Writes a float field value, including tag, to the stream. + /// </summary> + public void WriteFloat(int fieldNumber, float value) { + WriteTag(fieldNumber, WireFormat.WireType.Fixed32); + // FIXME: How do we convert a single to 32 bits? (Without unsafe code) + //WriteRawLittleEndian32(BitConverter.SingleT(value)); + } + + /// <summary> + /// Writes a uint64 field value, including tag, to the stream. + /// </summary> + public void WriteUInt64(int fieldNumber, ulong value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + WriteRawVarint64(value); + } + + /// <summary> + /// Writes an int64 field value, including tag, to the stream. + /// </summary> + public void WriteInt64(int fieldNumber, long value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + WriteRawVarint64((ulong)value); + } + + /// <summary> + /// Writes an int32 field value, including tag, to the stream. + /// </summary> + public void WriteInt32(int fieldNumber, int value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + if (value >= 0) { + WriteRawVarint32((uint)value); + } else { + // Must sign-extend. + WriteRawVarint64((ulong)value); + } + } + + /// <summary> + /// Writes a fixed64 field value, including tag, to the stream. + /// </summary> + public void WriteFixed64(int fieldNumber, long value) { + WriteTag(fieldNumber, WireFormat.WireType.Fixed64); + WriteRawLittleEndian64(value); + } + + /// <summary> + /// Writes a fixed32 field value, including tag, to the stream. + /// </summary> + public void WriteFixed32(int fieldNumber, int value) { + WriteTag(fieldNumber, WireFormat.WireType.Fixed32); + WriteRawLittleEndian32(value); + } + + /// <summary> + /// Writes a bool field value, including tag, to the stream. + /// </summary> + public void WriteBool(int fieldNumber, bool value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + WriteRawByte(value ? (byte)1 : (byte)0); + } + + /// <summary> + /// Writes a string field value, including tag, to the stream. + /// </summary> + public void WriteString(int fieldNumber, string value) { + WriteTag(fieldNumber, WireFormat.WireType.LengthDelimited); + // TODO(jonskeet): Optimise this if possible + // Unfortunately there does not appear to be any way to tell Java to encode + // UTF-8 directly into our buffer, so we have to let it create its own byte + // array and then copy. In .NET we can do the same thing very easily, + // so we don't need to worry about only writing one buffer at a time. + // We can optimise later. + byte[] bytes = Encoding.UTF8.GetBytes(value); + WriteRawVarint32((uint)bytes.Length); + WriteRawBytes(bytes); + } + + /// <summary> + /// Writes a group field value, including tag, to the stream. + /// </summary> + public void WriteGroup(int fieldNumber, IMessage value) { + WriteTag(fieldNumber, WireFormat.WireType.StartGroup); + value.WriteTo(this); + WriteTag(fieldNumber, WireFormat.WireType.EndGroup); + } + + public void WriteUnknownGroup(int fieldNumber, UnknownFieldSet value) { + WriteTag(fieldNumber, WireFormat.WireType.StartGroup); + value.WriteTo(this); + WriteTag(fieldNumber, WireFormat.WireType.EndGroup); + } + + public void WriteMessage(int fieldNumber, IMessage value) { + WriteTag(fieldNumber, WireFormat.WireType.LengthDelimited); + WriteRawVarint32((uint)value.SerializedSize); + value.WriteTo(this); + } + + public void WriteBytes(int fieldNumber, ByteString value) { + // TODO(jonskeet): Optimise this! (No need to copy the bytes twice.) + byte[] bytes = value.ToByteArray(); + WriteRawVarint32((uint)bytes.Length); + WriteRawBytes(bytes); + } + + public void WriteUInt32(int fieldNumber, uint value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + WriteRawVarint32(value); + } + + public void WriteEnum(int fieldNumber, int value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + WriteRawVarint32((uint)value); + } + + public void WriteSFixed32(int fieldNumber, int value) { + WriteTag(fieldNumber, WireFormat.WireType.Fixed32); + WriteRawVarint32((uint)value); + } + + public void WriteSFixed64(int fieldNumber, long value) { + WriteTag(fieldNumber, WireFormat.WireType.Fixed64); + WriteRawVarint64((ulong)value); + } + + public void WriteSInt32(int fieldNumber, int value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + WriteRawVarint32(EncodeZigZag32(value)); + } + + public void WriteSInt64(int fieldNumber, long value) { + WriteTag(fieldNumber, WireFormat.WireType.Varint); + WriteRawVarint64(EncodeZigZag64(value)); + } + + public void WriteMessageSetExtension(int fieldNumber, IMessage value) { + WriteTag(WireFormat.MessageSetField.Item, WireFormat.WireType.StartGroup); + WriteUInt32(WireFormat.MessageSetField.TypeID, (uint)fieldNumber); + WriteMessage(WireFormat.MessageSetField.Message, value); + WriteTag(WireFormat.MessageSetField.Item, WireFormat.WireType.EndGroup); + } + + public void WriteRawMessageSetExtension(int fieldNumber, ByteString value) { + WriteTag(WireFormat.MessageSetField.Item, WireFormat.WireType.StartGroup); + WriteUInt32(WireFormat.MessageSetField.TypeID, (uint)fieldNumber); + WriteBytes(WireFormat.MessageSetField.Message, value); + WriteTag(WireFormat.MessageSetField.Item, WireFormat.WireType.EndGroup); + } + + public void WriteField(Descriptors.FieldDescriptor.Type fieldType, int fieldNumber, object value) { + switch (fieldType) { + case Descriptors.FieldDescriptor.Type.Double: WriteDouble(fieldNumber, (double)value); break; + case Descriptors.FieldDescriptor.Type.Float: WriteFloat(fieldNumber, (float)value); break; + case Descriptors.FieldDescriptor.Type.Int64: WriteInt64(fieldNumber, (long)value); break; + case Descriptors.FieldDescriptor.Type.UInt64: WriteUInt64(fieldNumber, (ulong)value); break; + case Descriptors.FieldDescriptor.Type.Int32: WriteInt32(fieldNumber, (int)value); break; + case Descriptors.FieldDescriptor.Type.Fixed64: WriteFixed64(fieldNumber, (long)value); break; + case Descriptors.FieldDescriptor.Type.Fixed32: WriteFixed32(fieldNumber, (int)value); break; + case Descriptors.FieldDescriptor.Type.Bool: WriteBool(fieldNumber, (bool)value); break; + case Descriptors.FieldDescriptor.Type.String: WriteString(fieldNumber, (string)value); break; + case Descriptors.FieldDescriptor.Type.Group: WriteGroup(fieldNumber, (IMessage)value); break; + case Descriptors.FieldDescriptor.Type.Message: WriteMessage(fieldNumber, (IMessage)value); break; + case Descriptors.FieldDescriptor.Type.Bytes: WriteBytes(fieldNumber, (ByteString)value); break; + case Descriptors.FieldDescriptor.Type.UInt32: WriteUInt32(fieldNumber, (uint)value); break; + case Descriptors.FieldDescriptor.Type.SFixed32: WriteSFixed32(fieldNumber, (int)value); break; + case Descriptors.FieldDescriptor.Type.SFixed64: WriteSFixed64(fieldNumber, (long)value); break; + case Descriptors.FieldDescriptor.Type.SInt32: WriteSInt32(fieldNumber, (int)value); break; + case Descriptors.FieldDescriptor.Type.SInt64: WriteSInt64(fieldNumber, (long)value); break; + case Descriptors.FieldDescriptor.Type.Enum: WriteEnum(fieldNumber, ((Descriptors.EnumValueDescriptor)value).Number); + break; + } + } + + #endregion + + #region Underlying writing primitives + /// <summary> + /// Encodes and writes a tag. + /// </summary> + public void WriteTag(int fieldNumber, WireFormat.WireType type) { + WriteRawVarint32(WireFormat.MakeTag(fieldNumber, type)); + } + + public void WriteRawVarint32(uint value) { + while (true) { + if ((value & ~0x7F) == 0) { + WriteRawByte(value); + return; + } else { + WriteRawByte((value & 0x7F) | 0x80); + value >>= 7; + } + } + } + + public void WriteRawVarint64(ulong value) { + while (true) { + if ((value & ~0x7FUL) == 0) { + WriteRawByte((uint)value); + return; + } else { + WriteRawByte(((uint)value & 0x7F) | 0x80); + value >>= 7; + } + } + } + + public void WriteRawLittleEndian32(int value) { + WriteRawByte((byte)value); + WriteRawByte((byte)(value >> 8)); + WriteRawByte((byte)(value >> 16)); + WriteRawByte((byte)(value >> 24)); + } + + public void WriteRawLittleEndian64(long value) { + WriteRawByte((byte)value); + WriteRawByte((byte)(value >> 8)); + WriteRawByte((byte)(value >> 16)); + WriteRawByte((byte)(value >> 24)); + WriteRawByte((byte)(value >> 32)); + WriteRawByte((byte)(value >> 40)); + WriteRawByte((byte)(value >> 48)); + WriteRawByte((byte)(value >> 56)); + } + + public void WriteRawByte(byte value) { + if (position == limit) { + RefreshBuffer(); + } + + buffer[position++] = value; + } + + public void WriteRawByte(uint value) { + WriteRawByte((byte)value); + } + + /// <summary> + /// Writes out an array of bytes. + /// </summary> + public void WriteRawBytes(byte[] value) { + WriteRawBytes(value, 0, value.Length); + } + + /// <summary> + /// Writes out part of an array of bytes. + /// </summary> + public void WriteRawBytes(byte[] value, int offset, int length) { + if (limit - position >= length) { + Array.Copy(value, offset, buffer, position, length); + // We have room in the current buffer. + position += length; + } else { + // Write extends past current buffer. Fill the rest of this buffer and + // flush. + int bytesWritten = limit - position; + Array.Copy(value, offset, buffer, position, bytesWritten); + offset += bytesWritten; + length -= bytesWritten; + position = limit; + RefreshBuffer(); + + // Now deal with the rest. + // Since we have an output stream, this is our buffer + // and buffer offset == 0 + if (length <= limit) { + // Fits in new buffer. + Array.Copy(value, offset, buffer, 0, length); + position = length; + } else { + // Write is very big. Let's do it all at once. + output.Write(value, offset, length); + } + } + } + #endregion + + #region Size computations + + const int LittleEndian64Size = 8; + const int LittleEndian32Size = 4; + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// double field, including the tag. + /// </summary> + public static int ComputeDoubleSize(int fieldNumber, double value) { + return ComputeTagSize(fieldNumber) + LittleEndian64Size; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// float field, including the tag. + /// </summary> + public static int ComputeFloatSize(int fieldNumber, float value) { + return ComputeTagSize(fieldNumber) + LittleEndian32Size; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// uint64 field, including the tag. + /// </summary> + public static int ComputeUInt64Size(int fieldNumber, ulong value) { + return ComputeTagSize(fieldNumber) + ComputeRawVarint64Size(value); + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// int64 field, including the tag. + /// </summary> + public static int ComputeInt64Size(int fieldNumber, long value) { + return ComputeTagSize(fieldNumber) + ComputeRawVarint64Size((ulong)value); + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// int32 field, including the tag. + /// </summary> + public static int ComputeInt32Size(int fieldNumber, int value) { + if (value >= 0) { + return ComputeTagSize(fieldNumber) + ComputeRawVarint32Size((uint)value); + } else { + // Must sign-extend. + return ComputeTagSize(fieldNumber) + 10; + } + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// fixed64 field, including the tag. + /// </summary> + public static int ComputeFixed64Size(int fieldNumber, long value) { + return ComputeTagSize(fieldNumber) + LittleEndian64Size; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// fixed32 field, including the tag. + /// </summary> + public static int ComputeFixed32Size(int fieldNumber, int value) { + return ComputeTagSize(fieldNumber) + LittleEndian32Size; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// bool field, including the tag. + /// </summary> + public static int ComputeBoolSize(int fieldNumber, bool value) { + return ComputeTagSize(fieldNumber) + 1; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// string field, including the tag. + /// </summary> + public static int ComputeStringSize(int fieldNumber, String value) { + int byteArraySize = Encoding.UTF8.GetByteCount(value); + return ComputeTagSize(fieldNumber) + + ComputeRawVarint32Size((uint)byteArraySize) + + byteArraySize; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// group field, including the tag. + /// </summary> + public static int ComputeGroupSize(int fieldNumber, IMessage value) { + return ComputeTagSize(fieldNumber) * 2 + value.SerializedSize; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// group field represented by an UnknownFieldSet, including the tag. + /// </summary> + public static int ComputeUnknownGroupSize(int fieldNumber, + UnknownFieldSet value) { + return ComputeTagSize(fieldNumber) * 2 + value.SerializedSize; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// embedded message field, including the tag. + /// </summary> + public static int ComputeMessageSize(int fieldNumber, IMessage value) { + int size = value.SerializedSize; + return ComputeTagSize(fieldNumber) + ComputeRawVarint32Size((uint)size) + size; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// bytes field, including the tag. + /// </summary> + public static int ComputeBytesSize(int fieldNumber, ByteString value) { + return ComputeTagSize(fieldNumber) + + ComputeRawVarint32Size((uint)value.Length) + + value.Length; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// uint32 field, including the tag. + /// </summary> + public static int ComputeUInt32Size(int fieldNumber, uint value) { + return ComputeTagSize(fieldNumber) + ComputeRawVarint32Size(value); + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// enum field, including the tag. The caller is responsible for + /// converting the enum value to its numeric value. + /// </summary> + public static int ComputeEnumSize(int fieldNumber, int value) { + return ComputeTagSize(fieldNumber) + ComputeRawVarint32Size((uint)value); + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// sfixed32 field, including the tag. + /// </summary> + public static int ComputeSFixed32Size(int fieldNumber, int value) { + return ComputeTagSize(fieldNumber) + LittleEndian32Size; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// sfixed64 field, including the tag. + /// </summary> + public static int ComputeSFixed64Size(int fieldNumber, long value) { + return ComputeTagSize(fieldNumber) + LittleEndian64Size; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// sint32 field, including the tag. + /// </summary> + public static int ComputeSInt32Size(int fieldNumber, int value) { + return ComputeTagSize(fieldNumber) + + ComputeRawVarint32Size(EncodeZigZag32(value)); + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// sint64 field, including the tag. + /// </summary> + public static int ComputeSInt64Size(int fieldNumber, long value) { + return ComputeTagSize(fieldNumber) + + ComputeRawVarint64Size(EncodeZigZag64(value)); + } + + /* + * Compute the number of bytes that would be needed to encode a + * MessageSet extension to the stream. For historical reasons, + * the wire format differs from normal fields. + */ + /// <summary> + /// Compute the number of bytes that would be needed to encode a + /// MessageSet extension to the stream. For historical reasons, + /// the wire format differs from normal fields. + /// </summary> + public static int ComputeMessageSetExtensionSize(int fieldNumber, IMessage value) { + return ComputeTagSize(WireFormat.MessageSetField.Item) * 2 + + ComputeUInt32Size(WireFormat.MessageSetField.TypeID, (uint) fieldNumber) + + ComputeMessageSize(WireFormat.MessageSetField.Message, value); + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode an + /// unparsed MessageSet extension field to the stream. For + /// historical reasons, the wire format differs from normal fields. + /// </summary> + public static int ComputeRawMessageSetExtensionSize(int fieldNumber, ByteString value) { + return ComputeTagSize(WireFormat.MessageSetField.Item) * 2 + + ComputeUInt32Size(WireFormat.MessageSetField.TypeID, (uint) fieldNumber) + + ComputeBytesSize(WireFormat.MessageSetField.Message, value); + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a varint. + /// </summary> + public static int ComputeRawVarint32Size(uint value) { + if ((value & (0xffffffff << 7)) == 0) return 1; + if ((value & (0xffffffff << 14)) == 0) return 2; + if ((value & (0xffffffff << 21)) == 0) return 3; + if ((value & (0xffffffff << 28)) == 0) return 4; + return 5; + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a varint. + /// </summary> + public static int ComputeRawVarint64Size(ulong value) { + if ((value & (0xffffffffffffffffL << 7)) == 0) return 1; + if ((value & (0xffffffffffffffffL << 14)) == 0) return 2; + if ((value & (0xffffffffffffffffL << 21)) == 0) return 3; + if ((value & (0xffffffffffffffffL << 28)) == 0) return 4; + if ((value & (0xffffffffffffffffL << 35)) == 0) return 5; + if ((value & (0xffffffffffffffffL << 42)) == 0) return 6; + if ((value & (0xffffffffffffffffL << 49)) == 0) return 7; + if ((value & (0xffffffffffffffffL << 56)) == 0) return 8; + if ((value & (0xffffffffffffffffL << 63)) == 0) return 9; + return 10; + } + + + /* + * Compute the number of bytes that would be needed to encode a + * field of arbitrary type, including tag, to the stream. + * + * @param type The field's type. + * @param number The field's number. + * @param value Object representing the field's value. Must be of the exact + * type which would be returned by + * {@link Message#getField(Descriptors.FieldDescriptor)} for + * this field. + */ + public static int ComputeFieldSize(Descriptors.FieldDescriptor.Type fieldType, int fieldNumber, Object value) { + switch (fieldType) { + case Descriptors.FieldDescriptor.Type.Double: return ComputeDoubleSize(fieldNumber, (double)value); + case Descriptors.FieldDescriptor.Type.Float: return ComputeFloatSize(fieldNumber, (float)value); + case Descriptors.FieldDescriptor.Type.Int64: return ComputeInt64Size(fieldNumber, (long)value); + case Descriptors.FieldDescriptor.Type.UInt64: return ComputeUInt64Size(fieldNumber, (ulong)value); + case Descriptors.FieldDescriptor.Type.Int32: return ComputeInt32Size(fieldNumber, (int)value); + case Descriptors.FieldDescriptor.Type.Fixed64: return ComputeFixed64Size(fieldNumber, (long)value); + case Descriptors.FieldDescriptor.Type.Fixed32: return ComputeFixed32Size(fieldNumber, (int)value); + case Descriptors.FieldDescriptor.Type.Bool: return ComputeBoolSize(fieldNumber, (bool)value); + case Descriptors.FieldDescriptor.Type.String: return ComputeStringSize(fieldNumber, (string)value); + case Descriptors.FieldDescriptor.Type.Group: return ComputeGroupSize(fieldNumber, (IMessage)value); + case Descriptors.FieldDescriptor.Type.Message: return ComputeMessageSize(fieldNumber, (IMessage)value); + case Descriptors.FieldDescriptor.Type.Bytes: return ComputeBytesSize(fieldNumber, (ByteString)value); + case Descriptors.FieldDescriptor.Type.UInt32: return ComputeUInt32Size(fieldNumber, (uint)value); + case Descriptors.FieldDescriptor.Type.SFixed32: return ComputeSFixed32Size(fieldNumber, (int)value); + case Descriptors.FieldDescriptor.Type.SFixed64: return ComputeSFixed64Size(fieldNumber, (long)value); + case Descriptors.FieldDescriptor.Type.SInt32: return ComputeSInt32Size(fieldNumber, (int)value); + case Descriptors.FieldDescriptor.Type.SInt64: return ComputeSInt64Size(fieldNumber, (long)value); + case Descriptors.FieldDescriptor.Type.Enum: return ComputeEnumSize(fieldNumber, ((Descriptors.EnumValueDescriptor)value).Number); + default: + throw new ArgumentOutOfRangeException("Invalid field type " + fieldType); + } + } + + /// <summary> + /// Compute the number of bytes that would be needed to encode a tag. + /// </summary> + public static int ComputeTagSize(int fieldNumber) { + return ComputeRawVarint32Size(WireFormat.MakeTag(fieldNumber, 0)); + } + #endregion + + /// <summary> + /// Encode a 32-bit value with ZigZag encoding. + /// </summary> + /// <remarks> + /// ZigZag encodes signed integers into values that can be efficiently + /// encoded with varint. (Otherwise, negative values must be + /// sign-extended to 64 bits to be varint encoded, thus always taking + /// 10 bytes on the wire.) + /// </remarks> + public static uint EncodeZigZag32(int n) { + // Note: the right-shift must be arithmetic + return (uint)((n << 1) ^ (n >> 31)); + } + + /// <summary> + /// Encode a 64-bit value with ZigZag encoding. + /// </summary> + /// <remarks> + /// ZigZag encodes signed integers into values that can be efficiently + /// encoded with varint. (Otherwise, negative values must be + /// sign-extended to 64 bits to be varint encoded, thus always taking + /// 10 bytes on the wire.) + /// </remarks> + public static ulong EncodeZigZag64(long n) { + return (ulong)((n << 1) ^ (n >> 63)); + } + + private void RefreshBuffer() { + if (output == null) { + // We're writing to a single buffer. + throw new OutOfSpaceException(); + } + + // Since we have an output stream, this is our buffer + // and buffer offset == 0 + output.Write(buffer, 0, position); + position = 0; + } + + /// <summary> + /// Indicates that a CodedOutputStream wrapping a flat byte array + /// ran out of space. + /// </summary> + public class OutOfSpaceException : IOException { + internal OutOfSpaceException() + : base("CodedOutputStream was writing to a flat byte array and ran out of space.") { + } + } + + public void Flush() { + if (output != null) { + RefreshBuffer(); + } + } + } +}
\ No newline at end of file diff --git a/csharp/ProtocolBuffers/Descriptors.cs b/csharp/ProtocolBuffers/Descriptors.cs new file mode 100644 index 00000000..ae09ee5a --- /dev/null +++ b/csharp/ProtocolBuffers/Descriptors.cs @@ -0,0 +1,39 @@ + +using System; + +namespace Google.ProtocolBuffers { + public class Descriptors { + public class Descriptor { + } + public class FieldDescriptor { + public enum Type { + Double, + Float, + Int64, + UInt64, + Int32, + Fixed64, + Fixed32, + Bool, + String, + Group, + Message, + Bytes, + UInt32, + SFixed32, + SFixed64, + SInt32, + SInt64, + Enum + } + } + + public class EnumValueDescriptor + { + public int Number + { + get { throw new NotImplementedException(); } + } + } + } +} diff --git a/csharp/ProtocolBuffers/ExtensionRegistry.cs b/csharp/ProtocolBuffers/ExtensionRegistry.cs new file mode 100644 index 00000000..54d86ad7 --- /dev/null +++ b/csharp/ProtocolBuffers/ExtensionRegistry.cs @@ -0,0 +1,5 @@ + +namespace Google.ProtocolBuffers { + public class ExtensionRegistry { + } +} diff --git a/csharp/ProtocolBuffers/IBuilder.cs b/csharp/ProtocolBuffers/IBuilder.cs new file mode 100644 index 00000000..ebd6b408 --- /dev/null +++ b/csharp/ProtocolBuffers/IBuilder.cs @@ -0,0 +1,227 @@ +using System; +using System.Collections.Generic; +using System.Text; +using System.IO; + +namespace Google.ProtocolBuffers { + + /// <summary> + /// Interface implemented by Protocol Message builders. + /// TODO(jonskeet): Consider "SetXXX" methods returning the builder, as well as the properties. + /// </summary> + /// <typeparam name="T">Type of message</typeparam> + public interface IBuilder<T> where T : IMessage<T> { + /// <summary> + /// Resets all fields to their default values. + /// </summary> + IBuilder<T> Clear(); + + /// <summary> + /// Merge the specified other message into the message being + /// built. Merging occurs as follows. For each field: + /// For singular primitive fields, if the field is set in <paramref name="other"/>, + /// then <paramref name="other"/>'s value overwrites the value in this message. + /// For singular message fields, if the field is set in <paramref name="other"/>, + /// it is merged into the corresponding sub-message of this message using the same + /// merging rules. + /// For repeated fields, the elements in <paramref name="other"/> are concatenated + /// with the elements in this message. + /// </summary> + /// <param name="other"></param> + /// <returns></returns> + IBuilder<T> MergeFrom(IMessage<T> other); + + /// <summary> + /// Constructs the final message. Once this is called, this Builder instance + /// is no longer valid, and calling any other method may throw a + /// NullReferenceException. If you need to continue working with the builder + /// after calling Build, call Clone first. + /// </summary> + /// <exception cref="UninitializedMessageException">the message + /// is missing one or more required fields; use BuildPartial to bypass + /// this check</exception> + IMessage<T> Build(); + + /// <summary> + /// Like Build(), but does not throw an exception if the message is missing + /// required fields. Instead, a partial message is returned. + /// </summary> + /// <returns></returns> + IMessage<T> BuildPartial(); + + /// <summary> + /// Clones this builder. + /// TODO(jonskeet): Explain depth of clone. + /// </summary> + IBuilder<T> Clone(); + + /// <summary> + /// Returns true iff all required fields in the message and all + /// embedded messages are set. + /// </summary> + bool Initialized { get; } + + /// <summary> + /// Parses a message of this type from the input and merges it with this + /// message, as if using MergeFrom(IMessage<T>). + /// </summary> + /// <remarks> + /// Warning: This does not verify that all required fields are present + /// in the input message. If you call Build() without setting all + /// required fields, it will throw an UninitializedMessageException. + /// There are a few good ways to deal with this: + /// <list> + /// <item>Call Initialized to verify to verify that all required fields are + /// set before building.</item> + /// <item>Parse the message separately using one of the static ParseFrom + /// methods, then use MergeFrom(IMessage<T>) to merge it with + /// this one. ParseFrom will throw an InvalidProtocolBufferException + /// (an IOException) if some required fields are missing. + /// Use BuildPartial to build, which ignores missing required fields. + /// </list> + /// </remarks> + IBuilder<T> MergeFrom(CodedInputStream input); + + /// <summary> + /// Like MergeFrom(CodedInputStream), but also parses extensions. + /// The extensions that you want to be able to parse must be registered + /// in <paramref name="extensionRegistry"/>. Extensions not in the registry + /// will be treated as unknown fields. + /// </summary> + IBuilder<T> MergeFrom(CodedInputStream input, ExtensionRegistry extensionRegistry); + + /// <summary> + /// Get the message's type's descriptor. + /// <see cref="IMessage{T}.DescriptorForType"/> + /// </summary> + Descriptors.Descriptor DescriptorForType { get; } + + /// <summary> + /// Get's the message's type's default instance. + /// <see cref="IMessage{T}.DefaultInstanceForType" /> + /// </summary> + IMessage<T> DefaultInstanceForType { get; } + + /// <summary> + /// Behaves like the equivalent property in IMessage<T>. + /// The returned map may or may not reflect future changes to the builder. + /// Either way, the returned map is unmodifiable. + /// </summary> + IDictionary<ProtocolBuffers.Descriptors.FieldDescriptor, object> AllFields { get; } + + /// <summary> + /// Create a builder for messages of the appropriate type for the given field. + /// Messages built with this can then be passed to the various mutation properties + /// and methods. + /// </summary> + /// <typeparam name="TField"></typeparam> + /// <param name="field"></param> + /// <returns></returns> + IBuilder<TField> NewBuilderForField<TField>(Descriptors.FieldDescriptor field) + where TField : IMessage<TField>; + + /// <summary> + /// <see cref="IMessage{T}.HasField"/> + /// </summary> + bool HasField(Descriptors.FieldDescriptor field); + + /// <summary> + /// Allows getting and setting of a field. + /// <see cref="IMessage{T}.Item(Descriptors.FieldDescriptor)"/> + /// </summary> + /// <param name="field"></param> + /// <returns></returns> + object this[Descriptors.FieldDescriptor field] { get; set; } + + /// <summary> + /// Clears the field. This is exactly equivalent to calling the generated + /// Clear method corresponding to the field. + /// </summary> + /// <param name="field"></param> + /// <returns></returns> + IBuilder<T> ClearField(Descriptors.FieldDescriptor field); + + /// <summary> + /// <see cref="IMessage{T}.GetRepeatedFieldCount"/> + /// </summary> + /// <param name="field"></param> + /// <returns></returns> + int GetRepeatedFieldCount(Descriptors.FieldDescriptor field); + + + /// <summary> + /// Allows getting and setting of a repeated field value. + /// <see cref="IMessage{T}.Item(Descriptors.FieldDescriptor, int)"/> + /// </summary> + object this[Descriptors.FieldDescriptor field, int index] { get; set; } + + /// <summary> + /// Appends the given value as a new element for the specified repeated field. + /// </summary> + /// <exception cref="ArgumentException">the field is not a repeated field, + /// the field does not belong to this builder's type, or the value is + /// of the incorrect type + /// </exception> + IBuilder<T> AddRepeatedField(Descriptors.FieldDescriptor field, object value); + + /// <summary> + /// <see cref="IMessage{T}.UnknownFields"/> + /// </summary> + UnknownFieldSet UnknownFields { get; set; } + + /// <summary> + /// Merge some unknown fields into the set for this message. + /// </summary> + IBuilder<T> MergeUnknownFields(UnknownFieldSet unknownFields); + + #region Convenience methods + // TODO(jonskeet): Implement these as extension methods? + + /// <summary> + /// Parse <paramref name="data"/> as a message of this type and merge + /// it with the message being built. This is just a small wrapper around + /// MergeFrom(CodedInputStream). + /// </summary> + IBuilder<T> MergeFrom(ByteString data); + + /// <summary> + /// Parse <paramref name="data"/> as a message of this type and merge + /// it with the message being built. This is just a small wrapper around + /// MergeFrom(CodedInputStream, ExtensionRegistry). + /// </summary> + IBuilder<T> MergeFrom(ByteString data, ExtensionRegistry extensionRegistry); + + /// <summary> + /// Parse <paramref name="data"/> as a message of this type and merge + /// it with the message being built. This is just a small wrapper around + /// MergeFrom(CodedInputStream). + /// </summary> + IBuilder<T> MergeFrom(byte[] data); + + /// <summary> + /// Parse <paramref name="data"/> as a message of this type and merge + /// it with the message being built. This is just a small wrapper around + /// MergeFrom(CodedInputStream, ExtensionRegistry). + /// </summary> + IBuilder<T> MergeFrom(byte[] data, ExtensionRegistry extensionRegistry); + + /// <summary> + /// Parse <paramref name="data"/> as a message of this type and merge + /// it with the message being built. This is just a small wrapper around + /// MergeFrom(CodedInputStream). Note that this method always reads + /// the entire input (unless it throws an exception). If you want it to + /// stop earlier, you will need to wrap the input in a wrapper + /// stream which limits reading. Despite usually reading the entire + /// stream, this method never closes the stream. + /// </summary> + IBuilder<T> MergeFrom(Stream input); + + /// <summary> + /// Parse <paramref name="data"/> as a message of this type and merge + /// it with the message being built. This is just a small wrapper around + /// MergeFrom(CodedInputStream, ExtensionRegistry). + /// </summary> + IBuilder<T> MergeFrom(Stream input, ExtensionRegistry extensionRegistry); + #endregion + } +} diff --git a/csharp/ProtocolBuffers/IMessage.cs b/csharp/ProtocolBuffers/IMessage.cs new file mode 100644 index 00000000..6a41d78e --- /dev/null +++ b/csharp/ProtocolBuffers/IMessage.cs @@ -0,0 +1,162 @@ +using System; +using System.Collections.Generic; +using System.IO; + +namespace Google.ProtocolBuffers { + + /// <summary> + /// Non-generic interface. + /// TODO(jonskeet): Do we want or need this? + /// </summary> + public interface IMessage { + void WriteTo(CodedOutputStream output); + int SerializedSize { get; } + } + + /// <summary> + /// Interface implemented by all Protocol Buffers messages. + /// </summary> + public interface IMessage<T> where T : IMessage<T> { + /// <summary> + /// Returns the message's type's descriptor. This differs from the + /// Descriptor property of each generated message class in that this + /// method is an abstract method of IMessage whereas Descriptor is + /// a static property of a specific class. They return the same thing. + /// </summary> + Descriptors.Descriptor DescriptorForType { get; } + + /// <summary> + /// Returns an instance of this message type with all fields set to + /// their default values. This may or may not be a singleton. This differs + /// from the DefaultInstance property of each generated message class in that this + /// method is an abstract method of IMessage whereas DefaultInstance is + /// a static property of a specific class. They return the same thing. + /// </summary> + IMessage<T> DefaultInstanceForType { get; } + + /// <summary> + /// Returns a collection of all the fields in this message which are set + /// and their corresponding values. A singular ("required" or "optional") + /// field is set iff HasField() returns true for that field. A "repeated" + /// field is set iff GetRepeatedFieldSize() is greater than zero. The + /// values are exactly what would be returned by calling + /// GetField(Descriptors.FieldDescriptor) for each field. The map + /// is guaranteed to be a sorted map, so iterating over it will return fields + /// in order by field number. + /// </summary> + IDictionary<Descriptors.FieldDescriptor, object> AllFields { get; } + + /// <summary> + /// Returns true if the given field is set. This is exactly equivalent + /// to calling the generated "Has" property corresponding to the field. + /// </summary> + /// <exception cref="ArgumentException">the field is a repeated field, + /// or it's not a field of this type</exception> + bool HasField(Descriptors.FieldDescriptor field); + + /// <summary> + /// Obtains the value of the given field, or the default value if + /// it isn't set. For value type fields including enums, the boxed + /// value is returned. For embedded message fields, the sub-message + /// is returned. For repeated fields, an IList<T> is returned. + /// </summary> + object this[Descriptors.FieldDescriptor field] { get; } + + /// <summary> + /// Returns the number of elements of a repeated field. This is + /// exactly equivalent to calling the generated "Count" property + /// corresponding to the field. + /// </summary> + /// <exception cref="ArgumentException">the field is not a repeated field, + /// or it's not a field of this type</exception> + int GetRepeatedFieldCount(Descriptors.FieldDescriptor field); + + /// <summary> + /// Gets an element of a repeated field. For value type fields + /// including enums, the boxed value is returned. For embedded + /// message fields, the sub-message is returned. + /// </summary> + /// <exception cref="ArgumentException">the field is not a repeated field, + /// or it's not a field of this type</exception> + /// <exception cref="ArgumentOutOfRangeException">the index is out of + /// range for the repeated field's value</exception> + object this[Descriptors.FieldDescriptor field, int index] { get; } + + /// <summary> + /// Returns the unknown fields for this message. + /// </summary> + UnknownFieldSet UnknownFields { get; } + + /// <summary> + /// Returns true iff all required fields in the message and all embedded + /// messages are set. + /// </summary> + bool Initialized { get; } + + /// <summary> + /// Serializes the message and writes it to the given output stream. + /// This does not flush or close the stream. + /// </summary> + /// <param name="output"></param> + void WriteTo(CodedOutputStream output); + + /// <summary> + /// Returns the number of bytes required to encode this message. + /// The result is only computed on the first call and memoized after that. + /// </summary> + int SerializedSize { get; } + + #region Comparison and hashing + /// <summary> + /// Compares the specified object with this message for equality. + /// Returns true iff the given object is a message of the same type + /// (as defined by DescriptorForType) and has identical values + /// for all its fields. + /// </summary> + bool Equals(object other); + + /// <summary> + /// Returns the hash code value for this message. + /// TODO(jonskeet): Specify the hash algorithm, but better than the Java one! + /// </summary> + /// <returns></returns> + int GetHashCode(); + #endregion + + #region Convenience methods + /// <summary> + /// Converts the message to a string in protocol buffer text format. + /// This is just a trivial wrapper around TextFormat.PrintToString. + /// </summary> + string ToString(); + + /// <summary> + /// Serializes the message to a ByteString. This is a trivial wrapper + /// around WriteTo(CodedOutputStream). + /// </summary> + ByteString ToByteString(); + + /// <summary> + /// Serializes the message to a byte array. This is a trivial wrapper + /// around WriteTo(CodedOutputStream). + /// </summary> + byte[] ToByteArray(); + + /// <summary> + /// Serializes the message and writes it to the given stream. + /// This is just a wrapper around WriteTo(CodedOutputStream). This + /// does not flush or close the stream. + /// </summary> + /// <param name="output"></param> + void WriteTo(Stream output); + #endregion + + #region Builders + /// <summary> + /// Constructs a new builder for a message of the same type as this message. + /// </summary> + IBuilder<T> NewBuilderForType(); + #endregion + + } +} diff --git a/csharp/ProtocolBuffers/InvalidProtocolBufferException.cs b/csharp/ProtocolBuffers/InvalidProtocolBufferException.cs new file mode 100644 index 00000000..8b61f9f1 --- /dev/null +++ b/csharp/ProtocolBuffers/InvalidProtocolBufferException.cs @@ -0,0 +1,7 @@ +using System; +using System.IO; + +namespace Google.ProtocolBuffers { + public class InvalidProtocolBufferException : IOException { + } +} diff --git a/csharp/ProtocolBuffers/Properties/AssemblyInfo.cs b/csharp/ProtocolBuffers/Properties/AssemblyInfo.cs new file mode 100644 index 00000000..4653dbe3 --- /dev/null +++ b/csharp/ProtocolBuffers/Properties/AssemblyInfo.cs @@ -0,0 +1,36 @@ +using System.Reflection; +using System.Runtime.CompilerServices; +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("ProtocolBuffers")] +[assembly: AssemblyDescription("")] +[assembly: AssemblyConfiguration("")] +[assembly: AssemblyCompany("")] +[assembly: AssemblyProduct("ProtocolBuffers")] +[assembly: AssemblyCopyright("Copyright © 2008")] +[assembly: AssemblyTrademark("")] +[assembly: AssemblyCulture("")] + +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. 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("279b643d-70e8-47ae-9eb1-500d1c48bab6")] + +// 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 Build and Revision Numbers +// by using the '*' as shown below: +// [assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("1.0.0.0")] +[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/csharp/ProtocolBuffers/ProtocolBuffers.csproj b/csharp/ProtocolBuffers/ProtocolBuffers.csproj new file mode 100644 index 00000000..196f46d3 --- /dev/null +++ b/csharp/ProtocolBuffers/ProtocolBuffers.csproj @@ -0,0 +1,60 @@ +<?xml version="1.0" encoding="utf-8"?> +<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> + <PropertyGroup> + <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> + <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> + <ProductVersion>9.0.21022</ProductVersion> + <SchemaVersion>2.0</SchemaVersion> + <ProjectGuid>{6908BDCE-D925-43F3-94AC-A531E6DF2591}</ProjectGuid> + <OutputType>Library</OutputType> + <AppDesignerFolder>Properties</AppDesignerFolder> + <RootNamespace>Google.ProtocolBuffers</RootNamespace> + <AssemblyName>Google.ProtocolBuffers</AssemblyName> + <TargetFrameworkVersion>v2.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>DEBUG;TRACE</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + </PropertyGroup> + <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> + <DebugType>pdbonly</DebugType> + <Optimize>true</Optimize> + <OutputPath>bin\Release\</OutputPath> + <DefineConstants>TRACE</DefineConstants> + <ErrorReport>prompt</ErrorReport> + <WarningLevel>4</WarningLevel> + </PropertyGroup> + <ItemGroup> + <Reference Include="System" /> + <Reference Include="System.Data" /> + <Reference Include="System.Xml" /> + </ItemGroup> + <ItemGroup> + <Compile Include="ByteString.cs" /> + <Compile Include="CodedInputStream.cs" /> + <Compile Include="CodedOutputStream.cs" /> + <Compile Include="Descriptors.cs" /> + <Compile Include="ExtensionRegistry.cs" /> + <Compile Include="IBuilder.cs" /> + <Compile Include="IMessage.cs" /> + <Compile Include="InvalidProtocolBufferException.cs" /> + <Compile Include="Properties\AssemblyInfo.cs" /> + <Compile Include="UninitializedMessageException.cs" /> + <Compile Include="UnknownFieldSet.cs" /> + <Compile Include="WireFormat.cs" /> + </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/csharp/ProtocolBuffers/UninitializedMessageException.cs b/csharp/ProtocolBuffers/UninitializedMessageException.cs new file mode 100644 index 00000000..a77499af --- /dev/null +++ b/csharp/ProtocolBuffers/UninitializedMessageException.cs @@ -0,0 +1,6 @@ +using System; + +namespace Google.ProtocolBuffers { + public class UninitializedMessageException : Exception { + } +} diff --git a/csharp/ProtocolBuffers/UnknownFieldSet.cs b/csharp/ProtocolBuffers/UnknownFieldSet.cs new file mode 100644 index 00000000..a9602b3e --- /dev/null +++ b/csharp/ProtocolBuffers/UnknownFieldSet.cs @@ -0,0 +1,13 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Google.ProtocolBuffers { + public class UnknownFieldSet { + public void WriteTo(CodedOutputStream output) { + throw new NotImplementedException(); + } + + public int SerializedSize { get { return 0; } } + } +} diff --git a/csharp/ProtocolBuffers/WireFormat.cs b/csharp/ProtocolBuffers/WireFormat.cs new file mode 100644 index 00000000..df15526a --- /dev/null +++ b/csharp/ProtocolBuffers/WireFormat.cs @@ -0,0 +1,28 @@ +using System; +using System.Collections.Generic; +using System.Text; + +namespace Google.ProtocolBuffers { + public class WireFormat { + public enum WireType { + Varint = 0, + Fixed64 = 1, + LengthDelimited = 2, + StartGroup = 3, + EndGroup = 4, + Fixed32 = 5 + } + + internal class MessageSetField { + internal const int Item = 1; + internal const int TypeID = 2; + internal const int Message = 3; + } + + public static uint MakeTag(int fieldNumber, WireType type) { + + // FIXME + return 0; + } + } +} |