zoukankan      html  css  js  c++  java
  • 原创Spring.Context.Support.ContextRegistry”的类型初始值设定项引发异常,以及Spring.net的配置的大体写法

    第一个可能的原因为:没有引用Common.Logging.dll(我的原因就是这个)

    第二个原因为:<object id="服务的名称" type="命名空间,程序集" ></object>里边的type少了一项,也有可能报错,具体大家可以参考这种写法:

    <object id="CaseDispatchVehicle119Dao" type="BJCreation.CallApp.HibernateDAL.Hibernate.CaseDispatchVehicle119DaoHibernate,BJCreation.CallApp.HibernateDAL">
    <property name="HibernateTemplate" ref="HibernateTemplate"/>  ---说明:配置NHibernate的
    </object>

    <object id="CaseListDao" type="BJCreation.CallApp.OracleDAL.CaseListDaoOracle,BJCreation.CallApp.OracleDAL">

    <!--配置构造函数的-->
    <constructor-arg name="dataSource" type="string" value="ConnectionStringCur"/>
    <constructor-arg type="string" name="viewname" value="v_caselist"/>
    <constructor-arg type="string" name="zhqueryviewname" value="v_zhquerycaselist"/>
    <constructor-arg type="string" name="htjkviewname" value="v_caseinfolist"/>
    </object>

    <!--写到类里边的Dictionary-->

    <object id="DictionaryXZQH" type="BJCreation.VoiceFeedbackModify.Common.GlobalService,BJCreation.VoiceFeedbackModify.Common">
    <property name="XZQH">
    <dictionary key-type="string" value-type="string">
    <entry key="001" value="测试"/>
    </dictionary>
    </property>
    </object>

    <!--单独的Diction<string,string>-->
    <object id="FormSize" type="System.Collections.Generic.Dictionary&lt;string,string&gt;">
    <constructor-arg>
    <dictionary key-type="string" value-type="string">
    <entry key="LocationX" value="0" />
    <entry key="LocationY" value="0" />
    </dictionary>
    </constructor-arg>
    </object>

    <!--单独的List<string>-->

    <object id="JJDGF" type="System.Collections.Generic.List&lt;string>">
    <constructor-arg>
    <list element-type="System.String">
    <value>规范</value>
    <value>单位错误</value>
    </list>
    </constructor-arg>
    </object>

  • 相关阅读:
    悲观锁乐观锁实战
    悲观锁
    乐观锁
    mysql数据库怎么设置乐观锁
    猴子吃桃问题
    算法题
    面试总结
    分布式系统理论(二):一致性协议Paxos
    职工工资管理
    79-WordSearch
  • 原文地址:https://www.cnblogs.com/smthts/p/2377881.html
Copyright © 2011-2022 走看看