Class PreFillType.Builder
- java.lang.Object
-
- com.bumptech.glide.load.engine.prefill.PreFillType.Builder
-
- Enclosing class:
- PreFillType
public static class PreFillType.Builder extends java.lang.ObjectBuilder forPreFillType.
-
-
Constructor Summary
Constructors Constructor Description Builder(int size)Constructor for a builder that uses the given size as the width and height of the Bitmaps to prefill.Builder(int width, int height)Constructor for a builder that uses the given dimensions as the dimensions of the Bitmaps to prefill.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PreFillType.BuildersetConfig(android.graphics.Bitmap.Config config)Sets theBitmap.Configfor the Bitmaps to pre-fill.PreFillType.BuildersetWeight(int weight)Sets the weight to use to balance how many Bitmaps of this type are prefilled relative to the other requested types.
-
-
-
Constructor Detail
-
Builder
public Builder(int size)
Constructor for a builder that uses the given size as the width and height of the Bitmaps to prefill.- Parameters:
size- The width and height in pixels of the Bitmaps to prefill.
-
Builder
public Builder(int width, int height)Constructor for a builder that uses the given dimensions as the dimensions of the Bitmaps to prefill.- Parameters:
width- The width in pixels of the Bitmaps to prefill.height- The height in pixels of the Bitmaps to prefill.
-
-
Method Detail
-
setConfig
public PreFillType.Builder setConfig(@Nullable android.graphics.Bitmap.Config config)
Sets theBitmap.Configfor the Bitmaps to pre-fill.- Parameters:
config- The config to use, or null to use Glide's default.- Returns:
- This builder.
-
setWeight
public PreFillType.Builder setWeight(int weight)
Sets the weight to use to balance how many Bitmaps of this type are prefilled relative to the other requested types.- Parameters:
weight- An integer indicating how to balance pre-filling this size and configuration ofBitmapagainst any other sizes/configurations that may be being pre-filled.- Returns:
- This builder.
-
-