All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.hyf.hotrefresh.adapter.spring.properties.HotRefreshProperties Maven / Gradle / Ivy

There is a newer version: 1.2.5
Show newest version
package com.hyf.hotrefresh.adapter.spring.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;

import java.util.ArrayList;
import java.util.List;

/**
 * @author baB_hyf
 * @date 2022/05/13
 */
@ConfigurationProperties(HotRefreshProperties.PREFIX)
public class HotRefreshProperties {

    public static final String PREFIX = "hyf.hot-refresh";

    /**
     * 是否启用热刷新功能
     */
    private boolean enabled = true;

    /**
     * 针对SpringMVC提供的拦截器的相关配置
     */
    private final InterceptorEscape interceptorEscape = new InterceptorEscape();

    public boolean isEnabled() {
        return enabled;
    }

    public void setEnabled(boolean enabled) {
        this.enabled = enabled;
    }

    public InterceptorEscape getInterceptorEscape() {
        return interceptorEscape;
    }

    public static class InterceptorEscape {

        /**
         * SpringMVC提供的拦截器是否进行跳过-全局配置
         */
        private boolean enabled = true;

        /**
         * 跳过的类
         */
        private List> includeClasses = new ArrayList<>();

        /**
         * 不跳过的类
         */
        private List> excludeClasses = new ArrayList<>();

        public boolean isEnabled() {
            return enabled;
        }

        public void setEnabled(boolean enabled) {
            this.enabled = enabled;
        }

        public List> getIncludeClasses() {
            return includeClasses;
        }

        public void setIncludeClasses(List> includeClasses) {
            this.includeClasses = includeClasses;
        }

        public List> getExcludeClasses() {
            return excludeClasses;
        }

        public void setExcludeClasses(List> excludeClasses) {
            this.excludeClasses = excludeClasses;
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy