Package com.helger.pdflayout.render
Class PreparationContext
- java.lang.Object
-
- com.helger.pdflayout.render.PreparationContext
-
@Immutable public final class PreparationContext extends Object
The current context for preparing an element. The preparation context depends on the location of an element.- Author:
- Philip Helger
-
-
Constructor Summary
Constructors Constructor Description PreparationContext(PreparationContextGlobal aGlobalCtx, float fAvailableWidth, float fAvailableHeight)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description floatgetAvailableHeight()floatgetAvailableWidth()PreparationContextGlobalgetGlobalContext()StringtoString()
-
-
-
Constructor Detail
-
PreparationContext
public PreparationContext(@Nullable PreparationContextGlobal aGlobalCtx, @Nonnegative float fAvailableWidth, @Nonnegative float fAvailableHeight)
Constructor- Parameters:
aGlobalCtx- The global preparation context worked upon. May benull.fAvailableWidth- The available width of the surrounding element. Includes margin, border and padding of the contained element. Should be > 0.fAvailableHeight- The available height of the surrounding element. Includes margin, border and padding of the contained element. Should be > 0.
-
-
Method Detail
-
getGlobalContext
@Nullable public PreparationContextGlobal getGlobalContext()
-
getAvailableWidth
public float getAvailableWidth()
- Returns:
- The available width of the surrounding element. Should be > 0.
-
getAvailableHeight
public float getAvailableHeight()
- Returns:
- The available height of the surrounding element. Should be > 0.
-
-