コード例 #1
0
 public void Add(TnfToDoListDetails tnfToDoListMessage)
 {
     Add(new object[]
     {
         tnfToDoListMessage.MessageOid,
         tnfToDoListMessage.Type,
         tnfToDoListMessage.Value
     });
 }
コード例 #2
0
 public int Update(TnfToDoListDetails tnfToDoListMessage)
 {
     return(Update(new object[]
     {
         tnfToDoListMessage.MessageOid,
         tnfToDoListMessage.Type,
         tnfToDoListMessage.Value
     }));
 }
コード例 #3
0
        private static TnfToDoListDetails ReadObject(IDataRecord reader)
        {
            var tnfToDoListDetails = new TnfToDoListDetails();

            tnfToDoListDetails.MessageOid = reader["message_oid"].FromDbString();
            tnfToDoListDetails.Type       = GetIdentityCode(reader["type"].FromDbString());
            tnfToDoListDetails.Value      = reader["value"].FromDbString();

            return(tnfToDoListDetails);
        }
コード例 #4
0
        public List <TnfToDoListDetails> GetAll(string messageOid)
        {
            var    tnfToDoListDetails = new List <TnfToDoListDetails>();
            string commandText        = String.Format("SELECT * FROM {0} WHERE message_oid = {1}", TnfToDoListDetailsTableName, messageOid);

            using (IDataReader idataReader = Db.ExecuteReader(commandText))
            {
                while (idataReader != null && idataReader.Read())
                {
                    TnfToDoListDetails tnfToDoListDetail = ReadObject(idataReader);
                    tnfToDoListDetails.Add(tnfToDoListDetail);
                }
            }
            return(tnfToDoListDetails);
        }