/// <summary> /// 更新一条数据 /// </summary> public bool Update() { StringBuilder strSql = new StringBuilder(); strSql.Append("update LOGINUSER set "); strSql.Append("USERNAME='******',"); strSql.Append("EMAIL='" + EMAIL + "',"); strSql.Append("PASSWORD='******'"); strSql.Append(" where USERID='" + USERID + "' "); CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { pComm.Execute(strSql.ToString());//执行Sql语句无返回值 pComm.Close(); return(true); } catch (System.Exception e) { pComm.Close(); throw e; } }
//计算客户订单中产品所需要用到的生产领料用量--组件的领料用量(上线零件要加载出子件) public DataTable CalcMaterialDrawPlan2(string strDrawPlanGuID) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@DrawPlanGuID"; par[0, 1] = strDrawPlanGuID; dset = pComm.ExcuteSp("sp_GetMaterialDataByDrawPlanCalc2", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 得到所有产品类另信息 /// </summary> /// <returns>pDTMain 字段信息集</returns> public DataTable GetChangeBillDataAttachmentByGuID(string GuID) { string ps_Sql = ""; DataTable pDTMain = new DataTable(); CommonInterface pObj_Comm = CommonFactory.CreateInstance(CommonData.sql); try { ps_Sql = " select ChangeBillDataAttachmentGuID,ChangeBillGuID,FileGuID,FileSourceName,FileContent " + " from ChangeBillDataAttachment where ChangeBillDataAttachmentGuID='" + GuID + "' order by SortID"; pDTMain = pObj_Comm.ExeForDtl(ps_Sql); pObj_Comm.Close(); return(pDTMain); } catch (Exception e) { pObj_Comm.Close(); throw e; } }
//计算无BOM的物料需求计划 public DataTable sp_Calc_NoBOM(string BomPlanGuid) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@MaterialMRPPlanGuID"; par[0, 1] = BomPlanGuid; dset = pComm.ExcuteSp("sp_Calc_NoBOM", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
//调用存储过程,得到某个物料BOM子件,以Table形式加载 public DataTable sp_GetMaterialBomData_BomQry2(String MaterialID) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@MaterialFatherGuid"; par[0, 1] = MaterialID; dset = pComm.ExcuteSp("sp_GetMaterialBomData_BomQry2", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 将子类别全部置为一级类别名称 /// </summary> /// <param name="FileType"></param> /// <returns></returns> public void GetSubFileType2(string FileType) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { //DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@FileType"; par[0, 1] = FileType; pComm.ExcuteSp("sp_GetSubFileType2", par); pComm.Close(); // return dset.Tables[0]; } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 得到某个物料入库的所有批号情况 /// </summary> /// <param name="MaterialGuid"></param> /// <param name="StorageID"></param> public DataTable sp_GetStorageSumBatchNo(string MaterialGuid) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@MaterialGuID"; par[0, 1] = MaterialGuid; dset = pComm.ExcuteSp("sp_GetStorageSumBatchNo", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 领料单统计报表 /// </summary> /// <param name="strsql"></param> /// <returns></returns> public DataTable sp_DrawOrder_Report(string strWheresql) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@strWheresql"; par[0, 1] = strWheresql; dset = pComm.ExcuteSp("sp_DrawOrder_Report", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
//生成一个产品下面所有的子件 public DataSet sp_GetMaterialBomConsume(String Materialfatherguid) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@MaterialFatherGuid"; par[0, 1] = Materialfatherguid; dset = pComm.ExcuteSp("sp_GetMaterialBomConsume", par); pComm.Close(); return(dset); } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 得到客户订单主表数据--供物料需求计划调用 /// </summary> /// <param name="FatherMaterialGuid"></param> /// <returns></returns> public DataTable GetClientOrderBySelect(string strsql) { string ps_Sql = ""; DataTable pDTMain = new DataTable(); CommonInterface pObj_Comm = CommonFactory.CreateInstance(CommonData.sql); try { ps_Sql = "select 'False' as selectvalue, ClientOrderGuid,ClientOrderDetailGuid, ClientOrderID," + "ClientOrderDate, MaterialGuid, MaterialID, MaterialName, Spec, MaterialSum " + " from V_SelectClientOrder " + strsql + " order by CreateDate desc"; pDTMain = pObj_Comm.ExeForDtl(ps_Sql); pObj_Comm.Close(); return(pDTMain); } catch (Exception e) { pObj_Comm.Close(); throw e; } }
/// <summary> /// 得到生产领料计划数据 /// </summary> /// <param name="FatherMaterialGuid"></param> /// <returns></returns> public DataTable GetDrawPlanBySQL(string strsql) { string ps_Sql = ""; DataTable pDTMain = new DataTable(); CommonInterface pObj_Comm = CommonFactory.CreateInstance(CommonData.sql); try { ps_Sql = " select DrawPlanGuid,DrawPlanID as 生产领料计划单号,DrawPlanDate as 计算日期,Remark as 备注 ," + " ( select UserName from LoginUser where UserID=CreateGuid) as 制单人," + " convert(nvarchar(10),CreateDate,120) as 制单日期 from DrawPlan " + strsql + " order by CreateDate desc"; pDTMain = pObj_Comm.ExeForDtl(ps_Sql); pObj_Comm.Close(); return(pDTMain); } catch (Exception e) { pObj_Comm.Close(); throw e; } }
/// <summary> /// 得到数据-收发类型汇总表(包括出入库,调拨) /// </summary> /// <param name="strsql">查询条件仓库</param> /// <param name="strsql2">查询条件调拨</param> /// <param name="depot">仓库名</param> /// <returns></returns> public DataTable sp_GetDepotClassTypeDetailSum(string BeginDate, string EndDate, string Depot, string BarNo, string MaterialID, string MaterialName, string Spec, string Classid) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[8, 2]; par[0, 0] = "@BeginDate"; par[0, 1] = BeginDate; par[1, 0] = "@EndDate"; par[1, 1] = EndDate; par[2, 0] = "@Depot"; par[2, 1] = Depot; par[3, 0] = "@BarNo"; par[3, 1] = BarNo; par[4, 0] = "@MaterialID"; par[4, 1] = MaterialID; par[5, 0] = "@MaterialName"; par[5, 1] = MaterialName; par[6, 0] = "@Spec"; par[6, 1] = Spec; par[7, 0] = "@ClassID"; par[7, 1] = Classid; dset = pComm.ExcuteSp("sp_GetDepotClassTypeDetailSum", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
private void butLogin_Click(object sender, EventArgs e) { String sUserCode = txtUser.Text.Trim(); string sPassWord = MD5(txtPwd.Text.Trim()).ToLower(); string SqlOraStr = "SELECT USERID,USERNAME FROM T_USER A WHERE USERCODE = '" + sUserCode + "' AND PASSWORD ='******'"; CommonInterface pObj_Comm = CommonFactory.CreateInstance(CommonData.Oracle); try { DataTable pDTMain = pObj_Comm.ExeForDtl(SqlOraStr); pObj_Comm.Close(); if (pDTMain.Rows.Count != 0) //&&(myDs.Tables[0] !=null) { //this.Parent.Container.Add(new frmMain()); frmMain mMain = new frmMain(); Global.tUser._UserId = pDTMain.Rows[0]["USERID"].ToString(); Global.tUser._UserName = pDTMain.Rows[0]["USERNAME"].ToString(); mMain.Show(); this.Hide(); RegistryKey regkey = Registry.CurrentUser.CreateSubKey("EiipInfo"); regkey.SetValue("UserName", sUserCode); regkey.Close(); } else { MessageBox.Show("用户名密码不正确!", "错误", MessageBoxButtons.OK, MessageBoxIcon.Hand, MessageBoxDefaultButton.Button1); } } catch (Exception ex) { pObj_Comm.Close(); throw ex; } }
///<summary> /// 保存组的功能模块权限 /// </summary> /// <param name="tableid">SQL查询条件</param> /// <returns>存放查询结果的DataTable</returns> public void SaveGroupFunctionRight(List <string> lstGroup, List <GroupRightSet> lstFunctionRight) { string StrSQL = ""; GroupRightSet GroupRightSet = new GroupRightSet(); CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { pComm.BeginTrans(); for (int i = 0; i < lstGroup.Count; i++) { //先删除此组原来属于的功能权限 StrSQL = "delete from GroupRightSet where GroupID='" + lstGroup[i] + "'"; pComm.Execute(StrSQL); //再添加此组属于的功能权限 for (int j = 0; j < lstFunctionRight.Count; j++) { GroupRightSet = lstFunctionRight[j] as GroupRightSet; StrSQL = " insert into GroupRightSet(GroupID,ModuleID,FunctionID,FunctionRight) values('" + lstGroup[i] + "','" + GroupRightSet.ModuleID + "','" + GroupRightSet.FunctionID + "'," + GroupRightSet.FunctionRight.ToString() + ")"; pComm.Execute(StrSQL); } } pComm.CommitTrans(); pComm.Close(); } catch (Exception e) { pComm.RollbackTrans(); pComm.Close(); throw e; } }
/// <summary> /// 得到订单是否已审核或已结单- /// </summary> /// <param name="FatherMaterialGuid"></param> /// <returns></returns> public bool GetIsCheck(string StockOrderGuid) { string ps_Sql = ""; DataTable pDTMain = new DataTable(); CommonInterface pObj_Comm = CommonFactory.CreateInstance(CommonData.sql); try { ps_Sql = " select StockOrderGuid,CheckGuid,EndGuid from StockOrder where StockOrderGuid='" + StockOrderGuid + "' "; pDTMain = pObj_Comm.ExeForDtl(ps_Sql); pObj_Comm.Close(); if (pDTMain.Rows.Count > 0) { if (pDTMain.Rows[0]["CheckGuid"].ToString().Trim() != "") { return(true); } if (pDTMain.Rows[0]["EndGuid"].ToString().Trim() != "") { return(true); } return(false); } else { return(true); } } catch (Exception e) { pObj_Comm.Close(); throw e; } }
/// <summary> /// 得到所有产品类另信息--供料件选择用 /// </summary> /// <returns>pDTMain 字段信息集</returns> public DataTable GetSelectMaterialData_CN(string strsql) { string ps_Sql = ""; DataTable pDTMain = new DataTable(); CommonInterface pObj_Comm = CommonFactory.CreateInstance(CommonData.sql); try { ps_Sql = ps_Sql = " select 'False' as selectvalue,MaterialGuid ,MaterialId as 物料编号,MaterialName 物料名称, " + " (select InterName from StorageClass where InterId=ClassId) as 分类," + " (select UnitName from BasicData where UnitID=Spec ) as 规格,Price as 单价,PicID as 图号,ClientID as 客户编号," + " case when IsEnable=1 then '停用' else '正常' end as 状态 from Material " + strsql + " order by MaterialId"; pDTMain = pObj_Comm.ExeForDtl(ps_Sql); pObj_Comm.Close(); return(pDTMain); } catch (Exception e) { pObj_Comm.Close(); throw e; } }
//将生产领料计划中选择的物料放入到临时表进行计算 public void InsertIntoSelectMaterial(string strDrawPlanGuID, string strMaterialGuid, decimal decMaterialSum) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { StringBuilder strSql = new StringBuilder(); strSql.Append("insert into Temp_DrawPlanCalcMaterialBom("); strSql.Append("DrawPlanGuID,MaterialGuid,MaterialSum "); strSql.Append(")"); strSql.Append(" values ("); strSql.Append("'" + strDrawPlanGuID + "',"); strSql.Append("'" + strMaterialGuid + "',"); strSql.Append("" + decMaterialSum + ""); strSql.Append(")"); pComm.Execute(strSql.ToString()); pComm.Close(); } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 更新一条数据 /// </summary> public bool Update() { StringBuilder strSql = new StringBuilder(); strSql.Append("update Depot set "); strSql.Append("DepotName='" + DepotName + "',"); strSql.Append("DepotPerson='" + DepotPerson + "',"); strSql.Append("Telephone='" + Telephone + "',"); strSql.Append("Remark='" + Remark + "'"); strSql.Append(" where DepotGuid='" + DepotGuid + "' "); CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { pComm.Execute(strSql.ToString());//执行Sql语句无返回值 pComm.Close(); return(true); } catch (System.Exception e) { pComm.Close(); throw e; } }
//调用存储过程,得到某个物料BOM子件,以Table形式加载 public DataTable sp_GetOneStorageSumDataByYJ2(string StorageID) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@StorageID"; par[0, 1] = StorageID; dset = pComm.ExcuteSp("sp_GetOneStorageSumDataByYJ2", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
///<summary> /// 输入条件返回结果查询 /// </summary> /// <param name="tableid">SQL查询条件</param> /// <returns>存放查询结果的DataTable</returns> public int GetAutoIDAdd(string flag) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { //更新缺陷自增号 string StrSQL = "update BillAutoID set BillAutoID=BillAutoID+1 where flag='" + flag + "'"; pComm.Execute(StrSQL); //得到自增后的号 DataTable dtl = new DataTable(); StrSQL = " select BillAutoID from BillAutoID where flag='" + flag + "'"; dtl = pComm.ExeForDtl(StrSQL); pComm.Close(); return(int.Parse(dtl.Rows[0]["BillAutoID"].ToString())); } catch (Exception e) { pComm.Close(); throw e; } }
//采购入库单号,付款单从采购入库单中选择 public DataTable sp_GetSelectStockInOrder(string PaymentID) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[1, 2]; par[0, 0] = "@PaymentID"; par[0, 1] = PaymentID; dset = pComm.ExcuteSp("sp_GetSelectStockInOrder", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 检测用户名与密码正确性 /// </summary> /// <param name="userid"></param> /// <param name="password"></param> /// <returns></returns> public bool CheckUserPassword(string userid, string password) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataTable dtl = new DataTable(); string StrSQL = " select userid,password from LoginUser where userid='" + userid + "'"; dtl = pComm.ExeForDtl(StrSQL); pComm.Close(); //校验密码正确性 if (dtl.Rows.Count > 0) { string password2 = EncryptDES(password, "ABCD1234"); //用户输入的密码 if (password2 != dtl.Rows[0]["PASSWORD"].ToString()) //用户输入的密码与数据库中密码比较 { return(true); } else { return(false); } } else { return(false); } } catch (Exception e) { pComm.Close(); throw e; } }
///<summary> /// 输入条件返回结果查询 /// </summary> /// <param name="tableid">SQL查询条件</param> /// <returns>存放查询结果的DataTable</returns> public void DeleteSyslog(List <string> lst) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { pComm.BeginTrans(); string StrSQL = ""; for (int i = 0; i < lst.Count; i++) { StrSQL = " delete from SystemLog where NoID='" + lst[i] + "'"; pComm.Execute(StrSQL); } pComm.CommitTrans(); pComm.Close(); } catch (Exception e) { pComm.RollbackTrans(); pComm.Close(); throw e; } }
/// <summary> /// 库存明细报表 /// </summary> /// <param name="MaterialGuid"></param> /// <param name="StorageID"></param> public DataTable StockDetailReport(string MaterialGuid, string StorageID) { CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataSet dset = new DataSet(); string[,] par; par = new string[2, 2]; par[0, 0] = "@Depot"; par[0, 1] = StorageID; par[1, 0] = "@MaterialGuID"; par[1, 1] = MaterialGuid; dset = pComm.ExcuteSp("sp_GetStorageMaterialDetailSum", par); pComm.Close(); return(dset.Tables[0]); } catch (Exception e) { pComm.Close(); throw e; } }
/// <summary> /// 是否停用 /// </summary> public bool IsEnable(string USERID) { string IsEnable = ""; StringBuilder strSql = new StringBuilder(); strSql.Append("select IsEnable from LOGINUSER where USERID='" + USERID + "'"); CommonInterface pComm = CommonFactory.CreateInstance(CommonData.sql); try { DataTable dtl = new DataTable(); dtl = pComm.ExeForDtl(strSql.ToString()); pComm.Close(); if (dtl.Rows.Count > 0) { IsEnable = dtl.Rows[0]["IsEnable"].ToString(); if (IsEnable.Trim() == "1") { return(true); } else { return(false); } } else { return(false); } } catch (System.Exception e) { pComm.Close(); throw e; } }
public PriorSample() : this(CommonFactory.CreateRandom()) { }
private void button1_Click(object sender, EventArgs e) { string sDateFrom = dtpDateFrom.Value.ToString("yyyyMMdd"); string sDateTo = dtpDateTo.Value.ToString("yyyyMMdd"); string[] _Parameters = new string[4] { "as_datefrom", "as_dateto", "an_deptid", "aors" }; string[] _ParametersValue = new string[4] { sDateFrom, sDateTo, "24", "" }; string[] _ParametersType = new string[4] { "Varchar2", "Varchar2", "Varchar2", "RefCursor" }; string[] _ParametersDirection = new string[4] { "Input", "Input", "Input", "Output" }; /* * try * { * OracleConnection _connObj = new OracleConnection(ConfigurationSettings.AppSettings["ConnStr"]); * _connObj.Open(); * OracleCommand _cmdObj = _connObj.CreateCommand(); * _cmdObj.CommandText = "CX_SALE.cur_fin_fee_sum"; * _cmdObj.CommandType = CommandType.StoredProcedure; * * OracleParameter _refParam1 = new OracleParameter(); * _refParam1.ParameterName = "as_datefrom"; * _refParam1.OracleDbType = OracleDbType.Varchar2; * _refParam1.Direction = ParameterDirection.Input; * _refParam1.Value = "20170701"; * _cmdObj.Parameters.Add(_refParam1); * * OracleParameter _refParam2 = new OracleParameter(); * _refParam2.ParameterName = "as_dateto"; * _refParam2.OracleDbType = OracleDbType.Varchar2; * _refParam2.Direction = ParameterDirection.Input; * _refParam1.Value = "20170710"; * _cmdObj.Parameters.Add(_refParam2); * * OracleParameter _refParam3 = new OracleParameter(); * _refParam3.ParameterName = "an_deptid"; * _refParam3.OracleDbType = OracleDbType.Varchar2; * _refParam3.Direction = ParameterDirection.Input; * _refParam3.Value = "24"; * _cmdObj.Parameters.Add(_refParam3); * * OracleParameter _refParam = new OracleParameter(); * _refParam.ParameterName = "aors"; * _refParam.OracleDbType = OracleDbType.RefCursor; * _refParam.Direction = ParameterDirection.Output; * _cmdObj.Parameters.Add(_refParam); * * OracleDataAdapter _adapterObj = new OracleDataAdapter(_cmdObj); * DataSet _datasetObj = new DataSet(); * _adapterObj.Fill(_datasetObj); * gridControl1.DataSource = _datasetObj.Tables[0]; * * _connObj.Close(); * _connObj.Dispose(); * _connObj = null; * * } * catch (Exception ex) * { * MessageBox.Show(ex.ToString()); * } * * */ CommonInterface pObj_Comm = CommonFactory.CreateInstance(CommonData.Oracle); try { DataTable pDTMain = pObj_Comm.ExecuteSPSursor("CX_SALE.cur_fin_fee_sum", _Parameters, _ParametersValue, _ParametersType, _ParametersDirection).Tables[0]; gridControl1.DataSource = pDTMain; pObj_Comm.Close(); } catch (Exception ex) { pObj_Comm.Close(); throw ex; } }
/// <summary> Creates a new Rock Game Object from an existing one (FlyWeight Pattern). </summary> /// <param name="position"> The position to create the Game Object in. </param> /// <returns> The new created Rock. </returns> public GameObject CreateRock(Vector2 position) { return(CommonFactory.CreateCommonObject(flyWeightRock, "Rock", position)); }
public void checkForPossibleAnswers(ISet <Clause> resolvents) { // If no bindings being looked for, then // is just a true false query. foreach (Clause aClause in resolvents) { if (answerClause.isEmpty()) { if (aClause.isEmpty()) { proofs.Add(new ProofFinal(aClause.getProofStep(), CollectionFactory.CreateMap <Variable, Term>())); complete = true; } } else { if (aClause.isEmpty()) { // This should not happen // as added an answer literal, which // implies the database (i.e. premises) are // unsatisfiable to begin with. throw new IllegalStateException("Generated an empty clause while looking for an answer, implies original KB is unsatisfiable"); } if (aClause.isUnitClause() && aClause.isDefiniteClause() && aClause .getPositiveLiterals() .Get(0) .getAtomicSentence() .getSymbolicName() .Equals(answerLiteral.getAtomicSentence() .getSymbolicName())) { IMap <Variable, Term> answerBindings = CollectionFactory.CreateMap <Variable, Term>(); ICollection <Term> answerTerms = aClause.getPositiveLiterals().Get(0).getAtomicSentence().getArgs(); int idx = 0; foreach (Variable v in answerLiteralVariables) { answerBindings.Put(v, answerTerms.Get(idx)); idx++; } bool addNewAnswer = true; foreach (Proof p in proofs) { if (p.getAnswerBindings().SequenceEqual(answerBindings)) { addNewAnswer = false; break; } } if (addNewAnswer) { proofs.Add(new ProofFinal(aClause.getProofStep(), answerBindings)); } } } if (CommonFactory.Now().BiggerThan(finishTime)) { complete = true; // Indicate that I have run out of query time timedOut = true; } } }
/// <summary> Creates a Cactus Game Object from an existing one (FlyWeight Pattern). </summary> /// <param name="position"> The position to create object in. </param> /// <returns> The new Cactus Game Object. </returns> public GameObject CreateCactus(Vector2 position) { return(CommonFactory.CreateCommonObject(flyWeightCactus, "Cactus", position)); }