码迷,mamicode.com
首页 >  
搜索关键字:decorator pattern    ( 8466个结果
Java 正则表达式 向前、向后匹配
//向后匹配String a = "I paid $90 for 10 oranges, 12 pears and 8 apples. I saved $5 on "; Pattern p = Pattern.compile("(?<=\\$)\\d+"); Matcher m = p.ma...
分类:编程语言   时间:2014-07-09 23:18:56    阅读次数:455
设计模式 - 策略模式(Strategy Pattern) 具体解释
策略模式(Strategy Pattern) 具体解释本文地址:http://blog.csdn.net/caroline_wendy/article/details/26577879本文版权全部, 禁止转载, 如有须要, 请站内联系.策略模式: 定义了算法族, 分别封装起来, 让它们之间能够相互替...
分类:其他好文   时间:2014-07-09 23:14:08    阅读次数:227
为什么要提倡“Design Pattern呢
为什么要提倡“Design Pattern呢?根本原因是为了代码复用,增加可维护性。那么怎么才能实现代码复用呢?面向对象有几个原则:开闭原则(Open Closed Principle,OCP)、里氏代换原则(Liskov Substitution Principle,LSP)、依赖倒转原则(Dep...
分类:其他好文   时间:2014-07-09 20:15:39    阅读次数:213
Shell删除特定文件以外的文件
Bash Shell有个extglob选项。开启后Shell可以 另外识别出5个模式匹配操作符,能使文件匹配更加方便 。开启的方法:使用shopt命令:shopt -s extglob关闭的方法: shopt -u extglob开启后,以下5个模式匹配操作符将被识别:?(pattern-lis.....
分类:其他好文   时间:2014-07-08 23:26:36    阅读次数:269
检测乳腺癌细胞中的有丝分裂(3)
今天看的文章题目是《A Gamma-Gaussian Mixture Model for Detection of Mitotic Cells in Breast Cancer Histopathology Images》 原理:先分割出肿瘤区域,然后在肿瘤区域使用Gamma-Gaussian混合模型检测有丝分裂细胞,最后使用svm分类器减少检测错误。 步骤: 1、因为有丝分裂大多是发生在肿...
分类:其他好文   时间:2014-07-08 20:06:36    阅读次数:219
[Ruby]How to create singleton class ?
Singleton is one design pattern in the software engineering. Ruby has its own special feature to declare singleton class...
分类:其他好文   时间:2014-07-08 18:05:25    阅读次数:213
LeetCode——ZigZag Conversion
The string "PAYPALISHIRING" is written in a zigzag pattern on a given number of rows like this: (you may want to display this pattern in a fixed font for better legibility) P A H N A P L S I...
分类:其他好文   时间:2014-07-08 17:42:31    阅读次数:192
检测乳腺癌细胞中的有丝分裂(4)
文章题目是《Learning-based mitotic cell detection in histopathological images》 原理:分为个步骤,第一,分割出候选有丝分裂细胞;第二,利用纹理等特征检测出有丝分裂细胞。 这篇文章读起来挺简单的,都是我们所熟悉的,本文使用了两个开源工具,”ilastik”和”CellCognition” 。 1、分割出候选有丝分裂细胞 一个基...
分类:其他好文   时间:2014-07-08 14:52:28    阅读次数:239
访问者模式(Visitor Pattern)
访问者模式(Visitor Pattern)是GoF提出的23种设计模式中的一种,属于行为模式。 据《大话设计模式》中说算是最复杂也是最难以理解的一种模式了。    定义(源于GoF《Design Pattern》):表示一个作用于某对象结构中的各元素的操作。它使你可以在 不改变各元素类的前提下定义作用于这些元素的新操作。从定义可以看出结构对象是使用访问者模式必备 条件,而且这个结构对象必...
分类:其他好文   时间:2014-07-08 14:01:22    阅读次数:156
Linux中grep、egrep正则表达式的使用
正则表达式的由来正则表达式,英文写法RegularExpression,在编程语言中常被简写为regex、regexp等。它是用来描述、匹配一系列符合某个句法规则字符串的单个字符串。正则表达式通常被用来检索、替换那些符合某个模式(Pattern)的文本。1950年代,UNIX之父KenThompson将正则表..
分类:系统相关   时间:2014-07-08 08:08:21    阅读次数:402
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!