org.apache.pdfbox.preflight.graphic

## Class ColorSpaceHelperFactory

- java.lang.Object
- - org.apache.pdfbox.preflight.graphic.ColorSpaceHelperFactory

    public class ColorSpaceHelperFactory
    extends Object

This factory create the right Helper according to the owner of the ColorSpace entry.

### Nested Class Summary

Nested Classes
`static class` `ColorSpaceHelperFactory.ColorSpaceRestriction` Enum used as argument of methods of this factory to return the right Helper.

### Constructor Summary

Constructors
Constructor and Description
`ColorSpaceHelperFactory()`

### Method Summary

All Methods Instance Methods Concrete Methods
`ColorSpaceHelper` `getColorSpaceHelper(PreflightContext context, org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace cs, ColorSpaceHelperFactory.ColorSpaceRestriction csr)` Return an instance of ColorSpaceHelper according to the ColorSpaceRestriction value.

### Methods inherited from class java.lang.Object

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

### Constructor Detail

#### ColorSpaceHelperFactory

    public ColorSpaceHelperFactory()

### Method Detail

#### getColorSpaceHelper

    public ColorSpaceHelper getColorSpaceHelper(PreflightContext context,
                                                org.apache.pdfbox.pdmodel.graphics.color.PDColorSpace cs,
                                                ColorSpaceHelperFactory.ColorSpaceRestriction csr)

Return an instance of ColorSpaceHelper according to the ColorSpaceRestriction value.

- ColorSpaceRestriction.NO_PATTERN : returns NoPatternColorSpaceHelper
- ColorSpaceRestriction.ONLY_DEVICE : returns DeviceColorSpaceHelper
- ColorSpaceRestriction.NO_RESTRICTION (default) : returns StandardColorSpaceHelper

Parameters:
  `context` - the PreflightContext to access useful data
  `cs` - the High level PDFBox object which represents the ColorSpace
  `csr` - the color space restriction
Returns:
  the ColorSpaceHelper instance.