Esempio n. 1
0
        public PatientInBedRoom GetObjectByKey(object keypair)
        {
            if (this.Contains(GetKey(keypair)) == false)
            {
                return(null);
            }
            PatientInBedRoom ob = this[GetKey(keypair)];

            return((PatientInBedRoom)ob);
        }
Esempio n. 2
0
        public PatientInBedRoom GetObjectByKey(long k_PtInBdRmID)
        {
            if (this.Contains(GetKey(k_PtInBdRmID)) == false)
            {
                return(null);
            }
            PatientInBedRoom ob = this[GetKey(k_PtInBdRmID)];

            return((PatientInBedRoom)ob);
        }
Esempio n. 3
0
        public PatientInBedRoom GetObjectByKey(KeyValuePair <string, long> keypair)
        {
            if (this.Contains(keypair) == false)
            {
                return(null);
            }
            PatientInBedRoom ob = this[keypair];

            return((PatientInBedRoom)ob);
        }
Esempio n. 4
0
        public bool ChangeItem(KeyValuePair <string, long> keypair, PatientInBedRoom item)
        {
            PatientInBedRoom orig = this.GetObjectByKey(keypair);

            if (orig != null)
            {
                int index = this.IndexOf(orig);
                this.SetItem(index, item);

                return(true);
            }

            return(false);
        }
Esempio n. 5
0
        public PatientInBedRoom GetObjectByKey(long k_PtInBdRmID, LV.Core.DAL.Base.IRepository repository)
        {
            if (this.Contains(GetKey(k_PtInBdRmID)) == false)
            {
                PatientInBedRoom ob = repository.GetQuery <PatientInBedRoom>().FirstOrDefault(o => o.PtInBdRmID == k_PtInBdRmID);
                if (ob != null)
                {
                    this.Add(ob);
                }
                return(ob);
            }
            PatientInBedRoom obj = this[GetKey(k_PtInBdRmID)];

            return((PatientInBedRoom)obj);
        }
Esempio n. 6
0
        public bool DeleteObject(PatientInBedRoom item, LV.Core.DAL.Base.IRepository repository)
        {
            repository.Update(item);

            return(true);
        }
Esempio n. 7
0
        public bool AddObject(PatientInBedRoom item, LV.Core.DAL.Base.IRepository repository)
        {
            repository.Add(item);

            return(true);
        }
Esempio n. 8
0
 protected override KeyValuePair <string, long> GetKeyForItem(PatientInBedRoom item)
 {
     return(item.Key);
 }