-
大小: 93KB文件类型: .rar金币: 1下载: 0 次发布日期: 2021-12-04
- 语言: 其他
- 标签: jsoup SpringBoot mysql
资源简介
基于jsoup解析url地址爬取网页信息整合SpringBoot独立idea项目
代码片段和文件信息
/*
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License Version 2.0 (the
“License“); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing
software distributed under the License is distributed on an
“AS IS“ BASIS WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
*/
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.net.URL;
import java.nio.channels.Channels;
import java.nio.channels.ReadableByteChannel;
import java.util.Properties;
public class MavenWrapperDownloader {
/**
* Default URL to download the maven-wrapper.jar from if no ‘downloadUrl‘ is provided.
*/
private static final String DEFAULT_DOWNLOAD_URL =
“https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.4.2/maven-wrapper-0.4.2.jar“;
/**
* Path to the maven-wrapper.properties file which might contain a downloadUrl property to
* use instead of the default one.
*/
private static final String MAVEN_WRAPPER_PROPERTIES_PATH =
“.mvn/wrapper/maven-wrapper.properties“;
/**
* Path where the maven-wrapper.jar will be saved to.
*/
private static final String MAVEN_WRAPPER_JAR_PATH =
“.mvn/wrapper/maven-wrapper.jar“;
/**
* Name of the property which should be used to override the default download url for the wrapper.
*/
private static final String PROPERTY_NAME_WRAPPER_URL = “wrapperUrl“;
public static void main(String args[]) {
System.out.println(“- Downloader started“);
File baseDirectory = new File(args[0]);
System.out.println(“- Using base directory: “ + baseDirectory.getAbsolutePath());
// If the maven-wrapper.properties exists read it and check if it contains a custom
// wrapperUrl parameter.
File mavenWrapperPropertyFile = new File(baseDirectory MAVEN_WRAPPER_PROPERTIES_PATH);
String url = DEFAULT_DOWNLOAD_URL;
if (mavenWrapperPropertyFile.exists()) {
FileInputStream mavenWrapperPropertyFileInputStream = null;
try {
mavenWrapperPropertyFileInputStream = new FileInputStream(mavenWrapperPropertyFile);
Properties mavenWrapperProperties = new Properties();
mavenWrapperProperties.load(mavenWrapperPropertyFileInputStream);
url = mavenWrapperProperties.getProperty(PROPERTY_NAME_WRAPPER_URL url);
} catch (IOException e) {
Syste
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 3595 2019-02-18 11:46 pom.xm
文件 23 2019-02-13 09:11 .idea\.name
文件 6365 2019-02-18 09:54 .idea\artifacts\2014_sifa_iportal_jsoup_jar.xm
文件 860 2019-02-13 09:12 .idea\compiler.xm
文件 209 2019-02-13 09:12 .idea\encodings.xm
文件 592 2019-02-13 09:12 .idea\libraries\Maven__ch_qos_logback_logback_classic_1_2_3.xm
文件 571 2019-02-13 09:12 .idea\libraries\Maven__ch_qos_logback_logback_core_1_2_3.xm
文件 510 2019-02-13 09:16 .idea\libraries\Maven__com_alibaba_druid_1_1_9.xm
文件 650 2019-02-13 09:16 .idea\libraries\Maven__com_alibaba_druid_spring_boot_starter_1_1_9.xm
文件 546 2019-02-13 09:12 .idea\libraries\Maven__com_fasterxm
文件 668 2019-02-13 09:12 .idea\libraries\Maven__com_fasterxm
文件 619 2019-02-13 09:12 .idea\libraries\Maven__com_fasterxm
文件 647 2019-02-13 09:12 .idea\libraries\Maven__com_fasterxm
文件 698 2019-02-13 09:12 .idea\libraries\Maven__com_fasterxm
文件 698 2019-02-13 09:16 .idea\libraries\Maven__com_fasterxm
文件 712 2019-02-13 09:12 .idea\libraries\Maven__com_fasterxm
文件 753 2019-02-13 09:12 .idea\libraries\Maven__com_fasterxm
文件 571 2019-02-13 09:16 .idea\libraries\Maven__com_github_jsqlparser_jsqlparser_1_0.xm
文件 585 2019-02-13 09:16 .idea\libraries\Maven__com_github_pagehelper_pagehelper_5_1_4.xm
文件 767 2019-02-13 09:16 .idea\libraries\Maven__com_github_pagehelper_pagehelper_spring_boot_autoconfigure_1_2_5.xm
文件 725 2019-02-13 09:16 .idea\libraries\Maven__com_github_pagehelper_pagehelper_spring_boot_starter_1_2_5.xm
文件 570 2019-02-13 09:12 .idea\libraries\Maven__com_jayway_jsonpath_json_path_2_4_0.xm
文件 724 2019-02-13 09:12 .idea\libraries\Maven__com_vaadin_external_google_android_json_0_0_20131108_vaadin1.xm
文件 527 2019-02-13 09:12 .idea\libraries\Maven__com_zaxxer_HikariCP_3_2_0.xm
文件 635 2019-02-13 09:12 .idea\libraries\Maven__javax_annotation_javax_annotation_api_1_3_2.xm
文件 635 2019-02-13 09:12 .idea\libraries\Maven__javax_validation_validation_api_2_0_1_Final.xm
文件 537 2019-02-13 09:16 .idea\libraries\Maven__joda_time_joda_time_2_10_1.xm
文件 479 2019-02-13 09:12 .idea\libraries\Maven__junit_junit_4_12.xm
文件 598 2019-02-13 09:12 .idea\libraries\Maven__mysql_mysql_connector_java_8_0_13.xm
文件 553 2019-02-13 09:12 .idea\libraries\Maven__net_bytebuddy_byte_buddy_1_9_7.xm
............此处省略103个文件信息
- 上一篇:多屏幕多任务栏工具栏
- 下一篇:实验3.1高斯消去法的数值稳定性实验
相关资源
- springboot 深度整合mina开箱即用
- 基于Swing框架的KTV点歌系统
- delphi实现裁剪图片并上传至服务器
- SpringBoot实战与原理分析视频课程(
- springboot-tio-activemq.rar整合SpringBoot实现
- 销售信息系统,数据库课程设计 ,
- 汽车租赁系统.zip
- drools集成springboot demo
- 前端页面实现对数据库的操作
-
sm整合phoenix和连接池(xm
l和注解两 - springboot文件上传路径保存数据库并且
- 创建springboot + mybatis项目,实现登录、
- springboot整合oss实现文件的上传查看删
- SpringBoot框架,前后端分离写的新闻管
- Maven+SpringBoot+JPA单表增删改查
- 超市订单管理系统基于springbootmybati
- Mybatis案例一所用建表语句
- springboot-AOP实现多数据源动态切换Dr
- springboot简单分页
- 完整版 最新全国高校数据库信息包含
- Springboot和bootstrap实现shiro权限控制配
- 基于MVC实现的简单注册登录小Demo
- springboot-mybatis-dubbo-zookeeper项目框架
- SSM框架实现注册登录功能
- SpringBoot+Atomikos分布式事务及多数据源
- SpringBoot之整合Spring Security代码
- springboot支付宝网页支付
- springboot+webuploader 实现大文件切片上传
- SpringBoot使用JMS的小ActiveMQ实现
- Navicat Premium 15.0.4可用汉化语言包269
评论
共有 条评论