日期:2014-05-18 浏览次数:20825 次
<?xml version="1.0" encoding="utf-8" ?> <objects xmlns="http://www.springframework.net" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.springframework.net http://www.springframework.net/xsd/spring-objects.xsd"> <object id="Global" type="FDC.Model.Ora.Global.GlobalSessionFactory,FDC.Model.Ora"> </object> <object id="ToolConfigDao" type="FDC.Model.Ora.DAO.ToolConfigDAO,FDC.Model.Ora"> <constructor-arg name="ISession" ref="Global"/>//此处现在是错的, </object> </objects>
public ToolConfigDAO(ISession session) : base(session) { } public class GlobalSessionFactory { public ISession session;//想取此处值作为ToolConfigDAO的构造方法的参数传入 private ISessionFactory sessionFactory;