public virtual void RemoveLogins(ApplicationUserLogin __item) { if (__item != null) { __item.User = null; } }
public virtual void InternalRemoveLogins(ApplicationUserLogin __item) { if (__item == null) { return; } logins?.Remove(__item); }
public virtual void InternalAddLogins(ApplicationUserLogin __item) { if (__item == null || disableInternalAdditions) { return; } logins?.Add(__item); }
public virtual void AddLogins(ApplicationUserLogin __item) { if (__item == null) { return; } if (__item.User != this) { __item.User = this; } }
public void DeleteApplicationUserLogin(zAppDev.DotNet.Framework.Identity.Model.ApplicationUserLogin applicationuserlogin, bool doNotCallDeleteForThis = false, bool isCascaded = false, object calledBy = null) { if (applicationuserlogin == null || applicationuserlogin.IsTransient()) { return; } applicationuserlogin.User = null; if (!doNotCallDeleteForThis) { Delete <zAppDev.DotNet.Framework.Identity.Model.ApplicationUserLogin>(applicationuserlogin, isCascaded); } }
public virtual void SetLoginsAt(ApplicationUserLogin __item, int __index) { if (__item == null) { logins[__index].User = null; } else { logins[__index] = __item; if (__item.User != this) { __item.User = this; } } }
public virtual void AddAtIndexLogins(int index, ApplicationUserLogin __item) { if (__item == null) { return; } logins?.Insert(index, __item); disableInternalAdditions = true; try { if (__item.User != this) { __item.User = this; } } finally { disableInternalAdditions = false; } }
/// <summary> /// Returns true if self and the provided entity have the same Id values /// and the Ids are not of the default Id value /// </summary> protected bool HasSameNonDefaultIdAs(ApplicationUserLogin compareTo) { return(!this.IsTransient() && !compareTo.IsTransient() && this.Id.Equals(compareTo.Id)); }
/// <summary> /// Copies the current object to a new instance /// </summary> /// <param name="deep">Copy members that refer to objects external to this class (not dependent)</param> /// <param name="copiedObjects">Objects that should be reused</param> /// <param name="asNew">Copy the current object as a new one, ready to be persisted, along all its members.</param> /// <param name="reuseNestedObjects">If asNew is true, this flag if set, forces the reuse of all external objects.</param> /// <param name="copy">Optional - An existing [ApplicationUserLogin] instance to use as the destination.</param> /// <returns>A copy of the object</returns> public virtual ApplicationUserLogin Copy(bool deep = false, Hashtable copiedObjects = null, bool asNew = false, bool reuseNestedObjects = false, ApplicationUserLogin copy = null) { if (copiedObjects == null) { copiedObjects = new Hashtable(); } if (copy == null && copiedObjects.Contains(this)) { return((ApplicationUserLogin)copiedObjects[this]); } copy = copy ?? new ApplicationUserLogin(); if (!asNew) { copy.TransientId = this.TransientId; copy.Id = this.Id; } copy.LoginProvider = this.LoginProvider; copy.ProviderKey = this.ProviderKey; if (!copiedObjects.Contains(this)) { copiedObjects.Add(this, copy); } if (deep && this.user != null) { if (!copiedObjects.Contains(this.user)) { if (asNew && reuseNestedObjects) { copy.User = this.User; } else if (asNew) { copy.User = this.User.Copy(deep, copiedObjects, true); } else { copy.user = this.user.Copy(deep, copiedObjects, false); } } else { if (asNew) { copy.User = (ApplicationUser)copiedObjects[this.User]; } else { copy.user = (ApplicationUser)copiedObjects[this.User]; } } } return(copy); }