Home
last modified time | relevance | path

Searched refs:newBuilder (Results 1 – 25 of 136) sorted by relevance

123456

/third_party/protobuf/java/core/src/test/java/com/google/protobuf/
DAbstractProto3LiteSchemaTest.java78 newBuilder() in mergeOptionalMessageFields()
79 .setFieldMessage10(newBuilder().setFieldInt643(123).clearFieldInt325().build()) in mergeOptionalMessageFields()
82 newBuilder() in mergeOptionalMessageFields()
83 .setFieldMessage10(newBuilder().clearFieldInt643().setFieldInt325(456).build()) in mergeOptionalMessageFields()
86 newBuilder() in mergeOptionalMessageFields()
87 .setFieldMessage10(newBuilder().setFieldInt643(789).clearFieldInt325().build()) in mergeOptionalMessageFields()
103 roundtrip("Field 53", newBuilder().setFieldDouble53(100).build()); in oneofFieldsShouldRoundtrip()
104 roundtrip("Field 54", newBuilder().setFieldFloat54(100).build()); in oneofFieldsShouldRoundtrip()
105 roundtrip("Field 55", newBuilder().setFieldInt6455(100).build()); in oneofFieldsShouldRoundtrip()
106 roundtrip("Field 56", newBuilder().setFieldUint6456(100L).build()); in oneofFieldsShouldRoundtrip()
[all …]
DAbstractProto3SchemaTest.java78 newBuilder() in mergeOptionalMessageFields()
79 .setFieldMessage10(newBuilder().setFieldInt643(123).clearFieldInt325().build()) in mergeOptionalMessageFields()
82 newBuilder() in mergeOptionalMessageFields()
83 .setFieldMessage10(newBuilder().clearFieldInt643().setFieldInt325(456).build()) in mergeOptionalMessageFields()
86 newBuilder() in mergeOptionalMessageFields()
87 .setFieldMessage10(newBuilder().setFieldInt643(789).clearFieldInt325().build()) in mergeOptionalMessageFields()
102 roundtrip("Field 53", newBuilder().setFieldDouble53(100).build()); in oneofFieldsShouldRoundtrip()
103 roundtrip("Field 54", newBuilder().setFieldFloat54(100).build()); in oneofFieldsShouldRoundtrip()
104 roundtrip("Field 55", newBuilder().setFieldInt6455(100).build()); in oneofFieldsShouldRoundtrip()
105 roundtrip("Field 56", newBuilder().setFieldUint6456(100L).build()); in oneofFieldsShouldRoundtrip()
[all …]
DTextFormatTest.java144 TextFormat.Parser.newBuilder().setAllowUnknownFields(true).build();
147 TextFormat.Parser.newBuilder().setAllowUnknownExtensions(true).build();
150 TextFormat.Parser.newBuilder()
154 private final TextFormat.Parser defaultParser = TextFormat.Parser.newBuilder().build();
195 return UnknownFieldSet.newBuilder() in makeUnknownFieldSet()
198 UnknownFieldSet.Field.newBuilder() in makeUnknownFieldSet()
204 UnknownFieldSet.newBuilder() in makeUnknownFieldSet()
205 .addField(12, UnknownFieldSet.Field.newBuilder().addVarint(6).build()) in makeUnknownFieldSet()
209 UnknownFieldSet.newBuilder() in makeUnknownFieldSet()
210 .addField(10, UnknownFieldSet.Field.newBuilder().addVarint(5).build()) in makeUnknownFieldSet()
[all …]
DUnknownFieldSetTest.java76 UnknownFieldSet.Builder bizarroFields = UnknownFieldSet.newBuilder(); in getBizarroData()
78 UnknownFieldSet.Field varintField = UnknownFieldSet.Field.newBuilder().addVarint(1).build(); in getBizarroData()
79 UnknownFieldSet.Field fixed32Field = UnknownFieldSet.Field.newBuilder().addFixed32(1).build(); in getBizarroData()
106 UnknownFieldSet.Field.Builder fieldBuilder = UnknownFieldSet.Field.newBuilder(); in testFieldBuildersAreReusable()
118 UnknownFieldSet.Builder unknownSetBuilder = UnknownFieldSet.newBuilder(); in testClone()
119 UnknownFieldSet.Field.Builder fieldBuilder = UnknownFieldSet.Field.newBuilder(); in testClone()
130 UnknownFieldSet.newBuilder() in testClone_lengthDelimited()
131 .addField(997, UnknownFieldSet.Field.newBuilder().addVarint(99).build()) in testClone_lengthDelimited()
134 UnknownFieldSet.Field.newBuilder() in testClone_lengthDelimited()
155 UnknownFieldSet.newBuilder() in testReuse()
[all …]
DAbstractProto2LiteSchemaTest.java57 newBuilder() in mergeOptionalMessageFields()
58 .setFieldMessage10(newBuilder().setFieldInt643(123).clearFieldInt325().build()) in mergeOptionalMessageFields()
61 newBuilder() in mergeOptionalMessageFields()
62 .setFieldMessage10(newBuilder().clearFieldInt643().setFieldInt325(456).build()) in mergeOptionalMessageFields()
65 newBuilder() in mergeOptionalMessageFields()
66 .setFieldMessage10(newBuilder().setFieldInt643(789).clearFieldInt325().build()) in mergeOptionalMessageFields()
82 roundtrip("Field 53", newBuilder().setFieldDouble53(100).build()); in oneofFieldsShouldRoundtrip()
83 roundtrip("Field 54", newBuilder().setFieldFloat54(100).build()); in oneofFieldsShouldRoundtrip()
84 roundtrip("Field 55", newBuilder().setFieldInt6455(100).build()); in oneofFieldsShouldRoundtrip()
85 roundtrip("Field 56", newBuilder().setFieldUint6456(100L).build()); in oneofFieldsShouldRoundtrip()
[all …]
DAbstractProto2SchemaTest.java57 newBuilder() in mergeOptionalMessageFields()
58 .setFieldMessage10(newBuilder().setFieldInt643(123).clearFieldInt325().build()) in mergeOptionalMessageFields()
61 newBuilder() in mergeOptionalMessageFields()
62 .setFieldMessage10(newBuilder().clearFieldInt643().setFieldInt325(456).build()) in mergeOptionalMessageFields()
65 newBuilder() in mergeOptionalMessageFields()
66 .setFieldMessage10(newBuilder().setFieldInt643(789).clearFieldInt325().build()) in mergeOptionalMessageFields()
81 roundtrip("Field 53", newBuilder().setFieldDouble53(100).build()); in oneofFieldsShouldRoundtrip()
82 roundtrip("Field 54", newBuilder().setFieldFloat54(100).build()); in oneofFieldsShouldRoundtrip()
83 roundtrip("Field 55", newBuilder().setFieldInt6455(100).build()); in oneofFieldsShouldRoundtrip()
84 roundtrip("Field 56", newBuilder().setFieldUint6456(100L).build()); in oneofFieldsShouldRoundtrip()
[all …]
DLazyMessageLiteTest.java58 LazyNestedInnerMessageLite nested = LazyNestedInnerMessageLite.newBuilder().setNum(3).build(); in testSetValues()
60 LazyInnerMessageLite.newBuilder().setNum(2).setNested(nested).build(); in testSetValues()
62 LazyMessageLite.newBuilder() in testSetValues()
89 LazyMessageLite.newBuilder() in testSetRepeatedValues()
91 .addRepeatedInner(LazyInnerMessageLite.newBuilder().setNum(119)) in testSetRepeatedValues()
92 .addRepeatedInner(LazyInnerMessageLite.newBuilder().setNum(122)) in testSetRepeatedValues()
103 LazyMessageLite.newBuilder() in testRepeatedMutability()
104 .addRepeatedInner(LazyInnerMessageLite.newBuilder().setNum(119)) in testRepeatedMutability()
105 .addRepeatedInner(LazyInnerMessageLite.newBuilder().setNum(122)) in testRepeatedMutability()
120 LazyInnerMessageLite inner = LazyInnerMessageLite.newBuilder().setNum(i).build(); in testAddAll()
[all …]
DGeneratedMessageTest.java89 TestAllExtensions.Builder builder = TestAllExtensions.newBuilder(); in testGetFieldBuilderForExtensionField()
109 TestAllExtensions.Builder builder = TestAllExtensions.newBuilder(); in testGetFieldBuilderWithExistingMessage()
112 NestedMessage.newBuilder().setBb(123).build()); in testGetFieldBuilderWithExistingMessage()
132 TestAllExtensions.Builder builder = TestAllExtensions.newBuilder(); in testGetFieldBuilderWithExistingBuilder()
133 NestedMessage.Builder nestedMessageBuilder = NestedMessage.newBuilder().setBb(123); in testGetFieldBuilderWithExistingBuilder()
162 TestAllExtensions.Builder builder = TestAllExtensions.newBuilder(); in testGetRepeatedFieldBuilderForExtensionField()
165 NestedMessage.newBuilder().setBb(123).build()); in testGetRepeatedFieldBuilderForExtensionField()
186 TestAllExtensions.Builder builder = TestAllExtensions.newBuilder(); in testGetRepeatedFieldBuilderForExistingBuilder()
187 NestedMessage.Builder nestedMessageBuilder = NestedMessage.newBuilder().setBb(123); in testGetRepeatedFieldBuilderForExistingBuilder()
217 TestAllExtensions.Builder builder = TestAllExtensions.newBuilder(); in testGetExtensionFieldOutOfBound()
[all …]
DMessageTest.java51 TestAllTypes.newBuilder()
59 TestAllTypes.newBuilder()
62 .setOptionalForeignMessage(ForeignMessage.newBuilder().setC(3).build())
86 TestAllTypes result = TestAllTypes.newBuilder(MERGE_DEST).mergeFrom(MERGE_SOURCE).build(); in testMergeFrom()
97 TestAllTypes.newBuilder(MERGE_DEST) in testMergeFromDynamic()
98 .mergeFrom(DynamicMessage.newBuilder(MERGE_SOURCE).build()) in testMergeFromDynamic()
107 DynamicMessage.newBuilder(MERGE_DEST) in testDynamicMergeFrom()
108 .mergeFrom(DynamicMessage.newBuilder(MERGE_SOURCE).build()) in testDynamicMergeFrom()
119 TestRequired.newBuilder().setA(1).setB(2).setC(3).build();
122 TestRequired.Builder builder = TestRequired.newBuilder(); in testRequired()
[all …]
DDynamicMessageTest.java62 Message.Builder builder = DynamicMessage.newBuilder(TestAllTypes.getDescriptor()); in testDynamicMessageAccessors()
69 Message.Builder builder = DynamicMessage.newBuilder(TestAllTypes.getDescriptor()); in testSettersAfterBuild()
88 Message.Builder builder = DynamicMessage.newBuilder(TestEmptyMessage.getDescriptor()); in testUnknownFields()
90 UnknownFieldSet.newBuilder() in testUnknownFields()
91 .addField(1, UnknownFieldSet.Field.newBuilder().addVarint(1).build()) in testUnknownFields()
92 .addField(2, UnknownFieldSet.Field.newBuilder().addFixed32(1).build()) in testUnknownFields()
97 Message.Builder newBuilder = builder.clone(); in testUnknownFields() local
98 assertEquals(2, newBuilder.getUnknownFields().asMap().size()); in testUnknownFields()
100 newBuilder.clear(); in testUnknownFields()
101 assertTrue(newBuilder.getUnknownFields().asMap().isEmpty()); in testUnknownFields()
[all …]
DWireFormatLiteTest.java243 TestFieldOrderings.newBuilder() in testParseMultipleExtensionRanges()
265 TestExtensionInsideTable.newBuilder() in testExtensionInsideTable()
297 TestMessageSet.newBuilder() in testSerializeMessageSetWithFlag()
300 TestMessageSetExtension1.newBuilder().setI(123).build()) in testSerializeMessageSetWithFlag()
303 TestMessageSetExtension2.newBuilder().setStr("foo").build()) in testSerializeMessageSetWithFlag()
344 RawMessageSet.newBuilder() in testParseMessageSetWithFlag()
346 RawMessageSet.Item.newBuilder() in testParseMessageSetWithFlag()
349 TestMessageSetExtension1.newBuilder().setI(123).build().toByteString()) in testParseMessageSetWithFlag()
352 RawMessageSet.Item.newBuilder() in testParseMessageSetWithFlag()
355 TestMessageSetExtension2.newBuilder().setStr("foo").build().toByteString()) in testParseMessageSetWithFlag()
[all …]
DTestUtilLite.java154 TestAllTypesLite.Builder builder = TestAllTypesLite.newBuilder(); in getAllLiteSetBuilder()
164 TestAllExtensionsLite.Builder builder = TestAllExtensionsLite.newBuilder(); in getAllLiteExtensionsSet()
170 TestPackedExtensionsLite.Builder builder = TestPackedExtensionsLite.newBuilder(); in getLitePackedExtensionsSet()
193 builder.setOptionalGroup(TestAllTypesLite.OptionalGroup.newBuilder().setA(117).build()); in setAllFields()
195 TestAllTypesLite.NestedMessage.newBuilder().setBb(118).build()); in setAllFields()
196 builder.setOptionalForeignMessage(ForeignMessageLite.newBuilder().setC(119).build()); in setAllFields()
197 builder.setOptionalImportMessage(ImportMessageLite.newBuilder().setD(120).build()); in setAllFields()
198 builder.setOptionalPublicImportMessage(PublicImportMessageLite.newBuilder().setE(126).build()); in setAllFields()
199 builder.setOptionalLazyMessage(TestAllTypesLite.NestedMessage.newBuilder().setBb(127).build()); in setAllFields()
226 builder.addRepeatedGroup(TestAllTypesLite.RepeatedGroup.newBuilder().setA(217).build()); in setAllFields()
[all …]
DLiteEqualsAndHashTest.java61 Foo foo1a = Foo.newBuilder() in testEquals()
63 .addBar(Bar.newBuilder().setName("foo1")) in testEquals()
65 Foo foo1b = Foo.newBuilder() in testEquals()
67 .addBar(Bar.newBuilder().setName("foo1")) in testEquals()
69 Foo foo2 = Foo.newBuilder() in testEquals()
71 .addBar(Bar.newBuilder().setName("foo2")) in testEquals()
83 Bar bar = Bar.newBuilder().setName("bar").build(); in testEquals()
84 BarPrime barPrime = BarPrime.newBuilder().setName("bar").build(); in testEquals()
89 TestOneofEquals.Builder builder = TestOneofEquals.newBuilder(); in testOneofEquals()
99 Foo fooWithOnlyValue = Foo.newBuilder() in testEqualsAndHashCodeWithUnknownFields()
[all …]
DWireFormatTest.java198 TestFieldOrderings.newBuilder() in testInterleavedFieldsAndExtensions()
210 DynamicMessage.newBuilder(TestFieldOrderings.getDescriptor()) in testInterleavedFieldsAndExtensions()
232 TestFieldOrderings.newBuilder() in testParseMultipleExtensionRanges()
254 TestExtensionInsideTable.newBuilder() in testExtensionInsideTable()
268 DynamicMessage.newBuilder(TestFieldOrderings.getDescriptor()) in testParseMultipleExtensionRangesDynamic()
293 TestMessageSet.newBuilder() in testSerializeMessageSetWithFlag()
296 TestMessageSetExtension1.newBuilder().setI(123).build()) in testSerializeMessageSetWithFlag()
299 TestMessageSetExtension2.newBuilder().setStr("foo").build()) in testSerializeMessageSetWithFlag()
301 UnknownFieldSet.newBuilder() in testSerializeMessageSetWithFlag()
304 UnknownFieldSet.Field.newBuilder() in testSerializeMessageSetWithFlag()
[all …]
DMapForProto2Test.java73 1, MessageValue.newBuilder().setValue(11).build()); in setMapValuesUsingMutableMap()
75 2, MessageValue.newBuilder().setValue(22).build()); in setMapValuesUsingMutableMap()
77 3, MessageValue.newBuilder().setValue(33).build()); in setMapValuesUsingMutableMap()
98 .putInt32ToMessageField(1, MessageValue.newBuilder().setValue(11).build()) in setMapValuesUsingAccessors()
99 .putInt32ToMessageField(2, MessageValue.newBuilder().setValue(22).build()) in setMapValuesUsingAccessors()
100 .putInt32ToMessageField(3, MessageValue.newBuilder().setValue(33).build()) in setMapValuesUsingAccessors()
107 TestMap.Builder usingMutableMapBuilder = TestMap.newBuilder(); in testSetMapValues()
112 TestMap.Builder usingAccessorsBuilder = TestMap.newBuilder(); in testSetMapValues()
180 1, MessageValue.newBuilder().setValue(111).build()); in updateMapValuesUsingMutableMap()
183 4, MessageValue.newBuilder().setValue(44).build()); in updateMapValuesUsingMutableMap()
[all …]
/third_party/protobuf/java/util/src/test/java/com/google/protobuf/util/
DFieldMaskTreeTest.java146 Message.Builder newBuilder = in merge() local
147 DynamicMessage.newBuilder(source.getDescriptorForType()) in merge()
150 DynamicMessage.newBuilder(source.getDescriptorForType()) in merge()
153 newBuilder, in merge() local
156 builder.mergeFrom(newBuilder.buildPartial()); in merge()
163 TestRequired value = TestRequired.newBuilder().setA(4321).setB(8765).setC(233333).build(); in testMergeRequire()
164 TestRequiredMessage source = TestRequiredMessage.newBuilder().setRequiredMessage(value).build(); in testMergeRequire()
167 TestRequiredMessage.Builder builder = TestRequiredMessage.newBuilder(); in testMergeRequire()
193 TestAllTypes.newBuilder() in testMergeImpl()
195 .setOptionalNestedMessage(NestedMessage.newBuilder().setBb(5678)) in testMergeImpl()
[all …]
DJsonFormatTest.java186 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testAllFields()
240 TestAllTypes.newBuilder() in testUnknownEnumValues()
253 TestMap.Builder mapBuilder = TestMap.newBuilder(); in testUnknownEnumValues()
270 TestAllTypes.newBuilder() in testSpecialFloatValues()
289 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testParserAcceptStringForNumericField()
315 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testParserAcceptFloatingPointValueForIntegerField()
344 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in assertRejects()
362 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in assertAccepts()
410 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testParserAcceptNull()
454 builder = TestAllTypes.newBuilder(); in testParserAcceptNull()
[all …]
DValuesTest.java46 .isEqualTo(Value.newBuilder().setNullValue(NullValue.NULL_VALUE).build()); in testOfNull_IsNullValue()
50 assertThat(Values.of(true)).isEqualTo(Value.newBuilder().setBoolValue(true).build()); in testOfBoolean_ConstructsValue()
51 assertThat(Values.of(false)).isEqualTo(Value.newBuilder().setBoolValue(false).build()); in testOfBoolean_ConstructsValue()
55 assertThat(Values.of(100)).isEqualTo(Value.newBuilder().setNumberValue(100).build()); in testOfNumeric_ConstructsValue()
56 assertThat(Values.of(1000L)).isEqualTo(Value.newBuilder().setNumberValue(1000).build()); in testOfNumeric_ConstructsValue()
57 assertThat(Values.of(1000.23f)).isEqualTo(Value.newBuilder().setNumberValue(1000.23f).build()); in testOfNumeric_ConstructsValue()
58 assertThat(Values.of(10000.23)).isEqualTo(Value.newBuilder().setNumberValue(10000.23).build()); in testOfNumeric_ConstructsValue()
62 assertThat(Values.of("")).isEqualTo(Value.newBuilder().setStringValue("").build()); in testOfString_ConstructsValue()
63 assertThat(Values.of("foo")).isEqualTo(Value.newBuilder().setStringValue("foo").build()); in testOfString_ConstructsValue()
67 Struct.Builder builder = Struct.newBuilder(); in testOfStruct_ConstructsValue()
[all …]
/third_party/protobuf/java/compatibility_tests/v2.5.0/tests/src/main/java/com/google/protobuf/test/
DTextFormatTest.java151 return UnknownFieldSet.newBuilder() in makeUnknownFieldSet()
153 UnknownFieldSet.Field.newBuilder() in makeUnknownFieldSet()
159 UnknownFieldSet.newBuilder() in makeUnknownFieldSet()
161 UnknownFieldSet.Field.newBuilder() in makeUnknownFieldSet()
167 UnknownFieldSet.Field.newBuilder() in makeUnknownFieldSet()
173 UnknownFieldSet.Field.newBuilder() in makeUnknownFieldSet()
185 TestEmptyMessage.newBuilder() in testPrintUnknownFields()
215 final Object value = NestedMessage.newBuilder().setBb(42).build(); in testPrintField()
245 Message message = TestAllTypes.newBuilder() in testPrintExotic()
285 TestMessageSet.newBuilder() in testPrintMessageSet()
[all …]
DDynamicMessageTest.java60 DynamicMessage.newBuilder(TestAllTypes.getDescriptor()); in testDynamicMessageAccessors()
68 DynamicMessage.newBuilder(TestAllTypes.getDescriptor()); in testSettersAfterBuild()
88 DynamicMessage.newBuilder(TestEmptyMessage.getDescriptor()); in testUnknownFields()
89 builder.setUnknownFields(UnknownFieldSet.newBuilder() in testUnknownFields()
90 .addField(1, UnknownFieldSet.Field.newBuilder().addVarint(1).build()) in testUnknownFields()
91 .addField(2, UnknownFieldSet.Field.newBuilder().addFixed32(1).build()) in testUnknownFields()
96 Message.Builder newBuilder = builder.clone(); in testUnknownFields() local
97 assertEquals(2, newBuilder.getUnknownFields().asMap().size()); in testUnknownFields()
99 newBuilder.clear(); in testUnknownFields()
100 assertTrue(newBuilder.getUnknownFields().asMap().isEmpty()); in testUnknownFields()
[all …]
DGeneratedMessageTest.java84 TestAllTypes.newBuilder().getDefaultInstanceForType()); in testDefaultInstance()
88 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testMessageOrBuilder()
95 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testUsingBuilderMultipleTimes()
103 builder.setOptionalForeignMessage(ForeignMessage.newBuilder().setC(1)); in testUsingBuilderMultipleTimes()
104 builder.addRepeatedForeignMessage(ForeignMessage.newBuilder().setC(1)); in testUsingBuilderMultipleTimes()
122 builder.setOptionalForeignMessage(ForeignMessage.newBuilder().setC(2)); in testUsingBuilderMultipleTimes()
123 builder.setRepeatedForeignMessage(0, ForeignMessage.newBuilder().setC(2)); in testUsingBuilderMultipleTimes()
149 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testRepeatedArraysAreImmutable()
207 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testSettersRejectNull()
273 TestAllTypes.Builder builder = TestAllTypes.newBuilder(); in testRepeatedSetters()
[all …]
DMessageTest.java55 TestAllTypes.newBuilder()
63 TestAllTypes.newBuilder()
66 .setOptionalForeignMessage(ForeignMessage.newBuilder().setC(3).build())
82 TestAllTypes.newBuilder(MERGE_DEST) in testMergeFrom()
95 TestAllTypes.newBuilder(MERGE_DEST) in testMergeFromDynamic()
96 .mergeFrom(DynamicMessage.newBuilder(MERGE_SOURCE).build()) in testMergeFromDynamic()
105 DynamicMessage.newBuilder(MERGE_DEST) in testDynamicMergeFrom()
106 .mergeFrom(DynamicMessage.newBuilder(MERGE_SOURCE).build()) in testDynamicMergeFrom()
118 TestRequired.newBuilder().setA(1).setB(2).setC(3).build();
121 TestRequired.Builder builder = TestRequired.newBuilder(); in testRequired()
[all …]
DUnknownFieldSetTest.java69 UnknownFieldSet.Builder bizarroFields = UnknownFieldSet.newBuilder(); in getBizarroData()
72 UnknownFieldSet.Field.newBuilder().addVarint(1).build(); in getBizarroData()
74 UnknownFieldSet.Field.newBuilder().addFixed32(1).build(); in getBizarroData()
157 TestEmptyMessage.newBuilder().mergeFrom(emptyMessage).build(); in testCopyFrom()
164 TestEmptyMessage.newBuilder() in testMergeFrom()
166 UnknownFieldSet.newBuilder() in testMergeFrom()
168 UnknownFieldSet.Field.newBuilder() in testMergeFrom()
171 UnknownFieldSet.Field.newBuilder() in testMergeFrom()
176 TestEmptyMessage.newBuilder() in testMergeFrom()
178 UnknownFieldSet.newBuilder() in testMergeFrom()
[all …]
/third_party/protobuf/java/lite/src/test/java/com/google/protobuf/
DLiteTest.java99 TestAllTypesLite.newBuilder() in testLite()
102 .setOptionalNestedMessage(NestedMessage.newBuilder().setBb(7)) in testLite()
135 TestAllExtensionsLite.newBuilder() in testLiteExtensions()
141 NestedMessage.newBuilder().setBb(7).build()) in testLiteExtensions()
159 TestAllTypesLite.Builder expected = TestAllTypesLite.newBuilder().setOptionalInt32(123); in testClone()
163 TestAllExtensionsLite.newBuilder() in testClone()
172 TestAllTypesLite.newBuilder().addAllRepeatedBytes(null); in testAddAll()
209 TestAllTypesLite.Builder builder = TestAllTypesLite.newBuilder(); in testSanityCopyOnWrite()
311 ForeignMessageLite foreignMessage = ForeignMessageLite.newBuilder().setC(1).build(); in testSanityCopyOnWrite()
323 ForeignMessageLite foreignMessageC3 = ForeignMessageLite.newBuilder().setC(3).build(); in testSanityCopyOnWrite()
[all …]
/third_party/libphonenumber/tools/java/common/test/com/google/i18n/phonenumbers/
DBuildMetadataFromXmlTest.java171 PhoneMetadata.Builder metadata = PhoneMetadata.newBuilder(); in testLoadInternationalFormat()
172 NumberFormat nationalFormat = NumberFormat.newBuilder().build(); in testLoadInternationalFormat()
184 PhoneMetadata.Builder metadata = PhoneMetadata.newBuilder(); in testLoadInternationalFormatWithBothNationalAndIntlFormatsDefined()
185 NumberFormat.Builder nationalFormat = NumberFormat.newBuilder(); in testLoadInternationalFormatWithBothNationalAndIntlFormatsDefined()
197 PhoneMetadata.Builder metadata = PhoneMetadata.newBuilder(); in testLoadInternationalFormatExpectsOnlyOnePattern()
202 NumberFormat.newBuilder().build()); in testLoadInternationalFormatExpectsOnlyOnePattern()
213 PhoneMetadata.Builder metadata = PhoneMetadata.newBuilder(); in testLoadInternationalFormatUsesNationalFormatByDefault()
214 NumberFormat.Builder nationalFormat = NumberFormat.newBuilder(); in testLoadInternationalFormatUsesNationalFormatByDefault()
227 PhoneMetadata.Builder metadata = PhoneMetadata.newBuilder(); in testLoadInternationalFormatCopiesNationalFormatData()
228 NumberFormat.Builder nationalFormat = NumberFormat.newBuilder(); in testLoadInternationalFormatCopiesNationalFormatData()
[all …]

123456