提交 4b95a829 编写于 作者: A ascrutae

CenterType添加String转Type的方法

上级 25dbe41a
......@@ -16,4 +16,12 @@ public enum CenterType {
public String getType() {
return type;
}
public static CenterType convert(String type) {
if (zookeeper.type.equals(type)) {
return zookeeper;
}
throw new IllegalArgumentException("Failed to find center type[" + type + "]");
}
}
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册