上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 18 下一页
摘要: Description:Given an arraynums, write a function to move all0's to the end of it while maintaining the relative order of the non-zero elements.For exa... 阅读全文
posted @ 2015-09-26 21:37 Pickle 阅读(150) 评论(0) 推荐(0) 编辑
摘要: Description:Write a program to check whether a given number is an ugly number.Ugly numbers are positive numbers whose prime factors only include2, 3, ... 阅读全文
posted @ 2015-09-26 21:05 Pickle 阅读(157) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2015-09-03 10:21 Pickle 阅读(466) 评论(0) 推荐(0) 编辑
摘要: JUnit单元测试解析 1.首先看看什么是JUnit: JUnit官网对JUnit的简单解释: JUnit is a simple framework to write repeatable tests. It is an instance of the xUnit architecture for 阅读全文
posted @ 2015-09-02 20:56 Pickle 阅读(4380) 评论(1) 推荐(10) 编辑
摘要: Logging Mybatis内置的日志工厂提供日志功能,具体的日志实现有以下几种工具: SLF4J Apache Commons Logging Log4j 2 Log4j JDK logging 具体选择哪个日志实现工具由MyBatis的内置日志工厂确定。它会使用最先找到的(按上文列举的顺序查找 阅读全文
posted @ 2015-09-01 20:12 Pickle 阅读(413) 评论(0) 推荐(0) 编辑
摘要: SQL语句构建器类问题Java程序员面对的最痛苦的事情之一就是在Java代码中嵌入SQL语句。这么来做通常是由于SQL语句需要动态来生成-否则可以将它们放到外部文件或者存储过程中。正如你已经看到的那样,MyBatis在它的XML映射特性中有一个强大的动态SQL生成方案。但有时在Java代码内部创建S... 阅读全文
posted @ 2015-09-01 20:07 Pickle 阅读(3008) 评论(0) 推荐(1) 编辑
摘要: Java API 既然你已经知道如何配置 MyBatis 和创建映射文件,你就已经准备好来提升技能了。 MyBatis 的 Java API 就是你收获你所做的努力的地方。正如你即将看到的,和 JDBC 相比, MyBatis 很大程度简化了你的代码而且保持简洁,很容易理解和维护。MyBatis 3 阅读全文
posted @ 2015-09-01 19:52 Pickle 阅读(390) 评论(0) 推荐(0) 编辑
摘要: 动态 SQL MyBatis 的强大特性之一便是它的动态 SQL。如果你有使用 JDBC 或其他类似框架的经验,你就能体会到根据不同条件拼接 SQL 语句有多么痛苦。拼接的时候要确保不能忘了必要的空格,还要注意省掉列名列表最后的逗号。利用动态 SQL 这一特性可以彻底摆脱这种痛苦。 通常使用动态 S 阅读全文
posted @ 2015-09-01 17:26 Pickle 阅读(324) 评论(0) 推荐(1) 编辑
摘要: Mapper XML 文件 MyBatis 的真正强大在于它的映射语句,也是它的魔力所在。由于它的异常强大,映射器的 XML 文件就显得相对简单。如果拿它跟具有相同功能的 JDBC 代码进行对比,你会立即发现省掉了将近 95% 的代码。MyBatis 就是针对 SQL 构建的,并且比普通的方法做的更 阅读全文
posted @ 2015-09-01 16:54 Pickle 阅读(4616) 评论(0) 推荐(3) 编辑
摘要: XML 映射配置文件 MyBatis 的配置文件包含了影响 MyBatis 行为甚深的设置(settings)和属性(properties)信息。文档的顶层结构如下: configuration 配置 properties 属性 settings 设置 typeAliases 类型命名 typeHa 阅读全文
posted @ 2015-09-01 15:28 Pickle 阅读(4690) 评论(2) 推荐(1) 编辑
摘要: 入门 安装 要使用 MyBatis, 只需将 mybatis-x.x.x.jar 文件置于 classpath 中即可。 如果使用 Maven 来构建项目,则需将下面的 dependency 代码置于 pom.xml 文件中: <dependency> <groupId>org.mybatis</g 阅读全文
posted @ 2015-09-01 14:16 Pickle 阅读(7428) 评论(2) 推荐(2) 编辑
摘要: 原文链接:http://www.iteye.com/topic/1123293Spring AOP使用动态代理技术在运行期织入增强的代码,为了揭示Spring AOP底层的工作机理,有必要对涉及到的Java知识进行学习。Spring AOP使用了两种代理机制:一种是基于JDK的动态代理;另一种是基于... 阅读全文
posted @ 2015-08-23 15:29 Pickle 阅读(364) 评论(0) 推荐(0) 编辑
摘要: 原文链接:http://www.iteye.com/topic/1123081 通俗易懂。 Java语言允许通过程序化的方式间接对Class进行操作,Class文件由类装载器装载后,在JVM中将形成一份描述Class结构的元信息对象,通过该元信息对象可以获知Class的结构信息:如构造函数、属... 阅读全文
posted @ 2015-08-23 10:28 Pickle 阅读(521) 评论(0) 推荐(0) 编辑
摘要: 原文:https://www.shiyanlou.com/courses/document/212 Spring 概述 1. Spring 是什么 Spring是一个开源的轻量级Java SE(Java 标准版本)/Java EE(Java 企业版本)开发应用框架,其目的是用于简化企业级应用程序开发 阅读全文
posted @ 2015-08-22 23:51 Pickle 阅读(7962) 评论(0) 推荐(1) 编辑
摘要: 最近学习Spring会配置许多XML文件,没有系统学习过XML遇到了许多问题,系统的看了一下有些拨云见日的感觉。 推荐学习:http://www.w3school.com.cn/xml/xml_intro.asp 下面的原文链接(Spring先行基础) XML的特殊字符 XML中共有5个特殊的字符, 阅读全文
posted @ 2015-08-22 23:02 Pickle 阅读(259) 评论(0) 推荐(0) 编辑
摘要: 官方文档:http://git-scm.com/doc 1.1 起步 - 关于版本控制 本章关于开始学习 Git。 我们从介绍有关版本控制工具的一些背景知识开始,然后讲解如何在你的系统运行 Git,最后是关于如何设置 Git 开始你的工作。 通过本章的学习,你应该了解为什么 Git 这么流行,为什么 阅读全文
posted @ 2015-08-21 22:49 Pickle 阅读(637) 评论(0) 推荐(0) 编辑
摘要: Description:Given a non-negative integernum, repeatedly add all its digits until the result has only one digit.For example:Givennum = 38, the process ... 阅读全文
posted @ 2015-08-20 21:49 Pickle 阅读(921) 评论(0) 推荐(1) 编辑
摘要: 二叉排序树(Binary Sort Tree)又称二叉查找树(Binary Search Tree),亦称二叉搜索树. 二叉排序树或者是一棵空树,或者是具有下列性质的二叉树: (1)若左子树不空,则左子树上所有结点的值均小于它的根结点的值; (2)若右子树不空,则右子树上所有结点的值均大于或等于它的 阅读全文
posted @ 2015-08-16 12:20 Pickle 阅读(1288) 评论(1) 推荐(0) 编辑
摘要: 队列是一种特殊的线性表,特殊之处在于它只允许在表的前端(front)进行删除操作,而在表的后端(rear)进行插入操作,和栈一样,队列是一种操作受限制的线性表。进行插入操作的端称为队尾,进行删除操作的端称为队头。队列中没有元素时,称为空队列。 队列的数据元素又称为队列元素。在队列中插入一个... 阅读全文
posted @ 2015-08-16 00:26 Pickle 阅读(7760) 评论(1) 推荐(0) 编辑
摘要: Description:Given acompletebinary tree, count the number of nodes.In a complete binary tree every level, except possibly the last, is completely fille... 阅读全文
posted @ 2015-08-13 23:29 Pickle 阅读(214) 评论(0) 推荐(0) 编辑
摘要: Description:Given a binary search tree (BST), find the lowest common ancestor (LCA) of two given nodes in the BST.According to thedefinition of LCA on... 阅读全文
posted @ 2015-08-13 00:50 Pickle 阅读(185) 评论(0) 推荐(0) 编辑
摘要: Description:Given a singly linked list, determine if it is a palindrome.Follow up:Could you do it in O(n) time and O(1) space?判断一个单向链表是不是回文。思路:最简单的思路就... 阅读全文
posted @ 2015-08-13 00:29 Pickle 阅读(179) 评论(0) 推荐(0) 编辑
摘要: 1.解决HTML页面中的中文问题: 为了使HTML页面很好地支持中文,就必须在每个HTML页面的头部增加如下代码: <HEAD> ... <META http-equiv=Content-Type content="text/html;charset=gb2312"> ... <HEAD> 2.解决 阅读全文
posted @ 2015-08-11 23:50 Pickle 阅读(2271) 评论(0) 推荐(0) 编辑
摘要: Description:Given two strings s and t, write a function to determine if t is an anagram of s.For example, s = "anagram", t = "nagaram", return true. s... 阅读全文
posted @ 2015-08-04 00:09 Pickle 阅读(334) 评论(0) 推荐(0) 编辑
摘要: 学完了计算机网络是时候整理一篇总结了,温故知新。注意:这篇博客很长长长(2.5万字+50图)。 TCP/IP网络知识点总结 一.总述 1.定义:计算机网络是一些互相连接的、自治的计算机的集合。因特网是网络的网络。 2.分类: 根据作用范围分类: 广域网 WAN (Wide Area Network) 阅读全文
posted @ 2015-08-03 14:56 Pickle 阅读(15594) 评论(7) 推荐(43) 编辑
上一页 1 ··· 7 8 9 10 11 12 13 14 15 ··· 18 下一页