aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Tango.PPC.Common/FileSystem/FileSystemOperation.cs
blob: 9fba7a8745d6142ba11fe98f0b88440b14799588 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight .c { color: #888888 } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error */
.highlight .k { color: #008800; font-weight: bold } /* Keyword */
.highlight .ch { color: #888888 } /* Comment.Hashbang */
.highlight .cm { color: #888888 } /* Comment.Multiline */
.highlight .cp { color: #cc0000; font-weight: bold } /* Comment.Preproc */
.highlight .cpf { color: #888888 } /* Comment.PreprocFile */
.highlight .c1 { color: #888888 } /* Comment.Single */
.highlight .cs { color: #cc0000; font-weight: bold; background-color: #fff0f0 } /* Comment.Special */
.highlight .gd { color: #000000; background-color: #ff
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Tango.PPC.Common.FileSystem
{
    /// <summary>
    /// Represents an active file system file/folder download/upload operation 
    /// </summary>
    public class FileSystemOperation
    {
        /// <summary>
        /// Gets or sets the operation mode.
        /// </summary>
        public FileSystemOperationMode Mode { get; set; }

        /// <summary>
        /// Gets or sets the operation identifier.
        /// </summary>
        public String Id { get; set; }

        /// <summary>
        /// Gets or sets the path for the operation.
        /// </summary>
        public String Path { get; set; }

        /// <summary>
        /// Should be set to true when the <see cref="Path"/> is a temporary zip file when performing download of a folder.
        /// </summary>
        public bool IsPathTempZip { get; set; }

        /// <summary>
        /// Gets or sets the actual path to extract the zip file when uploading folder.
        /// </summary>
        public String UploadPostPath { get; set; }

        /// <summary>
        /// Initializes a new instance of the <see cref="FileSystemOperation"/> class.
        /// </summary>
        /// <param name="mode">The mode.</param>
        /// <param name="path">The path.</param>
        public FileSystemOperation(FileSystemOperationMode mode, String path)
        {
            Mode = mode;
            Id = Guid.NewGuid().ToString();
            Path = path;
        }
    }
}