Easter79 Easter79
4年前
Vue 骚技巧,策略模式实现动态表单验证
!(https://oscimg.oschina.net/oscnet/5e0568a314054f2d995c1562bda18f70.png)策略模式(StrategyPattern)又称政策模式,其定义一系列的算法,把它们一个个封装起来,并且使它们可以互相替换。封装的策略算法一般是独立的,策略模式根据输入来调整采用哪个算法。
Wesley13 Wesley13
4年前
MongoDB开发系列
本篇文章主要介绍数据集设计中的分桶范式以及使用实例。数据集设计模式,MongoDB在官方文档https://docs.mongodb.com/ecosystem/ 中的usecases部分提供了详细的参考内容。结合文档,本篇说一些比较深入的MongoDB使用分桶模式分桶模式是MongoDB数据集设计的一种范式。分桶buckets
Stella981 Stella981
4年前
Python实现字符串反转
将字符串s‘helloword’反转输出为‘drowolleh’,以下通过多种方法实现1、字符串切片法(常用)s'helloword'rs::1print(r)结果:drowolleh2、使用reducereduce() 函数会对参数序列中元素进行累积
Stella981 Stella981
4年前
RabbitMQ的高可用集群部署
RabbitMQ的高可用集群部署标签(空格分隔):消息队列部署1\.RabbitMQ部署的三种模式1.1单一模式单机情况下不做集群,仅仅运行一个RabbitMQ.dockercompose.yml
Stella981 Stella981
4年前
Javascript中常用的13种设计模式
!(https://uploadimages.jianshu.io/upload_images/24944724cf8d19188586fa06.png?imageMogr2/autoorient/strip%7CimageView2/2/w/1240)介绍常用的Javascript设计模式。常用设计模式分类常用2
Stella981 Stella981
4年前
Python游戏开发——2D小游戏
一、序列应用——猜单词游戏代码:!(https://oscimg.oschina.net/oscnet/up06ce88a4a69332474dd81698407c39e716e.png)运行结果:!(https://oscimg.oschina.net/oscnet/upe946d71b5ee8018
Stella981 Stella981
4年前
Android 蓝牙启动流程(以及设置蓝牙为作为sink模式 & 接收端模式)
本文以Android7.1为基础(https://www.oschina.net/action/GoToLink?urlhttp%3A%2F%2Fandroidxref.com%2F7.1.1_r6%2F)最近在做蓝牙开发,研究了一下蓝牙的启动流程,总结一下Google在Android源码中推出了它和博通公司一起开发的Bl