test_class.file: dubbo-config/dubbo-config-api/src/test/java/org/apache/dubbo/config/bootstrap/builders/ServiceBuilderTest.java
test_class.identifier: ServiceBuilderTest
test_case.body: @Test
      void build() {
          MethodConfig method = new MethodConfig();
          ProviderConfig provider = new ProviderConfig();
  
          ServiceBuilder builder = new ServiceBuilder();
          builder.path("path").addMethod(method).provider(provider).providerIds("providerIds")
                  .generic(GENERIC_SERIALIZATION_DEFAULT);
  
          ServiceConfig config = builder.build();
          ServiceConfig config2 = builder.build();
  
          assertThat(config.getGeneric(), equalTo(GENERIC_SERIALIZATION_DEFAULT));
          Assertions.assertEquals("path", config.getPath());
          Assertions.assertEquals("providerIds", config.getProviderIds());
          Assertions.assertSame(provider, config.getProvider());
          Assertions.assertTrue(config.getMethods().contains(method));
          Assertions.assertEquals(1, config.getMethods().size());
          Assertions.assertNotSame(config, config2);
      }
test_case.class_method_signature: ServiceBuilderTest.build()
test_case.full_signature: @Test void build()
test_case.identifier: build
test_case.invocations: generic providerIds provider addMethod path build build assertThat getGeneric equalTo assertEquals getPath assertEquals getProviderIds assertSame getProvider assertTrue contains getMethods assertEquals size getMethods assertNotSame
test_case.modifiers: @Test
test_case.parameters: ()
test_case.return: void
test_case.signature: void build()
focal_class.declarator: interfaceName
focal_class.modifier: private
focal_class.original_string: private String interfaceName;
focal_class.type: String
focal_class.var_name: interfaceName
focal_class.declarator: interfaceClass
focal_class.modifier: private
focal_class.original_string: private Class<?> interfaceClass;
focal_class.type: Class<?>
focal_class.var_name: interfaceClass
focal_class.declarator: ref
focal_class.modifier: private
focal_class.original_string: private U ref;
focal_class.type: U
focal_class.var_name: ref
focal_class.declarator: path
focal_class.modifier: private
focal_class.original_string: private String path;
focal_class.type: String
focal_class.var_name: path
focal_class.declarator: methods
focal_class.modifier: private
focal_class.original_string: private List<MethodConfig> methods;
focal_class.type: List<MethodConfig>
focal_class.var_name: methods
focal_class.declarator: provider
focal_class.modifier: private
focal_class.original_string: private ProviderConfig provider;
focal_class.type: ProviderConfig
focal_class.var_name: provider
focal_class.declarator: providerIds
focal_class.modifier: private
focal_class.original_string: private String providerIds;
focal_class.type: String
focal_class.var_name: providerIds
focal_class.declarator: generic
focal_class.modifier: private
focal_class.original_string: private String generic;
focal_class.type: String
focal_class.var_name: generic
focal_class.file: dubbo-config/dubbo-config-api/src/main/java/org/apache/dubbo/config/bootstrap/builders/ServiceBuilder.java
focal_class.identifier: ServiceBuilder
focal_class.class_method_signature: ServiceBuilder.newBuilder()
focal_class.full_signature: public static ServiceBuilder newBuilder()
focal_class.identifier: newBuilder
focal_class.modifiers: public static
focal_class.parameters: ()
focal_class.return: ServiceBuilder
focal_class.signature: ServiceBuilder newBuilder()
focal_class.class_method_signature: ServiceBuilder.id(String id)
focal_class.full_signature: public ServiceBuilder id(String id)
focal_class.identifier: id
focal_class.modifiers: public
focal_class.parameters: (String id)
focal_class.return: ServiceBuilder
focal_class.signature: ServiceBuilder id(String id)
focal_class.class_method_signature: ServiceBuilder.interfaceName(String interfaceName)
focal_class.full_signature: public ServiceBuilder<U> interfaceName(String interfaceName)
focal_class.identifier: interfaceName
focal_class.modifiers: public
focal_class.parameters: (String interfaceName)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> interfaceName(String interfaceName)
focal_class.class_method_signature: ServiceBuilder.interfaceClass(Class<?> interfaceClass)
focal_class.full_signature: public ServiceBuilder<U> interfaceClass(Class<?> interfaceClass)
focal_class.identifier: interfaceClass
focal_class.modifiers: public
focal_class.parameters: (Class<?> interfaceClass)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> interfaceClass(Class<?> interfaceClass)
focal_class.class_method_signature: ServiceBuilder.ref(U ref)
focal_class.full_signature: public ServiceBuilder<U> ref(U ref)
focal_class.identifier: ref
focal_class.modifiers: public
focal_class.parameters: (U ref)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> ref(U ref)
focal_class.class_method_signature: ServiceBuilder.path(String path)
focal_class.full_signature: public ServiceBuilder<U> path(String path)
focal_class.identifier: path
focal_class.modifiers: public
focal_class.parameters: (String path)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> path(String path)
focal_class.class_method_signature: ServiceBuilder.addMethod(MethodConfig method)
focal_class.full_signature: public ServiceBuilder<U> addMethod(MethodConfig method)
focal_class.identifier: addMethod
focal_class.modifiers: public
focal_class.parameters: (MethodConfig method)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> addMethod(MethodConfig method)
focal_class.class_method_signature: ServiceBuilder.addMethods(List<? extends MethodConfig> methods)
focal_class.full_signature: public ServiceBuilder<U> addMethods(List<? extends MethodConfig> methods)
focal_class.identifier: addMethods
focal_class.modifiers: public
focal_class.parameters: (List<? extends MethodConfig> methods)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> addMethods(List<? extends MethodConfig> methods)
focal_class.class_method_signature: ServiceBuilder.provider(ProviderConfig provider)
focal_class.full_signature: public ServiceBuilder<U> provider(ProviderConfig provider)
focal_class.identifier: provider
focal_class.modifiers: public
focal_class.parameters: (ProviderConfig provider)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> provider(ProviderConfig provider)
focal_class.class_method_signature: ServiceBuilder.providerIds(String providerIds)
focal_class.full_signature: public ServiceBuilder<U> providerIds(String providerIds)
focal_class.identifier: providerIds
focal_class.modifiers: public
focal_class.parameters: (String providerIds)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> providerIds(String providerIds)
focal_class.class_method_signature: ServiceBuilder.generic(String generic)
focal_class.full_signature: public ServiceBuilder<U> generic(String generic)
focal_class.identifier: generic
focal_class.modifiers: public
focal_class.parameters: (String generic)
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> generic(String generic)
focal_class.class_method_signature: ServiceBuilder.build()
focal_class.full_signature: public ServiceConfig<U> build()
focal_class.identifier: build
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: ServiceConfig<U>
focal_class.signature: ServiceConfig<U> build()
focal_class.class_method_signature: ServiceBuilder.getThis()
focal_class.full_signature: @Override protected ServiceBuilder<U> getThis()
focal_class.identifier: getThis
focal_class.modifiers: @Override protected
focal_class.parameters: ()
focal_class.return: ServiceBuilder<U>
focal_class.signature: ServiceBuilder<U> getThis()
focal_class.superclass: extends AbstractServiceBuilder<ServiceConfig, ServiceBuilder<U>>
focal_method.body: public ServiceConfig<U> build() {
          ServiceConfig<U> serviceConfig = new ServiceConfig<>();
          super.build(serviceConfig);
  
          serviceConfig.setInterface(interfaceName);
          serviceConfig.setInterface(interfaceClass);
          serviceConfig.setRef(ref);
          serviceConfig.setPath(path);
          serviceConfig.setMethods(methods);
          serviceConfig.setProvider(provider);
          serviceConfig.setProviderIds(providerIds);
          serviceConfig.setGeneric(generic);
  
          return serviceConfig;
      }
focal_method.class_method_signature: ServiceBuilder.build()
focal_method.full_signature: public ServiceConfig<U> build()
focal_method.identifier: build
focal_method.invocations: build setInterface setInterface setRef setPath setMethods setProvider setProviderIds setGeneric
focal_method.modifiers: public
focal_method.parameters: ()
focal_method.return: ServiceConfig<U>
focal_method.signature: ServiceConfig<U> build()