This project has retired. For details please refer to its
Attic page.
ComponentsSelector (Cocoon API 2.1.12-dev [March 20 2012])
org.apache.cocoon.components.treeprocessor.sitemap
Class ComponentsSelector
java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.avalon.excalibur.component.AbstractDualLogEnabled
org.apache.avalon.excalibur.component.ExcaliburComponentSelector
org.apache.cocoon.components.ExtendedComponentSelector
org.apache.cocoon.components.treeprocessor.sitemap.ComponentsSelector
- All Implemented Interfaces:
- RoleManageable, LoggerManageable, LogKitManageable, Disposable, Initializable, Component, ComponentSelector, Composable, Configurable, Contextualizable, LogEnabled, Loggable, ThreadSafe, ParentAware, OutputComponentSelector, SitemapComponentSelector, Instrumentable, InstrumentManageable
public class ComponentsSelector
- extends ExtendedComponentSelector
- implements OutputComponentSelector, SitemapComponentSelector
Component selector for sitemap components.
- Version:
- CVS $Id: ComponentsSelector.html 1304258 2012-03-23 10:09:27Z ilgrosso $
- Author:
- Sylvain Wallez, Upayavira
Methods inherited from class org.apache.avalon.excalibur.component.ExcaliburComponentSelector |
addComponentInstance, compose, contextualize, getChildInstrumentables, getComponentHandler, getComponentHandlers, getInstrumentableName, getInstruments, setInstrumentableName, setInstrumentManager, setLoggerManager, setLogKitManager |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UNKNOWN
public static final int UNKNOWN
- See Also:
- Constant Field Values
GENERATOR
public static final int GENERATOR
- See Also:
- Constant Field Values
TRANSFORMER
public static final int TRANSFORMER
- See Also:
- Constant Field Values
SERIALIZER
public static final int SERIALIZER
- See Also:
- Constant Field Values
READER
public static final int READER
- See Also:
- Constant Field Values
MATCHER
public static final int MATCHER
- See Also:
- Constant Field Values
SELECTOR
public static final int SELECTOR
- See Also:
- Constant Field Values
ACTION
public static final int ACTION
- See Also:
- Constant Field Values
PIPELINE
public static final int PIPELINE
- See Also:
- Constant Field Values
SELECTOR_ROLES
public static final String[] SELECTOR_ROLES
COMPONENT_NAMES
public static final String[] COMPONENT_NAMES
ComponentsSelector
public ComponentsSelector()
setParentLocator
public void setParentLocator(ComponentLocator locator)
throws ComponentException
- Description copied from interface:
ParentAware
- Set the parent component manager and the role name
- Specified by:
setParentLocator
in interface ParentAware
- Overrides:
setParentLocator
in class ExtendedComponentSelector
- Throws:
ComponentException
getComponentInstanceName
protected String getComponentInstanceName()
- Return the component instance name according to the selector role
(e.g. "action" for "org.apache.cocoon.acting.Action").
- Overrides:
getComponentInstanceName
in class ExtendedComponentSelector
- Returns:
null
, but can be changed by subclasses
getClassAttributeName
protected String getClassAttributeName()
- Get the attribute for class names. This is "src" for known roles, and
"class" (the default) for other roles.
- Overrides:
getClassAttributeName
in class ExtendedComponentSelector
- Returns:
- "
class
", but can be changed by subclasses
configure
public void configure(Configuration config)
throws ConfigurationException
- Description copied from class:
ExtendedComponentSelector
- Configure this selector. This is the main difference with the parent class :
addComponent
public void addComponent(Object hint,
Class clazz,
Configuration config)
throws ComponentException
- Add a component in this selector. If needed, also register it's MIME type.
- Overrides:
addComponent
in class ExcaliburComponentSelector
- Throws:
ComponentException
initialize
public void initialize()
- Ensure system-defined components exist (e.g. <aggregator>) and initialize
the selector.
- Specified by:
initialize
in interface Initializable
- Overrides:
initialize
in class ExcaliburComponentSelector
getMimeTypeForHint
public String getMimeTypeForHint(Object hint)
- Get the MIME type for a given hint.
- Specified by:
getMimeTypeForHint
in interface OutputComponentSelector
- Parameters:
hint
- the component hint
- Returns:
- the MIME type for this hint, or
null
.
hasLabel
public boolean hasLabel(Object hint,
String label)
- Specified by:
hasLabel
in interface SitemapComponentSelector
getLabels
public String[] getLabels(Object hint)
- Specified by:
getLabels
in interface SitemapComponentSelector
getPipelineHint
public String getPipelineHint(Object hint)
- Specified by:
getPipelineHint
in interface SitemapComponentSelector
dispose
public void dispose()
- Specified by:
dispose
in interface Disposable
- Overrides:
dispose
in class ExtendedComponentSelector
Copyright © 1999-2010 The Apache Software Foundation. All Rights Reserved.