自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(37)
  • 资源 (4)
  • 收藏
  • 关注

原创 Mongodb副本集配置-手把手教导简易教程

1.Linux下docker启动mongodb副本集1.1拉取mongodb镜像1.2创建集群成员数据挂载目录/data/mongo /data/mongo2 /data/mongo3 /data/mongo41.3安装容器mongodb的镜像名称为mongo,副本集名称为rs,执行命令:docker run --name mongodb -p 27017:27017 -v /data/mongo/:/data/db/ -d mongo mongod --replSet rs

2020-11-26 10:38:37 303

原创 leetcode刷题记录 Hard 23. Merge k Sorted Lists

英文题目:Mergeksorted linked lists and return it as one sorted list. Analyze and describe its complexity.Example:Input:[ 1->4->5, 1->3->4, 2->6]Output: 1->1->2->...

2019-07-25 16:44:21 127

原创 leetcode刷题记录 Easy 21. Merge Two Sorted Lists

英文题目:Merge two sorted linked lists and return it as a new list. The new list should be made by splicing together the nodes of the first two lists.Example:Input: 1->2->4, 1->3->4...

2019-07-25 16:40:56 147

原创 leetcode刷题记录 Medium 22. Generate Parentheses

英文题目:Givennpairs of parentheses, write a function to generate all combinations of well-formed parentheses.For example, givenn= 3, a solution set is:[ "((()))", "(()())", "(())()", ...

2019-07-25 14:48:26 115

原创 leetcode刷题记录 easy(10) 728. Self Dividing Numbers

英文题目:Aself-dividing numberis a number that is divisible by every digit it contains.For example, 128 is a self-dividing number because128 % 1 == 0,128 % 2 == 0, and128 % 8 == 0.Also, a self...

2019-07-25 11:18:06 107

原创 leetcode刷题记录 easy(9) 657. Robot Return to Origin

英文题目:There is a robot starting at position (0, 0), the origin, on a 2D plane. Given a sequence of its moves, judge if this robotends up at (0, 0)after it completes its moves.The move sequence is...

2019-07-16 15:33:56 89

原创 leetcode刷题记录 easy(8) 977.Squares of a Sorted Array

英文题目:Given an array of integersAsorted in non-decreasing order,return an array of the squares of each number,also in sorted non-decreasing order.Example 1:Input: [-4,-1,0,3,10]Output: [0,1,...

2019-07-05 17:51:38 116

原创 leetcode刷题记录 easy(7) 961.N-Repeated Element in Size 2N Array

英文题目:In a arrayAof size2N, there areN+1unique elements, and exactly one of these elements is repeated N times.Return the element repeatedNtimes.Example 1:Input: [1,2,3,3]Output: 3...

2019-07-05 17:10:03 124

原创 leetcode刷题记录 easy(6) 905.Sort Array By Parity

英文题目:Given an arrayAof non-negative integers, return an array consisting of all the even elements ofA, followed by all the odd elements ofA.You may return any answer array that satisfies this ...

2019-07-05 16:33:47 89

原创 leetcode刷题记录 easy(5) 832.Flipping an Image

英文题目:Given a binary matrixA, we want to flip the image horizontally, then invert it, and return the resulting image.To flip an image horizontally means that each row of the image is reversed. Fo...

2019-07-05 16:11:49 86

原创 leetcode刷题记录 easy(4) 804.Unique Morse Code Words

英文题目:International Morse Code defines a standard encoding where each letter is mapped to a series of dots and dashes, as follows:"a"maps to".-","b"maps to"-...","c"maps to"-.-.", and so on....

2019-07-05 15:27:43 118

原创 leetcode刷题记录 easy(3) 1021.Remove Outermost Parentheses

英文题目:A valid parentheses string is either empty(""),"(" + A + ")", orA + B, whereAandBare valid parentheses strings, and+represents string concatenation. For example,"","()","(())()", a...

2019-07-05 15:20:35 80

原创 leetcode刷题记录 easy(2) 709.To Lower Case

英文题目:Implement function ToLowerCase() that has a string parameter str, and returns the same string in lowercase.Example 1:Input: "Hello"Output: "hello"Example 2:Input: "here"Output: "...

2019-07-05 12:02:57 79

原创 leetcode刷题记录 easy(1) 771.Jewels and Stones

英文题目:You're given stringsJrepresenting the types of stones that are jewels, andSrepresenting the stones you have. Each character inSis a type of stone you have. You want to know how many of ...

2019-07-05 11:54:56 160

原创 Java代码插入的记录时间与保存到MYSQL数据库后的时间不一致,时间相差8小时

1.问题 Java代码插入的记录时间与保存到MYSQL数据库后的时间不一致,时间相差8小时,例如:Java代码里插入的时间为:2019-03-12 14:57:53数据库里面显示的时间为:2019-03-12 06:57:532.原因 JDBC连接时设置了serverTimezone=UTC; UTC代表的是全球标准时间 ,而我们使用的时间是北京时区也就是东八区...

2019-03-14 10:18:01 8234 5

原创 Jquery判断滚动条是否在底部和控制滚动条滑动到底部

界面<div class="msgList"></div>1.判断滚动条是否在底部//判断滚动条是否到底部$(".msgList").scroll(function(){ var scrollTop = $(this).scrollTop(); var scrollHeight = $(this)[0].scrollHeight; ...

2019-03-12 17:42:57 389

原创 Bootstrap 里的 popover 被挡住的解决方案

在Bootstarp中我们可以使用 popover插件做一些悬浮框内容的展示,但是如果父级有overflow:hidden属性,你会发现超出容器的部分会显示不出,被父容器所遮挡。如图所示:解决方案:只需要在绑定悬浮框的组件上添加data-container='body'即可<i class='fa fa-chevron-circle-down fa-2x' data-tog...

2019-03-01 11:12:33 1917

转载 让Bootstrap的popover在鼠标移入弹窗时不消失

转载地址:https://blog.csdn.net/u011125949/article/details/79973801使用bootstrap的popover,trigger设置为hover时,可以实现当鼠标放置到目标元素上时显示popover,可是无法实现当鼠标移动到popover上时不隐藏popover解决方案:以在hide.bs.popover事件中使用event.prevent...

2019-03-01 11:04:24 689

原创 Jackson将对象转换为json字符串时,设置默认的时间格式

Jackson将对象转换为json字符串时,时间默认是转换一串数字,不符合我们日常需求,所以需要设置默认的时间格式。public class JsonUtils { // 定义jackson对象 private static final ObjectMapper MAPPER = new ObjectMapper(); /** * 将对象转换成json...

2019-02-28 16:18:09 1937

转载 ajax动态加载的数据的click事件问题

转载地址:https://blog.csdn.net/DreamFJ/article/details/75365123问:为什么ajax加载出来的html,无法用选择器绑定事件,但可以直接在html上使用onclick等事件?如ajax 加载了<divclass="div">div</div>然后$('.div').click(function(){.....

2019-02-28 16:12:17 1159

原创 Eclipse快速搭建SpringBoot(Maven项目)

环境准备:IDE:EclipseJAVA:JDK1.8一、新建MAVEN项目File→New→Maven Project→New Maven projectGroup Id: com.springbootArtifacrt Id: SpBootDemoPackaging:war右键项目,选择Java EE Tools→Generate Deployment De...

2019-02-14 15:24:04 1476

原创 Eclipse新建Maven项目没有web.xml文件问题解决

使用eclipse新建maven项目时,没有自动创建web.xml文件,出现异常。解决方法:1.手动在webapp目录下创建WEB-INF/web.xml2.右键项目,选择Java EE Tools→Generate Deployment Descriptor Stub,自动创建web.xml...

2019-02-13 11:58:00 1985

原创 手把手教你搭建Maven项目整合SSM框架(spring+springmvc+mybatis)

环境准备:IDE:Eclipse数据库:MYSQL8.0JAVA:JDK1.8一、新建MAVEN项目File→New→Maven Project→NewMaven projectGroup Id: com.ssmArtifacrt Id: SSMdemo二、声明依赖(pom.xml)<project xmlns="http://maven.apach...

2019-01-26 10:30:58 1867 9

原创 The superclass javax.servlet.http.HttpServlet was not found on the Java Build Path

我们在用Eclipse进行Java web开发时,可能会出现这样的错误:The superclass javax.servlet.http.HttpServlet was not found on the Java Build Path。此时右键项目Build Path→Configure Build Path选择Server Library 然后apply即可...

2019-01-23 12:03:44 86

原创 EasyUI使用tree方法生成树形结构url加载两次的问题

html代码中使用class声明了easyui-tree,导致easyUI解析代码的时候先解析class声明的easyui-tree,这样组件就请求了一次url;然后又调用js初始化代码请求一次url。这样就导致了重复加载,解决的方法就是只用一种方法来声明easyUI组件以避免重复的请求数据,解决办法只需要删除html中的class声明(class="easyui-tree");例子如下:...

2018-08-15 10:28:19 1091 1

原创 Android 多图选择Demo, eclipse开发,下载即可运行,方便实用,支持多图选择、拍照、预览图片、删除图片等功能

CSDN下载地址:https://download.csdn.net/download/qq_29518175/10590844Github 地址:https://github.com/molongwoyoupu/PicSelectDemo如果觉得有用请点赞支持,谢谢

2018-08-08 14:40:35 643

原创 java.lang.NoSuchMethodError: android.content.res.Resources.getDrawable

java.lang.NoSuchMethodError: android.content.res.Resources.getDrawable或者 java.lang.NoSuchMethodError:android.content.Context.getDrawable原因:Resources的getDrawable方法和Context类的getDrawable方法都是API21才添加的,低版本...

2018-04-04 11:41:14 444

原创 集成微信分享的应用签名遇到的坑

微信移动应用审核通过,集成微信后调用微信分享功能,出现异常,出现 [pool-13-thread-1(2966): null:-1] - Server response error code:404, error:{"ret":-1, "msg":"invalid appkey"}。输出type:2 errCode:-6。原因是应用签名错误,正确的应该是填入 MD5 fingerprint...

2018-03-15 10:40:34 3808 1

原创 安卓开发 7.0以上 解决 进入拍照闪退的问题

        /** * 拍照 */ private void takePhoto() { //获取系統版本 int currentapiVersion = android.os.Build.VERSION.SDK_INT; // 判断存储卡是否可以用,可用进行存储 if (Environment.getExternalStorageState(...

2018-03-01 18:37:59 1266

原创 记录下来的网址 便于以后查找

Maven中央仓库信息速查http://maven.outofmemory.cn/http://search.maven.orghttp://mvnrepository.com/http://repo1.maven.orghttp://www.zaole.net/

2018-02-01 15:34:09 341

原创 Android沉浸式的状态栏的简单实现

最近实现了沉浸式的状态栏,记录下来自己实现的方法,方便回顾1.先是创建工具类,在这个类中获取到状态栏的高度,设置想要设置的状态栏背景import android.annotation.TargetApi;import android.app.Activity;import android.content.Context;import android.os.Build;import andr...

2018-01-20 11:39:30 214

原创 解决无法使用http访问安装好nginx和ftp的图片服务器的问题

出现该问题的原因是nginx.conf文件中没有修改需要将标红的部分改为访问图片服务器的根目录(/home/ftpuser)user root;#user nobody;worker_processes 1;#error_log logs/error.log;#error_log logs/error.log notice;#error_log logs/erro...

2017-08-19 19:43:35 913

原创 解决向ftp服务器传图片只能传入ftpuser的根目录不能传入下级目录的问题

向ftp服务器上传图片时出现问题:只能将文件上传至服务器的根路径,无法上传至我生成的目录下,甚至我自己手动新建的文件夹也不行。出现该问题的原因是访问FTP服务器时用了ftp用户名和密码,获取的是该ftp用户的权限,而服务器根目录下的文件夹权限是属于root的,所以没有获得权限解决方法:进入/homt/ftpuser目录执行#ls -l查询该目录下文件夹的权限执行#chown...

2017-08-19 19:40:56 1533

原创 http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException异常解决方法

最近编写程序遇到了下面的异常,所以记录了下来。 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-clean-plugin:2.5:clean (default-clean) on project taotao-rest: Failed to clean project: Failed to delete C:\Us...

2017-08-14 22:44:33 29603 2

转载 如何重置CentOS 7的Root密码?设置CentOS 7的Root密码的方法与步骤

重置Centos 7 Root密码的方式和Centos 6完全不同。让我来展示一下到底如何操作。1 、在启动grub菜单,选择编辑选项启动2 、按键盘e键,来进入编辑界面3 、找到Linux 16的那一行,将ro改为rw init=/sysroot/bin/sh4 、现在按下 Control+x ,使用单用户模式启动5 、现在,可以使用下面的命令访问系统

2017-08-02 22:13:49 271 2

原创 org.apache.ibatis.binding.BindingException: Invalid bound statement (not found):

org.apache.ibatis.binding.BindingException: Invalid bound statement (not found): 典型的找不到mapper映射文件的异常  解决方法:修改pom文件在pom文件中添加如下内容:<!-- 如果不添加此节点mybatis的mapper.xml文件都会被漏掉。 --><b...

2017-07-28 13:31:31 237

原创 No compiler is provided in this environment. Perhaps you are running on a JRE rather than a JDK?

出现异常:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.2:compile (default-compile) on project taotao-manager-pojo: Compilation failureNo compiler is provided in this environm...

2017-07-28 12:29:15 313

Spring-SpringMVC-Mybatis-Maven-Bootstrap3

Eclipse搭建Maven项目整合SSM框架(maven+spring+springmvc+mybatis); CSDN博客地址:https://blog.csdn.net/qq_29518175/article/details/86607735

2019-01-26

android 图片选择Demo

Android 多图选择Demo, eclipse开发,下载即可运行,方便实用,实现了多图选择、拍照、预览图片、删除图片等功能

2018-08-08

Android开发图片验证码的实现

Android开发图片验证码的实现,非常简单好用,轻松引入项目

2018-01-20

Android开发二维码的生成和扫一扫功能的实现

通过开源框架zxing实现安卓项目中二维码扫描识别及生成二维码图片功能。

2018-01-20

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除