Class ProjectionTypeFactory

java.lang.Object
com.broadleafcommerce.common.extension.ProjectionTypeFactory

public final class ProjectionTypeFactory extends Object
Factory for providing instantations of concrete implementations of the Projection interface based on a reference persistence domain class.
Author:
Jeff Fischer
  • Method Details

    • get

      public static <T> Projection<T> get(Class<T> from)
      Retrieve Projection instance referencing the persistence domain class type. See ProjectionFactory for more information on dynamic projections.
      Type Parameters:
      T - The persistence domain class type
      Parameters:
      from - The persistence domain class the projection instances references
      Returns:
      The instantiated instance implementing Projection.
    • get

      public static <T> Projection<T> get(Class<T> from, String id)
      Retrieve Projection instance referencing the persistence domain class type. See ProjectionFactory for more information on dynamic projections.
      Type Parameters:
      T - The persistence domain class type
      Parameters:
      from - The persistence domain class the projection instances references
      id - The id value to set on the projection instance (see Projection.getId())
      Returns:
      The instantiated instance implementing Projection.