public static Dictionary <string, object> GetPeakZoneGroupGains(BuildingData BuildingData, TSDZoneArray TSDZoneArray, List <ZoneDataGroup> ZoneDataGroups) { List <string> aValues = new List <string>(); foreach (ZoneDataGroup aZoneDataGroup in ZoneDataGroups) { string aValue = ZoneDataGroup.Name(aZoneDataGroup); foreach (ZoneData aZoneData in ZoneDataGroup.GetZonesData(aZoneDataGroup)) { aValue += ":" + ZoneData.GUID(aZoneData); } aValues.Add(aValue); } object[,] aResults = BuildingData.pBuildingData.GetPeakZoneGroupGains(aValues.ToArray(), new TSDZoneArray[] { TSDZoneArray }) as object[, ]; List <List <object> > aListList = new List <List <object> >(); for (int i = 0; i < aResults.GetLength(0); i++) { List <object> aList = new List <object>(); for (int j = 0; j < aResults.GetLength(1); j++) { aList.Add(aResults[i, j]); } aListList.Add(aList); } return(new Dictionary <string, object> { { "ZoneDataGroupNames", aListList[0] }, { "Gains", aListList[1] }, { "Indexes", aListList[2] } }); }
public static List <ZoneData> GetZonesData(ZoneDataGroup ZoneDataGroup) { List <ZoneData> aZoneDataGroupList = new List <ZoneData>(); int aIndex = 1; TSD.ZoneData aZoneData = ZoneDataGroup.pZoneDataGroup.GetZoneData(aIndex); while (aZoneData != null) { aZoneDataGroupList.Add(new ZoneData(aZoneData)); aIndex++; aZoneData = ZoneDataGroup.pZoneDataGroup.GetZoneData(aIndex); } return(aZoneDataGroupList); }
/// <summary> /// Get Peak Zone Group Gain /// </summary> /// <param name="BuildingData">TSD Building Data</param> /// <param name="TSDZoneArray">TSD Zone Array</param> /// <param name="ZoneDataGroup">TSD Zone Data Group</param> /// <returns name="Values">Values</returns> /// <search> /// TAS, TSDDocument, TSDDocument, BuildingData, tas, tsddocument, tsddocument, GetPeakZoneGroupGain, Get Peak Zone Group Gain /// </search> public static float GetPeakZoneGroupGain(BuildingData BuildingData, TSDZoneArray TSDZoneArray, ZoneDataGroup ZoneDataGroup) { List <ZoneData> aZoneDataList = ZoneDataGroup.GetZonesData(ZoneDataGroup); return(BuildingData.pBuildingData.GetPeakZoneGroupGain(aZoneDataList.ConvertAll(x => ZoneData.GUID(x)).ToArray(), new TSDZoneArray[] { TSDZoneArray })); }
public static ZoneData GetZoneData(ZoneDataGroup ZoneDataGroup, int Index = 1) { return(new ZoneData(ZoneDataGroup.pZoneDataGroup.GetZoneData(Index))); }
public static string Description(ZoneDataGroup ZoneDataGroup) { return(ZoneDataGroup.pZoneDataGroup.description); }
public static string Name(ZoneDataGroup ZoneDataGroup) { return(ZoneDataGroup.pZoneDataGroup.name); }
public static int ZoneCount(ZoneDataGroup ZoneDataGroup) { return(ZoneDataGroup.pZoneDataGroup.zoneCount); }