Class TagPluginParser


  • public class TagPluginParser
    extends java.lang.Object
    Parser for Tag Plugin descriptors.
    • Constructor Summary

      Constructors 
      Constructor Description
      TagPluginParser​(ServletContext context, boolean blockExternal)
      Creates a new TagPluginParser.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addPlugin​(java.lang.String tagClass, java.lang.String pluginClass)
      Registers a plugin class for the given tag class.
      java.util.Map<java.lang.String,​java.lang.String> getPlugins()
      Returns the map of registered tag plugins.
      void parse​(java.net.URL url)
      Parses a tag plugin descriptor from the given URL.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • TagPluginParser

        public TagPluginParser​(ServletContext context,
                               boolean blockExternal)
        Creates a new TagPluginParser.
        Parameters:
        context - the servlet context
        blockExternal - whether to block external entities
    • Method Detail

      • parse

        public void parse​(java.net.URL url)
                   throws java.io.IOException,
                          org.xml.sax.SAXException
        Parses a tag plugin descriptor from the given URL.
        Parameters:
        url - the URL of the descriptor file
        Throws:
        java.io.IOException - if an I/O error occurs
        org.xml.sax.SAXException - if a parsing error occurs
      • addPlugin

        public void addPlugin​(java.lang.String tagClass,
                              java.lang.String pluginClass)
        Registers a plugin class for the given tag class.
        Parameters:
        tagClass - the tag handler class name
        pluginClass - the plugin class name
      • getPlugins

        public java.util.Map<java.lang.String,​java.lang.String> getPlugins()
        Returns the map of registered tag plugins.
        Returns:
        the map from tag class names to plugin class names