Class ECMContainer

java.lang.Object
org.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.fulcrum.testcontainer.ECMContainer
All Implemented Interfaces:
org.apache.avalon.framework.activity.Disposable, org.apache.avalon.framework.activity.Initializable, org.apache.avalon.framework.logger.LogEnabled, org.apache.fulcrum.yaafi.container.Container

public class ECMContainer extends org.apache.avalon.framework.logger.AbstractLogEnabled implements org.apache.fulcrum.yaafi.container.Container
This is a simple ECM based container that can be used in unit test of the fulcrum components.
Version:
$Id$
Author:
Quinton McCombs
  • Field Summary

    Fields inherited from interface org.apache.fulcrum.yaafi.container.Container

    COMPONENT_APP_ROOT, URN_AVALON_HOME, URN_AVALON_TEMP
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructor
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Disposes of the container and releases resources
    void
    Initializes the container
    lookup(String roleName)
    Returns an instance of the named component
    void
    release(Object component)
     
    void
    release(org.apache.avalon.framework.component.Component component)
    Releases the component
    void
    startup(String configFileName, String roleFileName, String parametersFileName)
    Starts up the container and initializes it.

    Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled

    enableLogging, getLogger, setupLogger, setupLogger, setupLogger

    Methods inherited from class java.lang.Object

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

    • ECMContainer

      public ECMContainer()
      Constructor
  • Method Details

    • startup

      public void startup(String configFileName, String roleFileName, String parametersFileName)
      Starts up the container and initializes it.
      Specified by:
      startup in interface org.apache.fulcrum.yaafi.container.Container
      Parameters:
      configFileName - Name of the component configuration file
      roleFileName - Name of the role configuration file
    • initialize

      public void initialize() throws Exception
      Initializes the container
      Specified by:
      initialize in interface org.apache.avalon.framework.activity.Initializable
      Throws:
      Exception - generic exception
    • dispose

      public void dispose()
      Disposes of the container and releases resources
      Specified by:
      dispose in interface org.apache.avalon.framework.activity.Disposable
    • lookup

      public Object lookup(String roleName) throws org.apache.avalon.framework.component.ComponentException
      Returns an instance of the named component
      Specified by:
      lookup in interface org.apache.fulcrum.yaafi.container.Container
      Parameters:
      roleName - Name of the role the component fills.
      Throws:
      org.apache.avalon.framework.component.ComponentException - generic exception
    • release

      public void release(org.apache.avalon.framework.component.Component component)
      Releases the component
      Parameters:
      component - instance of the component to release
    • release

      public void release(Object component)
      Specified by:
      release in interface org.apache.fulcrum.yaafi.container.Container