Klasse VelocityOutletSaxHandlerFactory

java.lang.Object
org.apache.torque.generator.configuration.outlet.VelocityOutletSaxHandlerFactory
Alle implementierten Schnittstellen:
TypedOutletSaxHandlerFactory

public class VelocityOutletSaxHandlerFactory extends Object implements TypedOutletSaxHandlerFactory
Creates Velocity outlet SAX handlers.
  • Konstruktordetails

    • VelocityOutletSaxHandlerFactory

      public VelocityOutletSaxHandlerFactory()
  • Methodendetails

    • getType

      public String getType()
      Returns the outlet type which can be handled by the OutletSaxHandlers created by this factory.
      Angegeben von:
      getType in Schnittstelle TypedOutletSaxHandlerFactory
      Gibt zurück:
      "velocityOutlet".
    • getTemplatesFilenameExtensionsForScan

      public Collection<String> getTemplatesFilenameExtensionsForScan()
      Returns the filename extensions for templates which define outlets of this type. These extensions are used for scanning the templates tree.
      Angegeben von:
      getTemplatesFilenameExtensionsForScan in Schnittstelle TypedOutletSaxHandlerFactory
      Gibt zurück:
      A list with the entry ".vm".
    • createOutletForTemplate

      public Outlet createOutletForTemplate(String templatePath, ConfigurationProvider configurationProvider) throws ConfigurationException
      Creates an outlet for a template with the given file name.
      Angegeben von:
      createOutletForTemplate in Schnittstelle TypedOutletSaxHandlerFactory
      Parameter:
      templatePath - the path to the template, relative to the templates directory, not null.
      configurationProvider - the configuration provider, not null.
      Gibt zurück:
      the outlet, not null.
      Löst aus:
      ConfigurationException - if the outlet cannot be created.
    • getOutletSaxHandler

      public final OutletSaxHandler getOutletSaxHandler(QualifiedName outletName, ConfigurationProvider configurationProvider, UnitDescriptor unitDescriptor, ConfigurationHandlers configurationHandlers) throws SAXException
      Returns a VelocityOutletSaxHandler for reading the configuration of Velocity outlets. This implementation uses the provided name as outlet name.
      Angegeben von:
      getOutletSaxHandler in Schnittstelle TypedOutletSaxHandlerFactory
      Parameter:
      outletName - the name for the outlet which configuration will be read in by the generated SaxHandlerFactory, or null if the name of the outlet should be determined from the parsed xml.
      configurationProvider - The access object for the configuration files, not null.
      unitDescriptor - The description of the generation unit, not null.
      configurationHandlers - the available configuration handlers, not null.
      Gibt zurück:
      a new VelocityOutletSaxHandler.
      Löst aus:
      SAXException - if the SAX Handler for the outlet can not be created from the given XML element.