/third_party/protobuf/csharp/src/Google.Protobuf.Test/ |
D | UnknownFieldSetTest.cs | 80 emptyMessage.MergeFrom(message.ToByteArray()); in TestMergeCodedInput() 82 Assert.AreEqual(message.ToByteArray(), emptyMessage.ToByteArray()); in TestMergeCodedInput() 84 var newMessage = message.Descriptor.Parser.ParseFrom(emptyMessage.ToByteArray()); in TestMergeCodedInput() 95 emptyMessage.MergeFrom(message.ToByteArray()); in TestMergeMessage() 99 Assert.AreEqual(message.ToByteArray(), otherEmptyMessage.ToByteArray()); in TestMergeMessage() 109 emptyMessage.MergeFrom(message.ToByteArray()); in TestEquals() 121 emptyMessage.MergeFrom(message.ToByteArray()); in TestHashCode() 133 Assert.AreEqual(emptyMessage.ToByteArray(), otherEmptyMessage.ToByteArray()); in TestClone() 135 emptyMessage.MergeFrom(message.ToByteArray()); in TestClone() 138 Assert.AreEqual(message.ToByteArray(), otherEmptyMessage.ToByteArray()); in TestClone() [all …]
|
D | ExtensionSetTest.cs | 35 var serialized = message.ToByteArray(); in TestMergeCodedInput() 72 var input = new CodedInputStream(message.ToByteArray()); in TryMergeFieldFrom_CodedInputStream()
|
D | MessageParsingHelpers.cs | 83 var bytes = message.ToByteArray(); 109 var bytes = message.ToByteArray(); in AssertWritingMessage()
|
D | LegacyGeneratedCodeTest.cs | 57 var data = message.ToByteArray(); in IntermixingOfNewAndLegacyGeneratedCodeWorksWithCodedInputStream() 82 var data = message.ToByteArray(); in LegacyGeneratedCodeThrowsWithReadOnlySequence()
|
D | ByteStringTest.cs | 117 byte[] data = bs.ToByteArray(); in ToByteArrayCopiesContents() 165 Assert.AreEqual(data, bs.ToByteArray()); in FromBase64_WithText()
|
D | GeneratedMessageTest.cs | 132 byte[] bytes = message.ToByteArray(); in RoundTrip_Empty() 248 byte[] bytes = message.ToByteArray(); in MapWithEmptyEntry() 664 var bytes = message.ToByteArray(); in OneofSerialization_NonDefaultValue() 681 var bytes = message.ToByteArray(); in OneofSerialization_DefaultValue() 719 var data = SampleMessages.CreateFullTestAllTypes().ToByteArray(); in DiscardUnknownFields_AllTypes()
|
D | CodedInputStreamTest.cs | 315 byte[] rawBytes = message.ToByteArray(); in ReadWholeMessage_VaryingBlockSizes() 333 byte[] rawBytes = message.ToByteArray(); in ReadWholeMessage_VaryingBlockSizes_FromSequence() 500 … = CodedInputStream.CreateWithLimits(new MemoryStream(atRecursiveLimit.ToByteArray()), 1000000, Co… in MaliciousRecursion() 569 … MemoryStream ms = new MemoryStream(SampleMessages.CreateFullTestAllTypes().ToByteArray()); in SizeLimit() 916 return message.ToByteArray(); in GenerateBigSerializedMessage()
|
D | CodedOutputStreamTest.cs | 261 byte[] rawBytes = message.ToByteArray(); in WriteWholeMessage_VaryingBlockSizes()
|
/third_party/protobuf/csharp/src/Google.Protobuf.Benchmarks/ |
D | WriteMessagesBenchmark.cs | 65 return manyWrapperFieldsTest.ToByteArray(); in ManyWrapperFieldsMessage_ToByteArray() 84 return manyPrimitiveFieldsTest.ToByteArray(); in ManyPrimitiveFieldsMessage_ToByteArray() 102 return emptyMessageTest.ToByteArray(); in EmptyMessage_ToByteArray() 160 public byte[] ToByteArray() => message.ToByteArray(); in ToByteArray() method in Google.Protobuf.Benchmarks.WriteMessagesBenchmark.SubTest
|
D | GoogleMessageBenchmark.cs | 82 public void ToByteArray() => subTests.ForEach(item => item.ToByteArray()); in ToByteArray() method in Google.Protobuf.Benchmarks.GoogleMessageBenchmark 113 public void ToByteArray() => message.ToByteArray(); in ToByteArray() method in Google.Protobuf.Benchmarks.GoogleMessageBenchmark.SubTest
|
D | BenchmarkDatasetConfig.cs | 69 Payloads = new List<byte[]>(dataset.Payload.Select(p => p.ToByteArray())); in BenchmarkDatasetConfig()
|
D | ParseMessagesBenchmark.cs | 215 this.data = message.ToByteArray(); in SubTest()
|
/third_party/protobuf/csharp/compatibility_tests/v3.0.0/src/Google.Protobuf.Test/WellKnownTypes/ |
D | WrappersTest.cs | 74 var bytes = message.ToByteArray(); in NonDefaultSingleValues() 104 var bytes = message.ToByteArray(); in NonNullDefaultIsPreservedThroughSerialization() 143 var bytes = message.ToByteArray(); in RepeatedWrappersSerializeDeserialize() 171 var actualBytes = message.ToByteArray(); in RepeatedWrappersBinaryFormat() 197 var bytes = message.ToByteArray(); in MapWrappersSerializeDeserialize() 291 var bytes = message.ToByteArray(); in AssertOneofRoundTrip() 316 originalMessage.MergeFrom(mergingMessage.ToByteArray()); in Merging() 357 var bytes = new TestWellKnownTypes { Int32Field = 0 }.ToByteArray(); in MergingStreamNoValue()
|
/third_party/protobuf/csharp/compatibility_tests/v3.0.0/src/Google.Protobuf.Test/ |
D | GeneratedMessageTest.cs | 131 byte[] bytes = message.ToByteArray(); in RoundTrip_Empty() 166 byte[] bytes = message.ToByteArray(); in RoundTrip_SingleValues() 200 byte[] bytes = message.ToByteArray(); in RoundTrip_RepeatedValues() 232 byte[] bytes = message.ToByteArray(); in RoundTrip_Maps() 245 byte[] bytes = message.ToByteArray(); in MapWithEmptyEntry() 618 var bytes = message.ToByteArray(); in OneofSerialization_NonDefaultValue() 632 var bytes = message.ToByteArray(); in OneofSerialization_DefaultValue() 663 var data = SampleMessages.CreateFullTestAllTypes().ToByteArray(); in DiscardUnknownFields_AllTypes()
|
D | ByteStringTest.cs | 113 byte[] data = bs.ToByteArray(); in ToByteArrayCopiesContents() 161 Assert.AreEqual(data, bs.ToByteArray()); in FromBase64_WithText()
|
D | CodedInputStreamTest.cs | 234 byte[] rawBytes = message.ToByteArray(); in ReadWholeMessage_VaryingBlockSizes() 323 … = CodedInputStream.CreateWithLimits(new MemoryStream(atRecursiveLimit.ToByteArray()), 1000000, Co… in MaliciousRecursion() 332 … MemoryStream ms = new MemoryStream(SampleMessages.CreateFullTestAllTypes().ToByteArray()); in SizeLimit()
|
D | CodedOutputStreamTest.cs | 198 byte[] rawBytes = message.ToByteArray(); in WriteWholeMessage_VaryingBlockSizes()
|
/third_party/protobuf/csharp/src/Google.Protobuf/ |
D | MessageExtensions.cs | 99 public static byte[] ToByteArray(this IMessage message) in ToByteArray() method in Google.Protobuf.MessageExtensions 146 return ByteString.AttachBytes(message.ToByteArray()); in ToByteString()
|
D | ByteString.cs | 147 public byte[] ToByteArray() in ToByteArray() method in Google.Protobuf.ByteString
|
/third_party/protobuf/csharp/src/AddressBook/ |
D | SampleUsage.cs | 63 bytes = book.ToByteArray(); in Main()
|
/third_party/protobuf/csharp/src/Google.Protobuf.Test/WellKnownTypes/ |
D | WrappersTest.cs | 176 var actualBytes = message.ToByteArray(); in RepeatedWrappersBinaryFormat() 323 originalMessage.MergeFrom(mergingMessage.ToByteArray()); in Merging() 364 var bytes = new TestWellKnownTypes { Int32Field = 0 }.ToByteArray(); in MergingStreamNoValue()
|
/third_party/protobuf/csharp/src/Google.Protobuf.Conformance/ |
D | Program.cs | 77 byte[] outputData = response.ToByteArray(); in RunTest()
|