private List <FabStep> BuildForwardStepChange(FabStep step, FabProduct prod) { List <FabStep> list = new List <FabStep>(); FabProduct orgProd = prod; FabStep prevStep = step; while (true) { FabStep nextStep = prevStep.GetNextStep(prod, ref prod); if (nextStep == null) { break; } if (orgProd.ProductID != prod.ProductID) { break; } if (list.Contains(nextStep)) { break; } AddRoute(nextStep, true); list.Add(nextStep); prevStep = nextStep; } return(list); }
/// <summary> /// 가까운 PhotoStep을 찾습니다. /// </summary> /// <returns>찾지못할 경우 Null이 반환됩니다.</returns> public static FabStep GetNextPhotoNearByMe(this FabStep baseStep, FabProduct baseProduct, int stepCnt, out int idx) { FabStep currStep = baseStep; FabProduct currProd = baseProduct; int cnt = 0; while (cnt < stepCnt) { FabStep nextStep = currStep.GetNextStep(currProd, ref currProd); if (nextStep == null) { break; } if (nextStep.StdStep.IsPhoto) { idx = cnt; return(nextStep); } currStep = nextStep; //count : only MandatoryStep if (nextStep.IsMandatoryStep) { cnt++; } } idx = 0; return(null); }
public static List <FabStep> GetNextStepList(this FabStep baseStep, FabProduct baseProduct, int stepCnt = 999) { List <FabStep> list = new List <FabStep>(); FabStep currStep = baseStep; FabProduct currProd = baseProduct; int cnt = 0; while (cnt < stepCnt) { FabStep nextStep = currStep.GetNextStep(currProd, ref currProd); if (nextStep == null) { break; } list.Add(nextStep); currStep = nextStep; cnt++; } return(list); }
private FabStep GetNextStep(FabStep step, FabProduct product, FabPlanInfo plan, ref FabProduct nextProduct) { string eqpID = plan.ResID; var targEqp = ResHelper.FindEqp(eqpID); string eqpGroup = targEqp == null ? null : targEqp.EqpGroup; string runMode = plan.EqpLoadInfo == null ? null : plan.EqpLoadInfo.RunMode; string productID = plan.ProductID; var branchStep = BranchStepMaster.GetBranchStep(eqpGroup, runMode, productID); if (branchStep != null) { var currProd = product; var currStep = step.GetNextStep(currProd, ref currProd); bool existStep = false; while (currStep != null) { if (currStep.StepID == branchStep.NextStepID) { existStep = true; break; } currStep = currStep.GetNextStep(currProd, ref currProd); } if (existStep) { nextProduct = currProd; return(currStep); } } return(step.GetNextStep(product, ref nextProduct)); }
internal static void WriteProductRoute() { foreach (var prod in InputMart.Instance.FabProduct.Values) { //Array제품이 BOP상 CF에도 등록되어 있으므로 제외 if (prod.IsArrayShopProduct() && IsCfShop(prod.ShopID)) { continue; } FabStep firstStep = prod.Process.FirstStep as FabStep; FabProduct nextProd = prod; FabStep currentStep = firstStep; FabStep prvStep = null; float idx = 0; while (true) { idx++; WriteProductRoute(nextProd, currentStep, idx); WriteAdditionalSubStep(nextProd, currentStep, prvStep, idx); FabStep nextStep = currentStep.GetNextStep(nextProd, ref nextProd); if (nextStep == null) { break; } prvStep = currentStep; currentStep = nextStep; if (idx > 200) { break; } } foreach (FabStep step in prod.FabProcess.NonPathSteps.Values) { WriteProductRoute(prod, step, 999); } } }