コード例 #1
0
        public void createEquipeTable()
        {
            EquipeMember eMember = new EquipeMember();

            StringBuilder sbElements = new StringBuilder();
            {
                bool justCreated = true;

                foreach (sqliteBase sElement in eMember.values)
                {
                    if (justCreated)
                    {
                        justCreated = false;
                    }
                    else
                    {
                        sbElements.Append(", ");
                    }
                    sbElements.Append(sElement.valueName + " " + sElement.dataType);
                }
            }

            string sql_command = "CREATE TABLE " + equipeTable + " ( " + sbElements.ToString() + ")";

            SQLiteCommandsExecuter.executeNonQuery(sql_command, Core.AppCore.dCore.M_dbConnection);
        }
コード例 #2
0
        private void UIBtOK_Click(object sender, RoutedEventArgs e)
        {
            EquipeMember eMember = new EquipeMember();

            eMember.name.value = UITbUserName.Text;
            Core.AppCore.dCore.EquipeMemberManager.addMember(eMember);
            this.DialogResult = true;
        }
コード例 #3
0
        public void addMember(EquipeMember eMember)
        {
            Request.RequestBuilder rb = new Request.RequestBuilder(equipeTable);
            rb.addElement(eMember.name.valueName, eMember.name.value);

            SQLiteCommand cmd = Request.CommandBuilder.getCommand(rb, Core.AppCore.dCore.M_dbConnection);

            cmd.ExecuteNonQuery();
        }
コード例 #4
0
        public List <EquipeMember> getEquipeFromReader(SQLiteDataReader reader)
        {
            List <EquipeMember> equipeMemeber = new List <EquipeMember>();

            while (reader.Read())
            {
                EquipeMember mb = new EquipeMember();
                mb.name.value      = reader[mb.name.valueName].ToString();
                mb.elementID.value = int.Parse(reader[mb.elementID.valueName].ToString());


                equipeMemeber.Add(mb);
            }

            return(equipeMemeber);
        }
コード例 #5
0
 public PersonView(EquipeMember eMemb)
 {
     InitializeComponent();
     EquipeMember = eMemb;
     LoadElement();
 }
コード例 #6
0
 public void deleteEquipeMember(EquipeMember member)
 {
     deleteEquipeMember(member.elementID.value);
 }