摘要: 1.依赖注入方法 手动装配和自动装配 2.手动装配 2.1 基于xml装配 2.1.1 构造方法 2.1.2 setter方法 2.1.3 p命名空间 对setter方法注入进行简化,替换<property>为: 但是需要加入schame命名空间 2.1.4 spEL 对<property>进行了统 阅读全文
posted @ 2018-03-03 19:16 fight139 阅读(458) 评论(0) 推荐(0)
摘要: 1.Javaweb项目结构 1.1修改生成.class文件的位置为WEB-INF下的classes: 生成的.class文件位置: 1.2 设置第三方jar包添加位置: 阅读全文
posted @ 2018-03-03 17:19 fight139 阅读(164) 评论(0) 推荐(0)
摘要: 一、bean的实例化方式 1.默认构造 <bean id="" class=""></bean> 必须提供默认构造方法 2.静态工厂 用于生产实例对象,所有的方法必须都是静态的 常用于spring整合其他框架(工具) <bean id="" class="工厂实现类" factory-method= 阅读全文
posted @ 2018-02-28 21:40 fight139 阅读(131) 评论(0) 推荐(0)
摘要: 一、IOC 1.目标类 提供UserService接口和实现类 获得UserService实现类的实例 之前开发中,直接new一个对象即可,使用spring之后,将由spring创建 --》IoC控制反转 以后需要实例对象时,从spring工厂(容器)获得,需要将实现类的全限定名称配置到xml中 2 阅读全文
posted @ 2018-02-28 20:26 fight139 阅读(196) 评论(0) 推荐(0)
摘要: 1.基本jar包 4+1:4个核心(beans+core+context+expression)+一个依赖(commons-logging...) 阅读全文
posted @ 2018-02-28 18:16 fight139 阅读(216) 评论(0) 推荐(0)
摘要: 1.到jar包 2.编写web.xml、springmvc-config.xml文件 web.xml springmvc-config.xml 3.编写controller控制器(注解) 阅读全文
posted @ 2018-02-25 18:46 fight139 阅读(123) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2018-02-25 13:27 fight139 阅读(117) 评论(0) 推荐(0)
摘要: 常量名 常量值 说明 struts.i18n.encoding UTF-8 应用中使用的编码 struts.objectFactory.spring.autoWire name 和spring框架整合有关 struts.multipart.parser jakarta 指定文件上传用的组件 stru 阅读全文
posted @ 2018-02-25 13:26 fight139 阅读(107) 评论(0) 推荐(0)
摘要: 1.基本jar包 阅读全文
posted @ 2018-02-24 20:16 fight139 阅读(113) 评论(0) 推荐(0)
摘要: 1.导出多个函数 fn.js module.exports = { fun1:function(){}, fun2:function(){} } 2.调用函数 var fun = require('./fn') fun.fun1() 或 fun['fun1']() fun.fun2() 阅读全文
posted @ 2018-01-07 22:48 fight139 阅读(141) 评论(0) 推荐(0)
摘要: 1.node.js的优点 性能高 开发效率高 应用范围广 2.安装 下载地址:http://nodejs.cn 下载git 3.框架选择 express(成熟),koa,Hapi 阅读全文
posted @ 2018-01-07 19:43 fight139 阅读(156) 评论(0) 推荐(0)
摘要: 1.前端 (1)依赖文件: (2)HTML (3)js <script type="text/javascript"> //文件名不能相同 $(function () { $("#uploader").plupload({ // General settings runtimes: 'gears,f 阅读全文
posted @ 2018-01-03 09:03 fight139 阅读(375) 评论(0) 推荐(0)
摘要: 就是通过建立类型为List<Lodging>的Lodging属性与炻Destination建立了联系。 public class Destination { public int DestinationId { get; set; } public string Name { get; set; } 阅读全文
posted @ 2017-12-21 16:34 fight139 阅读(217) 评论(0) 推荐(0)
摘要: 1.在Code First中使用属性 Length字长 字长用于描述数组的长度。包括对字符串和byte数组。 Code First的默认规则string 或者byte数组的长度应为最大。根据不同的数据库类型确定在数据库最终的类型。对SQL Server而言,string 会生成nvarchar(ma 阅读全文
posted @ 2017-12-21 15:09 fight139 阅读(317) 评论(0) 推荐(0)
摘要: 注意:Annotation特性标记可组合使用,也就是在一个类或属性上可以附加多个annotations特性 一、常用注解和对应的Fluent API 1.[Required] -->not null Property(t=>t.Name).IsRequired(); //Fluent API 2.[ 阅读全文
posted @ 2017-12-21 10:58 fight139 阅读(810) 评论(0) 推荐(0)