Package org.apache.tapestry5.plastic
Class PlasticManager.PlasticManagerBuilder
- java.lang.Object
-
- org.apache.tapestry5.internal.plastic.Lockable
-
- org.apache.tapestry5.plastic.PlasticManager.PlasticManagerBuilder
-
- Enclosing class:
- PlasticManager
public static class PlasticManager.PlasticManagerBuilder extends Lockable
A builder object for configuring the PlasticManager before instantiating it. Assumes a no-opPlasticManagerDelegate
and an empty set of controlled packages, which is appropriate when simply creating proxy objects. The builder object is internally mutable and uses a fluid API (each method returns the same instance).
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PlasticManager
create()
Creates the PlasticManager with the current set of options.PlasticManager.PlasticManagerBuilder
delegate(PlasticManagerDelegate delegate)
Sets thePlasticManagerDelegate
, which is ultimately responsible for transforming classes loaded from controlled packages.PlasticManager.PlasticManagerBuilder
enable(TransformationOption option)
PlasticManager.PlasticManagerBuilder
packages(Collection<String> packageNames)
Adds additional controlled packages, in which classes are loaded and transformed.
-
-
-
Method Detail
-
delegate
public PlasticManager.PlasticManagerBuilder delegate(PlasticManagerDelegate delegate)
Sets thePlasticManagerDelegate
, which is ultimately responsible for transforming classes loaded from controlled packages. The default delegate does nothing.
-
packages
public PlasticManager.PlasticManagerBuilder packages(Collection<String> packageNames)
Adds additional controlled packages, in which classes are loaded and transformed.
-
enable
public PlasticManager.PlasticManagerBuilder enable(TransformationOption option)
-
create
public PlasticManager create()
Creates the PlasticManager with the current set of options.- Returns:
- the PlasticManager
-
-