Interface RuntimeBeanDefinition.Builder<B>

Type Parameters:
B - The bean type
Enclosing interface:
RuntimeBeanDefinition<T>

public static interface RuntimeBeanDefinition.Builder<B>
A builder for constructing RuntimeBeanDefinition instances.
  • Method Details

    • qualifier

      @NonNull RuntimeBeanDefinition.Builder<B> qualifier(@Nullable Qualifier<B> qualifier)
      The qualifier to use.
      Parameters:
      qualifier - The qualifier
      Returns:
      This builder
    • replaces

      @NonNull RuntimeBeanDefinition.Builder<B> replaces(@Nullable Class<? extends B> otherType)
      Adds this type as a bean replacement of the given type.
      Parameters:
      otherType - The other type
      Returns:
      This bean builder
      Since:
      4.0.0
    • named

      default @NonNull RuntimeBeanDefinition.Builder<B> named(@Nullable String name)
      The qualifier to use.
      Parameters:
      name - The named qualifier to use.
      Returns:
      This builder
      Since:
      3.7.0
    • scope

      @NonNull RuntimeBeanDefinition.Builder<B> scope(@Nullable Class<? extends Annotation> scope)
      The scope to use.
      Parameters:
      scope - The scope
      Returns:
      This builder
    • singleton

      @NonNull RuntimeBeanDefinition.Builder<B> singleton(boolean isSingleton)
      Is the bean singleton.
      Parameters:
      isSingleton - True if it is singleton
      Returns:
      This builder
    • exposedTypes

      @NonNull RuntimeBeanDefinition.Builder<B> exposedTypes(Class<?>... types)
      Limit the exposed types of this bean.
      Parameters:
      types - The exposed types
      Returns:
      This builder
    • typeArguments

      @NonNull RuntimeBeanDefinition.Builder<B> typeArguments(Argument<?>... arguments)
      The type arguments for the type.
      Parameters:
      arguments - The arguments
      Returns:
      This builder
    • typeArguments

      @NonNull RuntimeBeanDefinition.Builder<B> typeArguments(Class<?> implementedType, Argument<?>... arguments)
      The type arguments for an implemented type of this type.
      Parameters:
      implementedType - The implemented type
      arguments - The arguments
      Returns:
      This builder
    • annotationMetadata

      @NonNull RuntimeBeanDefinition.Builder<B> annotationMetadata(@Nullable AnnotationMetadata annotationMetadata)
      The annotation metadata for the bean.
      Parameters:
      annotationMetadata - The annotation metadata
      Returns:
      This builder
    • build

      @NonNull RuntimeBeanDefinition<B> build()
      Builds the runtime bean.
      Returns:
      The runtime bean