正则表达式,又称规则表达式。(英语:Regular Expression,在代码中常简写为regex、regexp或RE),计算机科学的一个概念。正则表达式通常被用来检索、替换那些符合某个模式(规则)的文本。 正则表达式的特点是: 1. 灵活性、逻辑性和功能性非 常强; 2. 可以迅速地用极简单的方 ...
分类:
其他好文 时间:
2019-11-02 09:28:52
阅读次数:
79
290. Word Pattern Easy Easy Easy Given a pattern and a string str, find if str follows the same pattern. Here follow means a full match, such that the ...
分类:
其他好文 时间:
2019-11-01 16:03:27
阅读次数:
87
Python中的re模块 pattern=re.complie #打包模式,以下三种均可以使用pattern re.sub#替换 re.findall#查找所有的匹配 re.split#分割 ret=re.search(pattern,str)#从任意位置匹配 ret.group()#对应的匹配值 ...
分类:
编程语言 时间:
2019-11-01 14:37:32
阅读次数:
104
aspectAnnotation的切面信息,加到了AnnotationAwareAspectJAutoProxyCreator的advisorsCache属性里面去了。 解析annotationServiceImpl的时候(此时AspectAnnotation还没有解析),resolveBefore ...
分类:
编程语言 时间:
2019-11-01 14:36:05
阅读次数:
78
import redef build_match_and_apply_functions(pattern, search, replace): def matches_rule(word): return re.search(pattern, word) def apply_rule(word): ...
分类:
编程语言 时间:
2019-11-01 12:37:04
阅读次数:
186
1.工厂模式简介 In class based programming, the factory method pattern is a creational pattern that uses factory methods to deal with the problem of creating ...
分类:
其他好文 时间:
2019-11-01 00:02:24
阅读次数:
111
1.NoReverseMatch at / Reverse for 'about' not found. 'about' is not a valid view function or pattern name. 这是因为自己指定了app_name, 在html界面中同样要指定,即 ...
分类:
其他好文 时间:
2019-10-31 23:48:43
阅读次数:
118
最近线上排查问题时候,发现请求太多导致日志错综复杂,没办法把用户在一次或多次请求的日志关联在一起,所以就利用SpringBoot+Logback手写了一个简单的链路追踪,下面详细介绍下。 [TOC] 一、实现原理 Spring Boot默认使用LogBack日志系统,并且已经引入了相关的jar包,所 ...
分类:
编程语言 时间:
2019-10-31 13:41:12
阅读次数:
114
[TOC] Django choice参数 choice参数 用户性别 用户学历 用户工作状态 客户来源 ... 实例1 实例1 MTV与MVC模型 django号称是MTV框架,其实他还是MVC框架 MTV: M:models ,模型,就是数据模型,负责数据的存取; T: templates ,模 ...
分类:
其他好文 时间:
2019-10-30 18:21:54
阅读次数:
84
1、噪声分类维度 频率、颜色空间、时间相关性 2、噪声类型 2.1 噪声频率 高频——中频——低频: 2.2 色彩空间 luma noise:亮度噪声——chroma noise:颜色噪声 2.3 时间相关性 FPN(fixed pattern noise)——temporal noise 3、Re ...
分类:
其他好文 时间:
2019-10-30 13:46:49
阅读次数:
491