Exemple #1
0
 /// <summary>
 /// Clones this MetaFirstNameGenderLookup object to a new MetaFirstNameGenderLookup object
 /// </summary>
 /// <param name="source">The source.</param>
 /// <param name="deepCopy">if set to <c>true</c> a deep copy is made. If false, only the basic entity properties are copied.</param>
 /// <returns></returns>
 public static MetaFirstNameGenderLookup Clone(this MetaFirstNameGenderLookup source, bool deepCopy)
 {
     if (deepCopy)
     {
         return(source.Clone() as MetaFirstNameGenderLookup);
     }
     else
     {
         var target = new MetaFirstNameGenderLookup();
         target.CopyPropertiesFrom(source);
         return(target);
     }
 }
        /// <summary>
        /// Clones this MetaFirstNameGenderLookup object to a new MetaFirstNameGenderLookup object with default values for the properties in the Entity and Model base classes.
        /// </summary>
        /// <param name="source">The source.</param>
        /// <returns></returns>
        public static MetaFirstNameGenderLookup CloneWithoutIdentity(this MetaFirstNameGenderLookup source)
        {
            var target = new MetaFirstNameGenderLookup();

            target.CopyPropertiesFrom(source);

            target.Id          = 0;
            target.Guid        = Guid.NewGuid();
            target.ForeignKey  = null;
            target.ForeignId   = null;
            target.ForeignGuid = null;

            return(target);
        }
Exemple #3
0
 /// <summary>
 /// Copies the properties from another MetaFirstNameGenderLookup object to this MetaFirstNameGenderLookup object
 /// </summary>
 /// <param name="target">The target.</param>
 /// <param name="source">The source.</param>
 public static void CopyPropertiesFrom(this MetaFirstNameGenderLookup target, MetaFirstNameGenderLookup source)
 {
     target.Id            = source.Id;
     target.Country       = source.Country;
     target.FemaleCount   = source.FemaleCount;
     target.FemalePercent = source.FemalePercent;
     target.FirstName     = source.FirstName;
     target.ForeignGuid   = source.ForeignGuid;
     target.ForeignKey    = source.ForeignKey;
     target.Language      = source.Language;
     target.MaleCount     = source.MaleCount;
     target.MalePercent   = source.MalePercent;
     target.TotalCount    = source.TotalCount;
     target.Guid          = source.Guid;
     target.ForeignId     = source.ForeignId;
 }