You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
udi-wms-java/src/main/java/com/glxp/api/entity/auth/MetaEntity.java

61 lines
1.3 KiB
Java

3 years ago
package com.glxp.api.entity.auth;
import cn.hutool.core.util.StrUtil;
import cn.hutool.http.HttpUtil;
import lombok.Data;
/**
*
*/
@Data
public class MetaEntity {
/**
*
*/
private String title;
/**
* src/assets/icons/svg
*/
private String icon;
/**
* true <keep-alive>
*/
private boolean noCache;
/**
* http(s)://开头)
*/
private String link;
public MetaEntity(String title, String icon) {
this.title = title;
this.icon = icon;
}
public MetaEntity(String title, String icon, boolean noCache) {
this.title = title;
this.icon = icon;
this.noCache = noCache;
}
public MetaEntity(String title, String icon, String link) {
this.title = title;
this.icon = icon;
this.link = link;
}
public MetaEntity(String title, String icon, boolean noCache, String link) {
this.title = title;
this.icon = icon;
this.noCache = noCache;
if (StrUtil.isNotEmpty(link) && HttpUtil.isHttp(link)) {
this.link = link;
}
}
}