org.alfresco.ibatis
Class HierarchicalSqlMapConfigParser
java.lang.Object
org.alfresco.ibatis.HierarchicalSqlMapConfigParser
public class HierarchicalSqlMapConfigParser
- extends java.lang.Object
Extends the SqlMapConfigParser to allow the selection of a ResourceLoader
that will be used to load the resources specified in the sqlMap's resource.
By using the resource.dialect placeholder with hierarchical resource loading,
different resource files can be picked up for different dialects. This reduces duplication
when supporting multiple database configurations.
<sqlMapConfig>
<sqlMap resource="org/x/y/#resource.dialect#/View1.xml"/>
<sqlMap resource="org/x/y/#resource.dialect#/View2.xml"/>
</sqlMapConfig>
Much of the implementation is a direct copy of the iBatis SqlMapConfigParser
; some
of the protected methods do not have access to the object's state and can therefore
not be overridden successfully: IBATIS-589
- Since:
- 3.2 (Mobile)
Field Summary |
protected com.ibatis.common.xml.NodeletParser |
parser
|
protected com.ibatis.sqlmap.engine.builder.xml.XmlParserState |
state
|
Method Summary |
protected void |
addSqlMapNodelets()
|
com.ibatis.sqlmap.client.SqlMapClient |
parse(java.io.InputStream inputStream)
|
com.ibatis.sqlmap.client.SqlMapClient |
parse(java.io.InputStream inputStream,
java.util.Properties props)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
parser
protected final com.ibatis.common.xml.NodeletParser parser
state
protected com.ibatis.sqlmap.engine.builder.xml.XmlParserState state
HierarchicalSqlMapConfigParser
public HierarchicalSqlMapConfigParser(HierarchicalResourceLoader resourceLoader)
- Parameters:
resourceLoader
- the resource loader that supports the
parse
public com.ibatis.sqlmap.client.SqlMapClient parse(java.io.InputStream inputStream,
java.util.Properties props)
parse
public com.ibatis.sqlmap.client.SqlMapClient parse(java.io.InputStream inputStream)
addSqlMapNodelets
protected void addSqlMapNodelets()
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.