forked from fanruan/finekit
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.
33 lines
495 B
33 lines
495 B
package com.fanruan.api.env.shell; |
|
|
|
import com.fr.module.Module; |
|
|
|
/** |
|
* 模块封装 |
|
*/ |
|
public class ModuleShell { |
|
private Module module; |
|
|
|
public ModuleShell(Module module) { |
|
this.module = module; |
|
} |
|
|
|
/** |
|
* 启动模块 |
|
*/ |
|
public void start() { |
|
if (module != null) { |
|
module.start(); |
|
} |
|
} |
|
|
|
/** |
|
* 关闭模块 |
|
*/ |
|
public void stop() { |
|
if (module != null) { |
|
module.stop(); |
|
} |
|
} |
|
|
|
} |