شركة التطبيقات المتكاملة لتصميم النظم البرمجية الخاصة ش.ش.و.

Integrated Applications Programming Company

Skip Navigation LinksHome » Code Library » Koran

Public general use code classes and xml files that we've compiled and used over the years:

Koran Koran Reference Network Class Library support functions: Entity model

   1:  using System;
   2:  using System.Collections.Generic;
   3:  using System.Linq;
   4:  using System.Web;
   5:  using System.ComponentModel.DataAnnotations;
   6:  using System.ComponentModel.DataAnnotations.Schema;
   7:   
   8:  namespace Ia.Islamic.Cl.Model
   9:  {
  10:      ////////////////////////////////////////////////////////////////////////////
  11:   
  12:      /// <summary publish="true">
  13:      /// Koran Koran Reference Network Class Library support functions: Entity model
  14:      /// </summary>
  15:      /// <value>
  16:      /// https://msdn.microsoft.com/en-us/library/z1hkazw7(v=vs.100).aspx
  17:      /// </value>
  18:      /// <remarks> 
  19:      /// Copyright © 2001-2015 Jasem Y. Al-Shamlan (info@ia.com.kw), Integrated Applications - Kuwait. All Rights Reserved.
  20:      ///
  21:      /// This library is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by
  22:      /// the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
  23:      ///
  24:      /// This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
  25:      /// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
  26:      /// 
  27:      /// You should have received a copy of the GNU General Public License along with this library. If not, see http://www.gnu.org/licenses.
  28:      /// 
  29:      /// Copyright notice: This notice may not be removed or altered from any source distribution.
  30:      /// </remarks> 
  31:      public class Koran
  32:      {
  33:          /// <summary/>
  34:          public Koran() 
  35:          {
  36:              Chapters = new List<Ia.Islamic.Cl.Model.Chapter>();
  37:          }
  38:   
  39:          /// <summary/>
  40:          [Key, DatabaseGenerated(DatabaseGeneratedOption.None)]
  41:          public string Id { get; set; }
  42:   
  43:          /// <summary/>
  44:          public string Name { get; set; }
  45:   
  46:          /// <summary/>
  47:          public string LanguageIso { get; set; }
  48:   
  49:          /// <summary/>
  50:          public string Introduction { get; set; }
  51:   
  52:          /// <summary/>
  53:          public virtual ICollection<Chapter> Chapters { get; set; }
  54:   
  55:          ////////////////////////////////////////////////////////////////////////////
  56:   
  57:          /// <summary>
  58:          ///
  59:          /// </summary>
  60:          public bool IsUpdated(Ia.Islamic.Cl.Model.Koran updatedKoran)
  61:          {
  62:              bool updated;
  63:   
  64:              updated = false;
  65:   
  66:              //if (this.Chapters != updatedKoran.Chapters) { this.Chapters = updatedKoran.Chapters; updated = true; }
  67:              if (this.Introduction != updatedKoran.Introduction) { this.Introduction = updatedKoran.Introduction; updated = true; }
  68:              if (this.LanguageIso != updatedKoran.LanguageIso) { this.LanguageIso = updatedKoran.LanguageIso; updated = true; }
  69:              if (this.Name != updatedKoran.Name) { this.Name = updatedKoran.Name; updated = true; }
  70:   
  71:              return updated;
  72:          }
  73:   
  74:          ////////////////////////////////////////////////////////////////////////////
  75:          ////////////////////////////////////////////////////////////////////////////
  76:      }
  77:  }