xuxiuxi
2017-08-01 e09e9f8a34cbc99a33dfa9ef1792b0025575c3a8
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
 
package com.awsle.aibatis.client;
 
import java.io.InputStream;
 
import com.awsle.aibatis.io.XmlLoader;
import com.awsle.aibatis.parser.SqlMapConfigParser;
 
/**
 * 
 * @author 席有芳
 * @url http://code.awsle.com/index.php/p/aibatis/
 * @mail 951868171@qq.com
 * @version 1.0
 * @since aibatis-Alpha1.0.zip
 */
public class SqlMapClientBuilder {
 
    /**
     * 
     * @param path
     * @return
     */
    public static SqlMapClient buildSqlMapClient(String path){
        
        return buildSqlMapClient(XmlLoader.loadXmlInputStreamByPath(path));
    }
    
    /**
     * 
     * @param stream
     * @return
     */
    public static SqlMapClient buildSqlMapClient(InputStream stream){
        return new SqlMapConfigParser().parser(XmlLoader.loadXmlByStream(stream));
    }
}