Class DependenciesInfo.BuilderBase<BUILDER extends DependenciesInfo.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends DependenciesInfo>

java.lang.Object
io.helidon.inject.api.DependenciesInfo.BuilderBase<BUILDER,PROTOTYPE>
Type Parameters:
BUILDER - type of the builder extending this abstract builder
PROTOTYPE - type of the prototype interface that would be built by Prototype.Builder.buildPrototype()
All Implemented Interfaces:
Prototype.Builder<BUILDER,PROTOTYPE>
Direct Known Subclasses:
DependenciesInfo.Builder
Enclosing interface:
DependenciesInfo

public abstract static class DependenciesInfo.BuilderBase<BUILDER extends DependenciesInfo.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends DependenciesInfo> extends Object implements Prototype.Builder<BUILDER,PROTOTYPE>
Fluent API builder base for DependenciesInfo.
  • Constructor Details

    • BuilderBase

      protected BuilderBase()
      Protected to support extensibility.
  • Method Details

    • from

      public BUILDER from(DependenciesInfo prototype)
      Update this builder from an existing prototype instance.
      Parameters:
      prototype - existing prototype to update this builder from
      Returns:
      updated builder instance
    • from

      public BUILDER from(DependenciesInfo.BuilderBase<?,?> builder)
      Update this builder from an existing prototype builder instance.
      Parameters:
      builder - existing builder prototype to update this builder from
      Returns:
      updated builder instance
    • serviceInfoDependencies

      public BUILDER serviceInfoDependencies(Map<? extends ServiceInfoCriteria,Set<DependencyInfo>> serviceInfoDependencies)
      This method replaces all values with the new ones.
      Parameters:
      serviceInfoDependencies - map from the service info to its dependencies
      Returns:
      updated builder instance
      See Also:
    • addServiceInfoDependencies

      public BUILDER addServiceInfoDependencies(Map<? extends ServiceInfoCriteria,Set<DependencyInfo>> serviceInfoDependencies)
      This method keeps existing values, then puts all new values into the map.
      Parameters:
      serviceInfoDependencies - map from the service info to its dependencies
      Returns:
      updated builder instance
      See Also:
    • addServiceInfoDependency

      public BUILDER addServiceInfoDependency(ServiceInfoCriteria key, DependencyInfo serviceInfoDependency)
      This method adds a new value to the map value, or creates a new value.
      Parameters:
      key - key to add to
      serviceInfoDependency - additional value for the key
      Returns:
      updated builder instance
      See Also:
    • addServiceInfoDependencies

      public BUILDER addServiceInfoDependencies(ServiceInfoCriteria key, Set<DependencyInfo> serviceInfoDependencies)
      This method adds a new value to the map value, or creates a new value.
      Parameters:
      key - key to add to
      serviceInfoDependencies - additional values for the key
      Returns:
      updated builder instance
      See Also:
    • putServiceInfoDependency

      public BUILDER putServiceInfoDependency(ServiceInfoCriteria key, Set<DependencyInfo> serviceInfoDependency)
      This method adds a new value to the map, or replaces it if the key already exists.
      Parameters:
      key - key to add or replace
      serviceInfoDependency - new value for the key
      Returns:
      updated builder instance
      See Also:
    • clearFromServiceTypeName

      public BUILDER clearFromServiceTypeName()
      Clear existing value of this property.
      Returns:
      updated builder instance
      See Also:
    • fromServiceTypeName

      public BUILDER fromServiceTypeName(TypeName fromServiceTypeName)
      Optionally, the service type name aggregating allDependencies().
      Parameters:
      fromServiceTypeName - the optional service type name for which these dependencies belong
      Returns:
      updated builder instance
      See Also:
    • fromServiceTypeName

      public BUILDER fromServiceTypeName(Consumer<TypeName.Builder> consumer)
      Optionally, the service type name aggregating allDependencies().
      Parameters:
      consumer - the optional service type name for which these dependencies belong
      Returns:
      updated builder instance
      See Also:
    • serviceInfoDependencies

      public Map<ServiceInfoCriteria,Set<DependencyInfo>> serviceInfoDependencies()
      Represents the set of dependencies for each ServiceInfo.
      Returns:
      the service info dependencies
    • fromServiceTypeName

      public Optional<TypeName> fromServiceTypeName()
      Optionally, the service type name aggregating allDependencies().
      Returns:
      the from service type name
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • preBuildPrototype

      protected void preBuildPrototype()
      Handles providers and decorators.
    • validatePrototype

      protected void validatePrototype()
      Validates required properties.