org.apache.jsieve
Class TestManagerImpl

java.lang.Object
  extended by org.apache.jsieve.TestManagerImpl
All Implemented Interfaces:
TestManager

public class TestManagerImpl
extends java.lang.Object
implements TestManager

Maps Test names to configured Test implementation classes.

Thread Safety

Instances may safely be accessed concurrently by multiple threads.


Constructor Summary
TestManagerImpl(java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.String> classNameMap)
          TestManager is instanciated with getInstance
 
Method Summary
 ExecutableTest getTest(java.lang.String name)
           Method newInstance answers an instance of the class to which a Test name is mapped.
 java.lang.Class lookup(java.lang.String name)
           Method lookup answers the class to which a Test name is mapped.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TestManagerImpl

public TestManagerImpl(java.util.concurrent.ConcurrentMap<java.lang.String,java.lang.String> classNameMap)
TestManager is instanciated with getInstance

Method Detail

lookup

public java.lang.Class lookup(java.lang.String name)
                       throws LookupException

Method lookup answers the class to which a Test name is mapped.

Parameters:
name - - The name of the Test
Returns:
Class - The class of the Test
Throws:
LookupException

getTest

public ExecutableTest getTest(java.lang.String name)
                       throws LookupException

Method newInstance answers an instance of the class to which a Test name is mapped.

Specified by:
getTest in interface TestManager
Parameters:
name - - The name of the Test
Returns:
Class - The class of the Test
Throws:
LookupException


Copyright © 2008-2009 The Apache Software Foundation. All Rights Reserved.