O
- as Order
INVOICE
- as Invoice data structurepublic class SpringTemplateInvoiceService<O extends Order<I>,I extends OrderItem,INVOICE> extends TemplateInvoiceService<O,I,INVOICE> implements org.springframework.context.ApplicationContextAware
TemplateInvoiceService
for Spring Beans
Publisher
is derived from the Spring Context. The publisherTemplateName
should be prototype scope.
ApplicationContext
Constructor and Description |
---|
SpringTemplateInvoiceService() |
SpringTemplateInvoiceService(String publisherTemplateName)
Publisher s are stateful; hence the bean name is supplied so that a new instance is instatiated on each request |
Modifier and Type | Method and Description |
---|---|
org.springframework.context.ApplicationContext |
getApplicationContext() |
protected Publisher |
getPublisher(O order)
Get Publisher for each instance request
|
protected void |
processContext(O order,
Map dataMap)
Can process order to derive other intermediate context variables and put them in the context Map.
|
void |
setApplicationContext(org.springframework.context.ApplicationContext applicationContext) |
addChangeListener, convertStreamToInvoice, generateInvoice, getInvoiceType, getListeners, notifyAllListeners, setListeners, updateInvoiceHistory
public final void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) throws org.springframework.beans.BeansException
setApplicationContext
in interface org.springframework.context.ApplicationContextAware
org.springframework.beans.BeansException
protected void processContext(O order, Map dataMap)
TemplateInvoiceService
Date
(If new it will update the order object)processContext
in class TemplateInvoiceService<O extends Order<I>,I extends OrderItem,INVOICE>
protected final Publisher getPublisher(O order)
getPublisher
in class TemplateInvoiceService<O extends Order<I>,I extends OrderItem,INVOICE>
public org.springframework.context.ApplicationContext getApplicationContext()
Copyright © 2018. All rights reserved.