using System; using System.Collections; using System.Collections.Generic; using UnityEngine; [Serializable] public class BengZhanJianKongData { public string name; public float flowValue; public BengZhanState state; public string GetStateStr() { string result = "未知"; switch (state) { case BengZhanState.close: result = "关闭"; break; case BengZhanState.open: result = "开启"; break; case BengZhanState.fix: result = "养护"; break; case BengZhanState.warning: result = "告警"; break; } return result; } } /// /// 0:关闭 1:开启 :2养护 3:告警 /// public enum BengZhanState { close, open, fix, warning }