You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
675 B
38 lines
675 B
package com.fr.start.module; |
|
|
|
import com.fr.general.ComparatorUtils; |
|
|
|
/** |
|
* Created by juhaoyu on 2018/1/8. |
|
* 封装启动参数 |
|
*/ |
|
public class StartupArgs { |
|
|
|
private final String[] args; |
|
|
|
public StartupArgs(String[] args) { |
|
|
|
this.args = args; |
|
} |
|
|
|
public String[] get() { |
|
|
|
return args; |
|
} |
|
|
|
/** |
|
* 是否是产品演示 |
|
*/ |
|
public boolean isDemo() { |
|
|
|
if (args != null) { |
|
for (String arg : args) { |
|
if (ComparatorUtils.equals(arg, "demo")) { |
|
return true; |
|
} |
|
} |
|
} |
|
return false; |
|
} |
|
} |
|
|
|
|