/// <summary> /// Checks to see if the requested node is the target of a "set proration factor gage" (see StateDMI /// SetStreamEstimateCoefficientsPFGage() command). </summary> /// <param name="commonID"> the id of the node to check </param> /// <param name="prfGageData"> list of proration gage data </param> /// <returns> the index of in the PrfGageData that has a node ID that matches the specified commonID, or -1 if /// the node wasn't found. </returns> public static int isSetprfTarget(string commonID, IList <StateMod_PrfGageData> prfGageData) { string routine = "StateMod_NodeNetwork.isSetprfTarget"; int dl = 10; int numPrfGageData = 0; if (prfGageData != null) { numPrfGageData = prfGageData.Count; } if (Message.isDebugOn) { Message.printDebug(dl, routine, "Looking through " + numPrfGageData + " prfGageData's for " + commonID); } StateMod_PrfGageData prfGageData_j = null; for (int j = 0; j < numPrfGageData; j++) { prfGageData_j = prfGageData[j]; if (prfGageData_j.getNodeID().Equals(commonID, StringComparison.OrdinalIgnoreCase)) { if (Message.isDebugOn) { Message.printDebug(dl, routine, "Found a prfGageData target structure \"" + commonID + "\"."); } return(j); } } return(-1); }
/// <summary> /// Checks to see if the node is one where a "neighboring gage" is to be used for the upstream /// flow node. See the StateDMI SetStreamEstimateCoefficientsPFGage() command. </summary> /// <param name="commonID"> the id of the node to check </param> /// <returns> the number of the node if it is to receive information, or -1 if /// the node wasn't found or is not to receive information. </returns> public virtual int isSetprfTarget(string commonID) { return(StateMod_PrfGageData.isSetprfTarget(commonID, __prfGageData)); }