Class DefaultPrintMediaService
- java.lang.Object
-
- de.hybris.platform.warehousing.labels.service.impl.DefaultPrintMediaService
-
- All Implemented Interfaces:
PrintMediaService
public class DefaultPrintMediaService extends java.lang.Object implements PrintMediaService
Default implementation ofPrintMediaService
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
DOCUMENT_BODY_ENCODING
-
Constructor Summary
Constructors Constructor Description DefaultPrintMediaService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
generateHtmlMediaTemplate(MediaModel mediaModel)
Generates an HTML page for the givenMediaModel
java.lang.String
generatePopupScriptForMedia(MediaModel mediaModel, java.lang.String width, java.lang.String height, java.lang.String blockedPopupMessage)
Generates the script of the popup for the givenMediaModel
protected DocumentGenerationService
getDocumentGenerationService()
protected ImpersonationService
getImpersonationService()
MediaModel
getMediaForTemplate(java.lang.String frontendTemplateName, BusinessProcessModel businessProcessModel)
Generates theMediaModel
for the givenConsignmentModel
protected MediaService
getMediaService()
protected ModelService
getModelService()
protected OrderModel
getOrder(BusinessProcessModel businessProcessModel)
ExtractsOrderModel
from the business processvoid
setDocumentGenerationService(DocumentGenerationService documentGenerationService)
void
setImpersonationService(ImpersonationService impersonationService)
void
setMediaService(MediaService mediaService)
void
setModelService(ModelService modelService)
-
-
-
Field Detail
-
DOCUMENT_BODY_ENCODING
public static final java.lang.String DOCUMENT_BODY_ENCODING
- See Also:
- Constant Field Values
-
-
Method Detail
-
getMediaForTemplate
public MediaModel getMediaForTemplate(java.lang.String frontendTemplateName, BusinessProcessModel businessProcessModel)
Description copied from interface:PrintMediaService
Generates theMediaModel
for the givenConsignmentModel
- Specified by:
getMediaForTemplate
in interfacePrintMediaService
- Parameters:
frontendTemplateName
- the templateName to generate theMediaModel
businessProcessModel
- theBusinessProcessModel
for which media needs to be generated- Returns:
- the generated
MediaModel
-
generatePopupScriptForMedia
public java.lang.String generatePopupScriptForMedia(MediaModel mediaModel, java.lang.String width, java.lang.String height, java.lang.String blockedPopupMessage)
Generates the script of the popup for the givenMediaModel
- Specified by:
generatePopupScriptForMedia
in interfacePrintMediaService
- Parameters:
mediaModel
- theMediaModel
for which popup script needs to be generatedwidth
- the width of the popupheight
- the height of the popupblockedPopupMessage
- the localised message if the popups are blocked- Returns:
- the script of the popup
-
generateHtmlMediaTemplate
public java.lang.String generateHtmlMediaTemplate(MediaModel mediaModel)
Description copied from interface:PrintMediaService
Generates an HTML page for the givenMediaModel
- Specified by:
generateHtmlMediaTemplate
in interfacePrintMediaService
- Parameters:
mediaModel
- theMediaModel
to be rendered as an HTML page- Returns:
- the generated HTML page
-
getOrder
protected OrderModel getOrder(BusinessProcessModel businessProcessModel)
ExtractsOrderModel
from the business process- Parameters:
businessProcessModel
- theBusinessProcessModel
from whichOrderModel
needs to be extracted- Returns:
- the
OrderModel
-
getImpersonationService
protected ImpersonationService getImpersonationService()
-
setImpersonationService
public void setImpersonationService(ImpersonationService impersonationService)
-
getDocumentGenerationService
protected DocumentGenerationService getDocumentGenerationService()
-
setDocumentGenerationService
public void setDocumentGenerationService(DocumentGenerationService documentGenerationService)
-
getMediaService
protected MediaService getMediaService()
-
setMediaService
public void setMediaService(MediaService mediaService)
-
getModelService
protected ModelService getModelService()
-
setModelService
public void setModelService(ModelService modelService)
-
-