/// <summary> Removes the sync logic for member _auditInfoActionType</summary>
		/// <param name="signalRelatedEntity">If set to true, it will call the related entity's UnsetRelatedEntity method</param>
		/// <param name="resetFKFields">if set to true it will also reset the FK fields pointing to the related entity</param>
		private void DesetupSyncAuditInfoActionType(bool signalRelatedEntity, bool resetFKFields)
		{
			this.PerformDesetupSyncRelatedEntity( _auditInfoActionType, new PropertyChangedEventHandler( OnAuditInfoActionTypePropertyChanged ), "AuditInfoActionType", NinjaSoftware.Enio.CoolJ.RelationClasses.StaticAuditInfoRelations.AuditInfoActionTypeRoEntityUsingAuditInfoActionTypeIdStatic, true, signalRelatedEntity, "AuditInfoCollection", resetFKFields, new int[] { (int)AuditInfoFieldIndex.AuditInfoActionTypeId } );
			_auditInfoActionType = null;
		}
		/// <summary> setups the sync logic for member _auditInfoActionType</summary>
		/// <param name="relatedEntity">Instance to set as the related entity of type entityType</param>
		private void SetupSyncAuditInfoActionType(IEntityCore relatedEntity)
		{
			if(_auditInfoActionType!=relatedEntity)
			{
				DesetupSyncAuditInfoActionType(true, true);
				_auditInfoActionType = (AuditInfoActionTypeRoEntity)relatedEntity;
				this.PerformSetupSyncRelatedEntity( _auditInfoActionType, new PropertyChangedEventHandler( OnAuditInfoActionTypePropertyChanged ), "AuditInfoActionType", NinjaSoftware.Enio.CoolJ.RelationClasses.StaticAuditInfoRelations.AuditInfoActionTypeRoEntityUsingAuditInfoActionTypeIdStatic, true, new string[] {  } );
			}
		}
		protected AuditInfoEntity(SerializationInfo info, StreamingContext context) : base(info, context)
		{
			if(SerializationHelper.Optimization != SerializationOptimization.Fast) 
			{
				_auditInfoActionType = (AuditInfoActionTypeRoEntity)info.GetValue("_auditInfoActionType", typeof(AuditInfoActionTypeRoEntity));
				if(_auditInfoActionType!=null)
				{
					_auditInfoActionType.AfterSave+=new EventHandler(OnEntityAfterSave);
				}
				_entity = (EntityRoEntity)info.GetValue("_entity", typeof(EntityRoEntity));
				if(_entity!=null)
				{
					_entity.AfterSave+=new EventHandler(OnEntityAfterSave);
				}
				_user = (UserEntity)info.GetValue("_user", typeof(UserEntity));
				if(_user!=null)
				{
					_user.AfterSave+=new EventHandler(OnEntityAfterSave);
				}
				this.FixupDeserialization(FieldInfoProviderSingleton.GetInstance());
			}
			// __LLBLGENPRO_USER_CODE_REGION_START DeserializationConstructor
			// __LLBLGENPRO_USER_CODE_REGION_END
		}