org.webharvest.runtime.processors.plugins
Class DbParamPlugin

java.lang.Object
  extended by org.webharvest.runtime.processors.BaseProcessor
      extended by org.webharvest.runtime.processors.WebHarvestPlugin
          extended by org.webharvest.runtime.processors.plugins.DbParamPlugin

public class DbParamPlugin
extends WebHarvestPlugin

DB param plugin - can be used only inside database plugin.


Constructor Summary
DbParamPlugin()
           
 
Method Summary
 Variable executePlugin(Scraper scraper, ScraperContext context)
          Mathod that actually executes processor.
 java.lang.String[] getAttributeValueSuggestions(java.lang.String attributeName)
           
 java.lang.String getName()
          Defines name of the processor.
 java.lang.String[] getValidAttributes()
          This method should return all possible attribute names for the plugin processor.
 
Methods inherited from class org.webharvest.runtime.processors.WebHarvestPlugin
execute, getAttributeDesc, getDependantProcessors, getRequiredAttributes, getRequiredSubprocessors, getTagDesc, getValidSubprocessors, hasBody, setDef
 
Methods inherited from class org.webharvest.runtime.processors.BaseProcessor
getElementDef, run
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DbParamPlugin

public DbParamPlugin()
Method Detail

getName

public java.lang.String getName()
Description copied from class: WebHarvestPlugin
Defines name of the processor. Should be valid identifier. Processor's tag will use this name. For example, if this name is "myprocessor" in config file it will be used as <myprocessor...>...</myprocessor>

Specified by:
getName in class WebHarvestPlugin
Returns:
Name of the processor

executePlugin

public Variable executePlugin(Scraper scraper,
                              ScraperContext context)
Description copied from class: WebHarvestPlugin
Mathod that actually executes processor. Since one instance of this class may be used for multiple executions, creator of plugin is responsible for initiating local variables at the beginning of this method.

Specified by:
executePlugin in class WebHarvestPlugin
Returns:
Instance of variable as result of xecution.

getValidAttributes

public java.lang.String[] getValidAttributes()
Description copied from class: WebHarvestPlugin
This method should return all possible attribute names for the plugin processor.

Overrides:
getValidAttributes in class WebHarvestPlugin
Returns:
Array of attribute names (case insensitive)

getAttributeValueSuggestions

public java.lang.String[] getAttributeValueSuggestions(java.lang.String attributeName)
Overrides:
getAttributeValueSuggestions in class WebHarvestPlugin
Parameters:
attributeName - Name of plugin attribute
Returns:
Array of valuee suggestions for specified attribute (this is used for auto-complete feature in IDE). null means nothing to suggest.