上一页 1 ··· 3 4 5 6 7 8 9 10 11 下一页
摘要: int s = 3 ; System.out.println(s ==0 ? "一般" : s ==1 ? "不满意" : s == 2 ? "满意" : s ==3 ? "超棒!" : "未知"); 输出 "超棒!"; 阅读全文
posted @ 2020-07-14 11:57 ToDarcy 阅读(1028) 评论(0) 推荐(0) 编辑
摘要: # -*- coding:utf8 -*- import requests import lxml.html # 获取html内容中的a链接与内容 chapters_url = "http://www.civil.tsinghua.edu.cn/ce/83.html" html = requests 阅读全文
posted @ 2020-06-23 11:05 ToDarcy 阅读(1429) 评论(0) 推荐(0) 编辑
摘要: docker cp :用于容器与主机之间的数据拷贝。 1、从主机往容器中拷贝 将主机/www/s目录拷贝到容器XXXXX的/www目录下。 docker cp /www/S XXXXX:/www/ 2、将容器中文件拷往主机 将容器XXXXX的/www目录拷贝到主机的/tmp目录中。 docker c 阅读全文
posted @ 2020-06-22 15:23 ToDarcy 阅读(324) 评论(0) 推荐(0) 编辑
摘要: vim 中如何快速注释和取消注释例子: 1、在 10 - 20 行添加 // 注释 :10,20s#^#//#g2、在 10 - 20 行删除 // 注释 :10,20s#^//##g3、在 10 - 20 行添加 # 注释 :10,20s/^/#/g4、在 10 - 20 行删除 # 注释 :10 阅读全文
posted @ 2020-06-15 09:43 ToDarcy 阅读(1430) 评论(0) 推荐(1) 编辑
摘要: // 查找某内容存在次数 public static int searchEleNum(String str,String targetEle) { if( str.indexOf(targetEle) == -1 ) { return 0; }else { return 1 + searchEle 阅读全文
posted @ 2020-04-24 10:29 ToDarcy 阅读(4937) 评论(0) 推荐(0) 编辑
摘要: import time import pymysql from elasticsearch import Elasticsearch from elasticsearch import helpers ES = [ 'http://ip:9200' ] es = Elasticsearch(ES, 阅读全文
posted @ 2020-04-17 16:54 ToDarcy 阅读(1441) 评论(0) 推荐(0) 编辑
摘要: POST /索引/标签/_delete_by_query?pretty { "query" : { "match_all" : {} } } 阅读全文
posted @ 2020-04-16 12:01 ToDarcy 阅读(5547) 评论(0) 推荐(0) 编辑
摘要: 控制器 // 批量插入导出记录 int[] list = StringProcesser.toIntArray(idStr); List<ExportResource> ERLists = new ArrayList<>(); for (int id : list) { ExportResource 阅读全文
posted @ 2020-04-09 15:51 ToDarcy 阅读(1727) 评论(0) 推荐(0) 编辑
摘要: 时间转换为时间戳: /* * 将时间转换为时间戳 */ public static String dateToStamp(String s) throws ParseException{ String res; SimpleDateFormat simpleDateFormat = new Simp 阅读全文
posted @ 2020-04-08 14:38 ToDarcy 阅读(249) 评论(0) 推荐(0) 编辑
摘要: server { listen 80; server_name A.com; location /{ proxy_pass https://B.com/asi/; } location ^~/web/ { proxy_pass https://B.com/web/; } } 阅读全文
posted @ 2020-03-31 10:13 ToDarcy 阅读(883) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 9 10 11 下一页