docs: 各个类的文档注释调整, 更新作者信息.
This commit is contained in:
@@ -7,8 +7,9 @@ import com.serliunx.ddns.support.SystemInitializer;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 启动类
|
* 启动类
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class ManagerLite {
|
public final class ManagerLite {
|
||||||
|
|
||||||
|
|||||||
@@ -11,8 +11,9 @@ import java.util.concurrent.locks.ReentrantLock;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 配置信息的抽象实现, 定义公共逻辑
|
* 配置信息的抽象实现, 定义公共逻辑
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public abstract class AbstractConfiguration implements Configuration {
|
public abstract class AbstractConfiguration implements Configuration {
|
||||||
|
|
||||||
|
|||||||
@@ -5,8 +5,9 @@ import com.serliunx.ddns.core.Refreshable;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 配置信息逻辑定义
|
* 配置信息逻辑定义
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public interface Configuration extends Refreshable, Priority {
|
public interface Configuration extends Refreshable, Priority {
|
||||||
|
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.config;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 配置文件键常量信息
|
* 配置文件键常量信息
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class ConfigurationKeys {
|
public final class ConfigurationKeys {
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,11 @@
|
|||||||
package com.serliunx.ddns.config;
|
package com.serliunx.ddns.config;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* 文件配置管理
|
||||||
|
* @see PropertiesConfiguration
|
||||||
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public abstract class FileConfiguration extends AbstractConfiguration {
|
public abstract class FileConfiguration extends AbstractConfiguration {
|
||||||
|
|
||||||
|
|||||||
@@ -13,8 +13,9 @@ import java.util.Set;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 使用{@link Properties}实现的简单读取键值对形式的配置信息实现
|
* 使用{@link Properties}实现的简单读取键值对形式的配置信息实现
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class PropertiesConfiguration extends FileConfiguration {
|
public class PropertiesConfiguration extends FileConfiguration {
|
||||||
|
|
||||||
|
|||||||
@@ -9,8 +9,9 @@ import java.util.Map;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 实例类型集合
|
* 实例类型集合
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class InstanceClasses {
|
public final class InstanceClasses {
|
||||||
private InstanceClasses(){throw new UnsupportedOperationException();}
|
private InstanceClasses(){throw new UnsupportedOperationException();}
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.constant;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 保存实例的文件类型: XML、JSON等
|
* 保存实例的文件类型: XML、JSON等
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public enum InstanceFileType {
|
public enum InstanceFileType {
|
||||||
XML(".xml"),
|
XML(".xml"),
|
||||||
|
|||||||
@@ -4,8 +4,9 @@ import static com.serliunx.ddns.constant.SystemConstants.*;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 实例来源
|
* 实例来源
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public enum InstanceSource {
|
public enum InstanceSource {
|
||||||
FILE_JSON(JSON_FILE),
|
FILE_JSON(JSON_FILE),
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.constant;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 实例类型: 阿里云、华为云、腾讯云等
|
* 实例类型: 阿里云、华为云、腾讯云等
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public enum InstanceType {
|
public enum InstanceType {
|
||||||
|
|
||||||
|
|||||||
@@ -4,8 +4,9 @@ import java.io.File;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 系统常量
|
* 系统常量
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class SystemConstants {
|
public final class SystemConstants {
|
||||||
|
|
||||||
|
|||||||
@@ -3,6 +3,9 @@ package com.serliunx.ddns.core;
|
|||||||
/**
|
/**
|
||||||
* 定义一个实体的清理逻辑
|
* 定义一个实体的清理逻辑
|
||||||
* <li> 一般用来清理中间加载过程中所产生的无用对象
|
* <li> 一般用来清理中间加载过程中所产生的无用对象
|
||||||
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
@FunctionalInterface
|
@FunctionalInterface
|
||||||
public interface Clearable {
|
public interface Clearable {
|
||||||
|
|||||||
@@ -5,8 +5,9 @@ import java.io.FileFilter;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 文件过滤器, 用于加载过滤存储在文件中的实例信息时
|
* 文件过滤器, 用于加载过滤存储在文件中的实例信息时
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
* @see com.serliunx.ddns.core.factory.FileInstanceFactory
|
* @see com.serliunx.ddns.core.factory.FileInstanceFactory
|
||||||
*/
|
*/
|
||||||
public final class InstanceFileFilter implements FileFilter {
|
public final class InstanceFileFilter implements FileFilter {
|
||||||
|
|||||||
@@ -3,8 +3,9 @@ package com.serliunx.ddns.core;
|
|||||||
/**
|
/**
|
||||||
* 定义一个对象的优先级
|
* 定义一个对象的优先级
|
||||||
* <li> 数字越大, 优先级越小
|
* <li> 数字越大, 优先级越小
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
@FunctionalInterface
|
@FunctionalInterface
|
||||||
public interface Priority {
|
public interface Priority {
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.core;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 刷新逻辑
|
* 刷新逻辑
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
@FunctionalInterface
|
@FunctionalInterface
|
||||||
public interface Refreshable {
|
public interface Refreshable {
|
||||||
|
|||||||
@@ -19,8 +19,9 @@ import static com.serliunx.ddns.util.InstanceUtils.validateInstance;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 实例容器的抽象实现, 定义大部分公共逻辑
|
* 实例容器的抽象实现, 定义大部分公共逻辑
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public abstract class AbstractInstanceContext implements InstanceContext, MultipleSourceInstanceContext {
|
public abstract class AbstractInstanceContext implements InstanceContext, MultipleSourceInstanceContext {
|
||||||
|
|
||||||
|
|||||||
@@ -7,8 +7,9 @@ import com.serliunx.ddns.core.factory.YamlFileInstanceFactory;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 文件形式的实例容器
|
* 文件形式的实例容器
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class FileInstanceContext extends AbstractInstanceContext {
|
public class FileInstanceContext extends AbstractInstanceContext {
|
||||||
|
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.core.context;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 简易的容器实现, 需要手动进行刷新、添加实例工厂.
|
* 简易的容器实现, 需要手动进行刷新、添加实例工厂.
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/25
|
||||||
*/
|
*/
|
||||||
public class GenericInstanceContext extends AbstractInstanceContext {
|
public class GenericInstanceContext extends AbstractInstanceContext {
|
||||||
|
|
||||||
|
|||||||
@@ -3,8 +3,10 @@ package com.serliunx.ddns.core.context;
|
|||||||
import com.serliunx.ddns.core.factory.InstanceFactory;
|
import com.serliunx.ddns.core.factory.InstanceFactory;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 实例容器接口定义
|
||||||
* @since 1.0
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public interface InstanceContext extends InstanceFactory {
|
public interface InstanceContext extends InstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -9,8 +9,9 @@ import java.util.Set;
|
|||||||
* 多数据源的实例容器, 将多种实例来源汇聚到一起
|
* 多数据源的实例容器, 将多种实例来源汇聚到一起
|
||||||
* @see InstanceFactory
|
* @see InstanceFactory
|
||||||
* @see InstanceContext
|
* @see InstanceContext
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public interface MultipleSourceInstanceContext extends InstanceContext, ListableInstanceFactory {
|
public interface MultipleSourceInstanceContext extends InstanceContext, ListableInstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,12 @@ import java.util.stream.Collectors;
|
|||||||
import static com.serliunx.ddns.util.InstanceUtils.validateInstance;
|
import static com.serliunx.ddns.util.InstanceUtils.validateInstance;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 实例工厂抽象实现, 定义通用逻辑及实例存储.
|
||||||
* @since 1.0
|
* @see FileInstanceFactory
|
||||||
|
* @see DatabaseInstanceFactory
|
||||||
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public abstract class AbstractInstanceFactory implements InstanceFactory, ListableInstanceFactory {
|
public abstract class AbstractInstanceFactory implements InstanceFactory, ListableInstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -7,8 +7,9 @@ import java.util.Set;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 数据库实例工厂
|
* 数据库实例工厂
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public abstract class DatabaseInstanceFactory extends AbstractInstanceFactory {
|
public abstract class DatabaseInstanceFactory extends AbstractInstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -8,8 +8,12 @@ import java.util.*;
|
|||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 文件相关实例工厂, 定义所有来源为文件的实例工厂通用逻辑
|
||||||
* @since 1.0
|
* @see JacksonFileInstanceFactory 使用Jackson序列化、反序列化的实例
|
||||||
|
* @see YamlFileInstanceFactory 使用SankeYaml序列化、反序列化的实例
|
||||||
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public abstract class FileInstanceFactory extends AbstractInstanceFactory {
|
public abstract class FileInstanceFactory extends AbstractInstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -6,8 +6,11 @@ import com.serliunx.ddns.core.Refreshable;
|
|||||||
import com.serliunx.ddns.core.instance.Instance;
|
import com.serliunx.ddns.core.instance.Instance;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 简单的实例工厂逻辑定义, 添加、获取实例.
|
||||||
* @since 1.0
|
* <li> 属于顶层接口, 定义了通用行为: 如刷新和清理逻辑、排序规则等.
|
||||||
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public interface InstanceFactory extends Priority, Comparable<InstanceFactory>, Refreshable, Clearable {
|
public interface InstanceFactory extends Priority, Comparable<InstanceFactory>, Refreshable, Clearable {
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,9 @@ import static com.serliunx.ddns.constant.InstanceClasses.match;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Jackson文件实例工厂, 使用jackson的ObjectMapper来分别处理json和xml
|
* Jackson文件实例工厂, 使用jackson的ObjectMapper来分别处理json和xml
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
* @see ObjectMapper
|
* @see ObjectMapper
|
||||||
* @see com.fasterxml.jackson.dataformat.xml.XmlMapper
|
* @see com.fasterxml.jackson.dataformat.xml.XmlMapper
|
||||||
* @see com.fasterxml.jackson.databind.json.JsonMapper
|
* @see com.fasterxml.jackson.databind.json.JsonMapper
|
||||||
|
|||||||
@@ -6,8 +6,9 @@ import com.serliunx.ddns.core.instance.Instance;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Jackson-Json文件实例工厂
|
* Jackson-Json文件实例工厂
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class JsonFileInstanceFactory extends JacksonFileInstanceFactory {
|
public class JsonFileInstanceFactory extends JacksonFileInstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -7,8 +7,11 @@ import java.util.Map;
|
|||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 扩展型实自工厂接口, 定义了批量获取、筛选实例的方式.
|
||||||
* @since 1.0
|
* @see InstanceFactory
|
||||||
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public interface ListableInstanceFactory extends InstanceFactory {
|
public interface ListableInstanceFactory extends InstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -6,8 +6,9 @@ import com.serliunx.ddns.core.instance.Instance;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Jackson-Xml文件实例工厂
|
* Jackson-Xml文件实例工厂
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class XmlFileInstanceFactory extends JacksonFileInstanceFactory {
|
public class XmlFileInstanceFactory extends JacksonFileInstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -20,8 +20,11 @@ import java.util.Map;
|
|||||||
import static com.serliunx.ddns.constant.SystemConstants.TYPE_FIELD;
|
import static com.serliunx.ddns.constant.SystemConstants.TYPE_FIELD;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* Yaml文件实例工厂, 使用SnakeYaml来反序列化实例. 属于文件型实例工厂.
|
||||||
* @since 1.0
|
* @see FileInstanceFactory
|
||||||
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class YamlFileInstanceFactory extends FileInstanceFactory {
|
public class YamlFileInstanceFactory extends FileInstanceFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -14,8 +14,9 @@ import static com.serliunx.ddns.constant.SystemConstants.XML_ROOT_INSTANCE_NAME;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 实例抽象实现
|
* 实例抽象实现
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
@JsonInclude(JsonInclude.Include.NON_NULL)
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||||
@JsonIgnoreProperties(ignoreUnknown = true)
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
|
|||||||
@@ -21,8 +21,9 @@ import static com.serliunx.ddns.constant.SystemConstants.XML_ROOT_INSTANCE_NAME;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 阿里云实例定义
|
* 阿里云实例定义
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
@SuppressWarnings("all")
|
@SuppressWarnings("all")
|
||||||
@JacksonXmlRootElement(localName = XML_ROOT_INSTANCE_NAME)
|
@JacksonXmlRootElement(localName = XML_ROOT_INSTANCE_NAME)
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.core.instance;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 华为云实例定义
|
* 华为云实例定义
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class HuaweiInstance extends AbstractInstance {
|
public class HuaweiInstance extends AbstractInstance {
|
||||||
|
|
||||||
|
|||||||
@@ -5,8 +5,10 @@ import com.serliunx.ddns.constant.InstanceType;
|
|||||||
import com.serliunx.ddns.core.Refreshable;
|
import com.serliunx.ddns.core.Refreshable;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 实例行为、参数定义接口
|
||||||
* @since 1.0
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public interface Instance extends Runnable, Refreshable {
|
public interface Instance extends Runnable, Refreshable {
|
||||||
|
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.core.instance;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 腾讯云实例定义
|
* 腾讯云实例定义
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class TencentInstance extends AbstractInstance {
|
public class TencentInstance extends AbstractInstance {
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,8 @@ package com.serliunx.ddns.exception;
|
|||||||
/**
|
/**
|
||||||
* 实例相关异常信息
|
* 实例相关异常信息
|
||||||
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public abstract class InstanceException extends RuntimeException {
|
public abstract class InstanceException extends RuntimeException {
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,8 @@ import com.serliunx.ddns.core.instance.Instance;
|
|||||||
/**
|
/**
|
||||||
* 异常信息, 实例已存在
|
* 异常信息, 实例已存在
|
||||||
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class InstanceExistsException extends InstanceException {
|
public class InstanceExistsException extends InstanceException {
|
||||||
|
|
||||||
|
|||||||
@@ -4,8 +4,9 @@ import java.util.Collection;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 断言
|
* 断言
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class Assert {
|
public final class Assert {
|
||||||
|
|
||||||
|
|||||||
@@ -4,8 +4,11 @@ import com.serliunx.ddns.config.Configuration;
|
|||||||
import com.serliunx.ddns.core.context.MultipleSourceInstanceContext;
|
import com.serliunx.ddns.core.context.MultipleSourceInstanceContext;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 系统启动配置器
|
||||||
* @since 1.0
|
* @see SystemInitializer
|
||||||
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class Configurer {
|
public final class Configurer {
|
||||||
|
|
||||||
|
|||||||
@@ -10,8 +10,9 @@ import java.util.concurrent.locks.ReentrantLock;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 网络参数上下文, 目前仅用于存储本机网络IP
|
* 网络参数上下文, 目前仅用于存储本机网络IP
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class NetworkContextHolder {
|
public final class NetworkContextHolder {
|
||||||
|
|
||||||
|
|||||||
@@ -30,8 +30,9 @@ import static com.serliunx.ddns.config.ConfigurationKeys.KEY_THREAD_POOL_CORE_SI
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 系统初始化
|
* 系统初始化
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class SystemInitializer implements Refreshable, Clearable {
|
public final class SystemInitializer implements Refreshable, Clearable {
|
||||||
|
|
||||||
|
|||||||
@@ -14,8 +14,9 @@ import java.util.Collections;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* feign解码器
|
* feign解码器
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class JacksonDecoder implements Decoder {
|
public class JacksonDecoder implements Decoder {
|
||||||
|
|
||||||
|
|||||||
@@ -16,8 +16,9 @@ import java.util.Collections;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Feign兼容Jackson(反序列化返回值)
|
* Feign兼容Jackson(反序列化返回值)
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class JacksonEncoder implements Encoder {
|
public class JacksonEncoder implements Encoder {
|
||||||
|
|
||||||
|
|||||||
@@ -11,8 +11,9 @@ import feign.slf4j.Slf4jLogger;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 本机外网IP地址获取
|
* 本机外网IP地址获取
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
@SuppressWarnings("all")
|
@SuppressWarnings("all")
|
||||||
public interface IPAddressClient {
|
public interface IPAddressClient {
|
||||||
|
|||||||
@@ -2,8 +2,9 @@ package com.serliunx.ddns.support.feign.client.entity;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* IP地址查询响应
|
* IP地址查询响应
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
@SuppressWarnings("all")
|
@SuppressWarnings("all")
|
||||||
public class IPAddressResponse {
|
public class IPAddressResponse {
|
||||||
|
|||||||
@@ -7,8 +7,10 @@ import java.util.concurrent.ThreadFactory;
|
|||||||
import java.util.concurrent.atomic.AtomicInteger;
|
import java.util.concurrent.atomic.AtomicInteger;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 简易的实例活动相关的线程工厂, 仅仅定义了线程的名称规则.
|
||||||
* @since 1.0
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class TaskThreadFactory implements ThreadFactory {
|
public class TaskThreadFactory implements ThreadFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,10 @@
|
|||||||
package com.serliunx.ddns.thread;
|
package com.serliunx.ddns.thread;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author SerLiunx
|
* 同 {@link TaskThreadFactory}, 暂未使用.
|
||||||
* @since 1.0
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public class UtilThreadFactory extends TaskThreadFactory {
|
public class UtilThreadFactory extends TaskThreadFactory {
|
||||||
|
|
||||||
|
|||||||
@@ -5,8 +5,9 @@ import com.serliunx.ddns.support.Assert;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 实例相关工具方法集合
|
* 实例相关工具方法集合
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class InstanceUtils {
|
public final class InstanceUtils {
|
||||||
|
|
||||||
|
|||||||
@@ -6,8 +6,9 @@ import java.util.List;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 反射相关工具类
|
* 反射相关工具类
|
||||||
* @author SerLiunx
|
* @author <a href="mailto:serliunx@yeah.net">SerLiunx</a>
|
||||||
* @since 1.0
|
* @version 1.0.0
|
||||||
|
* @since 2024/5/15
|
||||||
*/
|
*/
|
||||||
public final class ReflectionUtils {
|
public final class ReflectionUtils {
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user