Class PropertyViewElementBuilderWrapper<T extends com.foreach.across.modules.web.ui.ViewElement>

java.lang.Object
com.foreach.across.modules.entity.views.helpers.PropertyViewElementBuilderWrapper<T>
All Implemented Interfaces:
com.foreach.across.modules.web.ui.ViewElementBuilder<T>

public final class PropertyViewElementBuilderWrapper<T extends com.foreach.across.modules.web.ui.ViewElement> extends Object implements com.foreach.across.modules.web.ui.ViewElementBuilder<T>
Wrapper for a ViewElementBuilder that sets the EntityPropertyDescriptor attribute on the builder context and applies additional post processors after the initial builder.
Since:
2.2.0
Author:
Arne Vandamme
See Also:
  • Nested Class Summary

    Nested classes/interfaces inherited from interface com.foreach.across.modules.web.ui.ViewElementBuilder

    com.foreach.across.modules.web.ui.ViewElementBuilder.Wither<T extends com.foreach.across.modules.web.ui.ViewElementBuilder>
  • Constructor Summary

    Constructors
    Constructor
    Description
    PropertyViewElementBuilderWrapper(@NonNull com.foreach.across.modules.web.ui.ViewElementBuilder<T> targetBuilder, EntityPropertyDescriptor propertyDescriptor, Collection<com.foreach.across.modules.web.ui.ViewElementPostProcessor<T>> postProcessors)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    build(com.foreach.across.modules.web.ui.ViewElementBuilderContext builderContext)
     
     
    @NonNull com.foreach.across.modules.web.ui.ViewElementBuilder<T>
     
    static com.foreach.across.modules.web.ui.ViewElementBuilder
    retrieveTargetBuilder(com.foreach.across.modules.web.ui.ViewElementBuilder builder)
    Fetches the target builder for a ViewElementBuilder.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface com.foreach.across.modules.web.ui.ViewElementBuilder

    andThen, build, doWith, map, map, postProcess, postProcess
  • Constructor Details

    • PropertyViewElementBuilderWrapper

      public PropertyViewElementBuilderWrapper(@NonNull @NonNull com.foreach.across.modules.web.ui.ViewElementBuilder<T> targetBuilder, EntityPropertyDescriptor propertyDescriptor, Collection<com.foreach.across.modules.web.ui.ViewElementPostProcessor<T>> postProcessors)
  • Method Details

    • build

      public T build(com.foreach.across.modules.web.ui.ViewElementBuilderContext builderContext)
      Specified by:
      build in interface com.foreach.across.modules.web.ui.ViewElementBuilder<T extends com.foreach.across.modules.web.ui.ViewElement>
    • retrieveTargetBuilder

      public static com.foreach.across.modules.web.ui.ViewElementBuilder retrieveTargetBuilder(com.foreach.across.modules.web.ui.ViewElementBuilder builder)
      Fetches the target builder for a ViewElementBuilder. If the builder is a PropertyViewElementBuilderWrapper, the actual target builder will be returned. Else the original builder is considered the target builder.
      Parameters:
      builder - to retrieve the target from
      Returns:
      current builder or unwrapped target
    • getTargetBuilder

      @NonNull public @NonNull com.foreach.across.modules.web.ui.ViewElementBuilder<T> getTargetBuilder()
    • getPropertyDescriptor

      public EntityPropertyDescriptor getPropertyDescriptor()