Interface PackagerFactory
-
- All Known Implementing Classes:
DefaultPackagerFactory
public interface PackagerFactory
Create aPackager
instance for a given container.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description Packager
createPackager(String containerId, PackagerType packagerType, String outputLocation)
Create aPackager
instance matching the specified container id.boolean
isPackagerRegistered(String containerId, PackagerType packagerType)
void
registerPackager(String containerId, PackagerType packagerType, Class<? extends Packager> packagerClass)
Registers aPackager
implementation.
-
-
-
Method Detail
-
registerPackager
void registerPackager(String containerId, PackagerType packagerType, Class<? extends Packager> packagerClass)
Registers aPackager
implementation.- Parameters:
containerId
- the container attached to this packagerpackagerType
- the packager's type (directory, zip, etc)packagerClass
- the packager implementation class to register
-
isPackagerRegistered
boolean isPackagerRegistered(String containerId, PackagerType packagerType)
- Parameters:
containerId
- the container attached to this packager classpackagerType
- the type to differentiate this packager from others for the specified container- Returns:
- true if the specified packager is already registered or false otherwise
-
createPackager
Packager createPackager(String containerId, PackagerType packagerType, String outputLocation)
Create aPackager
instance matching the specified container id.- Parameters:
containerId
- the container for which we need to create a packager instancepackagerType
- the packager's type (directory, zip, etc)outputLocation
- the location where the package will be generated. For example for a Directory Packager this will be the directory into which the package will be generated.- Returns:
- the packager instance
-
-