org.apache.fulcrum.yaafi.framework.factory
Class ServiceContainerFactory

java.lang.Object
  extended by org.apache.fulcrum.yaafi.framework.factory.ServiceContainerFactory

public class ServiceContainerFactory
extends java.lang.Object

A factory to hide how to initialize YAFFI since this might change over the time

Author:
Siegfried Goeschl

Constructor Summary
ServiceContainerFactory()
           
 
Method Summary
static ServiceContainer create(ServiceContainerConfiguration serviceManagerConfig)
          Create a fully initialized YAFFI service container.
static ServiceContainer create(ServiceContainerConfiguration serviceManagerConfig, org.apache.avalon.framework.context.Context context)
          Create a fully initialized YAFFI service container
static boolean dispose(ServiceContainer container)
          Disposes the container.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ServiceContainerFactory

public ServiceContainerFactory()
Method Detail

create

public static ServiceContainer create(ServiceContainerConfiguration serviceManagerConfig)
                               throws java.lang.Exception
Create a fully initialized YAFFI service container.

Parameters:
serviceManagerConfig - the configuration to use
Returns:
the service container
Throws:
java.lang.Exception - the creation failed

create

public static ServiceContainer create(ServiceContainerConfiguration serviceManagerConfig,
                                      org.apache.avalon.framework.context.Context context)
                               throws java.lang.Exception
Create a fully initialized YAFFI service container

Parameters:
serviceManagerConfig - the configuration to use
context - the context to use
Returns:
the service container
Throws:
java.lang.Exception - the creation failed

dispose

public static boolean dispose(ServiceContainer container)
Disposes the container.

Parameters:
container - the container to be disposed
Returns:
true if the disposal was successful or false otherwise


Copyright © 2000-2011 Apache Software Foundation. All Rights Reserved.