コード例 #1
0
		/// <summary>
		/// Move the specified object to the specified destination album. This method moves the physical files associated with this
		/// object to the destination album's physical directory. The object's Save() method is invoked to persist the changes to the
		/// data store. When moving albums, all the album's children, grandchildren, etc are also moved. 
		/// The audit fields are automatically updated before saving.
		/// </summary>
		/// <param name="galleryObjectToMove">The gallery object to move.</param>
		/// <param name="destinationAlbum">The album to which the current object should be moved.</param>
		public static void MoveGalleryObject(IGalleryObject galleryObjectToMove, IAlbum destinationAlbum)
		{
			string currentUser = Util.UserName;
			DateTime currentTimestamp = DateTime.Now;

			galleryObjectToMove.LastModifiedByUserName = currentUser;
			galleryObjectToMove.DateLastModified = currentTimestamp;

			galleryObjectToMove.MoveTo(destinationAlbum);
		}
コード例 #2
0
        /// <summary>
        /// Move the specified object to the specified destination album. This method moves the physical files associated with this
        /// object to the destination album's physical directory. The object's Save() method is invoked to persist the changes to the
        /// data store. When moving albums, all the album's children, grandchildren, etc are also moved.
        /// The audit fields are automatically updated before saving.
        /// </summary>
        /// <param name="galleryObjectToMove">The gallery object to move.</param>
        /// <param name="destinationAlbum">The album to which the current object should be moved.</param>
        public static void MoveGalleryObject(IGalleryObject galleryObjectToMove, IAlbum destinationAlbum)
        {
            string   currentUser      = Util.UserName;
            DateTime currentTimestamp = DateTime.Now;

            galleryObjectToMove.LastModifiedByUserName = currentUser;
            galleryObjectToMove.DateLastModified       = currentTimestamp;

            galleryObjectToMove.MoveTo(destinationAlbum);
        }
コード例 #3
0
        /// <summary>
        /// Move the specified object to the specified destination album. This method moves the physical files associated with this
        /// object to the destination album's physical directory. The object's Save() method is invoked to persist the changes to the
        /// data store. When moving albums, all the album's children, grandchildren, etc are also moved.
        /// The audit fields are automatically updated before saving.
        /// </summary>
        /// <param name="galleryObjectToMove">The gallery object to move.</param>
        /// <param name="destinationAlbum">The album to which the current object should be moved.</param>
        /// <exception cref="ArgumentNullException">Thrown when <paramref name="galleryObjectToMove" /> is null.</exception>
        public static void MoveGalleryObject(IGalleryObject galleryObjectToMove, IAlbum destinationAlbum)
        {
            if (galleryObjectToMove == null)
            {
                throw new ArgumentNullException("galleryObjectToMove");
            }

            string   currentUser      = Utils.UserName;
            DateTime currentTimestamp = DateTime.Now;

            galleryObjectToMove.LastModifiedByUserName = currentUser;
            galleryObjectToMove.DateLastModified       = currentTimestamp;

            galleryObjectToMove.MoveTo(destinationAlbum);
        }
コード例 #4
0
        /// <summary>
        /// Move the specified object to the specified destination album. This method moves the physical files associated with this
        /// object to the destination album's physical directory. The object's Save() method is invoked to persist the changes to the
        /// data store. When moving albums, all the album's children, grandchildren, etc are also moved. 
        /// The audit fields are automatically updated before saving.
        /// </summary>
        /// <param name="galleryObjectToMove">The gallery object to move.</param>
        /// <param name="destinationAlbum">The album to which the current object should be moved.</param>
        /// <exception cref="ArgumentNullException">Thrown when <paramref name="galleryObjectToMove" /> is null.</exception>
        public static void MoveGalleryObject(IGalleryObject galleryObjectToMove, IAlbum destinationAlbum)
        {
            if (galleryObjectToMove == null)
                throw new ArgumentNullException("galleryObjectToMove");

            string currentUser = Utils.UserName;
            DateTime currentTimestamp = DateTime.Now;

            galleryObjectToMove.LastModifiedByUserName = currentUser;
            galleryObjectToMove.DateLastModified = currentTimestamp;

            galleryObjectToMove.MoveTo(destinationAlbum);
        }