org.openmrs.report.impl
Class ReportServiceImpl

java.lang.Object
  extended by org.openmrs.report.impl.ReportServiceImpl
All Implemented Interfaces:
ReportService

Deprecated. see reportingcompatibility module

@Deprecated
public class ReportServiceImpl
extends java.lang.Object
implements ReportService

Methods specific to objects in the report package. These methods render reports or save them to the database

See Also:
ReportService, Context

Field Summary
 org.apache.commons.logging.Log log
          Deprecated.  
 
Constructor Summary
ReportServiceImpl()
          Deprecated. Default constructor
 
Method Summary
 java.lang.String applyReportXmlMacros(java.lang.String input)
          Deprecated. Applies the report xml macros to the input, and returns it.
 void createReportSchemaXml(ReportSchemaXml reportSchemaXml)
          Deprecated. use saveReportSchemaXml(reportSchemaXml)
 void deleteReportSchema(ReportSchema reportSchema)
          Deprecated. Deletes a ReportSchema from the database.
 void deleteReportSchemaXml(ReportSchemaXml reportSchemaXml)
          Deprecated. Delete the given ReportSchemaXml class from the db
 ReportData evaluate(ReportSchema reportSchema, Cohort inputCohort, EvaluationContext evalContext)
          Deprecated. This method evaluates a ReportSchema object for the given EvaluationContext and input Cohort.
 java.util.Map<java.lang.Class<? extends ReportRenderer>,ReportRenderer> getRenderers()
          Deprecated. Gets the renderers map registered to this report service
 java.util.List<RenderingMode> getRenderingModes(ReportSchema schema)
          Deprecated. Returns a List of RenderingModes that the passed ReportSchema supports, in their preferred order
 ReportRenderer getReportRenderer(java.lang.Class<? extends ReportRenderer> clazz)
          Deprecated. Returns the registered ReportRenderer whose class matches the passed class
 ReportRenderer getReportRenderer(java.lang.String className)
          Deprecated. Returns the registered ReportRenderer whose class matches the passed class name
 java.util.Collection<ReportRenderer> getReportRenderers()
          Deprecated. Returns a Collection of all registered ReportRenderers
 ReportSchema getReportSchema(java.lang.Integer reportSchemaId)
          Deprecated. Get the ReportSchema with the given id
 ReportSchema getReportSchema(ReportSchemaXml reportSchemaXml)
          Deprecated. Returns a ReportSchema object from a ReportSchemaXml definition De-serialized the xml definition, applies macro definitions, and returns an expanded report schema object
 java.util.List<ReportSchema> getReportSchemas()
          Deprecated. Return a list of ReportSchemas
 ReportSchemaXml getReportSchemaXml(java.lang.Integer reportSchemaXmlId)
          Deprecated. Get the xmlified ReportSchema object that was saved previously
 java.util.List<ReportSchemaXml> getReportSchemaXmls()
          Deprecated. Get all saved ReportSchemaXml objects in the db
 java.util.Properties getReportXmlMacros()
          Deprecated. Gets the macros that will be used when deserializing ReportSchemaXML
 void onShutdown()
          Deprecated. Clean up after this class.
 void registerRenderer(java.lang.Class<? extends ReportRenderer> rendererClass, ReportRenderer renderer)
          Deprecated. Registers the given renderer with the service
 void registerRenderer(java.lang.String rendererClass)
          Deprecated. Convenience method for ReportService.registerRenderer(Class, ReportRenderer)
 void removeRenderer(java.lang.Class<? extends ReportRenderer> renderingClass)
          Deprecated. Remove the renderer associated with rendererClass from the list of available renderers
 void saveReportSchema(ReportSchema reportSchema)
          Deprecated. Save or update the given ReportSchema in the database.
 void saveReportSchemaXml(ReportSchemaXml reportSchemaXml)
          Deprecated. Insert or update the given ReportSchemaXml object in the database.
 void saveReportXmlMacros(java.util.Properties macros)
          Deprecated. Saves the macros that will be used when deserializing ReportSchemaXML
 void setRenderers(java.util.Map<java.lang.Class<? extends ReportRenderer>,ReportRenderer> newRenderers)
          Deprecated. ADDs renderers...doesn't replace them.
 void setReportDAO(ReportDAO dao)
          Deprecated. Method used by Spring injection to set the ReportDAO implementation to use in this service
 void updateReportSchemaXml(ReportSchemaXml reportSchemaXml)
          Deprecated. use saveReportSchemaXml(reportSchemaXml)
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

public org.apache.commons.logging.Log log
Deprecated. 
Constructor Detail

ReportServiceImpl

public ReportServiceImpl()
Deprecated. 
Default constructor

Method Detail

setReportDAO

public void setReportDAO(ReportDAO dao)
Deprecated. 
Method used by Spring injection to set the ReportDAO implementation to use in this service

Parameters:
dao - The ReportDAO to use in this service

onShutdown

public void onShutdown()
Deprecated. 
Clean up after this class. Set the static var to null so that the classloader can reclaim the space.

See Also:
BaseOpenmrsService.onShutdown()

deleteReportSchema

public void deleteReportSchema(ReportSchema reportSchema)
Deprecated. 
Description copied from interface: ReportService
Deletes a ReportSchema from the database.

Specified by:
deleteReportSchema in interface ReportService
Parameters:
reportSchema - The ReportSchema to remove from the system
See Also:
ReportService.deleteReportSchema(org.openmrs.report.ReportSchema)

evaluate

public ReportData evaluate(ReportSchema reportSchema,
                           Cohort inputCohort,
                           EvaluationContext evalContext)
Deprecated. 
Description copied from interface: ReportService
This method evaluates a ReportSchema object for the given EvaluationContext and input Cohort. It returns the ReportData object which contains the Report "results".

Specified by:
evaluate in interface ReportService
Parameters:
reportSchema - - The ReportSchema is the main report definition, and contains all indicator and required parameter definitions
inputCohort - - If not null, this will limit the Report evaluation to only those patients in this Cohort. If null, all patients are evaluated.
evalContext - - The EvaluationContext which contains the parameters, provides caching for the report evaluation
Returns:
ReportData - Contains the evaluated report data
See Also:
ReportService.evaluate(org.openmrs.report.ReportSchema, org.openmrs.Cohort, org.openmrs.report.EvaluationContext)

getReportRenderer

public ReportRenderer getReportRenderer(java.lang.Class<? extends ReportRenderer> clazz)
Deprecated. 
Description copied from interface: ReportService
Returns the registered ReportRenderer whose class matches the passed class

Specified by:
getReportRenderer in interface ReportService
Parameters:
clazz - The ReportRenderer implementation class to retrieve
Returns:
- The ReportRenderer that has been registered that matches the passed class
See Also:
ReportService.getReportRenderer(java.lang.String)

getReportRenderer

public ReportRenderer getReportRenderer(java.lang.String className)
Deprecated. 
Description copied from interface: ReportService
Returns the registered ReportRenderer whose class matches the passed class name

Specified by:
getReportRenderer in interface ReportService
Parameters:
className - The String name of the ReportRenderer implementation class to retrieve
Returns:
The ReportRenderer that has been registered that matches the passed class name
See Also:
ReportService.getReportRenderer(java.lang.String)

getReportRenderers

public java.util.Collection<ReportRenderer> getReportRenderers()
Deprecated. 
Description copied from interface: ReportService
Returns a Collection of all registered ReportRenderers

Specified by:
getReportRenderers in interface ReportService
Returns:
All registered report renderers
See Also:
ReportService.getReportRenderers()

getRenderingModes

public java.util.List<RenderingMode> getRenderingModes(ReportSchema schema)
Deprecated. 
Description copied from interface: ReportService
Returns a List of RenderingModes that the passed ReportSchema supports, in their preferred order

Specified by:
getRenderingModes in interface ReportService
Returns:
all rendering modes for the given schema, in their preferred order
See Also:
ReportService.getRenderingModes(org.openmrs.report.ReportSchema)

getReportSchema

public ReportSchema getReportSchema(java.lang.Integer reportSchemaId)
                             throws APIException
Deprecated. 
Description copied from interface: ReportService
Get the ReportSchema with the given id

Specified by:
getReportSchema in interface ReportService
Parameters:
reportSchemaId - The Integer ReportSchema id
Returns:
the matching ReportSchema object
Throws:
APIException
See Also:
ReportService.getReportSchema(java.lang.Integer)

getReportSchema

public ReportSchema getReportSchema(ReportSchemaXml reportSchemaXml)
                             throws APIException
Deprecated. 
Description copied from interface: ReportService
Returns a ReportSchema object from a ReportSchemaXml definition De-serialized the xml definition, applies macro definitions, and returns an expanded report schema object

Specified by:
getReportSchema in interface ReportService
Parameters:
reportSchemaXml - - the ReportSchemaXml to use to return a ReportSchema instance
Returns:
ReportSchema
Throws:
APIException
See Also:
ReportService.getReportSchema(org.openmrs.report.ReportSchemaXml)

getReportSchemas

public java.util.List<ReportSchema> getReportSchemas()
                                              throws APIException
Deprecated. 
Description copied from interface: ReportService
Return a list of ReportSchemas

Specified by:
getReportSchemas in interface ReportService
Returns:
a List object containing all of the ReportSchemas
Throws:
APIException
See Also:
ReportService.getReportSchemas()

setRenderers

public void setRenderers(java.util.Map<java.lang.Class<? extends ReportRenderer>,ReportRenderer> newRenderers)
                  throws APIException
Deprecated. 
ADDs renderers...doesn't replace them.

Specified by:
setRenderers in interface ReportService
Parameters:
newRenderers - Map of class to renderer object
Throws:
APIException
See Also:
ReportService.setRenderers(java.util.Map)

getRenderers

public java.util.Map<java.lang.Class<? extends ReportRenderer>,ReportRenderer> getRenderers()
                                                                                     throws APIException
Deprecated. 
Description copied from interface: ReportService
Gets the renderers map registered to this report service

Specified by:
getRenderers in interface ReportService
Returns:
Map of registered org.openmrs.reports
Throws:
APIException
See Also:
ReportService.getRenderers()

registerRenderer

public void registerRenderer(java.lang.Class<? extends ReportRenderer> rendererClass,
                             ReportRenderer renderer)
                      throws APIException
Deprecated. 
Description copied from interface: ReportService
Registers the given renderer with the service

Specified by:
registerRenderer in interface ReportService
Throws:
APIException
See Also:
ReportService.registerRenderer(java.lang.Class, org.openmrs.report.ReportRenderer)

registerRenderer

public void registerRenderer(java.lang.String rendererClass)
                      throws APIException
Deprecated. 
Description copied from interface: ReportService
Convenience method for ReportService.registerRenderer(Class, ReportRenderer)

Specified by:
registerRenderer in interface ReportService
Throws:
APIException
See Also:
ReportService.registerRenderer(java.lang.String)

removeRenderer

public void removeRenderer(java.lang.Class<? extends ReportRenderer> renderingClass)
Deprecated. 
Description copied from interface: ReportService
Remove the renderer associated with rendererClass from the list of available renderers

Specified by:
removeRenderer in interface ReportService
See Also:
ReportService.removeRenderer(Class)

saveReportSchema

public void saveReportSchema(ReportSchema reportSchema)
Deprecated. 
Description copied from interface: ReportService
Save or update the given ReportSchema in the database. If this is a new ReportSchema, the returned ReportSchema will have a new ReportSchema.getReportSchemaId() inserted into it that was generated by the database

Specified by:
saveReportSchema in interface ReportService
Parameters:
reportSchema - The ReportSchema to save or update
See Also:
ReportService.saveReportSchema(org.openmrs.report.ReportSchema)

getReportSchemaXml

public ReportSchemaXml getReportSchemaXml(java.lang.Integer reportSchemaXmlId)
Deprecated. 
Description copied from interface: ReportService
Get the xmlified ReportSchema object that was saved previously

Specified by:
getReportSchemaXml in interface ReportService
Returns:
ReportSchemaXml object that is associated with the given id
See Also:
ReportService.getReportSchemaXml(java.lang.Integer)

saveReportSchemaXml

public void saveReportSchemaXml(ReportSchemaXml reportSchemaXml)
Deprecated. 
Description copied from interface: ReportService
Insert or update the given ReportSchemaXml object in the database.

Specified by:
saveReportSchemaXml in interface ReportService
Parameters:
reportSchemaXml - xml to save
See Also:
ReportService.saveReportSchemaXml(org.openmrs.report.ReportSchemaXml)

createReportSchemaXml

public void createReportSchemaXml(ReportSchemaXml reportSchemaXml)
Deprecated. use saveReportSchemaXml(reportSchemaXml)

Description copied from interface: ReportService
Create a new ReportSchemaXml object in the database.

Specified by:
createReportSchemaXml in interface ReportService
Parameters:
reportSchemaXml - xml to save
See Also:
ReportService.createReportSchemaXml(org.openmrs.report.ReportSchemaXml)

updateReportSchemaXml

public void updateReportSchemaXml(ReportSchemaXml reportSchemaXml)
Deprecated. use saveReportSchemaXml(reportSchemaXml)

Description copied from interface: ReportService
Update the given ReportSchemaXml object in the database.

Specified by:
updateReportSchemaXml in interface ReportService
Parameters:
reportSchemaXml - xml to save
See Also:
ReportService.updateReportSchemaXml(org.openmrs.report.ReportSchemaXml)

deleteReportSchemaXml

public void deleteReportSchemaXml(ReportSchemaXml reportSchemaXml)
Deprecated. 
Description copied from interface: ReportService
Delete the given ReportSchemaXml class from the db

Specified by:
deleteReportSchemaXml in interface ReportService
See Also:
ReportService.deleteReportSchemaXml(org.openmrs.report.ReportSchemaXml)

getReportSchemaXmls

public java.util.List<ReportSchemaXml> getReportSchemaXmls()
Deprecated. 
Description copied from interface: ReportService
Get all saved ReportSchemaXml objects in the db

Specified by:
getReportSchemaXmls in interface ReportService
Returns:
List of ReportSchemaXml objects
See Also:
ReportService.getReportSchemaXmls()

getReportXmlMacros

public java.util.Properties getReportXmlMacros()
Deprecated. 
Description copied from interface: ReportService
Gets the macros that will be used when deserializing ReportSchemaXML

Specified by:
getReportXmlMacros in interface ReportService
Returns:
macros
See Also:
ReportService.getReportXmlMacros()

saveReportXmlMacros

public void saveReportXmlMacros(java.util.Properties macros)
Deprecated. 
Description copied from interface: ReportService
Saves the macros that will be used when deserializing ReportSchemaXML

Specified by:
saveReportXmlMacros in interface ReportService
Parameters:
macros - the macros to set
See Also:
ReportService.saveReportXmlMacros(java.util.Properties)

applyReportXmlMacros

public java.lang.String applyReportXmlMacros(java.lang.String input)
Deprecated. 
Description copied from interface: ReportService
Applies the report xml macros to the input, and returns it.

Specified by:
applyReportXmlMacros in interface ReportService
Parameters:
input - The text (presumably a report schema xml definition) that you want to apply macros to
Returns:
the result of applying macro substitutions to input
See Also:
ReportService.applyReportXmlMacros(java.lang.String)

OpenMRS-1.7.x

Generated Apr 27 2012 10:06 PM. NOTE - these libraries are in active development and subject to change