Stuart McCulloch | f317322 | 2012-06-07 21:57:32 +0000 | [diff] [blame] | 1 | package aQute.lib.spring; |
| 2 | |
| 3 | import java.util.*; |
| 4 | |
Stuart McCulloch | 42151ee | 2012-07-16 13:43:38 +0000 | [diff] [blame^] | 5 | import aQute.bnd.osgi.*; |
Stuart McCulloch | f317322 | 2012-06-07 21:57:32 +0000 | [diff] [blame] | 6 | |
| 7 | /** |
| 8 | * This component is called when we find a resource in the META-INF/*.xml |
Stuart McCulloch | 4482c70 | 2012-06-15 13:27:53 +0000 | [diff] [blame] | 9 | * pattern. We parse the resource and and the imports to the builder. Parsing is |
| 10 | * done with XSLT (first time I see the use of having XML for the Spring |
| 11 | * configuration files!). |
Stuart McCulloch | f317322 | 2012-06-07 21:57:32 +0000 | [diff] [blame] | 12 | * |
| 13 | * @author aqute |
Stuart McCulloch | f317322 | 2012-06-07 21:57:32 +0000 | [diff] [blame] | 14 | */ |
| 15 | public class JPAComponent extends XMLTypeProcessor { |
Stuart McCulloch | 4482c70 | 2012-06-15 13:27:53 +0000 | [diff] [blame] | 16 | |
| 17 | protected List<XMLType> getTypes(Analyzer analyzer) throws Exception { |
| 18 | List<XMLType> types = new ArrayList<XMLType>(); |
| 19 | process(types, "jpa.xsl", "META-INF", "persistence.xml"); |
| 20 | return types; |
| 21 | } |
Stuart McCulloch | f317322 | 2012-06-07 21:57:32 +0000 | [diff] [blame] | 22 | } |