| | |
| | | |
| | | namespace HDL_ON.Entity |
| | | { |
| | | public class Fan : Function |
| | | public class Fan |
| | | { |
| | | public Fan() |
| | | { |
| | | } |
| | | |
| | | |
| | | [Newtonsoft.Json.JsonIgnore] |
| | | public Trait trait_openLevel; |
| | | /// <summary> |
| | | /// 档位 |
| | | /// </summary> |
| | | [Newtonsoft.Json.JsonIgnore] |
| | | public int openLevel |
| | | { |
| | | get |
| | | { |
| | | try |
| | | { |
| | | if (trait_openLevel == null) |
| | | { |
| | | trait_openLevel = propertList.Find((obj) => obj.attri == "openLevel"); |
| | | if (trait_openLevel == null) |
| | | { |
| | | trait_openLevel = new Trait() |
| | | { |
| | | attri = "openLevel", |
| | | value = new List<string> { "up", "down" }, |
| | | max = 7, |
| | | min = 0, |
| | | }; |
| | | } |
| | | trait_openLevel.curValues = trait_openLevel.min; |
| | | } |
| | | return Convert.ToInt32(trait_openLevel.curValues); |
| | | } |
| | | catch |
| | | { |
| | | MainPage.Log("openLevel 数据获取失败."); |
| | | return 0; |
| | | } |
| | | } |
| | | set |
| | | { |
| | | try |
| | | { |
| | | trait_openLevel.curValues = value; |
| | | } |
| | | catch |
| | | { |
| | | MainPage.Log("openLevel 数据刷新失败."); |
| | | } |
| | | } |
| | | } |
| | | |
| | | } |
| | | } |