【调整】json、xml、lua、yaml等数据源支持int类型的enum数据
parent
480b839d31
commit
e977a363ef
|
|
@ -67,7 +67,7 @@ namespace Luban.Job.Cfg.DataCreators
|
||||||
|
|
||||||
public DType Accept(TEnum type, JsonElement x, DefAssembly ass)
|
public DType Accept(TEnum type, JsonElement x, DefAssembly ass)
|
||||||
{
|
{
|
||||||
return new DEnum(type, x.GetString());
|
return new DEnum(type, x.ToString());
|
||||||
}
|
}
|
||||||
|
|
||||||
public DType Accept(TString type, JsonElement x, DefAssembly ass)
|
public DType Accept(TString type, JsonElement x, DefAssembly ass)
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ namespace Luban.Job.Cfg.DataCreators
|
||||||
|
|
||||||
private static string GetTextValue(YamlNode node)
|
private static string GetTextValue(YamlNode node)
|
||||||
{
|
{
|
||||||
return ((string)node);
|
return node.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public DType Accept(TBool type, YamlNode x, DefAssembly y)
|
public DType Accept(TBool type, YamlNode x, DefAssembly y)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue