| Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||||||
| AutoMockNameSpaceHandler |
|
| 0.0;0 |
| 1 | package org.doxla.spring.automock.xml.namespace; |
|
| 2 | ||
| 3 | import org.springframework.beans.factory.xml.NamespaceHandlerSupport; |
|
| 4 | ||
| 5 | /** |
|
| 6 | * Register a {@link BasicAutoMockBeanDefinitionParser} for each of the Spring AutoMock elements |
|
| 7 | * defined in the automock.xsd schema. |
|
| 8 | * |
|
| 9 | * @author danoxlade |
|
| 10 | */ |
|
| 11 | 5 | public class AutoMockNameSpaceHandler extends NamespaceHandlerSupport { |
| 12 | ||
| 13 | /** |
|
| 14 | * Register each {@link BasicAutoMockBeanDefinitionParser} with Spring |
|
| 15 | */ |
|
| 16 | public void init() { |
|
| 17 | 10 | for(NamespaceElement element : NamespaceElement.values()){ |
| 18 | 5 | registerBeanDefinitionParser(element.name(), new BasicAutoMockBeanDefinitionParser(element)); |
| 19 | } |
|
| 20 | 5 | } |
| 21 | ||
| 22 | } |