上一页 1 2 3 4 5 6 ··· 17 下一页
摘要: 依赖引入 三个配置文件 测试 阅读全文
posted @ 2018-01-29 21:17 Decouple 阅读(1400) 评论(0) 推荐(0) 编辑
摘要: 依赖引入 启用Spring Security 首先创建一个继承 的类。这个操作会导致一个名为 的`Filter SpringSecurityFilterChain`的bean 再创建一个配置类 至此Spring Security就被启用了, 目前所有的请求都会被拦截 。 配置 中有三个名为 的方法提 阅读全文
posted @ 2018-01-22 23:59 Decouple 阅读(4058) 评论(0) 推荐(0) 编辑
摘要: 对DispatcherServlet进行配置 Spring MVC的配置实际上就是对DispatcherServlet的配置 WebConfig的实现 阅读全文
posted @ 2017-12-10 16:27 Decouple 阅读(1823) 评论(0) 推荐(0) 编辑
摘要: Spring容器负责创建应用程序中的bean并通过依赖注入来协调这些对象之间的关系。但是,作为开发人员,要告诉Spring需要创建哪些bean并且如何将其装配在一起。当描述bean如何装配时,Spring提供了两种主要的配置方式。 基于Java的配置 隐式配置 Spring通过组件扫描来实现隐式配置 阅读全文
posted @ 2017-11-09 14:13 Decouple 阅读(1512) 评论(0) 推荐(0) 编辑
摘要: 类型擦除 Java在语法中虽然存在泛型的概念,但是在虚拟机中却没有泛型的概念,虚拟机中所有的类型都是普通类。无论何时定义一个泛型类型,编译后类型会被都被自动转换成一个相应的原始类型。 比如这个类 在编译后就变成了 对类型变量进行替换的规则有两条: 若为无限定的类型,如 Object` 若为限定类型, 阅读全文
posted @ 2017-10-10 11:47 Decouple 阅读(3350) 评论(0) 推荐(9) 编辑
摘要: 题意 Implement pow(x, n). 求X的N次方。 解法 用正常的办法来做是会超时的,因为可能有21亿次方的情况,所以需要优化一下。这里用到了 算法,简单来说就是将指数分解成二进制的形式,比如X的7次方,就可以表示成 ,这里将7分解成了 的形式,这样做之后,乘法就只需要进行三次,所以要做 阅读全文
posted @ 2016-10-09 18:12 Decouple 阅读(535) 评论(0) 推荐(0) 编辑
摘要: 题意 Given a collection of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T. Each 阅读全文
posted @ 2016-09-21 13:56 Decouple 阅读(200) 评论(0) 推荐(0) 编辑
摘要: 题意 Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T. The same rep 阅读全文
posted @ 2016-09-21 13:31 Decouple 阅读(181) 评论(0) 推荐(0) 编辑
摘要: 题意 The count and say sequence is the sequence of integers beginning as follows: 1, 11, 21, 1211, 111221, ... 1 is read off as "one 1" or 11. 11 is rea 阅读全文
posted @ 2016-09-20 20:28 Decouple 阅读(190) 评论(0) 推荐(0) 编辑
摘要: 题意 Given a sorted array and a target value, return the index if the target is found. If not, return the index where it would be if it were inserted in 阅读全文
posted @ 2016-09-20 18:30 Decouple 阅读(239) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 17 下一页